Skip to content

Commit 9afd190

Browse files
committed
Add GitHub Actions workflow for automated deployments
1 parent 02b915d commit 9afd190

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

.github/workflows/deploy.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: Deploy to Server
2+
on:
3+
push:
4+
branches:
5+
- main
6+
jobs:
7+
deploy:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: Deploy using SSH
11+
uses: appleboy/ssh-action@master
12+
with:
13+
host: ${{ secrets.SSH_HOST }}
14+
username: ${{ secrets.SSH_USERNAME }}
15+
key: ${{ secrets.ACTIONS_SSH_PRIVATE_KEY }}
16+
script: |
17+
cd /root/formula1_app/F1DataLab
18+
docker compose -f docker-compose_prod.yml down
19+
git fetch
20+
git pull
21+
docker compose -f docker-compose_prod.yml up -d --build

0 commit comments

Comments
 (0)