Skip to content

Commit

Permalink
chore: setup deploy previews
Browse files Browse the repository at this point in the history
  • Loading branch information
valerymelou committed Jul 14, 2024
1 parent 744a8ef commit e6f913e
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,27 @@ jobs:
path: |
dist
preview:
if: ${{ github.event.pull_request.base.ref == 'develop' }}
needs: build
runs-on: ubuntu-latest
environment: staging
steps:
- uses: actions/checkout@v4

- name: Download build result
uses: actions/download-artifact@v4
with:
path: dist
name: build-output-${{ github.ref_name }}

- uses: FirebaseExtended/action-hosting-deploy@v0
with:
repoToken: ${{ secrets.GITHUB_TOKEN }}
firebaseServiceAccount: ${{ secrets.FIREBASE_SERVICE_ACCOUNT }}
channelId: preview
projectId: ${{ secrets.FIREBASE_PROJECT_ID }}

staging:
if: github.ref == 'refs/heads/develop'
needs: build
Expand Down

0 comments on commit e6f913e

Please sign in to comment.