I'm a newbie to Jenkins Templating Engine, and trying to implement a CI process using JTE. Usually, when using Jenkins, i have a repo named DevOps
in which i keep all the utility scripts that i'm using in the CI process instead of placing them in the developers' source code repositories. So in each Jenkinsfile i check out the source code as well as the DevOps repo into the workspace and use it.
I was wondering if this is considered a best practice in general. If not, what is? and if is, what is the best way to imitate that kind of pattern in JTE, given that my fresh new Jenkinsfile looks like:
checkout scm
build()
deploy()
Checkout scm elegantly checks out the source code repository defined in the SCM plugin in the configuration page. Where can i embed another checkout
step that will clone the DevOps repo and still keep the JTE infrastructure generic?
coming in JTE 2.0 you'll be able to store and access library resources.
merged PR for the feature: https://github.com/jenkinsci/templating-engine-plugin/pull/102
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.