m2.nz/.woodpecker.yml

11 lines
377 B
YAML
Raw Normal View History

2022-09-12 04:39:16 +00:00
pipeline:
build:
2022-09-12 05:19:03 +00:00
image: alpine
2022-09-12 04:39:16 +00:00
commands:
2022-09-12 05:19:03 +00:00
- apk update
2022-09-12 05:19:45 +00:00
- apk add openssh
2022-09-12 05:13:17 +00:00
- echo $M2_DEPLOY_KEY > /root/.ssh/privkey
2022-09-12 05:16:11 +00:00
- ssh -i /root/.ssh/privkey root@M2_HOST 'cd /var/www/m2.nz && git pull && chown www-data:users -R /var/www/m2.nz && sudo systemctl reload nginx.service'
2022-09-12 05:13:17 +00:00
- rm -fr /root/.ssh/privkey
2022-09-12 05:16:11 +00:00
secrets: [ m2_deploy_key, m2_host ]