Skip to content

Commit 8fce347

Browse files
committed
Adding deploy job
1 parent 94c0bed commit 8fce347

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

.github/workflows/ci.yml

+15
Original file line numberDiff line numberDiff line change
@@ -45,3 +45,18 @@ jobs:
4545
run: |
4646
bin/rails db:prepare
4747
bin/rails test
48+
49+
deploy:
50+
if: github.ref == 'master' && github.event_name == 'push'
51+
needs: test
52+
environment:
53+
name: do-production
54+
url: https://rails-blog-et5u6.ondigitalocean.app
55+
56+
steps:
57+
- name: Install doctl
58+
uses: digitalocean/action-doctl@v2
59+
with:
60+
token: ${{ secrets.DIGITALOCEAN_ACCESS_TOKEN }}
61+
62+
- run: doctl apps create-deployment rails-blog

0 commit comments

Comments
 (0)