Merge "Add eject virtual media phase"

This commit is contained in:
Zuul 2021-11-04 18:48:23 +00:00 committed by Gerrit Code Review
commit e1355ce0e4
4 changed files with 32 additions and 0 deletions

View File

@ -34,3 +34,12 @@ replacements:
kind: BaremetalManager
name: PowerOffEphemeral
fieldrefs: ["spec.hostSelector.name%EPHEMERAL_NODE%"]
- source:
objref:
name: versions-remotedirect
fieldref: spec.remotedirect.node
target:
objref:
kind: BaremetalManager
name: EjectVirtualMediaEphemeral
fieldrefs: ["spec.hostSelector.name%EPHEMERAL_NODE%"]

View File

@ -239,6 +239,17 @@ spec:
name: EPHEMERAL_NODE
---
apiVersion: airshipit.org/v1alpha1
kind: BaremetalManager
metadata:
name: EjectVirtualMediaEphemeral
labels:
airshipit.org/deploy-k8s: "false"
spec:
operation: eject-virtual-media
hostSelector:
name: EPHEMERAL_NODE
---
apiVersion: airshipit.org/v1alpha1
kind: GenericContainer
metadata:
name: iso-cloud-init-data

View File

@ -280,6 +280,16 @@ config:
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: eject-virtual-media-ephemeral
config:
executorRef:
apiVersion: airshipit.org/v1alpha1
kind: BaremetalManager
name: EjectVirtualMediaEphemeral
---
apiVersion: airshipit.org/v1alpha1
kind: Phase
metadata:
name: kubectl-wait-node-ephemeral
clusterName: ephemeral-cluster

View File

@ -95,6 +95,8 @@ phases:
# To get ConfigMap for this phase, execute `airshipctl phase render --source config -k ConfigMap`
# and find ConfigMap with name kubectl-wait-cluster
- name: kubectl-wait-cluster-target
# Eject virtual media Ephemeral baremetal host to ensure it can reused.
- name: eject-virtual-media-ephemeral
# Power off Ephemeral baremetal host avoid DHCP conflict
- name: power-off-ephemeral
# List all nodes in target cluster