Skip to content

Commit

Permalink
Use same naming strategy as for cluster
Browse files Browse the repository at this point in the history
  • Loading branch information
feloy committed Nov 23, 2022
1 parent 4adb74e commit 63daaed
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pkg/dev/podmandev/pod.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,15 +44,15 @@ func createPodFromComponent(
Name: storage.OdoSourceVolume,
VolumeSource: corev1.VolumeSource{
PersistentVolumeClaim: &corev1.PersistentVolumeClaimVolumeSource{
ClaimName: getVolumeName(componentName, appName, "source"),
ClaimName: getVolumeName(componentName, appName, "odo-projects"),
},
},
},
{
Name: storage.SharedDataVolumeName,
VolumeSource: corev1.VolumeSource{
PersistentVolumeClaim: &corev1.PersistentVolumeClaimVolumeSource{
ClaimName: getVolumeName(componentName, appName, "shared"),
ClaimName: getVolumeName(componentName, appName, "odo-shared"),
},
},
},
Expand Down Expand Up @@ -97,7 +97,7 @@ func createPodFromComponent(
}

func getVolumeName(componentName string, appName string, volume string) string {
return "odo-projects-" + componentName + "-" + appName + "-" + volume
return volume + "-" + componentName + "-" + appName
}

func addHostPorts(containers []corev1.Container) []api.ForwardedPort {
Expand Down

0 comments on commit 63daaed

Please sign in to comment.