Skip to content

Commit

Permalink
add icsp & infra HA support (#46500)
Browse files Browse the repository at this point in the history
  • Loading branch information
heliubj18 authored Dec 7, 2023
1 parent f440cae commit 1b2e556
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,12 @@ echo "$(date) Creating agent hosted cluster manifests"
oc create ns ${HOSTED_CONTROL_PLANE_NAMESPACE}
mkdir /tmp/hc-manifests

${HYPERSHIFT_CLI_NAME} create cluster agent \
ICSP_COMMAND=""
if [[ $ENABLE_ICSP == "true" ]]; then
ICSP_COMMAND=$(echo "--image-content-sources ${SHARED_DIR}/mgmt_iscp.yaml")
fi

${HYPERSHIFT_CLI_NAME} create cluster agent ${ICSP_COMMAND} \
--name=${HOSTED_CLUSTER_NAME} \
--namespace=${CLUSTERS_NAMESPACE} \
--pull-secret=${PULL_SECRET} \
Expand All @@ -197,6 +202,7 @@ ${HYPERSHIFT_CLI_NAME} create cluster agent \
--ssh-key=${SSH_PUB_KEY_FILE}\
--release-image=${OCP_IMAGE_MULTI} \
--control-plane-availability-policy=${CP_AVAILABILITY_POLICY} \
--infra-availability-policy ${HYPERSHIFT_INFRA_AVAILABILITY_POLICY} \
--render > /tmp/hc-manifests/cluster-agent.yaml

# Split the manifest to replace routing strategy of various services
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ ref:
- name: CP_AVAILABILITY_POLICY
default: "SingleReplica"
documentation: "Control plane availability policy for the agent cluster"
- name: HYPERSHIFT_INFRA_AVAILABILITY_POLICY
default: "SingleReplica"
documentation: "Availability policy for infrastructure services in guest cluster. Supported options: SingleReplica, HighlyAvailable, default SingleReplica"
- name: AGENT_POWER_CREDENTIALS
default: /etc/hypershift-agent-power-credentials
- name: OPENSHIFT_VERSION
Expand All @@ -33,6 +36,9 @@ ref:
documentation: "Hostname of the bastion node hosted in POWERVS_INSTANCE_CRN where services configured for PXE boot"
- name: BASTION_CI_SCRIPTS_DIR
documentation: "Directory in BASTION where scripts related this CI are hosted"
- name: ENABLE_ICSP
default: "false"
documentation: "if true, applies image content sources from the management cluster config to the hosted cluster icsp/idms (path=${SHARED_DIR}/mgmt_iscp.yaml)"
commands: hypershift-mce-power-create-commands.sh
from: dev-scripts
grace_period: 15m0s
Expand Down

0 comments on commit 1b2e556

Please sign in to comment.