How do I import and export "Build Step"?
I know "copy from another job", but I want export build step only. And this makes copy only. I also google this, but its job move: move Hudson job to another server
I want this, because I want others to review on my build step. Some text format is exist? My build step contains several ant, several script of shell.
Create a project on JenkinsEnter function-export-example as name, select Pipeline , and click OK . In the newly created project, click Configure to set up. In the Pipeline section, select Pipeline script from SCM as Definition , Git as SCM , and your repo url as Repository URL . Click Save at the bottom.
Export the Existing ConfigurationExport the current configuration into Jenkins. yaml, click the Export Configuration button to download the Jenkins. yaml file.
If your build is becoming that complicated, I think it is a sign that there is much knowledge about the build in the CI system that should really be refactored and put in the repository instead.
Try to keep the CI configuration to a minimum. Make sure the repository contains all the knowledge about how to do a proper build.
If you really want to extract parts of job configuration in Jenkins, the API does not seem to help. You might get what you want by picking up the job configuration file at http://[jenkinshost]/job/[jobname]/config.xml
.
You can also try to use the Job Backup Plugin: https://wiki.jenkins-ci.org/display/JENKINS/thinBackup With this you can export and import Job configurations...
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With