From ee370e5819a9538a97a96b7aed9dd79316bd3744 Mon Sep 17 00:00:00 2001 From: Sacha Avazashvili Date: Fri, 13 Sep 2024 12:36:39 +0200 Subject: [PATCH 1/9] test --- .github/workflows/build-release.yml | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-release.yml b/.github/workflows/build-release.yml index 5e2583a4..10b5dbaa 100644 --- a/.github/workflows/build-release.yml +++ b/.github/workflows/build-release.yml @@ -41,5 +41,17 @@ jobs: uses: actions/upload-artifact@v4 with: name: ${{ github.event.repository.name }} - path: ./ + path: '.' include-hidden-files: true + + - name: Download artifact + uses: actions/download-artifact@v4 + with: + name: ${{ github.event.repository.name }} + path: '.' + + - name: Debug + run: | + pwd + ls -la + From 2b88dd364ee48d52e0d469c76a545af0d154596d Mon Sep 17 00:00:00 2001 From: Sacha Avazashvili Date: Fri, 13 Sep 2024 12:41:23 +0200 Subject: [PATCH 2/9] test --- .github/workflows/build-release.yml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-release.yml b/.github/workflows/build-release.yml index 10b5dbaa..229550c6 100644 --- a/.github/workflows/build-release.yml +++ b/.github/workflows/build-release.yml @@ -44,14 +44,25 @@ jobs: path: '.' include-hidden-files: true + debug: + name: Upload the production zip asset to the release + runs-on: ubuntu-latest + needs: build + steps: - name: Download artifact uses: actions/download-artifact@v4 with: name: ${{ github.event.repository.name }} path: '.' - - name: Debug + - name: Prepare the production zip run: | pwd ls -la + + - name: Prepare the production zip + run: | + cd ${{ github.event.repository.name }} + zip -r ${{ github.event.repository.name }}-${{ github.event.release.tag_name }}.zip ${{ github.event.repository.name }} -x '*.git*' + From cc63f55d63f8f2b87a25bf4e1e5d081076db3445 Mon Sep 17 00:00:00 2001 From: Sacha Avazashvili Date: Fri, 13 Sep 2024 12:44:02 +0200 Subject: [PATCH 3/9] test --- .github/workflows/build-release.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/build-release.yml b/.github/workflows/build-release.yml index 229550c6..13031290 100644 --- a/.github/workflows/build-release.yml +++ b/.github/workflows/build-release.yml @@ -45,7 +45,7 @@ jobs: include-hidden-files: true debug: - name: Upload the production zip asset to the release + name: Debug runs-on: ubuntu-latest needs: build steps: @@ -60,9 +60,7 @@ jobs: pwd ls -la - - name: Prepare the production zip run: | - cd ${{ github.event.repository.name }} zip -r ${{ github.event.repository.name }}-${{ github.event.release.tag_name }}.zip ${{ github.event.repository.name }} -x '*.git*' From 5fc7bbaf1f82ce25c418bcee510ee99296e9999e Mon Sep 17 00:00:00 2001 From: Sacha Avazashvili Date: Fri, 13 Sep 2024 12:47:50 +0200 Subject: [PATCH 4/9] test --- .github/workflows/build-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-release.yml b/.github/workflows/build-release.yml index 13031290..71b8db2c 100644 --- a/.github/workflows/build-release.yml +++ b/.github/workflows/build-release.yml @@ -53,7 +53,7 @@ jobs: uses: actions/download-artifact@v4 with: name: ${{ github.event.repository.name }} - path: '.' + path: './'${{ github.event.repository.name }} - name: Prepare the production zip run: | From bf977a5487dd2b09b59f5ae872281e4267794ec9 Mon Sep 17 00:00:00 2001 From: Sacha Avazashvili Date: Fri, 13 Sep 2024 12:51:27 +0200 Subject: [PATCH 5/9] test --- .github/workflows/build-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-release.yml b/.github/workflows/build-release.yml index 71b8db2c..e2c475bd 100644 --- a/.github/workflows/build-release.yml +++ b/.github/workflows/build-release.yml @@ -53,7 +53,7 @@ jobs: uses: actions/download-artifact@v4 with: name: ${{ github.event.repository.name }} - path: './'${{ github.event.repository.name }} + path: ./${{ github.event.repository.name }} - name: Prepare the production zip run: | From c4387f522beed1ab8fc788b0cefafcef7fa7da62 Mon Sep 17 00:00:00 2001 From: Sacha Avazashvili Date: Fri, 13 Sep 2024 13:08:09 +0200 Subject: [PATCH 6/9] test --- .github/workflows/build-release.yml | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build-release.yml b/.github/workflows/build-release.yml index e2c475bd..a10e7aba 100644 --- a/.github/workflows/build-release.yml +++ b/.github/workflows/build-release.yml @@ -55,12 +55,19 @@ jobs: name: ${{ github.event.repository.name }} path: ./${{ github.event.repository.name }} - - name: Prepare the production zip + - name: Set up Cloud SDK + uses: google-github-actions/setup-gcloud@v0 + with: + project_id: ${{ secrets.G_PROJECT_INTEGRATION }} + service_account_key: ${{ secrets.G_CREDENTIAL_INTEGRATION }} + export_default_credentials: true + + - name: Copy env files run: | pwd ls -la - - - name: Prepare the production zip - run: | - zip -r ${{ github.event.repository.name }}-${{ github.event.release.tag_name }}.zip ${{ github.event.repository.name }} -x '*.git*' + gcloud components install beta + gcloud beta secrets versions access latest --secret="${{env.GLOUD_SECRET_NAME}}" >> ${{ github.event.repository.name }}/${{ github.event.repository.name }}/.env + env: + GOOGLE_APPLICATION_CREDENTIALS: ${{ secrets.G_CREDENTIAL_INTEGRATION }} From 452f45062d81afd351a4ccbeba95391f56ab2d7e Mon Sep 17 00:00:00 2001 From: Sacha Avazashvili Date: Fri, 13 Sep 2024 13:10:52 +0200 Subject: [PATCH 7/9] jpp --- .github/workflows/build-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-release.yml b/.github/workflows/build-release.yml index a10e7aba..f4eb1b4a 100644 --- a/.github/workflows/build-release.yml +++ b/.github/workflows/build-release.yml @@ -67,7 +67,7 @@ jobs: pwd ls -la gcloud components install beta - gcloud beta secrets versions access latest --secret="${{env.GLOUD_SECRET_NAME}}" >> ${{ github.event.repository.name }}/${{ github.event.repository.name }}/.env + gcloud beta secrets versions access latest --secret="${{env.GLOUD_SECRET_NAME}}" >> ${{ github.event.repository.name }}/${{ github.event.repository.name }}/${{ github.event.repository.name }}/.env env: GOOGLE_APPLICATION_CREDENTIALS: ${{ secrets.G_CREDENTIAL_INTEGRATION }} From d5080c674448565d8cfeeadebe8589c96faeb06e Mon Sep 17 00:00:00 2001 From: Sacha Avazashvili Date: Fri, 13 Sep 2024 13:13:56 +0200 Subject: [PATCH 8/9] i m hungry --- .github/workflows/build-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-release.yml b/.github/workflows/build-release.yml index f4eb1b4a..56c44ef8 100644 --- a/.github/workflows/build-release.yml +++ b/.github/workflows/build-release.yml @@ -67,7 +67,7 @@ jobs: pwd ls -la gcloud components install beta - gcloud beta secrets versions access latest --secret="${{env.GLOUD_SECRET_NAME}}" >> ${{ github.event.repository.name }}/${{ github.event.repository.name }}/${{ github.event.repository.name }}/.env + gcloud beta secrets versions access latest --secret="${{env.GLOUD_SECRET_NAME}}" >> ./${{ github.event.repository.name }}/.env env: GOOGLE_APPLICATION_CREDENTIALS: ${{ secrets.G_CREDENTIAL_INTEGRATION }} From 99ce317bd946b9b5b9006381adc45ec637ae4415 Mon Sep 17 00:00:00 2001 From: Sacha Avazashvili Date: Fri, 13 Sep 2024 13:27:34 +0200 Subject: [PATCH 9/9] debugs --- .github/workflows/build-release.yml | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/.github/workflows/build-release.yml b/.github/workflows/build-release.yml index 56c44ef8..9c14ffe0 100644 --- a/.github/workflows/build-release.yml +++ b/.github/workflows/build-release.yml @@ -55,19 +55,13 @@ jobs: name: ${{ github.event.repository.name }} path: ./${{ github.event.repository.name }} - - name: Set up Cloud SDK - uses: google-github-actions/setup-gcloud@v0 - with: - project_id: ${{ secrets.G_PROJECT_INTEGRATION }} - service_account_key: ${{ secrets.G_CREDENTIAL_INTEGRATION }} - export_default_credentials: true + - name: Prepare the production zip + run: | + zip -r ${{ github.event.repository.name }}-${{ github.event.release.tag_name }}.zip ${{ github.event.repository.name }} -x '*.git*' - - name: Copy env files + - name: Debug run: | pwd ls -la - gcloud components install beta - gcloud beta secrets versions access latest --secret="${{env.GLOUD_SECRET_NAME}}" >> ./${{ github.event.repository.name }}/.env - env: - GOOGLE_APPLICATION_CREDENTIALS: ${{ secrets.G_CREDENTIAL_INTEGRATION }} +