-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Add SNO upgrade workflows #17519
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Add SNO upgrade workflows #17519
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 9 additions & 0 deletions
9
ci-operator/step-registry/openshift/upgrade/aws/single-node/OWNERS
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| approvers: | ||
| - romfreiman | ||
| - eranco74 | ||
| - tsorya | ||
| - osherdp | ||
| - yuvigold | ||
| - omertuc | ||
| - vrutkovs | ||
| - wking |
15 changes: 15 additions & 0 deletions
15
...penshift/upgrade/aws/single-node/openshift-upgrade-aws-single-node-workflow.metadata.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| { | ||
| "path": "openshift/upgrade/aws/single-node/openshift-upgrade-aws-single-node-workflow.yaml", | ||
| "owners": { | ||
| "approvers": [ | ||
| "romfreiman", | ||
| "eranco74", | ||
| "tsorya", | ||
| "osherdp", | ||
| "yuvigold", | ||
| "omertuc", | ||
| "vrutkovs", | ||
| "wking" | ||
| ] | ||
| } | ||
| } |
26 changes: 26 additions & 0 deletions
26
...egistry/openshift/upgrade/aws/single-node/openshift-upgrade-aws-single-node-workflow.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,26 @@ | ||
| workflow: | ||
| as: openshift-upgrade-aws-single-node | ||
| steps: | ||
| allow_best_effort_post_steps: true | ||
| pre: | ||
| - ref: ipi-install-hosted-loki | ||
| - chain: ipi-conf-aws | ||
| - ref: single-node-conf-aws | ||
| - chain: ipi-install-stableinitial | ||
| test: | ||
| - ref: openshift-e2e-test | ||
| post: | ||
| - chain: gather-network | ||
| - chain: gather-core-dump | ||
| - chain: ipi-aws-post | ||
| dependencies: | ||
| OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE: "release:initial" | ||
| OPENSHIFT_UPGRADE_RELEASE_IMAGE_OVERRIDE: "release:latest" | ||
| env: | ||
| TEST_TYPE: upgrade | ||
| TEST_SUITE: "" | ||
| TEST_UPGRADE_SUITE: "" | ||
| TEST_UPGRADE_OPTIONS: "" | ||
| TEST_SKIPS: "disruption_tests" | ||
| documentation: |- | ||
| The Openshift E2E AWS single node workflow executes the upgrade end-to-end test suite on AWS with a default single-node cluster configuration and Loki as log collector, exercising an upgrade during the process. | ||
1 change: 1 addition & 0 deletions
1
ci-operator/step-registry/openshift/upgrade/azure/single-node/OWNERS
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../OWNERS |
17 changes: 17 additions & 0 deletions
17
...hift/upgrade/azure/single-node/openshift-upgrade-azure-single-node-workflow.metadata.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| { | ||
| "path": "openshift/upgrade/azure/single-node/openshift-upgrade-azure-single-node-workflow.yaml", | ||
| "owners": { | ||
| "approvers": [ | ||
| "smarterclayton", | ||
| "wking", | ||
| "stevekuznetsov", | ||
| "vrutkovs", | ||
| "abhinavdahiya", | ||
| "deads2k", | ||
| "crawford", | ||
| "ewolinetz", | ||
| "csrwng", | ||
| "staebler" | ||
| ] | ||
| } | ||
| } |
26 changes: 26 additions & 0 deletions
26
...try/openshift/upgrade/azure/single-node/openshift-upgrade-azure-single-node-workflow.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,26 @@ | ||
| workflow: | ||
| as: openshift-upgrade-azure-single-node | ||
| steps: | ||
| allow_best_effort_post_steps: true | ||
| pre: | ||
| - ref: ipi-install-hosted-loki | ||
| - chain: ipi-conf-azure | ||
| - ref: single-node-conf-azure | ||
| - chain: ipi-install-stableinitial | ||
| test: | ||
| - ref: openshift-e2e-test | ||
| post: | ||
| - chain: gather-network | ||
| - chain: gather-core-dump | ||
| - chain: ipi-azure-post | ||
| dependencies: | ||
| OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE: "release:initial" | ||
| OPENSHIFT_UPGRADE_RELEASE_IMAGE_OVERRIDE: "release:latest" | ||
| env: | ||
| TEST_TYPE: upgrade | ||
| TEST_SUITE: "" | ||
| TEST_UPGRADE_SUITE: none | ||
| TEST_UPGRADE_OPTIONS: "" | ||
| TEST_SKIPS: "" | ||
| documentation: |- | ||
| The Openshift E2E Azure single node workflow executes the upgrade end-to-end test suite on Azure with a default single-node cluster configuration and Loki as log collector, exercising an upgrade during the process. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,7 @@ | ||
| approvers: | ||
| - romfreiman | ||
| - eranco74 | ||
| - tsorya | ||
| - osherdp | ||
| - yuvigold | ||
| - omertuc |
49 changes: 49 additions & 0 deletions
49
ci-operator/step-registry/single-node/conf/azure/single-node-conf-azure-commands.sh
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,49 @@ | ||
| #!/bin/bash | ||
|
|
||
| set -o errexit | ||
| set -o nounset | ||
| set -o pipefail | ||
|
|
||
| SINGLE_NODE_AZURE_INSTANCE_TYPE="Standard_D32s_v3" | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I expect there to be one set of folks maintaining these single-node conf step(s), so it might we worth a single |
||
|
|
||
| echo "Updating install-config.yaml to a single ${SINGLE_NODE_AZURE_INSTANCE_TYPE} control plane node and 0 workers" | ||
|
|
||
| pip3 install pyyaml --user | ||
| python3 -c ' | ||
| import yaml | ||
| import sys | ||
|
|
||
| input_file = sys.argv[1] | ||
| output_file = sys.argv[2] if len(sys.argv) == 3 else sys.argv[1] # Output in-place if destination not given | ||
|
|
||
| with open(input_file) as f: | ||
| cfg = yaml.safe_load(f) | ||
|
|
||
| # Some workflows do not define controlPlane in install-config.yaml | ||
| if not "controlPlane" in cfg: | ||
| cfg["controlPlane"] = {} | ||
|
|
||
| cfg["controlPlane"]["replicas"] = 1 | ||
|
|
||
| # Single Node Openshift requires extra memory and compute resources | ||
| platform = cfg["controlPlane"]["platform"] | ||
| if "azure" in platform: | ||
| platform["azure"]["type"] = "'${SINGLE_NODE_AZURE_INSTANCE_TYPE}'" | ||
| else: | ||
| raise ValueError("This step only applies to Azure, please use the correct step for your platform") | ||
|
vrutkovs marked this conversation as resolved.
Outdated
|
||
|
|
||
| # Some workflows do not define any compute machine pools in install-config.yaml | ||
| if not "compute" in cfg: | ||
| cfg["compute"] = [ | ||
| { | ||
| "name": "worker", | ||
| "platform": {}, | ||
| } | ||
| ] | ||
|
|
||
| for machine_pool in cfg["compute"]: | ||
| machine_pool["replicas"] = 0 | ||
|
|
||
| with open(output_file, "w") as f: | ||
| yaml.safe_dump(cfg, f) | ||
| ' "${SHARED_DIR}/install-config.yaml" | ||
13 changes: 13 additions & 0 deletions
13
ci-operator/step-registry/single-node/conf/azure/single-node-conf-azure-ref.metadata.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| { | ||
| "path": "single-node/conf/azure/single-node-conf-azure-ref.yaml", | ||
| "owners": { | ||
| "approvers": [ | ||
| "romfreiman", | ||
| "eranco74", | ||
| "tsorya", | ||
| "osherdp", | ||
| "yuvigold", | ||
| "omertuc" | ||
| ] | ||
| } | ||
| } |
10 changes: 10 additions & 0 deletions
10
ci-operator/step-registry/single-node/conf/azure/single-node-conf-azure-ref.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| ref: | ||
| as: single-node-conf-azure | ||
| from: installer | ||
| commands: single-node-conf-azure-commands.sh | ||
| resources: | ||
| requests: | ||
| cpu: 10m | ||
| memory: 100Mi | ||
| documentation: |- | ||
| Modifies install-config.yaml to use a single control-plane node and without any workers. |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
is loki is something specific here? Just so i understand, or this is the standard flow
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.
Copied from regular upgrade workflow
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.
This step would setup promtail on the cluster, sending container and journald logs to the central repo, which can be queried by Grafana.
This is a standard practice for upgrade workflows, as intermediate containers can be lost during reboot (or the node may never come back)