| Is any one using "SSH Username with private key" in DSL.groovy. I am trying to use two ways but both are giving exception: First way:- withCredentials([sshUserPrivateKey(credentialsId: 'hop_server_ssh', keyFileVariable: 'hop_file', passphraseVariable: 'hop_passphrase', usernameVariable: 'hop_user_name')]) { // some block } Second way:- wrappers { credentialsBinding { sshUserPrivateKey(credentialsId: 'hop_server_ssh', keyFileVariable: 'private_key', passphraseVariable: 'hop_phrase', usernameVariable:'hop_user') Exception: ERROR: (job_mi_backend_hop_deploy_dsl.groovy, line 36) No signature of method: javaposse.jobdsl.dsl.jobs.FreeStyleJob.sshUserPrivateKey() is applicable for argument types: (java.util.LinkedHashMap, job_mi_backend_hop_deploy_dsl$_run_closure1$_closure3) values: [[credentialsId:gid-chef-dorch-px, keyFileVariable:hop_file, ...], ...] Please help me to get access "SSH Username with private key" in DSL.groovy. |