This commit is contained in:
parent
941c1abf5b
commit
d8b7053fb5
1 changed files with 6 additions and 11 deletions
|
|
@ -3,30 +3,25 @@ on:
|
|||
branches:
|
||||
- main
|
||||
schedule:
|
||||
- cron: '0 * * * *' # every hour
|
||||
|
||||
- cron: '0 * * * *'
|
||||
jobs:
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
volumes:
|
||||
- /var/www/bubo:/var/www/bubo
|
||||
- /var/www/bubo:/mnt/deploy
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Install dependencies
|
||||
run: npm install
|
||||
|
||||
- name: Install rsync
|
||||
run: apt-get update && apt-get install -y rsync
|
||||
|
||||
- name: Build Bubo
|
||||
run: npm run build:bubo
|
||||
|
||||
- name: Ensure target directory exists
|
||||
run: mkdir -p /var/www/bubo
|
||||
|
||||
- name: List built files
|
||||
run: ls -la ./public/
|
||||
- name: Deploy to web root
|
||||
run: |
|
||||
rsync -avz --delete --exclude='.git' --exclude='.forgejo' \
|
||||
./public/ /var/www/bubo/
|
||||
./public/ /mnt/deploy/
|
||||
chmod -R 755 /mnt/deploy
|
||||
Loading…
Reference in a new issue