-
Notifications
You must be signed in to change notification settings - Fork 49
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix CAPD deployment using phase plan
This PS introduces phase plan for CAPD provider * Adds phase to merge kubeconfig * Patches type/gating plan to use capd phase plan * Patches cluster_map and executor to work with "default" namespace * Fixes CAPD zuul failures Relates-To: #564 Relates-To: #580 Relates-To: #587 Change-Id: I5007970c907bc87dccf6dd9fcb052afc1b5c13f7
- Loading branch information
Ratnopam Chakrabarti
committed
Sep 7, 2021
1 parent
0cb8e0f
commit 441ef0e
Showing
20 changed files
with
123 additions
and
189 deletions.
There are no files selected for viewing
This file contains 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,2 @@ | ||
resources: | ||
- metadata.yaml |
This file contains 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,11 @@ | ||
--- | ||
apiVersion: clusterctl.cluster.x-k8s.io/v1alpha3 | ||
kind: Metadata | ||
metadata: | ||
name: repository-metadata | ||
labels: | ||
airshipit.org/deploy-k8s: "false" | ||
releaseSeries: | ||
- major: 0 | ||
minor: 3 | ||
contract: v1alpha3 |
This file contains 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 |
---|---|---|
|
@@ -5,5 +5,6 @@ commonLabels: | |
|
||
resources: | ||
- crd | ||
- data | ||
- default | ||
- webhook |
This file contains 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 |
---|---|---|
|
@@ -13,3 +13,4 @@ resources: | |
- wait_bmh | ||
- wait_label_node | ||
- check_ingress_ctrl | ||
- merge_kubeconfig |
This file contains 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
6 changes: 6 additions & 0 deletions
6
manifests/function/phase-helpers/merge_kubeconfig/kustomization.yaml
This file contains 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,6 @@ | ||
configMapGenerator: | ||
- name: merge-kubeconfig | ||
options: | ||
disableNameSuffixHash: true | ||
files: | ||
- script=kubectl_merge_kubeconfig.sh |
This file contains 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 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 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,2 @@ | ||
resources: | ||
- metadata.yaml |
22 changes: 22 additions & 0 deletions
22
manifests/site/docker-test-site/phases/cluster_map_patch.yaml
This file contains 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,22 @@ | ||
apiVersion: airshipit.org/v1alpha1 | ||
kind: ClusterMap | ||
metadata: | ||
labels: | ||
airshipit.org/deploy-k8s: "false" | ||
name: main-map | ||
map: | ||
target-cluster: | ||
parent: ephemeral-cluster | ||
kubeconfigSources: | ||
- type: "filesystem" | ||
filesystem: | ||
path: ~/.airship/kubeconfig | ||
contextName: target-cluster | ||
- type: "bundle" | ||
bundle: | ||
contextName: target-cluster | ||
- type: "clusterAPI" | ||
clusterAPI: | ||
clusterNamespacedName: | ||
name: target-cluster | ||
namespace: default |
This file contains 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 @@ | ||
apiVersion: airshipit.org/v1alpha1 | ||
kind: Clusterctl | ||
metadata: | ||
name: clusterctl_move | ||
move-options: | ||
namespace: default | ||
action: move |
7 changes: 2 additions & 5 deletions
7
manifests/site/docker-test-site/phases/infrastructure-providers.json
This file contains 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 |
---|---|---|
@@ -1,18 +1,15 @@ | ||
[{ | ||
"op": "replace", | ||
"path": "/init-options/infrastructure-providers", | ||
"value": ["docker:v0.3.11"] | ||
"value": "docker:v0.3.11" | ||
}, | ||
{ | ||
"op": "replace", | ||
"path": "/providers/0", | ||
"value": { | ||
"name": "docker", | ||
"type": "InfrastructureProvider", | ||
"variable-substitution": true, | ||
"versions": { | ||
"v0.3.11": "airshipctl/manifests/function/capd/v0.3.11" | ||
} | ||
"url": "airshipctl/manifests/function/capd/v0.3.11" | ||
} | ||
} | ||
] |
This file contains 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 |
---|---|---|
@@ -1,14 +1,17 @@ | ||
resources: | ||
- ../../../phases | ||
- ../../../function/airshipctl-base-catalogues | ||
- plan.yaml | ||
patchesJson6902: | ||
- target: | ||
group: airshipit.org | ||
version: v1alpha1 | ||
kind: Clusterctl | ||
name: "clusterctl_init" | ||
path: infrastructure-providers.json | ||
patchesStrategicMerge: | ||
- plan_patch.yaml | ||
- cluster_map_patch.yaml | ||
- executor_patch.yaml | ||
transformers: | ||
- ../../../function/clusterctl/replacements | ||
- ../../../phases/replacements |
This file was deleted.
Oops, something went wrong.
This file contains 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,20 @@ | ||
apiVersion: airshipit.org/v1alpha1 | ||
kind: PhasePlan | ||
metadata: | ||
name: deploy-gating | ||
description: "Phase plan for docker-test-site deployment" | ||
phases: | ||
- name: clusterctl-init-ephemeral | ||
- name: kubectl-wait-deploy-ephemeral | ||
- name: kubectl-get-pods-ephemeral | ||
- name: controlplane-ephemeral | ||
- name: kubectl-merge-kubeconfig | ||
- name: kubectl-get-node-target | ||
- name: kubectl-get-pods-target | ||
- name: initinfra-networking-target | ||
- name: kubectl-wait-tigera-target | ||
- name: kubectl-get-pods-target | ||
- name: clusterctl-init-target | ||
- name: kubectl-wait-pods-any-ephemeral | ||
- name: clusterctl-move | ||
- name: workers-target |
This file contains 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
46 changes: 0 additions & 46 deletions
46
tools/deployment/provider_common/30_deploy_controlplane.sh
This file was deleted.
Oops, something went wrong.
39 changes: 0 additions & 39 deletions
39
tools/deployment/provider_common/32_cluster_init_target_node.sh
This file was deleted.
Oops, something went wrong.
69 changes: 0 additions & 69 deletions
69
tools/deployment/provider_common/33_cluster_move_target_node.sh
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.