expo build:ios 504 error everytime

Expo CLI 4.3.2 environment info:
OS: macOS 10.15.3
Shell: 3.2.57 - /bin/bash
Node: 12.16.0 - /usr/local/bin/node
npm: 6.13.4 - /usr/local/bin/npm
CocoaPods: 1.10.1 - /usr/local/bin/pod
Platforms: iOS 13.6, DriverKit 19.0, macOS 10.15, tvOS 13.4, watchOS 6.2
Xcode: 11.6/11E708 - /usr/bin/xcodebuild
expo: ~38.0.8 => 38.0.9
react: ~16.11.0 => 16.11.0
react-dom: ~16.11.0 => 16.11.0
react-native: https://github.com/expo/react-native/archive/sdk-38.0.2.tar.gz => 0.62.2
react-native-web: ~0.11.7 => 0.11.7
expo-cli: 4.3.2
Expo Workflow: managed

Everytime I try to build my project to submit to the appstore it fails on creating the distribution certificate.

The error is: Failed to set up Distribution Certificate

Will you provide your own Apple Distribution Certificate? › Let Expo handle the process

:heavy_check_mark: Created Apple distribution certificate

Failed to set up Distribution Certificate

Failed to prepare all credentials.

The next time you build, we will automatically use the following configuration:

No credentials configured for app @APPINFO/APPINFO with bundle identifier APPID

Request failed with status code 504

Error: Request failed with status code 504

at createError (/usr/local/lib/node_modules/expo-cli/node_modules/axios/lib/core/createError.js:16:15)

at settle (/usr/local/lib/node_modules/expo-cli/node_modules/axios/lib/core/settle.js:17:12)

at IncomingMessage.handleStreamEnd (/usr/local/lib/node_modules/expo-cli/node_modules/axios/lib/adapters/http.js:260:11)

at IncomingMessage.emit (events.js:333:22)

at endReadableNT (_stream_readable.js:1204:12)

at processTicksAndRejections (internal/process/task_queues.js:84:21)

Everything I have tried continues to fail.

Hey @riftapplication, are you still encountering this issue? It might be worth signing into the Apple Developer Portal and see if there are any issues coming from Apple about your account. Lastly, you can use expo credentials:manager to manually take action. Starting from a clean slate could be helpful.


When the cli says its creating a distribution certificate, it creates it and it shows up in my Apple developer account under the certificates tab. For some reason it just refuses to upload them to the expo side of things. I went into the expo credentials manager and there aren’t any existing certificates, keys, or anything and when trying to add them through the manager, it still fails

New weird interaction: after trying to build the distribution certificate enough times to the max amount of three, the cli instructions moved on to allow me to choose which one. However, it only showed two of the three available and no matter which one I select it gives the same error of failing to create apple distribution certificate.

@riftapplication it is possible our servers were down during the time you were getting a 504 error. If something was wrong with your particular request, we’d usually see a 400 status being returned instead.

Could you try again to see if you get the same response now?
Also, just to sanity check, can you run expo whoami and verify that it’s the account you expect, and that it has the proper permissions?

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.