Ben Place created JENKINS-14016:
-----------------------------------

             Summary: Xcode codesign fails in Jenkins but works as user running 
Jenkins
                 Key: JENKINS-14016
                 URL: https://issues.jenkins-ci.org/browse/JENKINS-14016
             Project: Jenkins
          Issue Type: Bug
          Components: xcode
    Affects Versions: current
         Environment: Mac OS X (10.7.4, 10.7.3), Jenkins 1.466, XCode 
integration 1.3.1
            Reporter: Ben Place


I've read the Xcode plugin FAQ, but I'm still getting this errorBuilding my app 
in Jenkins, I get:


    CodeSign build/Release-iphoneos/myApp.app
        cd /Users/Shared/Jenkins/Home/workspace/myApp/myApp
        setenv CODESIGN_ALLOCATE 
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/codesign_allocate
        setenv PATH 
"/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
        /usr/bin/codesign --force --sign 
8d5f448fb2390ad8bc4604f1e1a1a74ef022aff7 
--resource-rules=/Users/Shared/Jenkins/Home/workspace/myApp/myApp/build/Release-iphoneos/myApp.app/ResourceRules.plist
 --entitlements 
/Users/Shared/Jenkins/Home/workspace/myApp/myApp/build/myApp.build/Release-iphoneos/myApp.build/myApp.xcent
 
/Users/Shared/Jenkins/Home/workspace/myApp/myApp/build/Release-iphoneos/myApp.app
    
/Users/Shared/Jenkins/Home/workspace/myApp/myApp/build/Release-iphoneos/myApp.app:
 User interaction is not allowed.
    Command /usr/bin/codesign failed with exit code 1

    ** BUILD FAILED **


When I try the same commands from Terminal, I get:


    [myComputer:~] jenkins%  
    cd /Users/Shared/Jenkins/Home/workspace/myApp/myApp

    [myComputer:workspace/myApp/myApp] jenkins% 
    setenv CODESIGN_ALLOCATE 
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/codesign_allocate

    [myComputer:workspace/myApp/myApp] jenkins% 
    setenv PATH 
"/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"

    [myComputer:workspace/myApp/myApp] jenkins% 
    /usr/bin/codesign --force --sign 8d5f448fb2390ad8bc4604f1e1a1a74ef022aff7 
--resource-rules=/Users/Shared/Jenkins/Home/workspace/myApp/myApp/build/Release-iphoneos/myApp.app/ResourceRules.plist
 --entitlements 
/Users/Shared/Jenkins/Home/workspace/myApp/myApp/build/myApp.build/Release-iphoneos/myApp.build/myApp.xcent
 
/Users/Shared/Jenkins/Home/workspace/myApp/myApp/build/Release-iphoneos/myApp.app


If I've cleared keychain access to the dev cert, I will get a dialog asking me 
to allow access when I run the command from the Terminal.

When I run it from Jenkins, I do not see a dialog. If access is always allowed 
and I don't get a dialog when I run from the Terminal, I still can't get a 
successful build from Jenkins.

I'm reporting this as a defect because it works from the command line, but I 
know it might be my fault.

Thanks,
Ben

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.jenkins-ci.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to