Skip to content

Commit

Permalink
revert ocp install (#743)
Browse files Browse the repository at this point in the history
  • Loading branch information
ebattat authored Nov 15, 2023
1 parent 64cec00 commit a269b48
Show file tree
Hide file tree
Showing 2 changed files with 60 additions and 14 deletions.
35 changes: 29 additions & 6 deletions .github/workflows/Weekly_Func_Env_Installer_CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,10 +76,33 @@ jobs:
build=$(pip freeze | grep benchmark-runner | sed 's/==/=/g')
build_version="$(cut -d'=' -f2 <<<"$build")"
echo '>>>>>>>>>>>>>>>>>>>>>>>>>> OCP start step: ${{ matrix.step }} >>>>>>>>>>>>>>>>>>>>>>>>>>>>'
# Run OCP Install on provision machine
scp -r "/$RUNNER_PATH/.ssh/config" provision:"/$PROVISION_USER/.ssh/config"
scp -r "$PROVISION_PRIVATE_KEY_PATH" provision:"$CONTAINER_PRIVATE_KEY_PATH"
echo -e "podman run --rm -e OCP_ENV_FLAVOR=PERF -e IBM_API_KEY=$IBM_API_KEY -e GITHUB_TOKEN=$GITHUB_TOKEN -e INSTALL_OCP_VERSION=$INSTALL_OCP_VERSION -e INSTALL_STEP=${{ matrix.step }} -e WORKER_IDS=$WORKER_IDS -e PROVISION_IP=$PROVISION_IP -e CONTAINER_PRIVATE_KEY_PATH=$CONTAINER_PRIVATE_KEY_PATH -e CONTAINER_PRIVATE_KEY_PATH=$CONTAINER_PRIVATE_KEY_PATH -e PROVISION_USER=$PROVISION_USER -e PROVISION_PORT=$PROVISION_PORT -e PROVISION_KUBEADMIN_PASSWORD_PATH=$PROVISION_KUBEADMIN_PASSWORD_PATH -e PROVISION_KUBECONFIG_PATH=$PROVISION_KUBECONFIG_PATH -e PROVISION_INSTALLER_PATH=$PROVISION_INSTALLER_PATH -e PROVISION_INSTALLER_CMD=$PROVISION_INSTALLER_CMD -e PROVISION_INSTALLER_LOG=$PROVISION_INSTALLER_LOG -e GITHUB_REPOSITORY_SHORT=$GITHUB_REPOSITORY_SHORT -e PROVISION_TIMEOUT=3600 -e log_level=INFO -v $CONTAINER_PRIVATE_KEY_PATH:$CONTAINER_PRIVATE_KEY_PATH -v /$PROVISION_USER/.ssh/config:/$PROVISION_USER/.ssh/config --privileged quay.io/ebattat/benchmark-runner:latest" > "$RUNNER_PATH/install_ocp.sh"
scp -r "$RUNNER_PATH/install_ocp.sh" provision:"/tmp/install_ocp.sh"
ssh -t provision "chmod +x /tmp/install_ocp.sh;/tmp/./install_ocp.sh;rm -f /tmp/install_ocp.sh"
podman run --rm -e OCP_ENV_FLAVOR="PERF" -e IBM_API_KEY="$IBM_API_KEY" -e GITHUB_TOKEN="$GITHUB_TOKEN" -e INSTALL_OCP_VERSION="$INSTALL_OCP_VERSION" -e INSTALL_STEP="${{ matrix.step }}" -e WORKER_IDS="$WORKER_IDS" -e PROVISION_IP="$PROVISION_IP" -e CONTAINER_PRIVATE_KEY_PATH="$CONTAINER_PRIVATE_KEY_PATH" -e CONTAINER_PRIVATE_KEY_PATH="$CONTAINER_PRIVATE_KEY_PATH" -e PROVISION_USER="$PROVISION_USER" -e PROVISION_PORT="$PROVISION_PORT" -e PROVISION_KUBEADMIN_PASSWORD_PATH="$PROVISION_KUBEADMIN_PASSWORD_PATH" -e PROVISION_KUBECONFIG_PATH="$PROVISION_KUBECONFIG_PATH" -e PROVISION_INSTALLER_PATH="$PROVISION_INSTALLER_PATH" -e PROVISION_INSTALLER_CMD="$PROVISION_INSTALLER_CMD" -e PROVISION_INSTALLER_LOG="$PROVISION_INSTALLER_LOG" -e GITHUB_REPOSITORY_SHORT="$GITHUB_REPOSITORY_SHORT" -e PROVISION_TIMEOUT="3600" -e log_level="INFO" -v "$PROVISION_PRIVATE_KEY_PATH":"$CONTAINER_PRIVATE_KEY_PATH" -v "/$RUNNER_PATH/.ssh/config":"/$PROVISION_USER/.ssh/config" --privileged "quay.io/ebattat/benchmark-runner:latest"
echo '>>>>>>>>>>>>>>>>>>>>>>>>>> OCP end step: ${{ matrix.step }} >>>>>>>>>>>>>>>>>>>>>>>>>>>>'
- name: ▶ Rerun OCP assisted install after failure
env:
INSTALL_OCP_VERSION: "latest-4.14"
OCP_CLIENT_VERSION: "4.14.1"
IBM_API_KEY: ${{ secrets.IBM_API_KEY }}
GITHUB_TOKEN: ${{ secrets.GIT_TOKEN }}
WORKER_IDS: ${{ secrets.PERF_WORKER_IDS }}
PROVISION_IP: ${{ secrets.PERF_PROVISION_IP }}
PROVISION_USER: ${{ secrets.PERF_PROVISION_USER }}
PROVISION_PORT: ${{ secrets.PERF_PROVISION_PORT }}
PROVISION_KUBEADMIN_PASSWORD_PATH: ${{ secrets.PERF_PROVISION_KUBEADMIN_PASSWORD_PATH }}
PROVISION_KUBECONFIG_PATH: ${{ secrets.PERF_PROVISION_KUBECONFIG_PATH }}
PROVISION_INSTALLER_PATH: ${{ secrets.PERF_PROVISION_INSTALLER_PATH }}
PROVISION_INSTALLER_CMD: ${{ secrets.PERF_PROVISION_INSTALLER_CMD }}
PROVISION_INSTALLER_LOG: ${{ secrets.PERF_PROVISION_INSTALLER_LOG }}
GITHUB_REPOSITORY_SHORT: ${{ secrets.GIT_REPOSITORY_SHORT }}
CONTAINER_PRIVATE_KEY_PATH: ${{ secrets.CONTAINER_PRIVATE_KEY_PATH }}
RUNNER_PATH: ${{ secrets.RUNNER_PATH }}
if: ${{ failure() }}
run: |
build=$(pip freeze | grep benchmark-runner | sed 's/==/=/g')
build_version="$(cut -d'=' -f2 <<<"$build")"
echo '>>>>>>>>>>>>>>>>>>>>>>>>>> OCP start step: run_ibm_ocp_installer >>>>>>>>>>>>>>>>>>>>>>>>>>>>'
podman run --rm -e OCP_ENV_FLAVOR="PERF" -e IBM_API_KEY="$IBM_API_KEY" -e GITHUB_TOKEN="$GITHUB_TOKEN" -e INSTALL_OCP_VERSION="$INSTALL_OCP_VERSION" -e INSTALL_STEP="run_ibm_ocp_ipi_installer" -e WORKER_IDS="$WORKER_IDS" -e PROVISION_IP="$PROVISION_IP" -e CONTAINER_PRIVATE_KEY_PATH="$CONTAINER_PRIVATE_KEY_PATH" -e CONTAINER_PRIVATE_KEY_PATH="$CONTAINER_PRIVATE_KEY_PATH" -e PROVISION_USER="$PROVISION_USER" -e PROVISION_PORT="$PROVISION_PORT" -e PROVISION_KUBEADMIN_PASSWORD_PATH="$PROVISION_KUBEADMIN_PASSWORD_PATH" -e PROVISION_KUBECONFIG_PATH="$PROVISION_KUBECONFIG_PATH" -e PROVISION_INSTALLER_PATH="$PROVISION_INSTALLER_PATH" -e PROVISION_INSTALLER_CMD="$PROVISION_INSTALLER_CMD" -e PROVISION_INSTALLER_LOG="$PROVISION_INSTALLER_LOG" -e GITHUB_REPOSITORY_SHORT="$GITHUB_REPOSITORY_SHORT" -e PROVISION_TIMEOUT="3600" -e log_level="INFO" -v "$PROVISION_PRIVATE_KEY_PATH":"$CONTAINER_PRIVATE_KEY_PATH" -v "/$RUNNER_PATH/.ssh/config":"/$PROVISION_USER/.ssh/config" --privileged "quay.io/ebattat/benchmark-runner:latest"
echo '>>>>>>>>>>>>>>>>>>>>>>>>>> OCP end step: run_ibm_ocp_ipi_installer >>>>>>>>>>>>>>>>>>>>>>>>>>>>'
echo '>>>>>>>>>>>>>>>>>>>>>>>>>> OCP start step: verify_install_complete >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>'
podman run --rm -e OCP_ENV_FLAVOR="PERF" -e IBM_API_KEY="$IBM_API_KEY" -e GITHUB_TOKEN="$GITHUB_TOKEN" -e INSTALL_OCP_VERSION="$INSTALL_OCP_VERSION" -e INSTALL_STEP="verify_install_complete" -e WORKER_IDS="$WORKER_IDS" -e PROVISION_IP="$PROVISION_IP" -e CONTAINER_PRIVATE_KEY_PATH="$CONTAINER_PRIVATE_KEY_PATH" -e CONTAINER_PRIVATE_KEY_PATH="$CONTAINER_PRIVATE_KEY_PATH" -e PROVISION_USER="$PROVISION_USER" -e PROVISION_PORT="$PROVISION_PORT" -e PROVISION_KUBEADMIN_PASSWORD_PATH="$PROVISION_KUBEADMIN_PASSWORD_PATH" -e PROVISION_KUBECONFIG_PATH="$PROVISION_KUBECONFIG_PATH" -e PROVISION_INSTALLER_PATH="$PROVISION_INSTALLER_PATH" -e PROVISION_INSTALLER_CMD="$PROVISION_INSTALLER_CMD" -e PROVISION_INSTALLER_LOG="$PROVISION_INSTALLER_LOG" -e GITHUB_REPOSITORY_SHORT="$GITHUB_REPOSITORY_SHORT" -e PROVISION_TIMEOUT="3600" -e log_level="INFO" -v "$PROVISION_PRIVATE_KEY_PATH":"$CONTAINER_PRIVATE_KEY_PATH" --privileged "quay.io/ebattat/benchmark-runner:latest"
echo '>>>>>>>>>>>>>>>>>>>>>>>>>> OCP end step: verify_install_complete >>>>>>>>>>>>>>>>>>>>>>>>>>>>'
39 changes: 31 additions & 8 deletions .github/workflows/Weekly_Perf_Env_Installer_CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ on:
concurrency:
group: performance-environment
cancel-in-progress: false

jobs:
ocp_installer:
name: OCP
Expand All @@ -22,7 +22,7 @@ jobs:
max-parallel: 1
# continue to next job if failed
fail-fast: false
matrix:
matrix:
step: [ 'run_ibm_ocp_installer', 'verify_install_complete' ]
steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -76,10 +76,33 @@ jobs:
build=$(pip freeze | grep benchmark-runner | sed 's/==/=/g')
build_version="$(cut -d'=' -f2 <<<"$build")"
echo '>>>>>>>>>>>>>>>>>>>>>>>>>> OCP start step: ${{ matrix.step }} >>>>>>>>>>>>>>>>>>>>>>>>>>>>'
# Run OCP Install on provision machine
scp -r "/$RUNNER_PATH/.ssh/config" provision:"/$PROVISION_USER/.ssh/config"
scp -r "$PROVISION_PRIVATE_KEY_PATH" provision:"$CONTAINER_PRIVATE_KEY_PATH"
echo -e "podman run --rm -e OCP_ENV_FLAVOR=PERF -e IBM_API_KEY=$IBM_API_KEY -e GITHUB_TOKEN=$GITHUB_TOKEN -e INSTALL_OCP_VERSION=$INSTALL_OCP_VERSION -e INSTALL_STEP=${{ matrix.step }} -e WORKER_IDS=$WORKER_IDS -e PROVISION_IP=$PROVISION_IP -e CONTAINER_PRIVATE_KEY_PATH=$CONTAINER_PRIVATE_KEY_PATH -e CONTAINER_PRIVATE_KEY_PATH=$CONTAINER_PRIVATE_KEY_PATH -e PROVISION_USER=$PROVISION_USER -e PROVISION_PORT=$PROVISION_PORT -e PROVISION_KUBEADMIN_PASSWORD_PATH=$PROVISION_KUBEADMIN_PASSWORD_PATH -e PROVISION_KUBECONFIG_PATH=$PROVISION_KUBECONFIG_PATH -e PROVISION_INSTALLER_PATH=$PROVISION_INSTALLER_PATH -e PROVISION_INSTALLER_CMD=$PROVISION_INSTALLER_CMD -e PROVISION_INSTALLER_LOG=$PROVISION_INSTALLER_LOG -e GITHUB_REPOSITORY_SHORT=$GITHUB_REPOSITORY_SHORT -e PROVISION_TIMEOUT=3600 -e log_level=INFO -v $CONTAINER_PRIVATE_KEY_PATH:$CONTAINER_PRIVATE_KEY_PATH -v /$PROVISION_USER/.ssh/config:/$PROVISION_USER/.ssh/config --privileged quay.io/ebattat/benchmark-runner:latest" > "$RUNNER_PATH/install_ocp.sh"
scp -r "$RUNNER_PATH/install_ocp.sh" provision:"/tmp/install_ocp.sh"
ssh -t provision "chmod +x /tmp/install_ocp.sh;/tmp/./install_ocp.sh;rm -f /tmp/install_ocp.sh"
podman run --rm -e OCP_ENV_FLAVOR="PERF" -e IBM_API_KEY="$IBM_API_KEY" -e GITHUB_TOKEN="$GITHUB_TOKEN" -e INSTALL_OCP_VERSION="$INSTALL_OCP_VERSION" -e INSTALL_STEP="${{ matrix.step }}" -e WORKER_IDS="$WORKER_IDS" -e PROVISION_IP="$PROVISION_IP" -e CONTAINER_PRIVATE_KEY_PATH="$CONTAINER_PRIVATE_KEY_PATH" -e CONTAINER_PRIVATE_KEY_PATH="$CONTAINER_PRIVATE_KEY_PATH" -e PROVISION_USER="$PROVISION_USER" -e PROVISION_PORT="$PROVISION_PORT" -e PROVISION_KUBEADMIN_PASSWORD_PATH="$PROVISION_KUBEADMIN_PASSWORD_PATH" -e PROVISION_KUBECONFIG_PATH="$PROVISION_KUBECONFIG_PATH" -e PROVISION_INSTALLER_PATH="$PROVISION_INSTALLER_PATH" -e PROVISION_INSTALLER_CMD="$PROVISION_INSTALLER_CMD" -e PROVISION_INSTALLER_LOG="$PROVISION_INSTALLER_LOG" -e GITHUB_REPOSITORY_SHORT="$GITHUB_REPOSITORY_SHORT" -e PROVISION_TIMEOUT="3600" -e log_level="INFO" -v "$PROVISION_PRIVATE_KEY_PATH":"$CONTAINER_PRIVATE_KEY_PATH" -v "/$RUNNER_PATH/.ssh/config":"/$PROVISION_USER/.ssh/config" --privileged "quay.io/ebattat/benchmark-runner:latest"
echo '>>>>>>>>>>>>>>>>>>>>>>>>>> OCP end step: ${{ matrix.step }} >>>>>>>>>>>>>>>>>>>>>>>>>>>>'
- name: ▶ Rerun OCP assisted install after failure
env:
INSTALL_OCP_VERSION: "latest-4.14"
OCP_CLIENT_VERSION: "4.14.1"
IBM_API_KEY: ${{ secrets.IBM_API_KEY }}
GITHUB_TOKEN: ${{ secrets.GIT_TOKEN }}
WORKER_IDS: ${{ secrets.PERF_WORKER_IDS }}
PROVISION_IP: ${{ secrets.PERF_PROVISION_IP }}
PROVISION_USER: ${{ secrets.PERF_PROVISION_USER }}
PROVISION_PORT: ${{ secrets.PERF_PROVISION_PORT }}
PROVISION_KUBEADMIN_PASSWORD_PATH: ${{ secrets.PERF_PROVISION_KUBEADMIN_PASSWORD_PATH }}
PROVISION_KUBECONFIG_PATH: ${{ secrets.PERF_PROVISION_KUBECONFIG_PATH }}
PROVISION_INSTALLER_PATH: ${{ secrets.PERF_PROVISION_INSTALLER_PATH }}
PROVISION_INSTALLER_CMD: ${{ secrets.PERF_PROVISION_INSTALLER_CMD }}
PROVISION_INSTALLER_LOG: ${{ secrets.PERF_PROVISION_INSTALLER_LOG }}
GITHUB_REPOSITORY_SHORT: ${{ secrets.GIT_REPOSITORY_SHORT }}
CONTAINER_PRIVATE_KEY_PATH: ${{ secrets.CONTAINER_PRIVATE_KEY_PATH }}
RUNNER_PATH: ${{ secrets.RUNNER_PATH }}
if: ${{ failure() }}
run: |
build=$(pip freeze | grep benchmark-runner | sed 's/==/=/g')
build_version="$(cut -d'=' -f2 <<<"$build")"
echo '>>>>>>>>>>>>>>>>>>>>>>>>>> OCP start step: run_ibm_ocp_installer >>>>>>>>>>>>>>>>>>>>>>>>>>>>'
podman run --rm -e OCP_ENV_FLAVOR="PERF" -e IBM_API_KEY="$IBM_API_KEY" -e GITHUB_TOKEN="$GITHUB_TOKEN" -e INSTALL_OCP_VERSION="$INSTALL_OCP_VERSION" -e INSTALL_STEP="run_ibm_ocp_ipi_installer" -e WORKER_IDS="$WORKER_IDS" -e PROVISION_IP="$PROVISION_IP" -e CONTAINER_PRIVATE_KEY_PATH="$CONTAINER_PRIVATE_KEY_PATH" -e CONTAINER_PRIVATE_KEY_PATH="$CONTAINER_PRIVATE_KEY_PATH" -e PROVISION_USER="$PROVISION_USER" -e PROVISION_PORT="$PROVISION_PORT" -e PROVISION_KUBEADMIN_PASSWORD_PATH="$PROVISION_KUBEADMIN_PASSWORD_PATH" -e PROVISION_KUBECONFIG_PATH="$PROVISION_KUBECONFIG_PATH" -e PROVISION_INSTALLER_PATH="$PROVISION_INSTALLER_PATH" -e PROVISION_INSTALLER_CMD="$PROVISION_INSTALLER_CMD" -e PROVISION_INSTALLER_LOG="$PROVISION_INSTALLER_LOG" -e GITHUB_REPOSITORY_SHORT="$GITHUB_REPOSITORY_SHORT" -e PROVISION_TIMEOUT="3600" -e log_level="INFO" -v "$PROVISION_PRIVATE_KEY_PATH":"$CONTAINER_PRIVATE_KEY_PATH" -v "/$RUNNER_PATH/.ssh/config":"/$PROVISION_USER/.ssh/config" --privileged "quay.io/ebattat/benchmark-runner:latest"
echo '>>>>>>>>>>>>>>>>>>>>>>>>>> OCP end step: run_ibm_ocp_ipi_installer >>>>>>>>>>>>>>>>>>>>>>>>>>>>'
echo '>>>>>>>>>>>>>>>>>>>>>>>>>> OCP start step: verify_install_complete >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>'
podman run --rm -e OCP_ENV_FLAVOR="PERF" -e IBM_API_KEY="$IBM_API_KEY" -e GITHUB_TOKEN="$GITHUB_TOKEN" -e INSTALL_OCP_VERSION="$INSTALL_OCP_VERSION" -e INSTALL_STEP="verify_install_complete" -e WORKER_IDS="$WORKER_IDS" -e PROVISION_IP="$PROVISION_IP" -e CONTAINER_PRIVATE_KEY_PATH="$CONTAINER_PRIVATE_KEY_PATH" -e CONTAINER_PRIVATE_KEY_PATH="$CONTAINER_PRIVATE_KEY_PATH" -e PROVISION_USER="$PROVISION_USER" -e PROVISION_PORT="$PROVISION_PORT" -e PROVISION_KUBEADMIN_PASSWORD_PATH="$PROVISION_KUBEADMIN_PASSWORD_PATH" -e PROVISION_KUBECONFIG_PATH="$PROVISION_KUBECONFIG_PATH" -e PROVISION_INSTALLER_PATH="$PROVISION_INSTALLER_PATH" -e PROVISION_INSTALLER_CMD="$PROVISION_INSTALLER_CMD" -e PROVISION_INSTALLER_LOG="$PROVISION_INSTALLER_LOG" -e GITHUB_REPOSITORY_SHORT="$GITHUB_REPOSITORY_SHORT" -e PROVISION_TIMEOUT="3600" -e log_level="INFO" -v "$PROVISION_PRIVATE_KEY_PATH":"$CONTAINER_PRIVATE_KEY_PATH" --privileged "quay.io/ebattat/benchmark-runner:latest"
echo '>>>>>>>>>>>>>>>>>>>>>>>>>> OCP end step: verify_install_complete >>>>>>>>>>>>>>>>>>>>>>>>>>>>'

0 comments on commit a269b48

Please sign in to comment.