Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/politie/pipeline-library
Jenkins shared library for use with pipeline-as-code
https://github.com/politie/pipeline-library
groovy jenkins jenkins-pipeline jenkinsfile pipelines-as-code
Last synced: 2 months ago
JSON representation
Jenkins shared library for use with pipeline-as-code
- Host: GitHub
- URL: https://github.com/politie/pipeline-library
- Owner: politie
- License: apache-2.0
- Created: 2017-02-27T13:49:48.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2017-05-02T18:45:14.000Z (over 7 years ago)
- Last Synced: 2024-09-30T18:05:19.283Z (3 months ago)
- Topics: groovy, jenkins, jenkins-pipeline, jenkinsfile, pipelines-as-code
- Language: Groovy
- Size: 12.7 KB
- Stars: 102
- Watchers: 11
- Forks: 84
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# pipeline-library
Jenkins shared library for use with pipeline-as-code. You can use (parts of) this library in you `Jenkinsfile`.How to use
----------
* Fork this repo.
* Modify the `Constants.groovy` file and supply your specific configuration parameters (e.g. GitLab url, SonarQube url).
* Add your forked git repo to your Jenkins instance: *Manage Jenkins > Configure System > Global Pipeline Libraries* and name it `pipeline-library`.
* Import the global shared library into your `Jenkinsfile`:
```
@Library('pipeline-library')
import politie.jenkins.*def builder = new JenkinsPipelineBootstrap().createBuilder()
String serviceName = 'my-service'
String gitBranch = 'master'builder.mavenApplicationPipeline(serviceName, gitBranch)
```
* Start your Jenkins job.Note: if you just want to take advantage of our custom step definitions, take a look at [JenkinsPipelineSteps.groovy](src/politie/jenkins/JenkinsPipelineSteps.groovy)
Contributors
----------* [Bert Jan](https://github.com/bertjan)
* [Arno](https://github.com/arnobroekhof)
* [Richard](https://github.com/rkettelerij)