Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ metadata:
data:
images.json: >
{
"releaseVersion": "0.0.1-snapshot",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there something that substitutes this value? In oc adm release new? I am not seeing it in $ rg releaseVersion in oc git master.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oc adm release new is substituting it according to my manual testing, if you can double check that , it would be amazing

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also, grep for 0.0.1-snapshot in openshift/origin - that's where the substitution is

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"machineConfigOperator": "registry.svc.ci.openshift.org/openshift:machine-config-operator",
"etcd": "registry.svc.ci.openshift.org/openshift:etcd",
"infraImage": "registry.svc.ci.openshift.org/openshift:pod",
Expand Down
1 change: 1 addition & 0 deletions pkg/operator/images.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ package operator
// Change the installer to pass that arg with the image from the CVO
// (some time later) Change the option to required and drop the default
type Images struct {
ReleaseVersion string `json:"releaseVersion,omitempty"`
RenderConfigImages
ControllerConfigImages
}
Expand Down
5 changes: 5 additions & 0 deletions pkg/operator/sync.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,11 @@ func (optr *Operator) syncRenderConfig(_ *renderConfig) error {
return err
}

optrVersion, _ := optr.vStore.Get("operator")
if imgs.ReleaseVersion != optrVersion {
return fmt.Errorf("refusing to read images.json version %q, operator version %q", imgs.ReleaseVersion, optrVersion)
}

// sync up CAs
etcdCA, err := optr.getCAsFromConfigMap("openshift-config", "etcd-serving-ca", "ca-bundle.crt")
if err != nil {
Expand Down