Windows10环境 npm run dev 报错  终于找到正确答案

Error: EPERM: operation not permitted, open '/data/public/build/css/add.png'

原因: 我是运行在docker的php环境中的,nginx 和php-fpm在 docker中, 解决: 停止docker中的nginx 重新执行 npm run dev 就可以了   执行之后再start启动docker就可以了
感谢 https://blog.csdn.net/w770583069/article/details/82116116 提供的思路
PS /data> npm run dev

> @ dev /data> npm run development

> @ development /data> cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js

95% emitting

DONE  Compiled successfully in 610ms                                                                           12:33:39

fs.js:114throw err;^

Error: EPERM: operation not permitted, open '/data/public/build/css/add.png'at Object.openSync (fs.js:438:3)at copyFileSync (/data/node_modules/fs-extra/lib/copy-sync/copy-file-sync.js:23:18)at Object.copySync (/data/node_modules/fs-extra/lib/copy-sync/copy-sync.js:43:5)at File.copyTo (/data/node_modules/laravel-mix/src/File.js:193:12)at FileCollection.copyTo (/data/node_modules/laravel-mix/src/FileCollection.js:101:13)at src.forEach.file (/data/node_modules/laravel-mix/src/FileCollection.js:76:38)at Array.forEach (<anonymous>)    at FileCollection.copyTo (/data/node_modules/laravel-mix/src/FileCollection.js:76:17)    at FileCollection.copyTo (/data/node_modules/laravel-mix/src/FileCollection.js:94:25)    at src.forEach.file (/data/node_modules/laravel-mix/src/FileCollection.js:76:38)    at Array.forEach (<anonymous>)        at FileCollection.copyTo (/data/node_modules/laravel-mix/src/FileCollection.js:76:17)        at CopyFilesTask.run (/data/node_modules/laravel-mix/src/tasks/CopyFilesTask.js:14:20)        at CustomTasksPlugin.runTask (/data/node_modules/laravel-mix/src/webpackPlugins/CustomTasksPlugin.js:33:14)        at Mix.tasks.forEach.task (/data/node_modules/laravel-mix/src/webpackPlugins/CustomTasksPlugin.js:9:44)        at Array.forEach (<anonymous>)            at Compiler.compiler.plugin.stats (/data/node_modules/laravel-mix/src/webpackPlugins/CustomTasksPlugin.js:9:23)            at Compiler.applyPlugins (/data/node_modules/tapable/lib/Tapable.js:61:14)            at emitRecords.err (/data/node_modules/webpack/lib/Compiler.js:264:11)            at Compiler.emitRecords (/data/node_modules/webpack/lib/Compiler.js:371:38)            at emitAssets.err (/data/node_modules/webpack/lib/Compiler.js:258:10)            at applyPluginsAsyncSeries1.err (/data/node_modules/webpack/lib/Compiler.js:364:12)            at next (/data/node_modules/tapable/lib/Tapable.js:218:11)            at Compiler.compiler.plugin (/data/node_modules/webpack/lib/performance/SizeLimitsPlugin.js:99:4)            at Compiler.applyPluginsAsyncSeries1 (/data/node_modules/tapable/lib/Tapable.js:222:13)            at Compiler.afterEmit (/data/node_modules/webpack/lib/Compiler.js:361:9)            at require.forEach.err (/data/node_modules/webpack/lib/Compiler.js:350:15)            at /data/node_modules/async/dist/async.js:473:16            at iteratorCallback (/data/node_modules/async/dist/async.js:1064:13)            at /data/node_modules/async/dist/async.js:969:16            npm ERR! code ELIFECYCLE            npm ERR! errno 1            npm ERR! @ development: `cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js`            npm ERR! Exit status 1            npm ERR!            npm ERR! Failed at the @ development script.            npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

            npm ERR! A complete log of this run can be found in:            npm ERR!     C:/Users/Administrator.PC-20190309QPVT/AppData/Roaming/npm-cache/_logs/2019-03-21T04_33_39_487Z-debug.log            npm ERR! code ELIFECYCLE            npm ERR! errno 1            npm ERR! @ dev: `npm run development`            npm ERR! Exit status 1            npm ERR!            npm ERR! Failed at the @ dev script.            npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

            npm ERR! A complete log of this run can be found in:            npm ERR!     C:/Users/Administrator.PC-20190309QPVT/AppData/Roaming/npm-cache/_logs/2019-03-21T04_33_39_515Z-debug.log

巨坑npm run dev 报错 终于找到正确答案 Error: EPERM: operation not permitted, open '/data/public/build/css/add.p的更多相关文章

  1. vue项目初始化时npm run dev报错webpack-dev-server解决方法

    vue项目初始化时npm run dev报错webpack-dev-server解决方法 原因:这是新版webpack存在的BUG,卸载现有的新版本webpack,装老版本就好webpack-dev- ...

  2. nuxt.js 初始化 npm run dev 报错

    在初始化 npm install 了基本依赖后: npm run dev 报错: error in ./server/index.js Module build failed: Error: Plug ...

  3. npm run dev 报错 iview TypeError [ERR_INVALID_CALLBACK]: Callback must be a function

    运行npm run dev报这个错 然后找到 D:\text\vue\iview-admin\build\webpack.dev.config.js打开 将这一行代码: fs.write(fd, bu ...

  4. npm run dev 报错:Error: Cannot find module 'webpack-cli/bin/config-yargs'

    使用 npm run dev 时报错: Error: Cannot find module 'webpack-cli/bin/config-yargs' 原因是找不到webpack-cli这个包,使用 ...

  5. Vue 项目: npm run dev 报错 webpack-dev-server

    从码云上下载vue项目,运行npm run dev 时报错: > webpack-dev-server --inline --progress --config build/webpack.de ...

  6. vue.js环境配置步骤及npm run dev报错解决方案

    安装完成后,使用npm run dev 运行,成功后,就可以在浏览器中看到vue的欢迎画面了 最后一步可能报错,我就遇到这样的问题了, 个人问题仅供参考: ERROR Failed to compil ...

  7. npm run dev 报错 run `npm audit fix` to fix them, or `npm audit` for details

    前几天写的直接运行npm run dev还是ok的,突然不行了,前面报错是css-loader没有,删除style标签上的lang='scss'就好了,先不需要这个依赖.这个先不管. 只是后面的 ru ...

  8. vue项目,npm install后,npm run dev报错问题

    报错: ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! metools@1.0.0 dev: `node build/dev-server.js` npm ...

  9. vue 运行npm run dev报错

    npm run dev运行时报错,原因有很多. 一般用下面这种方法都能解决的. 最简单粗暴的方法: 1.删除依赖包node_modules 2.然后重新npm install就行了 (如果这步报错了, ...

随机推荐

  1. Knockoutjs 响应式计算研究

    reactive programming https://en.wikipedia.org/wiki/Reactive_programming In computing, reactive progr ...

  2. 开放源代码的设计层面框架Spring——day03

    spring第三天     一.AOP的相关概念         1.1AOP概述             1.1.1什么是AOP                 AOP:全称是Aspext Orie ...

  3. 树莓派设置固定IP地址

    vi /etc/dhcpcd.conf # 使用 vi 编辑文件,增加下列配置项 # 指定接口 eth0 interface eth0 # 指定静态IP,/24表示子网掩码为 255.255.255. ...

  4. docker学习------centos7.5下的swarm集群可视化构建

    1.swarm集群 manager : 192.168.211.175 agent1    : 192.168.211.176    agent2    :  192.168.211.177 2.环境 ...

  5. php获取脚本执行的参数

    在看PHP文档到预定义变量时碰到了$argc和$argv,顺手记录下 getopt()从命令行参数列表中获取选项 $arg = getopt('d:n:'); //只接收d n之后的参数 $num = ...

  6. Git管理源代码

    Git Git 是目前世界上最先进的分布式版本控制系统(没有之一) 作用 源代码管理 为什么要进行源代码管理? 方便多人协同开发 方便版本控制 Git单人本地仓库操作 安装git sudo apt-g ...

  7. JUC--ConcurrentHashMap

    HashMap HashTable HashTable锁住整个表 会存在复合操作上的问题“若不存则添加” “若存在则删除” 也是不安全的  效率低 ConcurrentHashMap:采用锁分段机制  ...

  8. NOIP2018Day1T2 货币系统

    题目描述 在网友的国度中共有 \(n\) 种不同面额的货币,第 \(i\) 种货币的面额为 \(a[i]\),你可以假设每一种货币都有无穷多张.为了方便,我们把货币种数为 \(n\).面额数组为 \( ...

  9. hostapd、/dev/random、/dev/urandom

    在使用hostapd做软ap时,出现了random熵不够的问题,导致节点连接不上这个ap. 下面先解释一下/dev/random和/dev/urandom 先让我们从一个工程中遇到的实际问题开始,先上 ...

  10. js |竖线字符串全部替换 replace

    一般人解决方案: 'a|b|c'.replace(/\|/g, ','); 神经病解决方案: 'a|b|c'.split('|').join(',');