From 33407af283b2a225fda023044888a5b7485d5794 Mon Sep 17 00:00:00 2001 From: Arne Teuke Date: Wed, 26 Nov 2025 19:32:28 +0100 Subject: [PATCH 1/2] add step to push to gitea --- Jenkinsfile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 899cab0..11ec530 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -107,16 +107,17 @@ pipeline { sshagent(['edd05eb6-26b5-4c7b-a5cc-ea2ab899f4fa']) { script { // Checkout from GitLab (already done implicitly) - sh """ + sh ''' git config user.name "Jenkins Server" git config user.email jenkins@confdroid.com git checkout master git remote add gitea https://gitea.confdroid.com/confdroid/puppet_cd.git git push --mirror gitea - """ + ''' } } } } +*/ } } From 543334eb329a62ebd3df2458bc10d69bbff03d6e Mon Sep 17 00:00:00 2001 From: Arne Teuke Date: Wed, 26 Nov 2025 19:34:48 +0100 Subject: [PATCH 2/2] add step to push to gitea --- Jenkinsfile | 28 +++++++++++++++------------- 1 file changed, 15 insertions(+), 13 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 11ec530..c1b112b 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -103,21 +103,23 @@ pipeline { } stage('Mirror to Gitea') { - steps { - sshagent(['edd05eb6-26b5-4c7b-a5cc-ea2ab899f4fa']) { - script { + steps { + sshagent(['edd05eb6-26b5-4c7b-a5cc-ea2ab899f4fa']) { + script { // Checkout from GitLab (already done implicitly) - sh ''' - git config user.name "Jenkins Server" - git config user.email jenkins@confdroid.com - git checkout master - git remote add gitea https://gitea.confdroid.com/confdroid/puppet_cd.git - git push --mirror gitea - ''' + sh """ + git config user.name "Jenkins Server" + git config user.email jenkins@confdroid.com + git checkout master + git remote add gitea https://gitea.confdroid.com/confdroid/puppet_cd.git + git push --mirror gitea + """ + } + } } - } - } - } +/* + when { branch 'master' } // Only on main branch to avoid noise */ + } } }