[JIRA] (JENKINS-47389) sh step within container step does not work when user is non-root

9 views
Skip to first unread message

jenkins-ci@carlossanchez.eu (JIRA)

unread,
May 25, 2018, 5:39:01 AM5/25/18
to jenkinsc...@googlegroups.com
Carlos Sanchez commented on Bug JENKINS-47389
 
Re: sh step within container step does not work when user is non-root

so this is the error, can you try making your image user be uid 1000 ?

[non-root-container] Running shell script
sh: can't create /home/jenkins/workspace/non-root-container@tmp/durable-bf906406/jenkins-log.txt: Permission denied
sh: can't create /home/jenkins/workspace/non-root-container@tmp/durable-bf906406/jenkins-result.txt.tmp: Permission denied
mv: can't rename '/home/jenkins/workspace/non-root-container@tmp/durable-bf906406/jenkins-result.txt.tmp': No such file or directory
touch: /home/jenkins/workspace/non-root-container@tmp/durable-bf906406/jenkins-log.txt: Permission denied
touch: /home/jenkins/workspace/non-root-container@tmp/durable-bf906406/jenkins-log.txt: Permission denied
touch: /home/jenkins/workspace/non-root-container@tmp/durable-bf906406/jenkins-log.txt: Permission denied
touch: /home/jenkins/workspace/non-root-container@tmp/durable-bf906406/jenkins-log.txt: Permission denied
touch: /home/jenkins/workspace/non-root-container@tmp/durable-bf906406/jenkins-log.txt: Permission denied
touch: /home/jenkins/workspace/non-root-container@tmp/durable-bf906406/jenkins-log.txt: Permission denied
touch: /home/jenkins/workspace/non-root-container@tmp/durable-bf906406/jenkins-log.txt: Permission denied
process apparently never started in /home/jenkins/workspace/non-root-container@tmp/durable-bf906406
Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v7.3.0#73011-sha1:3c73d0e)
Atlassian logo

jglick@cloudbees.com (JIRA)

unread,
Jul 16, 2019, 3:43:22 PM7/16/19
to jenkinsc...@googlegroups.com
Jesse Glick assigned an issue to Unassigned
 
Jenkins / Bug JENKINS-47389
Change By: Jesse Glick
Assignee: Carlos Sanchez
This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)

dr.elhombrechile@gmail.com (JIRA)

unread,
Nov 15, 2019, 11:57:03 PM11/15/19
to jenkinsc...@googlegroups.com
Diego Rodriguez commented on Bug JENKINS-47389
 
Re: sh step within container step does not work when user is non-root

Carlos Sanchez I'm running into this issue as well; I'd be more then happy to help fix the issue if you can point to the right place in the Kubernetes-plugin code;  

This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo

dr.elhombrechile@gmail.com (JIRA)

unread,
Nov 15, 2019, 11:57:04 PM11/15/19
to jenkinsc...@googlegroups.com

dr.elhombrechile@gmail.com (JIRA)

unread,
Nov 15, 2019, 11:58:04 PM11/15/19
to jenkinsc...@googlegroups.com
Diego Rodriguez assigned an issue to Unassigned

vas.pothala@gmail.com (JIRA)

unread,
Dec 20, 2019, 1:17:03 PM12/20/19
to jenkinsc...@googlegroups.com
Sriniva Pothala commented on Bug JENKINS-47389
 
Re: sh step within container step does not work when user is non-root

Just add the `jnlp` container with path pointing to `home/jekins/agent`. It worked for me

containerTemplate(name: 'jnlp', image: 'lachlanevenson/jnlp-slave:3.10-1-alpine', args: '${computer.jnlpmac} ${computer.name}', workingDir: '/home/jenkins/agent')

 

Reply all
Reply to author
Forward
0 new messages