Enable Woodpecker auto deploy
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful

This commit is contained in:
Matěj Divecký 2022-12-03 20:45:23 +01:00
parent 2b640ce0b4
commit 52fc13644a

24
.woodpecker.yml Normal file
View file

@ -0,0 +1,24 @@
pipeline:
build:
image: klakegg/hugo:alpine
commands:
- apk add --no-cache nodejs yarn
- yarn
- yarn styles:watch
- hugo
deploy:
image: alpine
when:
event: push
branch: master
secrets:
- BOT_PRIVATE_KEY
- DEPLOY_SERVER
commands:
- apk add openssh-client rsync
- mkdir -p $HOME/.ssh
- ssh-keyscan -t rsa nolog.cz >> $HOME/.ssh/known_hosts
- echo "$BOT_PRIVATE_KEY" > $HOME/.ssh/id_rsa
- chmod 0600 $HOME/.ssh/id_rsa
- rsync -avz --delete ./public/ $DEPLOY_SERVER:/var/www/nolog.cz/