Skip to content

Commit

Permalink
Create deploy.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
marcinbator authored Dec 5, 2024
1 parent 8c57f0a commit f6a0a51
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Deploy

on:
push:
branches: [ "main" ]

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Deploy
uses: appleboy/ssh-action@master
with:
host: ${{ secrets.REMOTE_HOST }}
username: ${{ secrets.REMOTE_USER }}
port: ${{ secrets.REMOTE_PORT }}
key: ${{ secrets.SSH_PRIVATE_KEY }}
script: |
cd /home/project/rag-2-ai
git checkout main
git pull
cd /home/project
docker compose up --build -d
echo "$(date): ai deployed successfully" >> deploy-log.txt
docker system prune -f

0 comments on commit f6a0a51

Please sign in to comment.