react-native-apple-authentication icon indicating copy to clipboard operation
react-native-apple-authentication copied to clipboard

How to create a production build on Expo?

Open angel-luis opened this issue 1 year ago • 6 comments

Hello,

Expo guides point to this command: eas build --platform ios --profile production --local

It generates an .ipa file to upload later to the Store.

The problem is that this app version doesn't works with Apple authentication. It throws:

Error: The operation couldn’t be completed. (com.apple.AuthenticationServices.AuthorizationError error 1000.)", }",

When I compile it manually with Xcode adding the Sign in with Apple capability, it works. But it's a dev build (with Expo dev tools) and only targeted for my iPhone.

So I don't know exactly what steps should I take to get the ipa working with this library.

Thank you in advance.

angel-luis avatar Jul 02 '25 08:07 angel-luis

It worked after install and add the following in app.json:

{
  "expo": {
    "plugins": ["expo-apple-authentication"]
  }
}

I didn't saw it in the docs, so maybe should be included in the Expo setup. I leave it open to know if it should be mandatory.

angel-luis avatar Jul 03 '25 07:07 angel-luis

["expo-apple-authentication"]

should I also install expo-apple-authentication ? this plugin config is for expo-apple-authentication

brianw-tech avatar Jul 19 '25 09:07 brianw-tech

["expo-apple-authentication"]

should I also install expo-apple-authentication ? this plugin config is for expo-apple-authentication

Yes.

angel-luis avatar Jul 24 '25 09:07 angel-luis

Hey @mikehardy, can you confirm the need to include this plugin for expo projects?

victoriomolina avatar Sep 17 '25 20:09 victoriomolina

The only thing we actually need from expo-apple-authentication is their plugin which adds the com.apple.developer.applesignin: ["Default"] entitlement during prebuild.

It does this when the ios.usesAppleSignIn field is set in expo app.json.

Instead, just manually add this to your app.json:

{
  "expo": {
    "ios": {
      "entitlements": {
        "com.apple.developer.applesignin": ["Default"]
      }
    }
  }
}

Don't set ios.usesAppleSignIn since that's an expo-apple-authentication property.

This gives you the iOS entitlement you need for EAS builds without the dependency conflict. I'd suggest we update the docs to replace the "Expo usage" section with this manual approach.

Follow-up: Please bring some attention to #373 where I propose fixing the README.md

trentrand avatar Sep 19 '25 20:09 trentrand

The only thing we actually need from expo-apple-authentication is their plugin which adds the com.apple.developer.applesignin: ["Default"] entitlement during prebuild.

It does this when the ios.usesAppleSignIn field is set in expo app.json.

Instead, just manually add this to your app.json:

{ "expo": { "ios": { "entitlements": { "com.apple.developer.applesignin": ["Default"] } } } } Don't set ios.usesAppleSignIn since that's an expo-apple-authentication property.

This gives you the iOS entitlement you need for EAS builds without the dependency conflict. I'd suggest we update the docs to replace the "Expo usage" section with this manual approach.

Follow-up: Please bring some attention to #373 where I propose fixing the README.md

You saved my day!

leotaozeng avatar Dec 31 '25 12:12 leotaozeng