- HX Club
- September 13, 2021
How to Create Pipeline Job on Jenkins
Create new jobs/Items on Jenkins
- First we need to install the Jenkins on system so click on link Here
- Once Jenkins is installed on system.
- Login to Jenkins server.
- Provide username & password.
- Click on Create a jobs option.
- Provide item/job name.
- Select Pipeline.
- Click on Ok.
- Provide project description.
- Select Build triggers. Its automatically start a build when we make any changes on source code.
- Provide Pipeline script code.
- Click Save.
For example:
pipeline {
agent { docker { image 'php' } }
stages {
stage('build') {
steps {
sh 'php --version'
}
}
}
}
- Click on Build Now.
- Check Build history.
- #1 indicate, Build has been done.