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

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

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

黄涛
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,

--
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 [hidden email].
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.
Reply | Threaded
Open this post in threaded view
|

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

Mark Waite-2
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

On Mon, Jan 22, 2018 at 8:20 PM 黄涛 <[hidden email]> wrote:
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,

--
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 [hidden email].
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.

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/CAO49JtFTKhmA%3Dhg%3DVzUKnoHg2cSXF7QMJVLHEF-Lo7ucPYfdqw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

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

Björn Rohlén
In reply to this post by 黄涛
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!

On Tuesday, 23 January 2018 04:20:28 UTC+1, 黄涛 wrote:
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,

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/17f3d2ef-5c16-4d45-839f-19ff6a8f6811%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

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

黄涛
In reply to this post by Mark Waite-2
Thank you very much!!

在 2018年1月23日星期二 UTC+8下午12:12:06,Mark Waite写道:
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 <a href="http://serverurl/jobs/xyzzy/config.xml" target="_blank" rel="nofollow" onmousedown="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fserverurl%2Fjobs%2Fxyzzy%2Fconfig.xml\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNFC9UOJrJt4CBiCWvxmnAbNCleaQA&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fserverurl%2Fjobs%2Fxyzzy%2Fconfig.xml\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNFC9UOJrJt4CBiCWvxmnAbNCleaQA&#39;;return true;">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

On Mon, Jan 22, 2018 at 8:20 PM 黄涛 <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="OWoZWc8gAwAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">huangta...@...> wrote:
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,

--
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 <a href="javascript:" target="_blank" gdf-obfuscated-mailto="OWoZWc8gAwAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit <a href="https://groups.google.com/d/msgid/jenkinsci-users/0bcfbf74-72f5-4e4a-ba05-f30902e4805d%40googlegroups.com?utm_medium=email&amp;utm_source=footer" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/d/msgid/jenkinsci-users/0bcfbf74-72f5-4e4a-ba05-f30902e4805d%40googlegroups.com?utm_medium\x3demail\x26utm_source\x3dfooter&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/msgid/jenkinsci-users/0bcfbf74-72f5-4e4a-ba05-f30902e4805d%40googlegroups.com?utm_medium\x3demail\x26utm_source\x3dfooter&#39;;return true;">https://groups.google.com/d/msgid/jenkinsci-users/0bcfbf74-72f5-4e4a-ba05-f30902e4805d%40googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;">https://groups.google.com/d/optout.

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/eacf3c41-a75e-4a67-a948-8eb50c9897da%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

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

黄涛
In reply to this post by 黄涛
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,黄涛写道:
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,

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/c055a5ca-0e42-409e-937a-407220e682e2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.