Commit d77750e 1 parent bee8f5f commit d77750e Copy full SHA for d77750e
File tree 2 files changed +35
-4
lines changed
2 files changed +35
-4
lines changed Original file line number Diff line number Diff line change 1
-
2
1
name : 🚀 Deploy to Fly
3
2
on :
4
3
workflow_dispatch :
5
4
push :
6
5
branches :
7
6
- main
7
+
8
8
jobs :
9
9
deploy :
10
10
name : Deploy app
13
13
steps :
14
14
- name : Checkout 🛎️
15
15
uses : actions/checkout@v4
16
+
16
17
- name : Setup Fly 🧰
17
18
uses : superfly/flyctl-actions/setup-flyctl@master
19
+
18
20
- name : Deploy to Fly.io 🛩️
21
+ id : deploy
19
22
run : flyctl deploy --remote-only
20
23
env :
21
24
FLY_API_TOKEN : ${{ secrets.FLY_TOKEN }}
25
+
26
+ - name : Create GitHub Deployment Status 🚢
27
+ id : create_deployment
28
+ uses : peter-evans/create-or-update-deployment@v1
29
+ with :
30
+ token : ${{ secrets.GITHUB_TOKEN }}
31
+ environment : production
32
+ environment_url : https://api.web-check.xyz
33
+ description : " Deploying the application to Fly.io"
34
+ transient_environment : false
35
+ auto_inactive : true
36
+
37
+ - name : Update GitHub Deployment Status to Success ✅
38
+ if : success()
39
+ uses : octokit/request-action@v2
40
+ with :
41
+ route : POST /repos/${{ github.repository }}/deployments/${{ steps.create_deployment.outputs.deployment_id }}/statuses
42
+ token : ${{ secrets.GITHUB_TOKEN }}
43
+ state : success
44
+ environment_url : https://api.web-check.xyz
45
+ description : ' ✅ Deployment successful! 🥳'
46
+
47
+ - name : Update GitHub Deployment Status to Failure 🚫
48
+ if : failure()
49
+ uses : octokit/request-action@v2
50
+ with :
51
+ route : POST /repos/${{ github.repository }}/deployments/${{ steps.create_deployment.outputs.deployment_id }}/statuses
52
+ token : ${{ secrets.GITHUB_TOKEN }}
53
+ state : failure
54
+ environment_url : https://api.web-check.xyz
55
+ description : ' 🚫 Deployment failed 😥'
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments