add step to push to gitea
This commit is contained in:
5
Jenkinsfile
vendored
5
Jenkinsfile
vendored
@@ -108,13 +108,16 @@ pipeline {
|
|||||||
script {
|
script {
|
||||||
// Checkout from GitLab (already done implicitly)
|
// 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 remote add gitea https://gitea.confdroid.com/confdroid/puppet_cd.git
|
||||||
git -c user.email=jenkins@confdroid.com -c user.name=Jenkins push --mirror gitea
|
git -c user.email=jenkins@confdroid.com -c user.name=Jenkins push --mirror gitea
|
||||||
"""
|
"""
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
when { branch 'main' } // Only on main branch to avoid noise
|
when { branch 'master' } // Only on main branch to avoid noise
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user