From da8439f14d3b85327f32e2281c0c275fff4b7cc9 Mon Sep 17 00:00:00 2001 From: grant-mcs Date: Fri, 6 May 2022 21:56:14 -0400 Subject: [PATCH 1/3] Add comment to warn about the side effect of committing and pushing changes in a workflow --- .github/workflows/html-app-publish.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/html-app-publish.yml b/.github/workflows/html-app-publish.yml index f9631a4..6dec173 100644 --- a/.github/workflows/html-app-publish.yml +++ b/.github/workflows/html-app-publish.yml @@ -75,6 +75,8 @@ jobs: # against the sigstore community Fulcio instance. run: cosign sign ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}@${{ steps.build-and-push.outputs.digest }} + # WARNING! This will cause any PR running these actions to be automatically merged. + # It should NOT be run except on the merge of a PR. # Update k8s manifest and commit the change - name: Update k8s manifest run: python ./.github/workflows/update-k8s-manifest.py ./html-app/k8s-manifest.yaml ${{ steps.meta.outputs.labels.org.opencontainers.image.version }} From 090962cdbac05a04db8e32f6e1e076c7a86f6c3e Mon Sep 17 00:00:00 2001 From: grant-mcs Date: Fri, 6 May 2022 21:58:55 -0400 Subject: [PATCH 2/3] Allow the testing of k8s deploy in CI --- .github/workflows/ci.yml | 2 +- .github/workflows/html-app-publish.yml | 24 ++++++++++++------------ 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ac3c4e5..89110bf 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -18,4 +18,4 @@ jobs: temp-call-publish-html-app: name: TEMP - Publish HTML app - uses: eclipse-pass/playground/.github/workflows/html-app-publish.yml@main + uses: eclipse-pass/playground/.github/workflows/html-app-publish.yml@c5108cb789850b7b9b542eddca05539679c4fec9 diff --git a/.github/workflows/html-app-publish.yml b/.github/workflows/html-app-publish.yml index 6dec173..e8ffd61 100644 --- a/.github/workflows/html-app-publish.yml +++ b/.github/workflows/html-app-publish.yml @@ -78,18 +78,18 @@ jobs: # WARNING! This will cause any PR running these actions to be automatically merged. # It should NOT be run except on the merge of a PR. # Update k8s manifest and commit the change - - name: Update k8s manifest - run: python ./.github/workflows/update-k8s-manifest.py ./html-app/k8s-manifest.yaml ${{ steps.meta.outputs.labels.org.opencontainers.image.version }} - - uses: fregante/setup-git-user@v1 - - name: Add updated file - run: git add ./html-app/k8s-manifest.yaml - - name: Commit update - run: git commit -m "Auto updating html-app/k8s-manifest.yaml to use ${{ steps.meta.outputs.tags }}" - - name: Push changes - uses: ad-m/github-push-action@master - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - branch: main + # - name: Update k8s manifest + # run: python ./.github/workflows/update-k8s-manifest.py ./html-app/k8s-manifest.yaml ${{ steps.meta.outputs.labels.org.opencontainers.image.version }} + # - uses: fregante/setup-git-user@v1 + # - name: Add updated file + # run: git add ./html-app/k8s-manifest.yaml + # - name: Commit update + # run: git commit -m "Auto updating html-app/k8s-manifest.yaml to use ${{ steps.meta.outputs.tags }}" + # - name: Push changes + # uses: ad-m/github-push-action@master + # with: + # github_token: ${{ secrets.GITHUB_TOKEN }} + # branch: main # Deploy the new Docker image to our test k8s cluster # The KUBE_CONFIG secret contains the information about where our k8s cluster can be found From e64f6eb1e13c33494ace6eff2ce57230dd392766 Mon Sep 17 00:00:00 2001 From: grant-mcs Date: Fri, 6 May 2022 22:44:03 -0400 Subject: [PATCH 3/3] TEMP - Update hash in ci.yml --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 89110bf..753165b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -18,4 +18,4 @@ jobs: temp-call-publish-html-app: name: TEMP - Publish HTML app - uses: eclipse-pass/playground/.github/workflows/html-app-publish.yml@c5108cb789850b7b9b542eddca05539679c4fec9 + uses: eclipse-pass/playground/.github/workflows/html-app-publish.yml@090962cdbac05a04db8e32f6e1e076c7a86f6c3e