Skip to content

Commit

Permalink
Merge pull request #454 from dprince/custom_vol_source
Browse files Browse the repository at this point in the history
Update to new lib-common VolumeSource structs
  • Loading branch information
openshift-merge-bot[bot] authored Nov 5, 2024
2 parents 5217665 + 6e8278d commit 54d6e95
Show file tree
Hide file tree
Showing 16 changed files with 15 additions and 3,008 deletions.
300 changes: 0 additions & 300 deletions api/bases/cinder.openstack.org_cinderapis.yaml

Large diffs are not rendered by default.

300 changes: 0 additions & 300 deletions api/bases/cinder.openstack.org_cinderbackups.yaml

Large diffs are not rendered by default.

300 changes: 0 additions & 300 deletions api/bases/cinder.openstack.org_cinders.yaml

Large diffs are not rendered by default.

300 changes: 0 additions & 300 deletions api/bases/cinder.openstack.org_cinderschedulers.yaml

Large diffs are not rendered by default.

300 changes: 0 additions & 300 deletions api/bases/cinder.openstack.org_cindervolumes.yaml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion api/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ go 1.21

require (
github.com/openstack-k8s-operators/lib-common/modules/common v0.5.1-0.20241029151503-4878b3fa3333
github.com/openstack-k8s-operators/lib-common/modules/storage v0.4.1-0.20241014140317-e5c35d28f3af
github.com/openstack-k8s-operators/lib-common/modules/storage v0.5.1-0.20241104140916-71a0e9d9766d
golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56
k8s.io/api v0.29.10
k8s.io/apimachinery v0.29.10
Expand Down
4 changes: 2 additions & 2 deletions api/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@ github.com/onsi/gomega v1.34.1 h1:EUMJIKUjM8sKjYbtxQI9A4z2o+rruxnzNvpknOXie6k=
github.com/onsi/gomega v1.34.1/go.mod h1:kU1QgUvBDLXBJq618Xvm2LUX6rSAfRaFRTcdOeDLwwY=
github.com/openstack-k8s-operators/lib-common/modules/common v0.5.1-0.20241029151503-4878b3fa3333 h1:yejekTWudX5af3mCJQ1MUPLEa0X6sIsklf07o9KilRk=
github.com/openstack-k8s-operators/lib-common/modules/common v0.5.1-0.20241029151503-4878b3fa3333/go.mod h1:YpNTuJhDWhbXM50O3qBkhO7M+OOyRmWkNVmJ4y3cyFs=
github.com/openstack-k8s-operators/lib-common/modules/storage v0.4.1-0.20241014140317-e5c35d28f3af h1:l8GXJhv4P/fy7Amz9XPEi8sn+hvxrQf1gICpmOaqOuE=
github.com/openstack-k8s-operators/lib-common/modules/storage v0.4.1-0.20241014140317-e5c35d28f3af/go.mod h1:cGynoLGY9NfyIeWXI3zZ+hgZdHF3SUi8ht5ygZ8CmhI=
github.com/openstack-k8s-operators/lib-common/modules/storage v0.5.1-0.20241104140916-71a0e9d9766d h1:6fA7kvhKRelVwNWxcMVe2d2lkN8MITY0OIudTBnmT+A=
github.com/openstack-k8s-operators/lib-common/modules/storage v0.5.1-0.20241104140916-71a0e9d9766d/go.mod h1:tfgBeLRqmlH/NQkLPe7396rj+t0whv2wPuMb8Ttvh8w=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
Expand Down
2 changes: 1 addition & 1 deletion api/v1beta1/cinder_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ const (
// DBPurgeDefaultSchedule - Default cron schedule for purging the DB
DBPurgeDefaultSchedule = "1 0 * * *"
// APITimeoutDefault - Default timeout in seconds for HAProxy, Apache, and RPCs
APITimeoutDefault = 60
APITimeoutDefault = 60
)

type CinderSpecBase struct {
Expand Down
300 changes: 0 additions & 300 deletions config/crd/bases/cinder.openstack.org_cinderapis.yaml

Large diffs are not rendered by default.

300 changes: 0 additions & 300 deletions config/crd/bases/cinder.openstack.org_cinderbackups.yaml

Large diffs are not rendered by default.

300 changes: 0 additions & 300 deletions config/crd/bases/cinder.openstack.org_cinders.yaml

Large diffs are not rendered by default.

300 changes: 0 additions & 300 deletions config/crd/bases/cinder.openstack.org_cinderschedulers.yaml

Large diffs are not rendered by default.

300 changes: 0 additions & 300 deletions config/crd/bases/cinder.openstack.org_cindervolumes.yaml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ require (
github.com/openstack-k8s-operators/infra-operator/apis v0.4.1-0.20241018085734-6534d4914f87
github.com/openstack-k8s-operators/keystone-operator/api v0.4.1-0.20241018180515-61e711f07467
github.com/openstack-k8s-operators/lib-common/modules/common v0.5.1-0.20241029151503-4878b3fa3333
github.com/openstack-k8s-operators/lib-common/modules/storage v0.4.1-0.20241014140317-e5c35d28f3af
github.com/openstack-k8s-operators/lib-common/modules/storage v0.5.1-0.20241104140916-71a0e9d9766d
github.com/openstack-k8s-operators/lib-common/modules/test v0.4.1-0.20241014140317-e5c35d28f3af
github.com/openstack-k8s-operators/mariadb-operator/api v0.4.1-0.20241017063825-352c57936a86
golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,8 @@ github.com/openstack-k8s-operators/lib-common/modules/common v0.5.1-0.2024102915
github.com/openstack-k8s-operators/lib-common/modules/common v0.5.1-0.20241029151503-4878b3fa3333/go.mod h1:YpNTuJhDWhbXM50O3qBkhO7M+OOyRmWkNVmJ4y3cyFs=
github.com/openstack-k8s-operators/lib-common/modules/openstack v0.4.1-0.20241014140317-e5c35d28f3af h1:fevDUHmqcnI4wDTKupKe/CcgVdgNpZXWkJx8u0/xEXs=
github.com/openstack-k8s-operators/lib-common/modules/openstack v0.4.1-0.20241014140317-e5c35d28f3af/go.mod h1:djfljx3jfHqywhY3oDvPg/GLKwiFVkds6v7P7/Yg+8g=
github.com/openstack-k8s-operators/lib-common/modules/storage v0.4.1-0.20241014140317-e5c35d28f3af h1:l8GXJhv4P/fy7Amz9XPEi8sn+hvxrQf1gICpmOaqOuE=
github.com/openstack-k8s-operators/lib-common/modules/storage v0.4.1-0.20241014140317-e5c35d28f3af/go.mod h1:cGynoLGY9NfyIeWXI3zZ+hgZdHF3SUi8ht5ygZ8CmhI=
github.com/openstack-k8s-operators/lib-common/modules/storage v0.5.1-0.20241104140916-71a0e9d9766d h1:6fA7kvhKRelVwNWxcMVe2d2lkN8MITY0OIudTBnmT+A=
github.com/openstack-k8s-operators/lib-common/modules/storage v0.5.1-0.20241104140916-71a0e9d9766d/go.mod h1:tfgBeLRqmlH/NQkLPe7396rj+t0whv2wPuMb8Ttvh8w=
github.com/openstack-k8s-operators/lib-common/modules/test v0.4.1-0.20241014140317-e5c35d28f3af h1:u5yJ/rV9VBMjKIcsu16/3rhiPcBxZN2sPqxnZHoRrNc=
github.com/openstack-k8s-operators/lib-common/modules/test v0.4.1-0.20241014140317-e5c35d28f3af/go.mod h1:LV0jo5etIsGyINpmB37i4oWR8zU6ApIuh7fsqGGA41o=
github.com/openstack-k8s-operators/mariadb-operator/api v0.4.1-0.20241017063825-352c57936a86 h1:eGlqcxs8fDP62/Vd56y+Gd0xy+3bfZyUGumyNduFVBA=
Expand Down
9 changes: 8 additions & 1 deletion pkg/cinder/volumes.go
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,14 @@ func GetVolumes(name string, storageSvc bool, extraVol []cinderv1beta1.CinderExt

for _, exv := range extraVol {
for _, vol := range exv.Propagate(svc) {
res = append(res, vol.Volumes...)
for _, v := range vol.Volumes {
volumeSource, _ := v.VolumeSource.ToCoreVolumeSource()
convertedVolume := corev1.Volume{
Name: v.Name,
VolumeSource: *volumeSource,
}
res = append(res, convertedVolume)
}
}
}
return res
Expand Down

0 comments on commit 54d6e95

Please sign in to comment.