From 8ee25eefc84b68e50d4396de408ac6d8115b9fa5 Mon Sep 17 00:00:00 2001 From: TBS093A Date: Tue, 1 Mar 2022 16:09:38 +0100 Subject: [PATCH] modify Jenkinsfile --- Jenkinsfile | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 8468442..8c41b3c 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -64,10 +64,18 @@ pipeline { echo '######################################################################' echo '### transfer files from jenkins pipeline to remote nginx as static ###' echo '######################################################################' - + + sh ''' + ssh -v -o StrictHostKeyChecking=no -i $PRIV_KEY -tt ubuntu@13.48.201.185 "sudo chown ubuntu:ubuntu -R /home/ubuntu/docker-compose/volumes/https-nginx-static/kamil-zuk-cv.tk ; " + ''' + sh ''' scp -v -o StrictHostKeyChecking=no -i $PRIV_KEY -r ./public/* ubuntu@13.48.201.185:/home/ubuntu/docker-compose/volumes/https-nginx-static/kamil-zuk-cv.tk ''' + + sh ''' + ssh -v -o StrictHostKeyChecking=no -i $PRIV_KEY -tt ubuntu@13.48.201.185 "sudo chown root:root -R /home/ubuntu/docker-compose/volumes/https-nginx-sta> + ''' } }