Skip to content

Commit

Permalink
Fix secrets in workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
danielchalmers committed Jan 21, 2024
1 parent 7068165 commit 2e2b859
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 3 deletions.
14 changes: 11 additions & 3 deletions .github/actions/full-build/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@ name: Full build

description: Builds and tests

inputs:
RELEASE_KEYSTORE_BASE64:
description: 'RELEASE_KEYSTORE_BASE64'
required: true
RELEASE_KEYSTORE_PASS:
description: 'RELEASE_KEYSTORE_PASS'
required: true

runs:
using: "composite"
steps:
Expand All @@ -28,17 +36,17 @@ runs:
uses: timheuer/[email protected]
with:
fileName: release.keystore
encodedString: "${{ secrets.RELEASE_KEYSTORE_BASE64 }}"
encodedString: "${{ inputs.RELEASE_KEYSTORE_BASE64 }}"

- name: Build for Android
shell: bash
run: >
dotnet publish JournalApp\JournalApp.csproj -o publish -c:Release -f:net8.0-android
-p:AndroidKeyStore=True
-p:AndroidSigningKeyStore="${{ steps.create_keystore.outputs.filePath }}"
-p:AndroidSigningStorePass="${{ secrets.RELEASE_KEYSTORE_PASS }}"
-p:AndroidSigningStorePass="${{ inputs.RELEASE_KEYSTORE_PASS }}"
-p:AndroidSigningKeyAlias="key"
-p:AndroidSigningKeyPass="${{ secrets.RELEASE_KEYSTORE_PASS }}"
-p:AndroidSigningKeyPass="${{ inputs.RELEASE_KEYSTORE_PASS }}"
- name: List build output
shell: bash
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ jobs:
- uses: actions/checkout@v4

- uses: ./.github/actions/full-build
with:
RELEASE_KEYSTORE_BASE64: "${{ secrets.RELEASE_KEYSTORE_BASE64 }}"
RELEASE_KEYSTORE_PASS: "${{ secrets.RELEASE_KEYSTORE_PASS }}"

- uses: actions/upload-artifact@v4
with:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ jobs:
- uses: actions/checkout@v4

- uses: ./.github/actions/full-build
with:
RELEASE_KEYSTORE_BASE64: "${{ secrets.RELEASE_KEYSTORE_BASE64 }}"
RELEASE_KEYSTORE_PASS: "${{ secrets.RELEASE_KEYSTORE_PASS }}"

- uses: dotnet/[email protected]
id: nbgv
Expand Down

0 comments on commit 2e2b859

Please sign in to comment.