What is the difference between the Jenkins jobs which are in workspace directory and jobs directory

0 votes
What is the difference between the Jenkins jobs which are in the workspace directory and jobs directory?

/var/lib/jenkins/workspace

/var/lib/jenkins/jobs

There are few jobs that are not present in the workspace directory which is in the jobs directory. want to understand what is the difference between them.
Oct 21, 2020 in Jenkins by Shashi
• 370 points

edited Oct 21, 2020 by MD 3,986 views

1 answer to this question.

0 votes

Hi@Shashi,

These folders have different meanings in Jenkins. If you upload or download any file with Jenkins Jobs, then those files you can find in the workspace directory.

[root@localhost workspace]# pwd
/var/lib/jenkins/workspace
[root@localhost workspace]# ls
Dynamic_Node1   Job2
[root@localhost Job2]# pwd
/var/lib/jenkins/workspace/Job2
[root@localhost Job2]# ls
deployment.yml  Dockerfile  Dockerfile.txt  file  index.html  sshd_config

On other hand, your Jenkins job can build multiple times. So every build will store in the Jobs directory. Just go through the above two directories, you will get the concept.

[root@localhost jobs]# pwd
/var/lib/jenkins/jobs
[root@localhost jobs]# ls
Dynamic_Node1  Dynamic_Node2  Job1  Job2  Job3
[root@localhost jobs]# cd Job1/
[root@localhost Job1]# ls
builds  config.xml  nextBuildNumber
answered Oct 21, 2020 by MD
• 95,460 points

Related Questions In Jenkins

+1 vote
1 answer

What is the difference between Hudson and Jenkins?

Jenkins and Hudson are Continuous Integration tool, ...READ MORE

answered Jun 17, 2019 in Jenkins by Neel
• 3,020 points
4,569 views
0 votes
1 answer

What are parameterized jobs in jenkins and how to configure it?

Hey @Hannah, Parameterized jobs/builds are the ones ...READ MORE

answered Dec 16, 2018 in Jenkins by Kiyara
5,093 views
0 votes
1 answer
0 votes
2 answers
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
4,039 views
+2 votes
1 answer
0 votes
1 answer

What is the difference between Jenkins and Maven?

Hi@akhtar, A maven is a build tool designed to manage ...READ MORE

answered Dec 8, 2020 in Jenkins by MD
• 95,460 points
3,732 views
0 votes
1 answer

What is the use of using declarative pipeline (i.e jenkins file) over scripted pipeline in real time

Hi@Shashi, The declarative pipeline is a relatively new ...READ MORE

answered Oct 28, 2020 in Jenkins by MD
• 95,460 points
1,549 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP