From 683618c5e733a9bd0f208a109fe65e01254a063e Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 10:56:00 +0300 Subject: [PATCH 01/25] feat: Github actions upload to S3 testing the theory --- .github/workflows/testing-test-build-app.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index 8c06126a834..9687bdf866a 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -29,7 +29,7 @@ jobs: ./gradlew assembleStagingCompat -p ./ --no-daemon uplod-to-s3: runs-on: buildjet-8vcpu-ubuntu-2204 - needs: [testing-build-app] + needs: [ testing-build-app ] steps: - name: Upload APK staging compat uses: ./.github/workflows/upload-aws-s3.yml From 5043cb3f06ba5278db55ed25e5bedbedc5f2d077 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 11:28:30 +0300 Subject: [PATCH 02/25] Testing 1 --- .github/workflows/testing-test-build-app.yml | 2 +- .github/workflows/upload-aws-s3.yml | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index 9687bdf866a..e086ae37dd2 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -1,6 +1,7 @@ name: "Testing Test Build App" on: + workflow_dispatch: merge_group: pull_request: types: [ opened, synchronize, edited ] @@ -29,7 +30,6 @@ jobs: ./gradlew assembleStagingCompat -p ./ --no-daemon uplod-to-s3: runs-on: buildjet-8vcpu-ubuntu-2204 - needs: [ testing-build-app ] steps: - name: Upload APK staging compat uses: ./.github/workflows/upload-aws-s3.yml diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index 366586b6d74..4d30a86e716 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -4,6 +4,7 @@ permissions: contents: read on: + workflow_dispatch: workflow_call: inputs: flavour: From b88391c1a61d1dd7209b7592a1a1ed360ba3ca79 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 11:31:29 +0300 Subject: [PATCH 03/25] Testing 2 --- .github/workflows/testing-test-build-app.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index e086ae37dd2..b63e9865bec 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -1,11 +1,10 @@ name: "Testing Test Build App" on: - workflow_dispatch: merge_group: pull_request: types: [ opened, synchronize, edited ] - workflow_call: + workflow_dispatch: jobs: testing-build-app: From 7e718bdc9dea2b1786abdca48f790ac0d7be3912 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 12:04:32 +0300 Subject: [PATCH 04/25] Testing 3 --- .github/workflows/testing-test-build-app.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index b63e9865bec..44b414ad06c 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -4,7 +4,7 @@ on: merge_group: pull_request: types: [ opened, synchronize, edited ] - workflow_dispatch: + workflow_call: jobs: testing-build-app: From c0f16d4b62b2749ec39a8c15229b943bbccf3ded Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 12:18:53 +0300 Subject: [PATCH 05/25] Testing 4 --- .github/workflows/testing-test-build-app.yml | 1 + .github/workflows/upload-aws-s3.yml | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index 44b414ad06c..c4321414453 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -28,6 +28,7 @@ jobs: run: | ./gradlew assembleStagingCompat -p ./ --no-daemon uplod-to-s3: + needs: [ testing-build-app ] runs-on: buildjet-8vcpu-ubuntu-2204 steps: - name: Upload APK staging compat diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index 4d30a86e716..366586b6d74 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -4,7 +4,6 @@ permissions: contents: read on: - workflow_dispatch: workflow_call: inputs: flavour: From 3aad0bce294f340734498e45e4f9efa3570884b4 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 12:28:36 +0300 Subject: [PATCH 06/25] Testing 5 --- .github/workflows/testing-test-build-app.yml | 5 +++++ .github/workflows/upload-aws-s3.yml | 5 ----- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index c4321414453..1206da31266 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -31,6 +31,11 @@ jobs: needs: [ testing-build-app ] runs-on: buildjet-8vcpu-ubuntu-2204 steps: + - name: Checkout + uses: actions/checkout@v4 + with: + submodules: recursive # Needed in order to fetch Kalium sources for building + fetch-depth: 0 - name: Upload APK staging compat uses: ./.github/workflows/upload-aws-s3.yml with: diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index 366586b6d74..10fc53f2b32 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -17,11 +17,6 @@ jobs: deploy-to-s3: runs-on: ubuntu-latest steps: - - name: Checkout - uses: actions/checkout@v4 - with: - submodules: recursive # Needed in order to fetch Kalium sources for building - fetch-depth: 0 - name: Uploading uses: hkusu/s3-upload-action@v2 with: From f70d343f387de22b00d4cad1734ca8c1674980fb Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 12:38:38 +0300 Subject: [PATCH 07/25] Testing 6 --- .github/workflows/testing-test-build-app.yml | 5 ----- .github/workflows/upload-aws-s3.yml | 11 +++++++---- 2 files changed, 7 insertions(+), 9 deletions(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index 1206da31266..c4321414453 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -31,11 +31,6 @@ jobs: needs: [ testing-build-app ] runs-on: buildjet-8vcpu-ubuntu-2204 steps: - - name: Checkout - uses: actions/checkout@v4 - with: - submodules: recursive # Needed in order to fetch Kalium sources for building - fetch-depth: 0 - name: Upload APK staging compat uses: ./.github/workflows/upload-aws-s3.yml with: diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index 10fc53f2b32..04dc31ba937 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -1,8 +1,5 @@ name: "Upload builds" -permissions: - contents: read - on: workflow_call: inputs: @@ -15,8 +12,14 @@ on: jobs: deploy-to-s3: - runs-on: ubuntu-latest + runs-on: buildjet-8vcpu-ubuntu-2204 steps: + - name: Checkout + uses: actions/checkout@v4 + with: + submodules: recursive # Needed in order to fetch Kalium sources for building + fetch-depth: 0 + - name: Uploading uses: hkusu/s3-upload-action@v2 with: From dcf12fb0e05f26cb59ef75191a6f58322ada90a8 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 12:45:02 +0300 Subject: [PATCH 08/25] Testing 7 --- .github/workflows/testing-test-build-app.yml | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index c4321414453..d0661b814c1 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -29,10 +29,7 @@ jobs: ./gradlew assembleStagingCompat -p ./ --no-daemon uplod-to-s3: needs: [ testing-build-app ] - runs-on: buildjet-8vcpu-ubuntu-2204 - steps: - - name: Upload APK staging compat - uses: ./.github/workflows/upload-aws-s3.yml - with: - flavour: "staging" - buildType: "compat" + uses: ./.github/workflows/upload-aws-s3.yml + with: + flavour: "staging" + buildType: "compat" From 9f0308ce43f1011ca0ae1ffe3c9af2f3936acdfe Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 12:56:42 +0300 Subject: [PATCH 09/25] Testing 8 --- .github/workflows/upload-aws-s3.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index 04dc31ba937..247fe03c883 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -22,6 +22,9 @@ jobs: - name: Uploading uses: hkusu/s3-upload-action@v2 + env: + GITHUB_USER: ${{ github.actor }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} From 62d7a9d5ad92fc902ce7a34eba654930a165febc Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 13:27:02 +0300 Subject: [PATCH 10/25] Testing 9 --- .github/workflows/upload-aws-s3.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index 247fe03c883..9b26259db0c 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -13,6 +13,9 @@ on: jobs: deploy-to-s3: runs-on: buildjet-8vcpu-ubuntu-2204 + env: + GITHUB_USER: ${{ github.actor }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} steps: - name: Checkout uses: actions/checkout@v4 @@ -21,10 +24,7 @@ jobs: fetch-depth: 0 - name: Uploading - uses: hkusu/s3-upload-action@v2 - env: - GITHUB_USER: ${{ github.actor }} - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + uses: hkusu/s3-upload-action@v2.1.0 with: aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} From e580d440d44e7fd403cf03e62326e6c92ad58b1e Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 14:39:10 +0300 Subject: [PATCH 11/25] Testing 10 --- .github/workflows/upload-aws-s3.yml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index 9b26259db0c..7f52869bba7 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -23,6 +23,21 @@ jobs: submodules: recursive # Needed in order to fetch Kalium sources for building fetch-depth: 0 + - name: Print secret 1 + run: | + echo "Secrets: ${{ secrets.AWS_ACCESS_KEY_ID }} " + env + + - name: Print secret 2 + run: | + echo "Secrets: ${{ secrets.AWS_SECRET_ACCESS_KEY }} " + env + + - name: Print secret 3 + run: | + echo "Secrets: ${{ secrets.AWS_S3_BUCKET }} " + env + - name: Uploading uses: hkusu/s3-upload-action@v2.1.0 with: From b2a7bdc04cff2be549d2fa086c327b42eeac1414 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 15:08:00 +0300 Subject: [PATCH 12/25] Testing 11 --- .github/workflows/testing-test-build-app.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index d0661b814c1..d628f7fa1e8 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -27,6 +27,11 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | ./gradlew assembleStagingCompat -p ./ --no-daemon + + - name: Print secret 0 + run: | + echo "Secrets: ${{ secrets.AWS_ACCESS_KEY_ID }} " + env uplod-to-s3: needs: [ testing-build-app ] uses: ./.github/workflows/upload-aws-s3.yml From c87907092b3cd2c6e073a35b78fc54b23ddeaa0c Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 15:14:55 +0300 Subject: [PATCH 13/25] Testing 12 --- .github/workflows/testing-test-build-app.yml | 9 +++---- .github/workflows/upload-aws-s3.yml | 28 +++++++------------- 2 files changed, 14 insertions(+), 23 deletions(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index d628f7fa1e8..8bf496f3ffd 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -27,14 +27,13 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | ./gradlew assembleStagingCompat -p ./ --no-daemon - - - name: Print secret 0 - run: | - echo "Secrets: ${{ secrets.AWS_ACCESS_KEY_ID }} " - env uplod-to-s3: needs: [ testing-build-app ] uses: ./.github/workflows/upload-aws-s3.yml with: flavour: "staging" buildType: "compat" + secrets: + aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} + aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} + aws-bucket: ${{ secrets.AWS_S3_BUCKET }} diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index 7f52869bba7..851e5154c43 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -9,6 +9,13 @@ on: buildType: required: true type: string + secrets: + aws-access-key-id: + required: true + aws-secret-access-key: + required: true + aws-bucket: + required: true jobs: deploy-to-s3: @@ -23,28 +30,13 @@ jobs: submodules: recursive # Needed in order to fetch Kalium sources for building fetch-depth: 0 - - name: Print secret 1 - run: | - echo "Secrets: ${{ secrets.AWS_ACCESS_KEY_ID }} " - env - - - name: Print secret 2 - run: | - echo "Secrets: ${{ secrets.AWS_SECRET_ACCESS_KEY }} " - env - - - name: Print secret 3 - run: | - echo "Secrets: ${{ secrets.AWS_S3_BUCKET }} " - env - - name: Uploading uses: hkusu/s3-upload-action@v2.1.0 with: - aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} - aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} + aws-access-key-id: ${{ secrets.aws-access-key-id }} + aws-secret-access-key: ${{ secrets.aws-secret-access-key }} aws-region: 'us-west-1' - aws-bucket: ${{ secrets.AWS_S3_BUCKET }} + aws-bucket: ${{ secrets.aws-bucket }} destination-dir: "megazord/android/reloaded/${inputs.flavour}/${inputs.buildType}/" file-path: './app/build/outputs/apk/${inputs.flavour}/${inputs.buildType}/com.wire.*.apk' output-file-url: 'true' From 4f556a17d92ab82fd15417e7cd8e5584b1b8383e Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 15:57:01 +0300 Subject: [PATCH 14/25] Testing 13 --- .github/workflows/upload-aws-s3.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index 851e5154c43..ab3b4d3b12c 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -17,6 +17,9 @@ on: aws-bucket: required: true +permissions: + contents: read + jobs: deploy-to-s3: runs-on: buildjet-8vcpu-ubuntu-2204 From 50788a02c4b21dfb668daa5e0676c90050bc1826 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 16:17:38 +0300 Subject: [PATCH 15/25] Testing 14 --- .github/workflows/testing-test-build-app.yml | 1 + .github/workflows/upload-aws-s3.yml | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index 8bf496f3ffd..20be4fab334 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -27,6 +27,7 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | ./gradlew assembleStagingCompat -p ./ --no-daemon + cp app/build/outputs/apk/staging/compat/com.wire.*.apk wire-android-staging-pr-${{ github.event.pull_request.number }}.apk uplod-to-s3: needs: [ testing-build-app ] uses: ./.github/workflows/upload-aws-s3.yml diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index ab3b4d3b12c..be087719782 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -40,8 +40,8 @@ jobs: aws-secret-access-key: ${{ secrets.aws-secret-access-key }} aws-region: 'us-west-1' aws-bucket: ${{ secrets.aws-bucket }} - destination-dir: "megazord/android/reloaded/${inputs.flavour}/${inputs.buildType}/" - file-path: './app/build/outputs/apk/${inputs.flavour}/${inputs.buildType}/com.wire.*.apk' + destination-dir: "megazord/android/reloaded/${{inputs.flavour}}/${{inputs.buildType}}/" + file-path: './app/build/outputs/apk/${{inputs.flavour}}/${{inputs.buildType}}/com.wire.*.apk' output-file-url: 'true' - name: Show URL From 4e7ac0c3d9f06af8429a4ba2a9daa43bcd2d1821 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 16:32:10 +0300 Subject: [PATCH 16/25] Testing 15 --- .github/workflows/upload-aws-s3.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index be087719782..d3594290dff 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -33,6 +33,18 @@ jobs: submodules: recursive # Needed in order to fetch Kalium sources for building fetch-depth: 0 + - name: Checking 2 + run: | + ls -la ./app/build/outputs/apk + + - name: Checking 1 + run: | + ls -la ./app/build/outputs/apk/${{inputs.flavour}} + + - name: Checking 0 + run: | + ls -la ./app/build/outputs/apk/${{inputs.flavour}}/${{inputs.buildType}}/ + - name: Uploading uses: hkusu/s3-upload-action@v2.1.0 with: From 901236a1bb921a6c4210a69878c402bd21eb2d09 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 17:07:50 +0300 Subject: [PATCH 17/25] Testing 16 --- .github/workflows/upload-aws-s3.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index d3594290dff..7ea1848f0c4 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -33,6 +33,18 @@ jobs: submodules: recursive # Needed in order to fetch Kalium sources for building fetch-depth: 0 + - name: Checking 5 + run: | + ls -la + + - name: Checking 4 + run: | + ls -la ./ + + - name: Checking 3 + run: | + ls -la ./app + - name: Checking 2 run: | ls -la ./app/build/outputs/apk From 67811006c9542f20e015477046d946950c224def Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 17:47:49 +0300 Subject: [PATCH 18/25] Testing 17 --- .github/workflows/upload-aws-s3.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index 7ea1848f0c4..43cc295f161 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -27,11 +27,11 @@ jobs: GITHUB_USER: ${{ github.actor }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} steps: - - name: Checkout - uses: actions/checkout@v4 - with: - submodules: recursive # Needed in order to fetch Kalium sources for building - fetch-depth: 0 +# - name: Checkout +# uses: actions/checkout@v4 +# with: +# submodules: recursive # Needed in order to fetch Kalium sources for building +# fetch-depth: 0 - name: Checking 5 run: | From af9e7fbba8dd92949af76359c5302937369a4186 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 17:48:18 +0300 Subject: [PATCH 19/25] Testing 18 --- .github/workflows/upload-aws-s3.yml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index 43cc295f161..60b511a2502 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -33,10 +33,6 @@ jobs: # submodules: recursive # Needed in order to fetch Kalium sources for building # fetch-depth: 0 - - name: Checking 5 - run: | - ls -la - - name: Checking 4 run: | ls -la ./ From b8e257fe6a84fc8da2d8de2a47ef070878541a06 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 18:43:55 +0300 Subject: [PATCH 20/25] Testing 19 --- .github/workflows/upload-aws-s3.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index 60b511a2502..d1e638eb641 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -27,11 +27,11 @@ jobs: GITHUB_USER: ${{ github.actor }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} steps: -# - name: Checkout -# uses: actions/checkout@v4 -# with: -# submodules: recursive # Needed in order to fetch Kalium sources for building -# fetch-depth: 0 + - name: Checkout + uses: actions/checkout@v4 + with: + submodules: recursive # Needed in order to fetch Kalium sources for building + fetch-depth: 0 - name: Checking 4 run: | From d20ae17c185ddbf6eb2d9faca2ec9e067cf0d414 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Wed, 22 May 2024 19:20:22 +0300 Subject: [PATCH 21/25] Testing 20 --- .github/workflows/testing-test-build-app.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index 20be4fab334..74f551a6b93 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -27,6 +27,8 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | ./gradlew assembleStagingCompat -p ./ --no-daemon + - name: Copy Staging Compat + run: | cp app/build/outputs/apk/staging/compat/com.wire.*.apk wire-android-staging-pr-${{ github.event.pull_request.number }}.apk uplod-to-s3: needs: [ testing-build-app ] From 5e31cc6edd7ed35fa2597513341e03a20462c73d Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Thu, 23 May 2024 12:03:44 +0300 Subject: [PATCH 22/25] Testing 21 --- .github/workflows/testing-test-build-app.yml | 28 +++++++++++--------- .github/workflows/upload-aws-s3.yml | 1 + 2 files changed, 16 insertions(+), 13 deletions(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index 74f551a6b93..3ad9433ec1b 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -27,16 +27,18 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | ./gradlew assembleStagingCompat -p ./ --no-daemon - - name: Copy Staging Compat - run: | - cp app/build/outputs/apk/staging/compat/com.wire.*.apk wire-android-staging-pr-${{ github.event.pull_request.number }}.apk - uplod-to-s3: - needs: [ testing-build-app ] - uses: ./.github/workflows/upload-aws-s3.yml - with: - flavour: "staging" - buildType: "compat" - secrets: - aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} - aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} - aws-bucket: ${{ secrets.AWS_S3_BUCKET }} + + - name: Uploading to S3 + id: upload + uses: hkusu/s3-upload-action@v2.1.0 + with: + aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} + aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} + aws-region: 'us-west-1' + aws-bucket: ${{ secrets.AWS_S3_BUCKET }} + destination-dir: "megazord/android/reloaded/staging/compat/" + file-path: './app/build/outputs/apk/staging/compat/com.wire.*.apk' + output-file-url: 'true' + + - name: Show URL + run: echo '${{ steps.upload.outputs.file-url }}' diff --git a/.github/workflows/upload-aws-s3.yml b/.github/workflows/upload-aws-s3.yml index d1e638eb641..88aa95ed2b0 100644 --- a/.github/workflows/upload-aws-s3.yml +++ b/.github/workflows/upload-aws-s3.yml @@ -54,6 +54,7 @@ jobs: ls -la ./app/build/outputs/apk/${{inputs.flavour}}/${{inputs.buildType}}/ - name: Uploading + id: upload uses: hkusu/s3-upload-action@v2.1.0 with: aws-access-key-id: ${{ secrets.aws-access-key-id }} From 5d56574cabd149ff00a971127d28f5c6b00d3265 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Thu, 23 May 2024 12:20:04 +0300 Subject: [PATCH 23/25] Testing 22 --- .github/workflows/testing-test-build-app.yml | 33 +++++++++++++++++++- 1 file changed, 32 insertions(+), 1 deletion(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index 3ad9433ec1b..e45a7665f80 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -28,6 +28,32 @@ jobs: run: | ./gradlew assembleStagingCompat -p ./ --no-daemon + + + + - name: Checking 4 + run: | + ls -la ./ + + - name: Checking 3 + run: | + ls -la ./app + + - name: Checking 2 + run: | + ls -la ./app/build/outputs/apk + + - name: Checking 1 + run: | + ls -la ./app/build/outputs/apk/staging + + - name: Checking 0 + run: | + ls -la ./app/build/outputs/apk/staging/compat/ + + + + - name: Uploading to S3 id: upload uses: hkusu/s3-upload-action@v2.1.0 @@ -41,4 +67,9 @@ jobs: output-file-url: 'true' - name: Show URL - run: echo '${{ steps.upload.outputs.file-url }}' + env: + EVENT_FILE_PATH: artifacts/Event File/event.json + GITHUB_USER: ${{ github.actor }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + gh pr comment "$PR_NUMBER" --body "APKs built during build-by-boris are available [here](${{ steps.upload.outputs.file-url }})" From fa5e7bb8471fcfb59d3094de10dd0f6dd4b58482 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Thu, 23 May 2024 13:35:18 +0300 Subject: [PATCH 24/25] Testing 23 --- .github/workflows/testing-test-build-app.yml | 27 +++----------------- 1 file changed, 3 insertions(+), 24 deletions(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index e45a7665f80..428f635b13a 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -27,33 +27,12 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | ./gradlew assembleStagingCompat -p ./ --no-daemon + cp app/build/outputs/apk/staging/compat/com.wire.*.apk wire-android-staging-pr-${{ github.event.pull_request.number }}.apk - - - - - name: Checking 4 + - name: Checking ... run: | ls -la ./ - - name: Checking 3 - run: | - ls -la ./app - - - name: Checking 2 - run: | - ls -la ./app/build/outputs/apk - - - name: Checking 1 - run: | - ls -la ./app/build/outputs/apk/staging - - - name: Checking 0 - run: | - ls -la ./app/build/outputs/apk/staging/compat/ - - - - - name: Uploading to S3 id: upload uses: hkusu/s3-upload-action@v2.1.0 @@ -63,7 +42,7 @@ jobs: aws-region: 'us-west-1' aws-bucket: ${{ secrets.AWS_S3_BUCKET }} destination-dir: "megazord/android/reloaded/staging/compat/" - file-path: './app/build/outputs/apk/staging/compat/com.wire.*.apk' + file-path: './wire-android-staging-pr-${{ github.event.pull_request.number }}.apk' output-file-url: 'true' - name: Show URL From 7d186dc7e15bcf0c95d44f63d8c8f7c9a8af49a9 Mon Sep 17 00:00:00 2001 From: Boris Safonov Date: Thu, 23 May 2024 14:07:37 +0300 Subject: [PATCH 25/25] Testing 24 --- .github/workflows/testing-test-build-app.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/testing-test-build-app.yml b/.github/workflows/testing-test-build-app.yml index 428f635b13a..19f4edfd8ec 100644 --- a/.github/workflows/testing-test-build-app.yml +++ b/.github/workflows/testing-test-build-app.yml @@ -31,7 +31,7 @@ jobs: - name: Checking ... run: | - ls -la ./ + echo "AWS_S3_BUCKET: ${{ secrets.AWS_S3_BUCKET }}" - name: Uploading to S3 id: upload @@ -51,4 +51,4 @@ jobs: GITHUB_USER: ${{ github.actor }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | - gh pr comment "$PR_NUMBER" --body "APKs built during build-by-boris are available [here](${{ steps.upload.outputs.file-url }})" + gh pr comment "${{ github.event.pull_request.number }}" --body "APKs built during build-by-boris are available [here](${{ steps.upload.outputs.file-url }})"