Add test-site phase overrides

Phase documents live at the type level in Treasuremap; however, many
test-site phases are defined at the site level. This change adds phase
overrides to the test-site in order to demonstrate patching a phase
path. The same process can be followed to add additional site-specific
phases.

Depends-On: https://review.opendev.org/754729

Change-Id: Ia4ede59c29752a71a17e3aad9118b496ba0d0233
This commit is contained in:
Drew Walters 2020-09-28 14:10:07 +00:00
parent 62585ea345
commit 9ebd597cd6
4 changed files with 41 additions and 1 deletions

View File

@ -0,0 +1,2 @@
phase:
path: manifests/site/test-site/phases

View File

@ -0,0 +1,5 @@
resources:
- ../../../type/airship-core/phases
patchesStrategicMerge:
- patch-entrypoints.yaml

View File

@ -0,0 +1,32 @@
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: initinfra-ephemeral
clusterName: ephemeral-cluster
config:
documentEntryPoint: manifests/site/test-site/ephemeral/initinfra
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: controlplane-ephemeral
clusterName: ephemeral-cluster
config:
documentEntryPoint: manifests/site/test-site/ephemeral/controlplane
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: initinfra-target
clusterName: target-cluster
config:
documentEntryPoint: manifests/site/test-site/target/initinfra
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: workers-target
clusterName: target-cluster
config:
documentEntryPoint: manifests/site/test-site/target/workers

View File

@ -19,9 +19,10 @@ set -xe
export AIRSHIPCTL_WS=${AIRSHIPCTL_WS:-$AIRSHIPCTL_PROJECT}
export AIRSHIP_CONFIG_MANIFEST_DIRECTORY=${AIRSHIP_CONFIG_MANIFEST_DIRECTORY:-$TREASUREMAP_PROJECT}
export AIRSHIP_CONFIG_METADATA_PATH=${AIRSHIP_CONFIG_METADATA_PATH:-"manifests/type/airship-core/metadata.yaml"}
export AIRSHIP_SITE_NAME=${AIRSHIP_SITE_NAME:-"manifests/site/test-site"}
export AIRSHIP_CONFIG_METADATA_PATH=${AIRSHIP_CONFIG_METADATA_PATH:-"$AIRSHIP_SITE_NAME/metadata.yaml"}
cd ${AIRSHIPCTL_PROJECT}
./tools/deployment/22_test_configs.sh