diff options
| author | Albin <albin@mullvad.net> | 2022-11-01 15:11:57 +0100 |
|---|---|---|
| committer | Albin <albin@mullvad.net> | 2022-11-01 15:11:57 +0100 |
| commit | 285b5fa8199ab61228a2a9c7094802e17cf00024 (patch) | |
| tree | 6be3ef3afc8fe5cea9e7796d75d03725395cf9f4 /.github/workflows | |
| parent | c2bbd53d73dd2cce9d07ce0caf53ccb7145996f9 (diff) | |
| parent | 07d86490c41e848dd319c05853c618db6b0d962d (diff) | |
| download | mullvadvpn-285b5fa8199ab61228a2a9c7094802e17cf00024.tar.xz mullvadvpn-285b5fa8199ab61228a2a9c7094802e17cf00024.zip | |
Merge branch 'improve-android-image-handling-in-build-action'
Diffstat (limited to '.github/workflows')
| -rw-r--r-- | .github/workflows/android-app.yml | 27 |
1 files changed, 26 insertions, 1 deletions
diff --git a/.github/workflows/android-app.yml b/.github/workflows/android-app.yml index 566121c3fa..a7a2cb0141 100644 --- a/.github/workflows/android-app.yml +++ b/.github/workflows/android-app.yml @@ -22,11 +22,36 @@ on: - update-version-metadata.sh # Build if requested manually from the Actions tab workflow_dispatch: + inputs: + override_container_image: + description: 'Override container image' + type: string + required: false jobs: + prepare: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + - name: Use custom container image if specified + if: "${{ github.event.inputs.override_container_image != '' }}" + run: echo "inner_container_image=${{ github.event.inputs.override_container_image }}" >> $GITHUB_ENV + + - name: Use default container image and resolve digest + if: "${{ github.event.inputs.override_container_image == '' }}" + run: | + digest="$(cat ./dist-assets/android-container-image-digest.txt)" + echo "inner_container_image=ghcr.io/mullvad/mullvadvpn-app-build-android@sha256:$digest" >> $GITHUB_ENV + + outputs: + container_image: "${{ env.inner_container_image }}" + build: + needs: prepare runs-on: ubuntu-latest container: - image: ghcr.io/mullvad/mullvadvpn-app-build-android@sha256:2efed8ce625375c3e60574bb4d35b0d80d7100ae8b5773d144812c7680ac247b + image: "${{ needs.prepare.outputs.container_image }}" steps: # Fix for HOME path overridden by GH runners when building in containers, see: # https://github.com/actions/runner/issues/863 |
