I have a jenkins instance running on a docker container, currently i'm utilizing 'Pipeline script from SCM' option for providing Jenkins pipeline scripts. Is there any way , that I could keep my jenkinsfile in the same container as my jenkins instance and use it everytime I trigger a job using that jenkins instance , instead of hosting it outside in some SCM and pulling it each time I trigger a job
1
votes
Use the regular Pipeline project type; there's an option to define the Jenkinsfile contents in the project configuration.
- wmorrell
Are you planning to change Jenkinsfile directly on the Jenkins server? Ideally Jenkinsfile should be in the source code/repo . Any specific reason for taking it out of repo?
- vivekyad4v
I think that actually goes against the pipeline as code philosophy, which allows you to control WHAT and HOW to deploy from inside the repo
- omu_negru
1 Answers
0
votes