This commit is contained in:
34
.gitea/workflows/deploy.yml
Normal file
34
.gitea/workflows/deploy.yml
Normal file
@@ -0,0 +1,34 @@
|
||||
# .gitea/workflows/deploy.yml
|
||||
|
||||
name: Deploy ThorsHammerNew
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
runs-on: linux
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
cd ${{ github.workspace }}
|
||||
pip install -r requirements.txt
|
||||
|
||||
- name: Copy files to app directory
|
||||
run: |
|
||||
rsync -av --delete \
|
||||
--exclude '.git' \
|
||||
--exclude '.gitea' \
|
||||
--exclude '*.db' \
|
||||
--exclude '.env' \
|
||||
--exclude 'ga_key.json' \
|
||||
${{ github.workspace }}/ /var/www/thorshammernew/
|
||||
|
||||
- name: Restart app service
|
||||
run: |
|
||||
sudo systemctl restart thorshammernew
|
||||
Reference in New Issue
Block a user