diff --git a/Jenkinsfile b/Jenkinsfile index 4952b08..5df2c7c 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,4 +1,8 @@ pipeline { +// environment { +// remote = [:] +// withCredentials([sshUserPrivateKey(credentialsId: 'jenkins', keyFileVariable: 'identity', usernameVariable: 'username')]) { +// remote.user = $userName agent { label 'pi501.in.thelinuxpro.net' @@ -23,8 +27,8 @@ pipeline { remote.name = "pi501.in.thelinuxpro.net" remote.host = "pi501.in.thelinuxpro.net" remote.allowAnyHosts = true - remote.user = userName - remote.identityFile = identity + remote.user = $userName + remote.identityFile = $identity sh 'echo $remote' sh 'echo $remote.user'