Update Jenkinsfile
This commit is contained in:
1 parent
e2633b0888
commit
f31394abe3
1 file changed
+2
-3
Vendored
+2
-3
@@ -37,10 +37,9 @@ pipeline {
|
||||
stage('deploy') {
|
||||
steps {
|
||||
script {
|
||||
echo 'deploying docker image to EC2...'
|
||||
def dockerCmd = "docker run -p 8080:8080 -d ${IMAGE_NAME}"
|
||||
|
||||
sshagent(['ec2-server-key']) {
|
||||
sh "ssh -o StrictHostKeyChecking=no ec2-user@35.180.251.121 ${dockerCmd}"
|
||||
sh ".test.sh"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user