[JIRA] (JENKINS-39406) Build step 'Execute shell' marked build as failure - on Mac slave

59 views
Skip to first unread message

zbeedatm@gmail.com (JIRA)

unread,
Nov 1, 2016, 10:04:06 AM11/1/16
to jenkinsc...@googlegroups.com
Muhammad Zbeedat created an issue
 
Jenkins / Bug JENKINS-39406
Build step 'Execute shell' marked build as failure - on Mac slave
Issue Type: Bug Bug
Assignee: Oleg Nenashev
Components: _unsorted
Created: 2016/Nov/01 2:03 PM
Priority: Blocker Blocker
Reporter: Muhammad Zbeedat

Hi,
I'm trying to run a job on Mac slave for the first time, the job is started but when reaching "Execute Shell" step with the following script:

#!/bin/sh
whoami
pwd
cd /Users/padmin/Documents/workspace/<My_Project>/

I'm getting the following:

+ whoami
root
+ pwd
/Users/padmin/workspace/<Job_Name>
+ cd /Users/padmin/Documents/workspace/<My_Project>/
/tmp/hudson8870516717374392933.sh: line 6: cd: /Users/padmin/Documents/workspace/PeerApp_Automation/GalilRobotFramework/: No such file or directory
Build step 'Execute shell' marked build as failure

What I had done so far:

  1. chmod -R 777 <My_Project>
    #Added "Inject Environment Variable" step with this content:PATH=/Library/Frameworks/Python.framework/Versions/2.7/bin:/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin

But no luck!
Please advice...

Thanks in advance.

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)
Atlassian logo

zbeedatm@gmail.com (JIRA)

unread,
Nov 1, 2016, 10:06:02 AM11/1/16
to jenkinsc...@googlegroups.com
Muhammad Zbeedat updated an issue
Change By: Muhammad Zbeedat
Hi,
I'm trying to run a job on Mac slave for the first time, the job is started but when reaching "Execute Shell" step with the following script:

#!/bin/sh
whoami
pwd
cd /Users/padmin/Documents/workspace/<My_Project>/

I'm getting the following:

+ whoami
{color:red}root{color}
+ pwd
{color:red}/Users/padmin/workspace/<Job_Name>{color}

+ cd /Users/padmin/Documents/workspace/<My_Project>/
/tmp/hudson8870516717374392933.sh: line 6: cd: {color:red}/Users/padmin/Documents/workspace/ PeerApp_Automation <My_Project> / GalilRobotFramework/ : No such file or directory{color}

Build step 'Execute shell' marked build as failure

What I had done so far:
# chmod -R 777 <My_Project>

#Added "Inject Environment Variable" step with this content:PATH=/Library/Frameworks/Python.framework/Versions/2.7/bin:/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin

But no luck!
Please advice...

Thanks in advance.

o.v.nenashev@gmail.com (JIRA)

unread,
Nov 3, 2016, 1:27:01 AM11/3/16
to jenkinsc...@googlegroups.com
Oleg Nenashev commented on Bug JENKINS-39406
 
Re: Build step 'Execute shell' marked build as failure - on Mac slave

I doubt it's a Jenkins issue. Most likely the directory just does not exist when you call CD. Please add check of the directory existence before you call cd. Please note that ALL directories in the path should have at least rx permissions. Otherwise your Jenkins user won't be able to navigate there

zbeedatm@gmail.com (JIRA)

unread,
Dec 21, 2016, 5:30:01 AM12/21/16
to jenkinsc...@googlegroups.com
Muhammad Zbeedat closed an issue as Not A Defect
 
Change By: Muhammad Zbeedat
Status: Open Closed
Resolution: Not A Defect
Reply all
Reply to author
Forward
0 new messages