Add optional step of preparing ansible server
This commit is contained in:
1
Jenkinsfile
vendored
1
Jenkinsfile
vendored
@@ -30,6 +30,7 @@ pipeline {
|
||||
withCredentials([sshUserPrivateKey(credentialsId: 'ansible-server-key', keyFileVariable: 'keyfile', usernameVariable: 'user')]){
|
||||
remote.user = user
|
||||
remote.identityFile = keyfile
|
||||
sshScript remote: remote, script: "prepare-ansible-server.sh"
|
||||
sshCommand remote: remote, command: "ansible-playbook my-playbook.yaml"
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user