Ionic iOS Jenkins - build failing 'requires a development team'

(Posted at end of another thread but someone sensibly suggested it may be worth a post of it’s own)…

Question is what are you supposed to do to get Jenkins building iOS ionic 1 projects and in particular how to avoid this error.

=== BUILD TARGET <myappname> OF PROJECT <myappname> WITH CONFIGURATION Release ===
Check dependencies
Signing for "<myappname>" requires a development team. Select a development team in the project editor.
Code signing is required for product type 'Application' in SDK 'iOS 10.2'

The key building bit of my jenkins step is this:

npm install --unsafe-perm=true
ionic state restore
ionic platform add ios
ionic resources
gulp sass
ionic build ios --release

Maybe I shouldn’t be needing to add the platform in each time or something, but others seemed to be doing this step (in quite old posts).

So, for this ‘development team’ error, I understand that normally (manually) you would open up XCode and set this up and I can do this fine but I want Jenkins to be building automatically.

I think the platform code is not under source control (by default - I think?) so when Jenkins gets the source the team is not set.

Are you supposed to put some XCode files under source control after opening XCode and setting the team?

I don’t see much(any) recent info on building iOS with Jenkins and dealing with this team thing (which seems to be a recent Apple change - about 6 months ago).

I would have thought many people would be building with Jenkins and iOS ionic but I am struggling to find answers on how to set things up right for the specific combination of Ionic, Jenkins and iOS.

( I saw some info that Cordova had an update where you can pass though the team but I’m not sure how you get that working with ‘Ionic Build ios’ commands. Are you supposed to do something different, call cordova direct, or xcode itself with something similar?

Hopefully this makes some sense.



No experience myself, but:

A more modern version to handle your certificates would probably be using a tool called “fastlane”. There are instructions online on how to use it with Jenkins and Cordova projects:

Please let us know if you found a solution for your problem and post it here for others to find. Thanks.

I’d heard Fastlane mentioned (before this current problem). I may well look at it a bit more (it seems to be a good thing) but ideally was hoping to solve the current error without bringing in extra tool sets if possible.

Thanks for the suggestion though as it’s put Fastlane back on my radar a bit more.

Ok, then here are some more links:
Automatic iOS and Android building and signing with Jenkins

Thanks for the links but unfortunately they don’t seem to address my situation in a way that will take me forwards.

I am already using the XCode plugin you linked to and there is somewhere it says you can put the team id in but it didn’t seem to make the build succeed.

The other link was someone with an issue which was never really properly resolved (someone saying they had a similar problem and did something with ruby to solve it - I didn’t gain a lot from that). The thread was September 2015 also but I think the change that is affecting me currently only arose when Apple changed things in September 2016.

Thanks anyway.

I suppose the question I am asking is:

Q: How do you set the development team of an ionic project without opening XCode? Or, if you don’t actually need to do that what do you do to make Ionic complete an automated signed release build on iOS (without opening XCode manually of course)?

The answer I am hoping to find would be something along the lines of either:
A1) “You can do it with Ionic you create file X and put this in it…, or append parameter Y to this command”.
A2) “You CAN NOT do it with Ionic alone at this time. I had this issue and I HAD to use to use tool X to do it.”

Wishful thinking to get such a straight answer I know but I live in hope.

It would seem likely Ionic itself would support automated builds without requiring additional tools (as seems fine on Android). As mentioned previously it seems something was added to Cordova a few months ago ( to address this issue, but I’m unsure how that applies to Ionic and what I need to do to make it work from Ionic.

The Ionic CLI build commands are just wrappers around the Cordova CLI commands. They match pretty close so all the params should work there, too. Like these here:

So if you append these to your ionic build ios --release this should actually work.

But as I can’t try it out myself right now I will stop answering and see if someone else can help.

Funny this ended up here. Here’s an updated link:

1 Like

Thanks for the update.

In the end I have just continued to build the xcode release manually. I don’t plan to work on lots of apps and have to do this often so leaving the iOS version manual is bearable for now.

I think I’ll take a look at Fastlane though should I return to trying to automate the iOS build with Jenkins again so your updated link will be useful.