Browse Source

Reuse phase, executor from airshipctl

* Inherit all phases from airshipctl
* moved kubeconfig to site directory

Change-Id: I69f54f7eed16835387e898511348278e0a67117e
Relates-To: #78
changes/56/772756/3
Sirajudeen 2 years ago
parent
commit
45c946e83a
  1. 0
      manifests/site/test-site/kubeconfig/kubeconfig.yaml
  2. 2
      manifests/site/test-site/kubeconfig/kustomization.yaml
  3. 1
      manifests/site/test-site/phases/kustomization.yaml
  4. 3
      manifests/site/test-site/target/catalogues/hosts.yaml
  5. 11
      manifests/type/airship-core/phases/cluster-map.yaml
  6. 6
      manifests/type/airship-core/phases/clusterctl_init_options.yaml
  7. 49
      manifests/type/airship-core/phases/executors.yaml
  8. 9
      manifests/type/airship-core/phases/kustomization.yaml
  9. 131
      manifests/type/airship-core/phases/phases.yaml
  10. 15
      manifests/type/airship-core/phases/plan.yaml

0
manifests/type/airship-core/phases/kubeconfig.yaml → manifests/site/test-site/kubeconfig/kubeconfig.yaml

2
manifests/site/test-site/kubeconfig/kustomization.yaml

@ -0,0 +1,2 @@
resources:
- kubeconfig.yaml

1
manifests/site/test-site/phases/kustomization.yaml

@ -1,2 +1,3 @@
resources:
- ../kubeconfig
- ../../../type/airship-core/phases

3
manifests/site/test-site/target/catalogues/hosts.yaml

@ -15,6 +15,7 @@ hosts:
bmcAddress: redfish+http://10.23.25.1:8000/redfish/v1/Systems/air-target-1
bmcUsername: root
bmcPassword: r00tme
disableCertificateVerification: false
ipAddresses:
oam-ipv4: 10.23.25.102
pxe-ipv4: 10.23.24.102
@ -28,6 +29,7 @@ hosts:
bmcAddress: redfish+http://10.23.25.2:8000/redfish/v1/Systems/air-target-2
bmcUsername: username
bmcPassword: password
disableCertificateVerification: false
ipAddresses:
oam-ipv4: 10.23.25.101
pxe-ipv4: 10.23.24.101
@ -41,6 +43,7 @@ hosts:
bmcAddress: redfish+http://10.23.25.1:8000/redfish/v1/Systems/air-worker-1
bmcUsername: username
bmcPassword: password
disableCertificateVerification: false
ipAddresses:
oam-ipv4: 10.23.25.103
pxe-ipv4: 10.23.24.103

11
manifests/type/airship-core/phases/cluster-map.yaml

@ -1,11 +0,0 @@
---
apiVersion: airshipit.org/v1alpha1
kind: ClusterMap
metadata:
labels:
airshipit.org/deploy-k8s: "false"
name: main-map
map:
target-cluster:
parent: ephemeral-cluster
ephemeral-cluster: {}

6
manifests/type/airship-core/phases/clusterctl_init_options.yaml

@ -1,6 +0,0 @@
---
apiVersion: airshipit.org/v1alpha1
kind: Clusterctl
metadata:
name: clusterctl_init
action: init

49
manifests/type/airship-core/phases/executors.yaml

@ -1,49 +0,0 @@
---
apiVersion: airshipit.org/v1alpha1
kind: KubernetesApply
metadata:
labels:
airshipit.org/deploy-k8s: "false"
name: kubernetes-apply
config:
waitOptions:
timeout: 2000
pruneOptions:
prune: false
---
# This is added to support phase with no-wait
# When there is a wait, then it does status-check and fails
# if the resource status(condition) is not met.
# There are cases where the resource do not have status
# field implemented. So a wait will fail with status check
apiVersion: airshipit.org/v1alpha1
kind: KubernetesApply
metadata:
labels:
airshipit.org/deploy-k8s: "false"
name: kubernetes-apply-nowait
config:
waitOptions:
timeout: 0
pruneOptions:
prune: false
---
apiVersion: airshipit.org/v1alpha1
kind: Clusterctl
metadata:
name: clusterctl_move
move-options: {}
action: move
---
apiVersion: airshipit.org/v1alpha1
kind: IsoConfiguration
metadata:
name: isogen
labels:
airshipit.org/deploy-k8s: "false"
builder:
outputFileName: ephemeral.iso
container:
containerRuntime: docker
image: quay.io/airshipit/image-builder:latest-ubuntu_focal
volume: /srv/images:/config

9
manifests/type/airship-core/phases/kustomization.yaml

@ -1,9 +1,2 @@
resources:
- phases.yaml
- plan.yaml
- executors.yaml
- cluster-map.yaml
- kubeconfig.yaml
- ../../../function/clusterctl
patchesStrategicMerge:
- clusterctl_init_options.yaml
- ../../../../../airshipctl/manifests/phases/

131
manifests/type/airship-core/phases/phases.yaml

@ -1,131 +0,0 @@
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: bootstrap-iso
config:
executorRef:
apiVersion: airshipit.org/v1alpha1
kind: IsoConfiguration
name: isogen
documentEntryPoint: ephemeral/bootstrap
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: initinfra-ephemeral
clusterName: ephemeral-cluster
config:
executorRef:
apiVersion: airshipit.org/v1alpha1
kind: KubernetesApply
name: kubernetes-apply
documentEntryPoint: ephemeral/initinfra
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: initinfra-networking-ephemeral
clusterName: ephemeral-cluster
config:
executorRef:
apiVersion: airshipit.org/v1alpha1
kind: KubernetesApply
name: kubernetes-apply-nowait
documentEntryPoint: ephemeral/initinfra-networking
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: controlplane-ephemeral
clusterName: ephemeral-cluster
config:
executorRef:
apiVersion: airshipit.org/v1alpha1
kind: KubernetesApply
name: kubernetes-apply
documentEntryPoint: ephemeral/controlplane
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: initinfra-target
clusterName: target-cluster
config:
cluster: target-cluster
executorRef:
apiVersion: airshipit.org/v1alpha1
kind: KubernetesApply
name: kubernetes-apply
documentEntryPoint: target/initinfra
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: initinfra-networking-target
clusterName: target-cluster
config:
cluster: target-cluster
executorRef:
apiVersion: airshipit.org/v1alpha1
kind: KubernetesApply
name: kubernetes-apply-nowait
documentEntryPoint: target/initinfra-networking
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: workers-target
clusterName: target-cluster
config:
cluster: target-cluster
executorRef:
apiVersion: airshipit.org/v1alpha1
kind: KubernetesApply
name: kubernetes-apply
documentEntryPoint: target/workers
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: clusterctl-init-ephemeral
clusterName: ephemeral-cluster
config:
executorRef:
apiVersion: airshipit.org/v1alpha1
kind: Clusterctl
name: clusterctl_init
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: clusterctl-init-target
clusterName: target-cluster
config:
executorRef:
apiVersion: airshipit.org/v1alpha1
kind: Clusterctl
name: clusterctl_init
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: clusterctl-move
clusterName: target-cluster
config:
executorRef:
apiVersion: airshipit.org/v1alpha1
kind: Clusterctl
name: clusterctl_move
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: workload-target
clusterName: target-cluster
config:
executorRef:
apiVersion: airshipit.org/v1alpha1
kind: KubernetesApply
name: kubernetes-apply
documentEntryPoint: target/workload

15
manifests/type/airship-core/phases/plan.yaml

@ -1,15 +0,0 @@
apiVersion: airshipit.org/v1alpha1
kind: PhasePlan
metadata:
name: phasePlan
phaseGroups:
- name: group1
phases:
- name: initinfra-ephemeral
- name: initinfra-networking-ephemeral
- name: clusterctl-init-ephemeral
- name: controlplane-ephemeral
- name: initinfra-target
- name: initinfra-networking-target
- name: workers-target
- name: workload-target
Loading…
Cancel
Save