-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c5d8c78
commit ec71464
Showing
3 changed files
with
29 additions
and
7 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,13 +2,37 @@ name: Build and deploy | |
|
||
on: | ||
push: | ||
branches: ["migration-to-golang"] | ||
branches: ["migration-to-golang", "dev", "main"] | ||
env: | ||
FLY_API_TOKEN: ${{ secrets. FLY_API_TOKEN }} | ||
jobs: | ||
build-mcmamina: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: π Read app name | ||
uses: SebRollen/[email protected] | ||
id: app_name | ||
with: | ||
file: fly.toml | ||
field: app | ||
|
||
- uses: superfly/flyctl-actions/setup-flyctl@master | ||
- run: flyctl deploy | ||
- name: π Deploy Go | ||
if: ${{ github.ref == 'refs/heads/migration-to-golang' }} | ||
run: flyctl deploy --remote-only --region waw --build-arg COMMIT_SHA=${{ github.sha }} --app ${{ steps.app_name.outputs.value }}-go | ||
env: | ||
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }} | ||
|
||
- name: π Deploy Staging | ||
if: ${{ github.ref == 'refs/heads/dev' }} | ||
run: flyctl deploy --remote-only --region waw --build-arg COMMIT_SHA=${{ github.sha }} --app ${{ steps.app_name.outputs.value }}-staging | ||
env: | ||
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }} | ||
|
||
- name: π Deploy Production | ||
if: ${{ github.ref == 'refs/heads/main' }} | ||
run: flyctl deploy --remote-only --region waw --build-arg COMMIT_SHA=${{ github.sha }} --app ${{ steps.app_name.outputs.value }} | ||
env: | ||
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }} |
This file contains 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