This commit is contained in:
parent
7f3db2ed48
commit
2de627ccf7
24
.gitea/workflows/deploy.yaml
Normal file
24
.gitea/workflows/deploy.yaml
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
name: Deploy to Production
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
jobs:
|
||||||
|
deploy:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: appleboy-ssh-action
|
||||||
|
uses: appleboy/ssh-action@v1.0.3
|
||||||
|
with:
|
||||||
|
host: ${{ secrets.PROD_HOST }}
|
||||||
|
port: ${{ secrets.PROD_PORT }}
|
||||||
|
username: ${{ secrets.PROD_USER }}
|
||||||
|
key: ${{ secrets.PROD_KEY }}
|
||||||
|
script: |
|
||||||
|
cd /data/www/bydauto/web-api
|
||||||
|
sudo -Hu www-data git pull origin main
|
||||||
|
sudo -Hu www-data composer install
|
||||||
|
sudo -Hu www-data /usr/local/bin/composer dump-autoload
|
||||||
|
sudo -Hu www-data php artisan optimize:clear
|
||||||
|
sudo -Hu www-data php artisan optimize
|
||||||
|
/usr/bin/supervisorctl reload
|
Loading…
Reference in New Issue
Block a user