website/.woodpecker.yml

30 lines
691 B
YAML
Raw Normal View History

2024-11-15 15:25:56 +04:00
when:
- event: push
branch: master
2024-11-15 11:22:40 +04:00
steps:
build:
image: node
2024-11-15 15:52:55 +04:00
commands:
2024-12-01 12:04:36 +04:00
- echo "Installing pnpm..."
2024-11-15 15:52:55 +04:00
- npm install -g pnpm
2024-12-01 12:04:36 +04:00
- echo "Installing dependencies..."
2024-11-15 15:52:55 +04:00
- pnpm i --frozen-lockfile
2024-12-01 12:04:36 +04:00
- echo "Building..."
2024-11-15 15:52:55 +04:00
- pnpm run build
deploy:
image: node
2024-12-01 12:04:36 +04:00
environment:
CLOUDFLARE_ACCOUNT_ID:
from_secret: cloudflare_account_id
CLOUDFLARE_API_TOKEN:
from_secret: cloudflare_api_token
2024-11-15 15:52:55 +04:00
commands:
2024-12-06 23:46:23 +04:00
- echo "Cleaning old files..."
2024-12-07 13:32:13 +04:00
- rm -r /tmp/output/*
- rm -r /tmp/output/.*
2024-12-06 23:46:23 +04:00
- echo "Moving new files..."
2024-12-06 23:01:15 +04:00
- cp -r dist/. /tmp/output
2024-12-06 16:40:55 +04:00
volumes:
- /home/docker/sakosite:/tmp/output