Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

459
Views
Why did Gitlab CI gave Error: Cannot find module './node-modules-paths'?

I got this error on my pipeline

> react-scripts build && cp .htaccess build/
internal/modules/cjs/loader.js:905
  throw err;
  ^
Error: Cannot find module './node-modules-paths'

I logged in to server

-rw-r--r--    1 root root    164 Nov 25  2020 .htaccess
-rw-r--r--    1 root root    827 May 23 11:00 Dockerfile
-rw-r--r--    1 node node   2101 Oct 26  2020 README.md
drwxr-xr-x    3 root root   4096 May 24 12:06 build
-rw-r--r--    1 root root    192 Jan 11  2021 debug.log
-rw-r--r--    1 root root     95 May 23 11:04 docker-entrypoint.sh
drwxr-xr-x    2 root root   4096 May 19 10:23 nginx
drwxr-xr-x 1176 node node  36864 May 24 12:04 node_modules

I am adding logs from my Docker container

1 verbose cli [ '/usr/local/bin/node', '/usr/local/bin/npm', 'run', 'build' ]
2 info using npm@6.14.16
3 info using node@v14.19.0
4 verbose run-script [ 'prebuild', 'build', 'postbuild' ]
5 info lifecycle fluffa-frontend@0.1.0~prebuild: fluffa-frontend@0.1.0
6 info lifecycle fluffa-frontend@0.1.0~build: fluffa-frontend@0.1.0
7 verbose lifecycle fluffa-frontend@0.1.0~build: unsafe-perm in lifecycle true
8 verbose lifecycle fluffa-frontend@0.1.0~build: PATH: /usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/var/www/html/fluffa.mykomp/fe/node_modules/.bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
9 verbose lifecycle fluffa-frontend@0.1.0~build: CWD: /var/www/html/fluffa.mykomp/fe
10 silly lifecycle fluffa-frontend@0.1.0~build: Args: [ '-c', 'react-scripts build && cp .htaccess build/' ]
11 silly lifecycle fluffa-frontend@0.1.0~build: Returned: code: 1  signal: null
12 info lifecycle fluffa-frontend@0.1.0~build: Failed to exec build script
13 verbose stack Error: fluffa-frontend@0.1.0 build: `react-scripts build && cp .htaccess build/`
13 verbose stack Exit status 1
13 verbose stack     at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16)
13 verbose stack     at EventEmitter.emit (events.js:400:28)
13 verbose stack     at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack     at ChildProcess.emit (events.js:400:28)
13 verbose stack     at maybeClose (internal/child_process.js:1058:16)
13 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:293:5)
14 verbose pkgid fluffa-frontend@0.1.0
15 verbose cwd /var/www/html/fluffa.mykomp/fe
16 verbose Linux 4.9.0-18-amd64
17 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "run" "build"
18 verbose node v14.19.0
19 verbose npm  v6.14.16
20 error code ELIFECYCLE

How it comes it can not find node_modules? Where path should be specified?

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!