update in branch preview deployment and fix in pr-close workflow (#10) #1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: 🤖 Branch Preview | |
| concurrency: | |
| group: ${{ github.repository }}-${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| on: | |
| push: | |
| branches: [main] | |
| jobs: | |
| deploy: | |
| name: 🚀 Deploy Branch Preview | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: forge-42/fly-deploy@v1.0.0-rc.2 | |
| id: deploy | |
| env: | |
| FLY_ORG: ${{ vars.FLY_ORG }} | |
| FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }} | |
| FLY_REGION: ${{ vars.FLY_REGION }} | |
| with: | |
| app_name: ${{github.event.repository.name}}-${{ github.ref_name }} | |
| env_vars: | | |
| APP_ENV=staging | |
| GITHUB_OWNER=${{github.repository_owner}} | |
| GITHUB_REPO=${{github.event.repository.name}} | |
| GITHUB_REPO_URL=https://github.com/${{ github.repository }} |