Swap out everything up to the ws with ${WORKSPACE} and that should do it.
Ben
On Jul 10, 2012 7:09 PM, "Benjamin Lau" <[email protected]> wrote:
> The file=@ you pass using curl needs a file path not a url.
>
> Ben
>
> On Jul 10, 2012 7:06 PM, "pkoder" <[email protected]> wrote:
> >
> > Hi,
> >
> >
> > I'm having an issue trying to do some post-build actions.
> >
> > Specifically, after creating my ipa's which is clearly present in the
> workspace,
> >
> > when I try to upload the build to test flight I get this error:
> >
> >
> > Started by user anonymous
> >
> > Building in workspace /Users/jumbuck/.jenkins/jobs/Deploy latest
> successful build to testflight/workspace
> >
> > [workspace] $ /bin/sh -xe
> /var/folders/lj/768fglcj11nbkkx1kpkcz7l40000gq/T/hudson5308169218545301797.sh
> >
> > + cd ..
> >
> > + curl http://testflightapp.com/api/builds.json -F file=@
> http://localhost:8080/job/first-ios-app/ws/build/Debug-iphoneos/JenkinsIOSExample-Debug-1.0.ipa-F
> api_token=xxx -F team_token=xxx -F 'notes=This is an autodeploy build
> from Jenkins!' -F notify=True -F distribution_lists=Test
> >
> > % Total % Received % Xferd Average Speed Time Time Time
> Current
> >
> > Dload Upload Total Spent Left
> Speed
> >
> >
> > 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:--
> 0
> >
> > 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:--
> 0
> >
> > curl: (26) couldn't open file "
> http://localhost:8080/job/first-ios-app/ws/build/Debug-iphoneos/JenkinsIOSExample-Debug-1.0.ipa
> "
> >
> >
> > Build step 'Execute shell' marked build as failure
> >
> > Finished: FAILURE
> >
> >
> >
> >
> > The post-build script is as follows:
> >
> >
> > # For this test lets just go up a directory and user the ipa we built.
> >
> > cd ..
> >
> > # Execute the magic to upload out IPA to testflight
> >
> > curl http://testflightapp.com/api/builds.json -F file=@
> http://localhost:8080/job/first-ios-app/ws/build/Debug-iphoneos/JenkinsIOSExample-Debug-1.0.ipa-F
> api_token="xxx" -F team_token="xxx" -F notes="This is an autodeploy
> build from Jenkins!" -F notify=True -F distribution_lists="Test"
>