Skip to content

Commit 7202666

Browse files
committed
Add Cyborg service containers to OpenStackVersion
Add the three related containers to the OpenStackVersion container images list and add default values. Jira: OSPRH-2767 Signed-off-by: melanie witt <melwittt@gmail.com>
1 parent 1a58205 commit 7202666

11 files changed

Lines changed: 130 additions & 0 deletions

‎api/bases/core.openstack.org_openstackcontrolplanes.yaml‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20005,6 +20005,12 @@ spec:
2000520005
type: string
2000620006
cloudkittyProcImage:
2000720007
type: string
20008+
cyborgAPIImage:
20009+
type: string
20010+
cyborgAgentImage:
20011+
type: string
20012+
cyborgConductorImage:
20013+
type: string
2000820014
designateAPIImage:
2000920015
type: string
2001020016
designateBackendbind9Image:

‎api/bases/core.openstack.org_openstackversions.yaml‎

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,12 @@ spec:
9191
type: string
9292
cloudkittyProcImage:
9393
type: string
94+
cyborgAPIImage:
95+
type: string
96+
cyborgAgentImage:
97+
type: string
98+
cyborgConductorImage:
99+
type: string
94100
designateAPIImage:
95101
type: string
96102
designateBackendbind9Image:
@@ -349,6 +355,12 @@ spec:
349355
type: string
350356
cloudkittyProcImage:
351357
type: string
358+
cyborgAPIImage:
359+
type: string
360+
cyborgAgentImage:
361+
type: string
362+
cyborgConductorImage:
363+
type: string
352364
designateAPIImage:
353365
type: string
354366
designateBackendbind9Image:
@@ -557,6 +569,12 @@ spec:
557569
type: string
558570
cloudkittyProcImage:
559571
type: string
572+
cyborgAPIImage:
573+
type: string
574+
cyborgAgentImage:
575+
type: string
576+
cyborgConductorImage:
577+
type: string
560578
designateAPIImage:
561579
type: string
562580
designateBackendbind9Image:
@@ -791,6 +809,12 @@ spec:
791809
type: string
792810
cloudkittyProcImage:
793811
type: string
812+
cyborgAPIImage:
813+
type: string
814+
cyborgAgentImage:
815+
type: string
816+
cyborgConductorImage:
817+
type: string
794818
designateAPIImage:
795819
type: string
796820
designateBackendbind9Image:

‎api/core/v1beta1/openstackversion_types.go‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -218,6 +218,9 @@ type ContainerTemplate struct {
218218
CinderSchedulerImage *string `json:"cinderSchedulerImage,omitempty"`
219219
CloudKittyAPIImage *string `json:"cloudkittyAPIImage,omitempty"`
220220
CloudKittyProcImage *string `json:"cloudkittyProcImage,omitempty"`
221+
CyborgAPIImage *string `json:"cyborgAPIImage,omitempty"`
222+
CyborgAgentImage *string `json:"cyborgAgentImage,omitempty"`
223+
CyborgConductorImage *string `json:"cyborgConductorImage,omitempty"`
221224
DesignateAPIImage *string `json:"designateAPIImage,omitempty"`
222225
DesignateBackendbind9Image *string `json:"designateBackendbind9Image,omitempty"`
223226
DesignateCentralImage *string `json:"designateCentralImage,omitempty"`

‎api/core/v1beta1/zz_generated.deepcopy.go‎

Lines changed: 15 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎bindata/crds/crds.yaml‎

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21034,6 +21034,12 @@ spec:
2103421034
type: string
2103521035
cloudkittyProcImage:
2103621036
type: string
21037+
cyborgAPIImage:
21038+
type: string
21039+
cyborgAgentImage:
21040+
type: string
21041+
cyborgConductorImage:
21042+
type: string
2103721043
designateAPIImage:
2103821044
type: string
2103921045
designateBackendbind9Image:
@@ -23668,6 +23674,12 @@ spec:
2366823674
type: string
2366923675
cloudkittyProcImage:
2367023676
type: string
23677+
cyborgAPIImage:
23678+
type: string
23679+
cyborgAgentImage:
23680+
type: string
23681+
cyborgConductorImage:
23682+
type: string
2367123683
designateAPIImage:
2367223684
type: string
2367323685
designateBackendbind9Image:
@@ -23926,6 +23938,12 @@ spec:
2392623938
type: string
2392723939
cloudkittyProcImage:
2392823940
type: string
23941+
cyborgAPIImage:
23942+
type: string
23943+
cyborgAgentImage:
23944+
type: string
23945+
cyborgConductorImage:
23946+
type: string
2392923947
designateAPIImage:
2393023948
type: string
2393123949
designateBackendbind9Image:
@@ -24134,6 +24152,12 @@ spec:
2413424152
type: string
2413524153
cloudkittyProcImage:
2413624154
type: string
24155+
cyborgAPIImage:
24156+
type: string
24157+
cyborgAgentImage:
24158+
type: string
24159+
cyborgConductorImage:
24160+
type: string
2413724161
designateAPIImage:
2413824162
type: string
2413924163
designateBackendbind9Image:
@@ -24368,6 +24392,12 @@ spec:
2436824392
type: string
2436924393
cloudkittyProcImage:
2437024394
type: string
24395+
cyborgAPIImage:
24396+
type: string
24397+
cyborgAgentImage:
24398+
type: string
24399+
cyborgConductorImage:
24400+
type: string
2437124401
designateAPIImage:
2437224402
type: string
2437324403
designateBackendbind9Image:

‎config/crd/bases/core.openstack.org_openstackcontrolplanes.yaml‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20005,6 +20005,12 @@ spec:
2000520005
type: string
2000620006
cloudkittyProcImage:
2000720007
type: string
20008+
cyborgAPIImage:
20009+
type: string
20010+
cyborgAgentImage:
20011+
type: string
20012+
cyborgConductorImage:
20013+
type: string
2000820014
designateAPIImage:
2000920015
type: string
2001020016
designateBackendbind9Image:

‎config/crd/bases/core.openstack.org_openstackversions.yaml‎

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,12 @@ spec:
9191
type: string
9292
cloudkittyProcImage:
9393
type: string
94+
cyborgAPIImage:
95+
type: string
96+
cyborgAgentImage:
97+
type: string
98+
cyborgConductorImage:
99+
type: string
94100
designateAPIImage:
95101
type: string
96102
designateBackendbind9Image:
@@ -349,6 +355,12 @@ spec:
349355
type: string
350356
cloudkittyProcImage:
351357
type: string
358+
cyborgAPIImage:
359+
type: string
360+
cyborgAgentImage:
361+
type: string
362+
cyborgConductorImage:
363+
type: string
352364
designateAPIImage:
353365
type: string
354366
designateBackendbind9Image:
@@ -557,6 +569,12 @@ spec:
557569
type: string
558570
cloudkittyProcImage:
559571
type: string
572+
cyborgAPIImage:
573+
type: string
574+
cyborgAgentImage:
575+
type: string
576+
cyborgConductorImage:
577+
type: string
560578
designateAPIImage:
561579
type: string
562580
designateBackendbind9Image:
@@ -791,6 +809,12 @@ spec:
791809
type: string
792810
cloudkittyProcImage:
793811
type: string
812+
cyborgAPIImage:
813+
type: string
814+
cyborgAgentImage:
815+
type: string
816+
cyborgConductorImage:
817+
type: string
794818
designateAPIImage:
795819
type: string
796820
designateBackendbind9Image:

‎config/operator/default_images.yaml‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,10 @@ spec:
4141
value: quay.io/openstack-s2i-containers/openstack-cinder-volume:master-latest
4242
- name: RELATED_IMAGE_CLOUDKITTY_IMAGE_URL_DEFAULT
4343
value: quay.io/openstack-s2i-containers/openstack-cloudkitty-api:master-latest
44+
- name: RELATED_IMAGE_CYBORG_IMAGE_URL_DEFAULT
45+
value: quay.io/openstack-s2i-containers/openstack-cyborg:master-latest
46+
- name: RELATED_IMAGE_CYBORG_AGENT_IMAGE_URL_DEFAULT
47+
value: quay.io/openstack-s2i-containers/openstack-cyborg-agent:master-latest
4448
- name: RELATED_IMAGE_DESIGNATE_API_IMAGE_URL_DEFAULT
4549
value: quay.io/openstack-s2i-containers/openstack-designate-api:master-latest
4650
- name: RELATED_IMAGE_DESIGNATE_BACKENDBIND9_IMAGE_URL_DEFAULT

‎hack/export_related_images.sh‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,3 +79,5 @@ export TEST_TOBIKO_IMAGE_URL_DEFAULT=quay.io/openstack-s2i-containers/openstack-
7979
export TEST_ANSIBLETEST_IMAGE_URL_DEFAULT=quay.io/openstack-s2i-containers/openstack-ansible-test:master-latest
8080
export TEST_HORIZONTEST_IMAGE_URL_DEFAULT=quay.io/openstack-s2i-containers/openstack-horizontest:master-latest
8181
export RELATED_IMAGE_OPENSTACK_MUST_GATHER_DEFAULT=quay.io/openstack-k8s-operators/openstack-must-gather:latest
82+
export RELATED_IMAGE_CYBORG_IMAGE_URL_DEFAULT=quay.io/openstack-s2i-containers/openstack-cyborg:master-latest
83+
export RELATED_IMAGE_CYBORG_AGENT_IMAGE_URL_DEFAULT=quay.io/openstack-s2i-containers/openstack-cyborg-agent:master-latest

‎internal/openstack/version.go‎

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,13 @@ func InitializeOpenStackVersionImageDefaults(ctx context.Context, envImages map[
114114
defaults.WatcherApplierImage = envImages["RELATED_IMAGE_WATCHER_BASE_IMAGE_URL_DEFAULT"]
115115
defaults.WatcherDecisionEngineImage = envImages["RELATED_IMAGE_WATCHER_BASE_IMAGE_URL_DEFAULT"]
116116
}
117+
if envImages["RELATED_IMAGE_CYBORG_IMAGE_URL_DEFAULT"] != nil {
118+
defaults.CyborgAPIImage = envImages["RELATED_IMAGE_CYBORG_IMAGE_URL_DEFAULT"]
119+
defaults.CyborgConductorImage = envImages["RELATED_IMAGE_CYBORG_IMAGE_URL_DEFAULT"]
120+
}
121+
if envImages["RELATED_IMAGE_CYBORG_AGENT_IMAGE_URL_DEFAULT"] != nil {
122+
defaults.CyborgAgentImage = envImages["RELATED_IMAGE_CYBORG_AGENT_IMAGE_URL_DEFAULT"]
123+
}
117124
// custom TEST_ images which aren't released downstream
118125
if envImages["TEST_TOBIKO_IMAGE_URL_DEFAULT"] != nil {
119126
defaults.TestTobikoImage = envImages["TEST_TOBIKO_IMAGE_URL_DEFAULT"]
@@ -182,6 +189,9 @@ func GetContainerImages(defaults *corev1beta1.ContainerDefaults, instance corev1
182189
CinderSchedulerImage: getImg(instance.Spec.CustomContainerImages.CinderSchedulerImage, defaults.CinderSchedulerImage),
183190
CloudKittyAPIImage: getImg(instance.Spec.CustomContainerImages.CloudKittyAPIImage, defaults.CloudKittyAPIImage),
184191
CloudKittyProcImage: getImg(instance.Spec.CustomContainerImages.CloudKittyProcImage, defaults.CloudKittyProcImage),
192+
CyborgAPIImage: getImg(instance.Spec.CustomContainerImages.CyborgAPIImage, defaults.CyborgAPIImage),
193+
CyborgAgentImage: getImg(instance.Spec.CustomContainerImages.CyborgAgentImage, defaults.CyborgAgentImage),
194+
CyborgConductorImage: getImg(instance.Spec.CustomContainerImages.CyborgConductorImage, defaults.CyborgConductorImage),
185195
DesignateAPIImage: getImg(instance.Spec.CustomContainerImages.DesignateAPIImage, defaults.DesignateAPIImage),
186196
DesignateBackendbind9Image: getImg(instance.Spec.CustomContainerImages.DesignateBackendbind9Image, defaults.DesignateBackendbind9Image),
187197
DesignateCentralImage: getImg(instance.Spec.CustomContainerImages.DesignateCentralImage, defaults.DesignateCentralImage),
@@ -379,6 +389,9 @@ func ControlplaneContainerImageMatch(ctx context.Context, controlPlane *corev1be
379389
if !CinderImageMatch(ctx, controlPlane, version) {
380390
failedMatches = append(failedMatches, "Cinder")
381391
}
392+
if !CyborgImageMatch(ctx, controlPlane, version) {
393+
failedMatches = append(failedMatches, "Cyborg")
394+
}
382395
if !DesignateImageMatch(ctx, controlPlane, version) {
383396
failedMatches = append(failedMatches, "Designate")
384397
}

0 commit comments

Comments
 (0)