question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

🐛[BUG] EACCES: permission denied, mkdir '/app/src/.umi-production/core'

See original GitHub issue

🐛 bug 描述

📷 复现步骤

dockerfile

$ cat Dockerfile 
circleci/node:latest-browsers  as node-builder

WORKDIR /app

USER root

COPY package.json .

RUN yarn

COPY . .

RUN npm run build
....

run docker build .

but failed

#14 2.410 > ant-design-pro@5.0.0-beta.3 build
#14 2.410 > umi build
#14 2.410 
#14 3.642 Babel could not read cache file: /root/.babel.7.14.0.production.json
#14 3.642 due to a permission issue. Cache is disabled.
#14 8.981 EACCES: permission denied, mkdir '/app/src/.umi-production/core'
#14 8.983 Error: EACCES: permission denied, mkdir '/app/src/.umi-production/core'
#14 8.983     at Object.mkdirSync (node:fs:1324:3)
#14 8.983     at d (/app/node_modules/@umijs/deps/compiled/mkdirp/index.js:1:2145)
#14 8.983     at Function.f [as sync] (/app/node_modules/@umijs/deps/compiled/mkdirp/index.js:1:372)
#14 8.983     at Proxy.fn (/app/node_modules/umi/node_modules/@umijs/preset-built-in/lib/plugins/registerMethods.js:78:24)
#14 8.983     at Object.<anonymous> (/app/node_modules/umi/node_modules/@umijs/preset-built-in/lib/plugins/generateFiles/core/history.js:83:9)
#14 8.983     at Generator.next (<anonymous>)
#14 8.983     at asyncGeneratorStep (/app/node_modules/umi/node_modules/@umijs/preset-built-in/lib/plugins/generateFiles/core/history.js:48:103)
#14 8.983     at _next (/app/node_modules/umi/node_modules/@umijs/preset-built-in/lib/plugins/generateFiles/core/history.js:50:194)
#14 8.983     at /app/node_modules/umi/node_modules/@umijs/preset-built-in/lib/plugins/generateFiles/core/history.js:50:364
#14 8.983     at new Promise (<anonymous>)

🏞 期望结果

💻 复现代码

© 版本信息

  • Ant Design Pro 版本: [e.g. 4.0.0]
  • umi 版本
  • 浏览器环境
  • 开发环境 [e.g. mac OS]

🚑 其他信息

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6

github_iconTop GitHub Comments

1reaction
oldthreefengcommented, Jul 28, 2021

USER admin ? @chenshuai2144

我这边已经用了 root 权限哇…

0reactions
oldthreefengcommented, Jul 28, 2021

谢谢啦~

Read more comments on GitHub >

github_iconTop Results From Across the Web

Replies: - 1 suggested answer - GitHub
We are getting "EACCES: permission denied, mkdir '/root/.config/Cypress/cy/production" error message in Jenkins console.
Read more >
permission denied, mkdir '/usr/app/node_modules/.cache ...
(EACCES: permission denied, mkdir '/usr/app/node_modules/.cache) How can I create a docker-compose file to make node_modules a non-root folder?
Read more >
Error: EACCES: permission denied, mkdir '/home/anit/Desktop ...
I am facing this issue while installing node-sass package I have tried using sudo command but same error prevails.
Read more >
An unexpected error occurred: "EACCES: permission denied
I have a workspace setup and ever sense I keep getting permission issues with yarn: error An unexpected error occurred: "EACCES: permission denied,...
Read more >
permission denied, mkdir '/.npm' > npm ERR! cb() never called ...
I am getting permission issue while installing NPM through Jenkins ... Unhandled rejection Error: EACCES: permission denied, mkdir '/.npm' ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found