From f7f498d30fdb484e71aa23961faec47f63c001bd Mon Sep 17 00:00:00 2001 From: Devon Shigaki Date: Mon, 9 Sep 2024 13:27:56 -0700 Subject: [PATCH] Updated workflow --- .github/workflow/firebase-functions.yml | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/.github/workflow/firebase-functions.yml b/.github/workflow/firebase-functions.yml index 85514dd..9c58b81 100644 --- a/.github/workflow/firebase-functions.yml +++ b/.github/workflow/firebase-functions.yml @@ -1,19 +1,22 @@ name: Firebase Functions CI/CD + on: push: branches: - - main + - firebase-cloud-project + jobs: deploy: runs-on: ubuntu-latest + steps: - - name: Checkout Repository - uses: actions/checkout@v4 - - name: Install Firebase Tools - run: npm install -g firebase-tools - - name: Authenticate with Firebase - run: firebase login:ci --no-localhost --token ${{ secrets.FIREBASE_TOKEN }} - - name: Install Dependencies - run: npm install - - name: Deploy Firebase Functions - run: firebase deploy --only functions \ No newline at end of file + - name: Checkout code + uses: actions/checkout@v2 + + - name: Install dependencies + run: npm install + + - name: Deploy to Firebase + env: + FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }} + run: firebase deploy --only functions --token "$FIREBASE_TOKEN"