When I use AppFlow to build an iOS App Store version of my app and it’s uploaded to Apple Connect, I get an email response telling me:
Your delivery was successful, but you may wish to correct the following issues in your next delivery: ITMS-90078: Missing Push Notification Entitlement - Your app appears to register with the Apple Push Notification service, but the app signature’s entitlements do not include the ‘aps-environment’ entitlement. If your app uses the Apple Push Notification service, make sure your App ID is enabled for Push Notification in the Provisioning Portal, and resubmit after signing your app with a Distribution provisioning profile that includes the ‘aps-environment’ entitlement.
I am using Ionic 7, Capacitor 5.3 and for push notifications, I’m using:
“onesignal-cordova-plugin”: “^5.0.0-beta-02”
I do not have access to xCode so I’d like to use AppFlow to build my ipa.
How can I enable Push Notification entitlements in AppFlow using Capacitor without using xCode?
This is tricky without a mac.
You have to add a App.entitlements file to your Xcode project, but it’s not as simple as copying a file, you have to actually add it to the project, so you can use a nodejs script that uses node-xcode or a similar library to do so, or probably https://trapeze.dev/
Then from https://developer.apple.com/ you have to add push notification capabilities to the app identifier and generate a new provisioning profile and make sure it shows the push notifications in the capabilities section.
I am allergic to Apple products so modifying anything in xcode is like doing my taxes. (yes, I break into hives) so I was hoping that AppFlow could keep me away from insanity. For the moment, I’ll just go back to the old method of starting a virtual mac on macincloud and following the config instructions on OneSignal. It will take less time than researching node-xcode scripts.
Do you think it would be a possible feature request to have AppFlow configure this for us when we run a build? Push Notifications are such an important feature that I think it would be a popular addition. Or perhaps have someone create a tutorial on how to specifically add the App.entitlements to our projects?
As Julio mentioned, developing without a Mac is tricky but doable. Fortunately, many iOS or Android configurations to native projects only have to be performed once, so to expand on his suggestions:
The easiest way: Use MacinCloud, make the changes, and you’re done.
Just giving my vote for MacInCloud That is what I use as I refuse to buy a Mac just to build our iOS app and perform the very little specific iOS development we need to do.