site/.woodpecker/web.yml
Ax333l 3425578e6d
Some checks failed
ci/woodpecker/push/web Pipeline failed
chore(ci): update deployment settings
2024-01-04 18:16:42 +01:00

22 lines
640 B
YAML

when:
branch: [master, ci, deploy]
event: push
steps:
build:
image: node:18-alpine
commands:
- npm ci
- npm run build
deploy:
image: alpine:3
commands:
- apk add --no-cache rsync openssh age
- echo $${AGE_KEY} > ./deploy/age_key_priv
- age --decrypt -i ./deploy/age_key_priv -o ./deploy/ssh_key_dec ./deploy/ssh_key
- chmod 600 ./deploy/ssh_key_dec
- rsync -avz --delete -e "ssh -p 2222 -i $PWD/deploy/ssh_key_dec -o UserKnownHostsFile=$PWD/deploy/known_hosts" dist/ www@192.168.30.215:/www
- rm -rf deploy
secrets: [age_key]
when:
branch: [ci, deploy]