How to change default permissions of created jobs in Jenkins file system

752 views
Skip to first unread message

黄涛

unread,
Jan 22, 2018, 10:20:28 PM1/22/18
to Jenkins Users
Hi all,

When I create a job(say foo), if I check the <JENKINS_HOME>/jobs/ directory all the jobs are created with the permission 750.
drwxr-x---  3 android android 4096  1月 23 09:17 foo/

I want to share jobs in samba,i want it to created with the 775.How can I achieve that?. 
Appreciate your help.. 

My jenkins version is 2.64 and i use jenkins.war in tomcat.

Regards,

Mark Waite

unread,
Jan 22, 2018, 11:12:06 PM1/22/18
to jenkins...@googlegroups.com
The umask setting for the Jenkins user is probably what controls the permissions on those files.  Refer to the "umask" man page on your system to see if you can find a way to set the umask on the account running the Jenkins process.

Job definitions can be downloaded with http (or https) from the Jenkins server.  For example, the configuration of the job "xyzzy" is available at http://serverurl/job/xyzzy/config.xml .  I think you'll find that is a better technique than Samba to see the latest job definition.  It avoids any temptation to modify the job definition on the file system and shows current settings.

Mark Waite

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/0bcfbf74-72f5-4e4a-ba05-f30902e4805d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Björn Rohlén

unread,
Jan 23, 2018, 11:01:05 AM1/23/18
to Jenkins Users
Mark is on the spot, but to specify, it's the user running Tomcat and the environment Tomcat is running under that you want to make sure the umask is set properly on, in your case umask 0002 (to get 775 or -rwrwxr-x). 

Take care!

黄涛

unread,
Jan 29, 2018, 4:26:14 AM1/29/18
to Jenkins Users
Thank you very much!!

在 2018年1月23日星期二 UTC+8下午12:12:06,Mark Waite写道:

黄涛

unread,
Jan 30, 2018, 8:42:54 AM1/30/18
to Jenkins Users
I had resolved this problem.I find my "umask" is correct.I change my tomcat from 8 to 7,It’s ok!!

在 2018年1月23日星期二 UTC+8上午11:20:28,黄涛写道:
Reply all
Reply to author
Forward
0 new messages