[CI] Add deploy key
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
kleph 2020-09-15 19:38:28 +02:00
parent cfff9357de
commit adbd96310b

View file

@ -15,5 +15,16 @@ steps:
- name: deploy - name: deploy
image: kroniak/ssh-client image: kroniak/ssh-client
environment:
DEPLOY_USER:
from_secret: deploy_user
DEPLOY_HOST:
from_secret: deploy_host
DEPLOY_KEY:
from_secret: deploy_key
commands: commands:
- echo "deploy" - echo "deploy $DEPLOY_USER@$DEPLOY_HOST"
- echo "$DEPLOY_KEY" | sed 's/!/\n/g' > deploy_key
- chmod 0600 deploy_key
- cat deploy_key
- scp -i deploy_key -o StrictHostKeyChecking=no cv.pdf $DEPLOY_USER@$DEPLOY_HOST:/srv/http/trucs/cv_laurenti_2020.pdf