Reputation: 192
What is the file path structure to connect Jenkins with local Git repository for the Pipeline script?
I have linked the Pipeline SCM with repository using the URL: file:///home/user/git/
, but when I try to put in the script path for the Pipeline script, ./Jenkinsfile
, an error occurs. A FileNotFoundException is thrown. How would I fix this? I do not want to create a absolute file path from a certain users git repository. I want to have a file path only from the git repository.
Thanks!
Upvotes: 2
Views: 2822
Reputation: 21
I've ran into similar issues running jenkins from a docker container. Try omitting user and file:// from your path.
/home/git/
I found this by executing:
docker exec -it jenkins-container bash
ls /home
Upvotes: 2