Skip to content

Commit

Permalink
Nightly build use Build environment
Browse files Browse the repository at this point in the history
  • Loading branch information
a-mabe committed Jan 1, 2025
1 parent b048fee commit 46e5161
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions .github/workflows/nightly_build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:

BuildAndroidRelease:
runs-on: ubuntu-latest
environment: production
environment: build
permissions:
contents: write

Expand Down Expand Up @@ -45,14 +45,14 @@ jobs:
uses: timheuer/[email protected]
with:
fileName: upload-keystore.jks
encodedString: ${{ secrets.KEYSTORE_FILE_BASE64 }}
encodedString: ${{ secrets.KEYSTORE }}

- name: Create key.properties
run: |
echo "storeFile=${{ steps.android_keystore.outputs.filePath }}" > android/key.properties
echo "storePassword=${{ secrets.KEYSTORE_PASSWORD }}" >> android/key.properties
echo "keyPassword=${{ secrets.KEYSTORE_KEY_PASSWORD }}" >> android/key.properties
echo "keyAlias=${{ secrets.KEYSTORE_KEY_ALIAS }}" >> android/key.properties
echo "storePassword=${{ secrets.SIGNING_STORE_PASSWORD }}" >> android/key.properties
echo "keyPassword=${{ secrets.SIGNING_KEY_PASSWORD }}" >> android/key.properties
echo "keyAlias=${{ secrets.SIGNING_KEY_ALIAS }}" >> android/key.properties
- name: Build Android Release APK
run: flutter build apk --release
Expand All @@ -74,8 +74,7 @@ jobs:

BuildiOSRelease:
runs-on: macos-latest
environment: production
needs: GetVersionNumber
environment: build
permissions:
contents: write
steps:
Expand All @@ -92,11 +91,11 @@ jobs:

- name: Install the Certificate and Provisioning Profile
env:
BUILD_CERTIFICATE_BASE64: ${{ secrets.APPSTORE_CERT_BASE64 }}
P12_PASSWORD: ${{ secrets.APPSTORE_CERT_PASSWORD }}
BUILD_PROVISION_PROFILE_BASE64: ${{ secrets.MOBILEPROVISION_BASE64 }}
BUILD_CERTIFICATE_BASE64: ${{ secrets.BUILD_CERTIFICATE_BASE64 }}
P12_PASSWORD: ${{ secrets.P12_PASSWORD }}
BUILD_PROVISION_PROFILE_BASE64: ${{ secrets.BUILD_PROVISION_PROFILE_BASE64 }}
KEYCHAIN_PASSWORD: ${{ secrets.KEYCHAIN_PASSWORD }}
EXPORT_OPTIONS_PLIST: ${{ secrets.EXPORT_OPTIONS_PLIST }}
# EXPORT_OPTIONS_PLIST: ${{ secrets.EXPORT_OPTIONS_PLIST }}
run: |
# create variables
CERTIFICATE_PATH=$RUNNER_TEMP/build_certificate.p12
Expand All @@ -115,11 +114,12 @@ jobs:
# apply provisioning profile
mkdir -p ~/Library/MobileDevice/Provisioning\ Profiles
cp $PP_PATH ~/Library/MobileDevice/Provisioning\ Profiles
EXPORT_OPTS_PATH=$RUNNER_TEMP/ExportOptions.plist
echo -n "$EXPORT_OPTIONS_PLIST" | base64 --decode -o $EXPORT_OPTS_PATH
# EXPORT_OPTS_PATH=$RUNNER_TEMP/ExportOptions.plist
# echo -n "$EXPORT_OPTIONS_PLIST" | base64 --decode -o $EXPORT_OPTS_PATH

- name: Build and Sign IPA
run: flutter build ipa --release --export-options-plist=$RUNNER_TEMP/ExportOptions.plist
run: flutter build ipa --debug
# --export-options-plist=$RUNNER_TEMP/ExportOptions.plist

- name: Upload IPA Artifact
uses: actions/upload-artifact@v3
Expand Down

0 comments on commit 46e5161

Please sign in to comment.