搜索

首页  >  问答  >  正文

Vercel部署失败:退出码1对应"npm run build"命令

<p><br /></p> <pre class="brush:php;toolbar:false;">这是部署详细日志: [15:19:45.948] throw err; [15:19:45.948] ^ [15:19:45.948] [15:19:45.948] Error: error:0308010C:digital envelope routines::unsupported [15:19:45.948] opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ], [15:19:45.948] library: 'digital envelope routines', [15:19:45.948] reason: 'unsupported', [15:19:45.948] code: 'ERR_OSSL_EVP_UNSUPPORTED' [15:19:45.948] } [15:19:45.948] [15:19:45.948] Node.js v18.16.1 [15:19:45.972] Error: Command "npm run build" exited with 1</pre> <p>Vercel部署错误npm run build退出码为1:我已尝试将npm run build添加到构建命令中,并添加环境变量CI=false,但错误仍然相同。</p>
P粉311423594P粉311423594468 天前616

全部回复(1)我来回复

  • P粉768045522

    P粉7680455222023-08-16 12:54:03

    我在Github上找到了一个类似的问题https://github.com/webpack/webpack/issues/15900。你能试一试吗?

    "scripts": {
      "start": "react-scripts --openssl-legacy-provider start",
      "build": "react-scripts --openssl-legacy-provider build",
    }

    回复
    0
  • 取消回复