You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

执行EAS Build时遇iOS Bundle Identifier配置缺失错误求助

解决EAS Build iOS Bundle Identifier配置错误

问题描述

执行eas build时出现以下错误:

📝 iOS Bundle Identifier Learn more: https://expo.fyi/bundle-identifier
CommandError: Input is required, but 'npx expo' is in non-interactive mode.
Project must have a ios.bundleIdentifier set in the Expo config (app.json or app.config.js).
Error: Unknown error. See logs of the Prebuild build phase for more information.

解决方案

  1. 配置iOS Bundle Identifier
    在项目根目录的app.json或app.config.js中添加ios.bundleIdentifier字段,格式需为反向域名(如com.yourcompany.yourapp):

    • app.json示例:
    {
      "expo": {
        "ios": {
          "bundleIdentifier": "com.yourdomain.yourappname"
        }
      }
    }
    
    • app.config.js示例:
    export default {
      expo: {
        ios: {
          bundleIdentifier: "com.yourdomain.yourappname"
        }
      }
    };
    
  2. 排查Prebuild阶段未知错误
    若配置后仍报错,前往EAS Build控制台找到对应构建任务,查看Prebuild阶段的日志输出,定位具体错误(如依赖缺失、配置冲突等)后针对性修复。

  3. 重新执行构建
    完成配置与错误修复后,重新运行:

    eas build
    

内容的提问来源于stack exchange,提问作者tonynnabs

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.16 17:53:15