From 616e2086ffb97aa3a116f0f91574eb2cc8baec28 Mon Sep 17 00:00:00 2001 From: Mark Goddard Date: Fri, 2 Feb 2024 14:11:03 +0000 Subject: [PATCH 1/3] CI: Remove use of venv from package-promote.yml This crept back in in df1f57effba79e0e806e18256326c708a66c5366 by accident. --- .github/workflows/package-promote.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/package-promote.yml b/.github/workflows/package-promote.yml index 1cd9a5ef..e2618584 100644 --- a/.github/workflows/package-promote.yml +++ b/.github/workflows/package-promote.yml @@ -48,7 +48,6 @@ jobs: if [[ $CHECK_MODE = true ]]; then args="$args --check --diff" fi - source venv/bin/activate && ansible-playbook -i ansible/inventory \ ansible/dev-pulp-repo-version-query-kayobe.yml \ ansible/dev-pulp-repo-promote.yml \ From 604be26f3d737176fc789bff6b34744fabc7d9ee Mon Sep 17 00:00:00 2001 From: Mark Goddard Date: Fri, 2 Feb 2024 14:13:12 +0000 Subject: [PATCH 2/3] CI: Update GitHub actions versions to those using node 20 See https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/ --- .github/actions/setup/action.yml | 2 +- .github/workflows/container-promote-old.yml | 2 +- .github/workflows/container-promote.yml | 2 +- .github/workflows/package-update-kayobe.yml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/actions/setup/action.yml b/.github/actions/setup/action.yml index 9556c36c..d3a1def3 100644 --- a/.github/actions/setup/action.yml +++ b/.github/actions/setup/action.yml @@ -13,7 +13,7 @@ inputs: runs: using: composite steps: - - uses: actions/setup-python@v3 + - uses: actions/setup-python@v4 with: python-version: 3.11.x # Cache Python dependencies diff --git a/.github/workflows/container-promote-old.yml b/.github/workflows/container-promote-old.yml index 19b2b064..4e12de31 100644 --- a/.github/workflows/container-promote-old.yml +++ b/.github/workflows/container-promote-old.yml @@ -34,7 +34,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup Release Train & dependencies uses: ./.github/actions/setup diff --git a/.github/workflows/container-promote.yml b/.github/workflows/container-promote.yml index 76eecf76..1a88fb01 100644 --- a/.github/workflows/container-promote.yml +++ b/.github/workflows/container-promote.yml @@ -35,7 +35,7 @@ jobs: vault-password-file: ${{ env.ANSIBLE_VAULT_PASSWORD_FILE }} - name: Clone StackHPC Kayobe configuration repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: repository: stackhpc/stackhpc-kayobe-config ref: refs/heads/${{ github.event.inputs.kayobe_config_branch }} diff --git a/.github/workflows/package-update-kayobe.yml b/.github/workflows/package-update-kayobe.yml index c80dfebf..2429d0ba 100644 --- a/.github/workflows/package-update-kayobe.yml +++ b/.github/workflows/package-update-kayobe.yml @@ -61,7 +61,7 @@ jobs: # For now, just create an artifact that the user can download. - name: Upload pulp-repo-versions.yml artifact if: ${{ steps.git-diff.outputs.changed == 'true' }} - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: pulp-repo-versions.yml path: stackhpc-kayobe-config/etc/kayobe/pulp-repo-versions.yml From e061754105eeec87457d1a171801f354fe52e273 Mon Sep 17 00:00:00 2001 From: Mark Goddard Date: Fri, 2 Feb 2024 14:14:49 +0000 Subject: [PATCH 3/3] CI: Use setup action in container-publish.yml This somehow missed the DRY conversion. --- .github/workflows/container-publish.yml | 21 +++++---------------- 1 file changed, 5 insertions(+), 16 deletions(-) diff --git a/.github/workflows/container-publish.yml b/.github/workflows/container-publish.yml index f4df440b..14131aa3 100644 --- a/.github/workflows/container-publish.yml +++ b/.github/workflows/container-publish.yml @@ -31,25 +31,14 @@ jobs: steps: - uses: actions/checkout@v4 - - name: Preparing Vault password file - run: | - echo "$ANSIBLE_VAULT_PASSWORD" > "$ANSIBLE_VAULT_PASSWORD_FILE" - env: - ANSIBLE_VAULT_PASSWORD: ${{ secrets.ANSIBLE_VAULT_PASSWORD }} - - - name: Installing dependencies - run: | - sudo apt update && - sudo apt install -y python3-venv && - python3 -m venv venv && - source venv/bin/activate && - pip install -U pip && - pip install -r requirements.txt && - ansible-galaxy collection install -r requirements.yml -p ansible/collections + - name: Setup Release Train & dependencies + uses: ./.github/actions/setup + with: + vault-password: ${{ secrets.ANSIBLE_VAULT_PASSWORD }} + vault-password-file: ${{ env.ANSIBLE_VAULT_PASSWORD_FILE }} - name: Publish container repositories run: | - source venv/bin/activate && ansible-playbook -i ansible/inventory \ ansible/dev-pulp-container-publish.yml \ -e kolla_container_image_filter="'$FILTER'" \