4
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

error An unexpected error occurred: "EPERM: operation not permitted, copyfileとでてCircleCIがビルドできなくなった

Last updated at Posted at 2020-12-09

ローカルでもビルドできるし、Dockerでもビルドできるのに、CircleCI上で突然ビルドできなくなった。
どうやら、うまくファイルがコピーできないようだ。

error An unexpected error occurred: "EPERM: operation not permitted, copyfile '/usr/local/share/.cache/yarn/v6/npm-@babel-cli-7.12.8-3b24ed2fd5da353ee6f19e8935ff8c93b5fe8430-integrity/node_modules/@babel/cli/LICENSE' -> '/usr/src/app/node_modules/@babel/cli/LICENSE'".

原因

下記の記事を読む限りだと、node14.9.0以降のバージョンが、CircleCI上のDockerに対応していないようだ。

対応

下記のようにバージョンを指定してあげるとうまくビルドできた。

.circleci/config.yml
version: 2.0
 jobs:
   build:
     docker:
       - image: circleci/node:14
     steps:
       - checkout
       - setup_remote_docker:
+          version: 19.03.13

参考

Docker build fails with EPERM: operation not permitted, copyfile..... when using node 14.9.0 or later – CircleCI Support Center - https://support.circleci.com/hc/en-us/articles/360050934711-Docker-build-fails-with-EPERM-operation-not-permitted-copyfile-when-using-node-14-9-0-or-later-

4
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?