Создал репозиторий локально и написал пайплайн
This commit is contained in:
parent
47d445fb8a
commit
62a10d7f28
29
.github/workflows/deploy.yml
vendored
Normal file
29
.github/workflows/deploy.yml
vendored
Normal file
@ -0,0 +1,29 @@
|
||||
name: Deploy to Server
|
||||
|
||||
on:
|
||||
branches:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Setup SSH Key
|
||||
uses: webfactory/ssh-agent@v0.7.0
|
||||
with:
|
||||
ssh-private-key: ${{ secrets.DEPLOY_SSH_KEY }}
|
||||
|
||||
- name: Add Known Host
|
||||
run: ssh-keyscan ${{ secrets.SERVER_IP }} >> ~/.ssh/known_hosts
|
||||
|
||||
- name: Deploy to Server
|
||||
run: |
|
||||
ssh -o StrictHostKeyChecking=no ${{ secrets.SERVER_USER }}@${{ secrets.SERVER_IP }} "
|
||||
cd ${{ secrets.PROJECT_PATH }} &&
|
||||
git pull origin master &&
|
||||
docker-compose down --remove-orphans &&
|
||||
docker-compose up -d --build
|
||||
"
|
0
backend/requirements.txt
Normal file → Executable file
0
backend/requirements.txt
Normal file → Executable file
0
backend/server.py
Normal file → Executable file
0
backend/server.py
Normal file → Executable file
0
db/init.sql
Normal file → Executable file
0
db/init.sql
Normal file → Executable file
0
docker-compose.yaml
Normal file → Executable file
0
docker-compose.yaml
Normal file → Executable file
0
frontend/index.html
Normal file → Executable file
0
frontend/index.html
Normal file → Executable file
0
frontend/static/css/styles.css
Normal file → Executable file
0
frontend/static/css/styles.css
Normal file → Executable file
0
nginx/nginx.conf
Normal file → Executable file
0
nginx/nginx.conf
Normal file → Executable file
0
nginx/ssl/domain.conf
Normal file → Executable file
0
nginx/ssl/domain.conf
Normal file → Executable file
0
nginx/ssl/domain.crt
Normal file → Executable file
0
nginx/ssl/domain.crt
Normal file → Executable file
0
nginx/ssl/domain.key
Normal file → Executable file
0
nginx/ssl/domain.key
Normal file → Executable file
0
scripts/post-receive
Normal file → Executable file
0
scripts/post-receive
Normal file → Executable file
Loading…
x
Reference in New Issue
Block a user