diff --git a/Jenkinsfile b/Jenkinsfile index d7ebb9a..08e1c7a 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -14,15 +14,17 @@ pipeline { stages { stage('Checkout') { steps { - sh ''' - if [ -d .git ]; then - git remote set-url origin ssh://git@git.mandelblog.com:2222/salt/mandelstudio.git - git fetch --tags --force --progress origin - else - git clone ssh://git@git.mandelblog.com:2222/salt/mandelstudio.git . - fi - git checkout -f origin/master - ''' + sshagent(credentials: ['gitea-ssh']) { + sh ''' + if [ -d .git ]; then + git remote set-url origin ssh://git@git.mandelblog.com:2222/salt/mandelstudio.git + git fetch --tags --force --progress origin + else + git clone ssh://git@git.mandelblog.com:2222/salt/mandelstudio.git . + fi + git checkout -f origin/master + ''' + } } } stage('Build') {