ol_site/.forgejo/workflows/build.yaml
Kamil Patecki 8ced2b2a60
Some checks failed
/ deploy (push) Failing after 8s
Dont remove demos folder
2025-08-29 00:03:55 +02:00

25 lines
750 B
YAML

on: [push]
jobs:
deploy:
runs-on: self-hosted
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '18'
cache: 'npm'
- name: Install dependencies
run: npm ci
- name: Build site
run: npm run build
- name: Deploy to web server
run: |
find /var/www/otomata -maxdepth 1 -type f -delete
find /var/www/otomata -maxdepth 1 -type d ! -name demos ! -name otomata -exec rm -rf {} +
cp -r _site/* /var/www/otomata/
chown -R www-data:www-data /var/www/otomata
chmod -R 755 /var/www/otomata