24 lines
648 B
YAML
24 lines
648 B
YAML
when:
|
|
branch:
|
|
include: [ main ]
|
|
|
|
# no testing at the moment, just huck it onto the server
|
|
steps:
|
|
deploy:
|
|
image: alpine:latest
|
|
secrets:
|
|
- oxaliq_deploy_ssh
|
|
commands:
|
|
- echo "SETTING UP SSH"
|
|
- apk add openssh-client
|
|
- mkdir -p $HOME/.ssh
|
|
- ssh-keyscan -t ed25519 oxaliq.net >> $HOME/.ssh/known_hosts
|
|
- echo "$oxaliq_deploy_ssh" > $HOME/.ssh/id_ed25519
|
|
- chmod 0600 $HOME/.ssh/id_ed25519
|
|
- echo "SSH SETUP DONE"
|
|
- echo "RUNNING DEPLOY SCRIPT"
|
|
- ./.woodpecker/deploy.sh
|
|
when:
|
|
# Only try to deploy if previous step is successful
|
|
status: success
|
|
- ssh
|