-
Notifications
You must be signed in to change notification settings - Fork 58
Create an initial release payload as release:initial
#284
Create an initial release payload as release:initial
#284
Conversation
75d2c38 to
0d624c2
Compare
|
@stevekuznetsov @bbguimaraes @petr-muller this is a prerequisite for the upgrade test framework. See openshift/release#2997 for an example of what the prow job looks like. We probably need to add support for a new flag, and we need to keep in mind that the PR testing is going to have future variants (i.e. now it's release tag -> tag + PR images, but in future will include "last stable version" and "upgrade then downgrade" testing), so we don't want to assume it'll be a simple variant yet. Every operator repo will get one of these, but it will be optional / not triggered by default. That means we need to solve how to generate optional prow job status so we can stop manually crafting prow jobs for those. |
Requires openshift/ci-operator#284 before it will function. Will be used as the template for other jobs. The job launches the cluster using a release image build from the current state of the integration stream (release:initial). It then launches the upgrade tests with openshift-tests run-upgrade all --to-image=.../ci-op-.../release:latest The test job will start the prereq tests, then once they are stable, launch the upgrade, monitoring invariants while the test continues. Once the upgrade is complete or fails, the postcondition tests will run and then the cluster is torn down. Due to limitations in the upstream infrastructure for upgrade tests we don't get the nice separation between tests that e2e runs do which is a future improvement. After this test is working we'll add it to other repos as a standard job, including the release verification jobs. We'll also invoke it from the release controller dynamically to calculate upgrade edges prior to promoting a job.
0d624c2 to
2c21cc3
Compare
47a67ed to
6fd86c0
Compare
|
Rebased on top of the merged PRs. One more follow up coming (that will build on this) to default the contents of |
6fd86c0 to
f4e6441
Compare
f4e6441 to
e6fc04e
Compare
| func (s *assembleReleaseStep) Requires() []api.StepLink { | ||
| return []api.StepLink{api.ImagesReadyLink()} | ||
| // if our prereq is provided, we don't need any prereqs | ||
| if len(os.Getenv(s.envVar())) > 0 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should use os.LookupEnv for this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah, I'm still in the older habit.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, the value has to be greater than zero. we ignore RELEASE_IMAGE_INITIAL= because having an empty env is invalid and if someone did bash to init the env var we want that. We don't discriminate between empty and unset here.
| } | ||
|
|
||
| func (s *assembleReleaseStep) Name() string { return "[release:latest]" } | ||
| func (s *assembleReleaseStep) Name() string { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
func (s *assembleReleaseStep) Name() string {
return fmt.Sprintf("[release:%s]", s.tag())
}
pkg/steps/release/create_release.go
Outdated
| if s.latest { | ||
| return "Create the release image containing all images built by this job" | ||
| } | ||
| return "Create the release image for the initial state of this job" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
initial state of current release at the time the job ran? could be more clear
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok
When we tag images in, create a second image stream `stable-initial` that will not be modified and then let a secondary task create an image stream from that alternate source. If RELEASE_IMAGE_INITIAL is already specified, skip the action and instead tag it to that location. Simplify the structure of the AssembleReleaseStep to handle both initial and latest. Makes it easy to test an upgrade from the previous state to the current state (post change) while also allowing for injecting an initial step.
e6fc04e to
f88657f
Compare
|
Updated PTAL |
|
/lgtm |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: smarterclayton, stevekuznetsov The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
…itial" This reverts commit b2c8eaf, reversing changes made to 1901ee4. Signed-off-by: Steve Kuznetsov <[email protected]>
Revert "Merge pull request #284 from smarterclayton/build_initial"
When we tag images in, create a second image stream
stable-initialthatwill not be modified and then let a secondary task create an image stream
from that alternate source. If RELEASE_IMAGE_INITIAL is already specified,
skip the action and instead tag it to that location.
Makes it easy to test an upgrade from the previous state to the current
state (post change) while also allowing for injecting an initial step.
Built on top of #282 #283