@@ -22,12 +22,13 @@ steps:
|
|||||||
|
|
||||||
deploy:
|
deploy:
|
||||||
image: alpine:latest
|
image: alpine:latest
|
||||||
|
environment:
|
||||||
|
DEPLOY_KEY:
|
||||||
|
from_secret: deploy_key
|
||||||
commands:
|
commands:
|
||||||
- apk add --no-cache openssh rsync
|
- apk add --no-cache openssh rsync
|
||||||
- mkdir -p /ssh
|
- mkdir -p /ssh
|
||||||
- echo "$$*** > /ssh/deploy_key
|
- echo "$DEPLOY_KEY" > /ssh/deploy_key
|
||||||
- chmod 600 /ssh/deploy_key
|
- chmod 600 /ssh/deploy_key
|
||||||
- ssh-keyscan -H 192.168.1.88 >> /etc/ssh/ssh_known_hosts 2>/dev/null
|
|
||||||
- rsync -e "ssh -i /ssh/deploy_key -o StrictHostKeyChecking=no" -avz --delete client/dist/ root@192.168.1.88:/var/www/
|
- rsync -e "ssh -i /ssh/deploy_key -o StrictHostKeyChecking=no" -avz --delete client/dist/ root@192.168.1.88:/var/www/
|
||||||
secrets: [deploy_key]
|
|
||||||
depends_on: [lint, build]
|
depends_on: [lint, build]
|
||||||
|
|||||||
Reference in New Issue
Block a user