attempting to enhance this image by installing Elm globally but encountering issues. It would appear that the installation process for npm is user 500 and owns and restricts access to /usr/local/lib/node_modules by default. Seems like an unnecessary constraint to impose on an already isolated environment.
Investigation revealed:
4337 error Linux 4.4.0-21-generic
4338 error argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "-g" "elm"
4339 error node v7.8.0
4340 error npm v4.2.0
4341 error path /usr/local/lib/node_modules
4342 error code EACCES
4343 error errno -13
4344 error syscall access
4345 error Error: EACCES: permission denied, access '/usr/local/lib/node_modules'
4345 error { Error: EACCES: permission denied, access '/usr/local/lib/node_modules'
4345 error errno: -13,
4345 error code: 'EACCES',
4345 error syscall: 'access',
4345 error path: '/usr/local/lib/node_modules' }
4346 error Please try running this command again as root/Administrator.
4347 verbose exit [ -13, true ]
and
ls -al /usr/local/lib/node_modules
total 12
drwxrwxr-x 3 500 500 4096 Mar 29 01:27 .
drwxrwxr-x 4 500 500 4096 Mar 29 01:27 ..
drwxrwxr-x 11 500 500 4096 Mar 29 01:27 npm
where
id -nu 500
id: 500: no such user
attempting to enhance this image by installing Elm globally but encountering issues. It would appear that the installation process for
npmis user500and owns and restricts access to/usr/local/lib/node_modulesby default. Seems like an unnecessary constraint to impose on an already isolated environment.Investigation revealed:
and
where