m2.nz/.woodpecker.yml

22 lines
692 B
YAML
Raw Normal View History

2022-09-12 04:39:16 +00:00
pipeline:
build:
image: golang
environment:
- HUGO_VERSION=0.102.3
commands:
2022-09-12 04:59:19 +00:00
- echo "Installing Hugo $${HUGO_VERSION}"
2022-09-12 04:55:26 +00:00
- wget https://github.com/gohugoio/hugo/releases/download/v$${HUGO_VERSION}/hugo_extended_$${HUGO_VERSION}_Linux-64bit.deb
- dpkg -i hugo_extended_$${HUGO_VERSION}_Linux-64bit.deb
2022-09-12 04:59:19 +00:00
- hugo
2022-09-12 05:07:49 +00:00
- ls
deploy:
image: golang
environment:
- HUGO_VERSION=0.102.3
commands:
- echo $M2_DEPLOY_KEY > privkey
- scp -i privkey -r public $M2_DEPLOY_STRING
- ssh -i privkey $M2_DEPLOY_STRING 'sudo systemctl reload nginx.service'
- rm -fr privkey
secrets: [ m2_deploy_secret, m2_deploy_string ]