I am trying to install a completely working Jenkins on my old PC with Ubuntu Server 12.04. I think my installation of Ubuntu Server and Jenkins was succesfull. I can access the Jenkins page by internet from any computer. So now I want Jenkins to access my private gitrepo on BitBucket.com. I have found this tutorial: Configuring Jenkins Git Tutorial and I am stuck with step 3.5. With says do this:
cd /srv/jenkins/jobs/project/workspace
git config user.email ""
git config user.name "jenkins"But with the first command I get the error:
-su cd: /srv/jenkins/jobs/project/workspace: No such file or directoryDo I have to make this folder? But when I do:
mkdir /srv/jenkins/jobs/project/workspace
mkdir: cannot create directory '/srv/jenkins/jobs/project/workspace': No such file or directoryI don't know much about all these things, because I am fairly new to this. I have come this far just because of all the tutorial on the internet, but now I am stuck :(
Edit:
I have tried the commando:
mkdir -p /srv/jenkins/jobs/project/workspace
mkdir: cannot create directory: '/srv/jenkins': Permission deniedSo I guess this is not the solution, because user jenkins doesn't have sudo rights. I hope some has another suggestion.
3 Answers
To create a whole path/set of directories, like you did with /srv/jenkins/jobs/project/workspace you need to pass the -p parameter to mkdir to create all of them at once.
mkdir -p /srv/jenkins/jobs/project/workspace 4 With a user with sudo privileges, try:
sudo chown jenkins:jenkins /srv/jenkins
chmod 750 /srv/jenkins Please, check first it the directory /srv/jenkins exists.
And then, try the mkdir -p /srv/jenkins/jobs/project/workspace.
Ok I have it all working. The tutorial gave me a good start, but I never completed step 3.5. I did searching in all the options and there I was able to set all necessary options. And I went on with step 4 of the tutorial and filled all required fields.