Test 46
Some checks failed
Deploy Flutter to Firebase (Mac) / deploy-android (push) Failing after 2m7s
Some checks failed
Deploy Flutter to Firebase (Mac) / deploy-android (push) Failing after 2m7s
This commit is contained in:
@@ -17,12 +17,24 @@ jobs:
|
||||
- name: Installer les dépendances Flutter
|
||||
run: flutter pub get
|
||||
|
||||
- name: Créer les fichiers secrets
|
||||
- name: Créer les fichiers secrets (Avec Debug JSON)
|
||||
run: |
|
||||
echo "${{ secrets.ENV_FILE }}" > .env
|
||||
echo "${{ secrets.FIREBASE_CREDENTIALS }}" > ./android/firebase_credentials.json
|
||||
|
||||
- name: Lancer Fastlane (Déploiement)
|
||||
# --- 📝 ÉCRITURE SÉCURISÉE DU JSON ---
|
||||
# On utilise printf pour éviter que le shell ne mange les guillemets
|
||||
printf '%s' '${{ secrets.FIREBASE_CREDENTIALS }}' > ./android/firebase_credentials.json
|
||||
|
||||
echo "---------------------------------------------------"
|
||||
echo "⚠️ DEBUG : Vérification du début du JSON Firebase"
|
||||
echo "(Ne doit PAS être vide et doit commencer par { \"type\": ... )"
|
||||
echo "---------------------------------------------------"
|
||||
# On affiche juste les 50 premiers caractères pour ne pas fuiter tout le secret
|
||||
head -c 50 ./android/firebase_credentials.json
|
||||
echo ""
|
||||
echo "---------------------------------------------------"
|
||||
|
||||
- name: Lancer Fastlane (Final)
|
||||
working-directory: ./android
|
||||
env:
|
||||
ANDROID_KEYSTORE_BASE64: ${{ secrets.ANDROID_KEYSTORE_BASE64 }}
|
||||
@@ -35,7 +47,7 @@ jobs:
|
||||
export GEM_PATH=$PWD/vendor/bundle
|
||||
export PATH=$GEM_HOME/bin:$PATH
|
||||
|
||||
# 2. Génération Keystore & Properties (Méthode Validée ✅)
|
||||
# 2. Génération Keystore & Properties
|
||||
echo "🔓 Décodage du Keystore..."
|
||||
echo "$ANDROID_KEYSTORE_BASE64" | base64 -D > keystore.jks
|
||||
KEYSTORE_PATH=$(pwd)/keystore.jks
|
||||
@@ -45,22 +57,19 @@ jobs:
|
||||
KEY_PASS=$(grep "keyPassword" temp_props.txt | cut -d'=' -f2 | tr -d '\r')
|
||||
KEY_ALIAS=$(grep "keyAlias" temp_props.txt | cut -d'=' -f2 | tr -d '\r')
|
||||
|
||||
# On recrée key.properties proprement
|
||||
echo "storePassword=$STORE_PASS" > key.properties
|
||||
echo "keyPassword=$KEY_PASS" >> key.properties
|
||||
echo "keyAlias=$KEY_ALIAS" >> key.properties
|
||||
echo "storeFile=$KEYSTORE_PATH" >> key.properties
|
||||
|
||||
# 3. Préparation Gemfile (Avec le plugin Firebase cette fois !)
|
||||
# 3. Préparation Gemfile
|
||||
rm -rf vendor Gemfile.lock .bundle
|
||||
|
||||
echo "source 'https://rubygems.org'" > Gemfile
|
||||
echo "gem 'fastlane', '>= 2.210.0'" >> Gemfile
|
||||
|
||||
# --- 🔌 LE PLUGIN MANQUANT 🔌 ---
|
||||
echo "gem 'fastlane-plugin-firebase_app_distribution'" >> Gemfile
|
||||
|
||||
# --- 🚑 CORRECTIFS RUBY 3.4 🚑 ---
|
||||
# Patchs Ruby 3.4
|
||||
echo "gem 'abbrev'" >> Gemfile
|
||||
echo "gem 'ostruct'" >> Gemfile
|
||||
echo "gem 'mutex_m'" >> Gemfile
|
||||
|
||||
Reference in New Issue
Block a user