Update 2 files
- /.gitea/workflows/test.yml - /.gitlab-ci.yml
This commit is contained in:
@@ -1,32 +0,0 @@
|
|||||||
name: Déploiement du site
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
backend-deploy:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: Checkout code
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
|
|
||||||
- name: Test SSH connection
|
|
||||||
uses: appleboy/ssh-action@master
|
|
||||||
with:
|
|
||||||
host: ${{ secrets.SSH_HOST }}
|
|
||||||
username: ${{ secrets.SSH_USER }}
|
|
||||||
password: ${{ secrets.SSH_PASSWORD }}
|
|
||||||
script: |
|
|
||||||
echo "CONNEXION REUSSIE"
|
|
||||||
|
|
||||||
- name: Update backend
|
|
||||||
uses: appleboy/ssh-action@master
|
|
||||||
with:
|
|
||||||
host: ${{ secrets.SSH_HOST }}
|
|
||||||
username: ${{ secrets.SSH_USER }}
|
|
||||||
password: ${{ secrets.SSH_PASSWORD }}
|
|
||||||
script: |
|
|
||||||
ssh mikoshi "cd /home/timelapse/backend && git pull origin main && docker restart timelapse-api"
|
|
||||||
9
.gitlab-ci.yml
Normal file
9
.gitlab-ci.yml
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
stages:
|
||||||
|
- deploy
|
||||||
|
|
||||||
|
deploy_timelapse:
|
||||||
|
stage: deploy
|
||||||
|
script:
|
||||||
|
- ssh kerboul@172.17.0.1 "cd /home/kerboul/scripts/timelapse && ./update_timelapse.sh"
|
||||||
|
only:
|
||||||
|
- main
|
||||||
Reference in New Issue
Block a user