Skip to content
This repository has been archived by the owner on Jul 20, 2022. It is now read-only.

Run commands as a low privilege user #34

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

kasparsd
Copy link
Collaborator

@kasparsd kasparsd commented Dec 13, 2019

Fixes #31.

This won't be necessary as soon as we switch to our own images that don't run as root by default.

@kasparsd kasparsd self-assigned this Dec 13, 2019
@derekherman
Copy link
Contributor

@kasparsd I get this error when testing the PR.

npm ERR! correctMkdir failed to make directory /.npm/_locks
npm ERR! code EACCES
npm ERR! syscall mkdir
npm ERR! path /.npm
npm ERR! errno -13
npm ERR! 
npm ERR! Your cache folder contains root-owned files, due to a bug in
npm ERR! previous versions of npm which has since been addressed.
npm ERR! 
npm ERR! To permanently fix this problem, please run:
npm ERR!   sudo chown -R 1000:0 "/.npm"
npm ERR! code ELIFECYCLE
npm ERR! errno 243
npm ERR! @xwp/block-scaffolding-wp@1.0.0 docker: `docker-compose run --user=1000 --workdir=/var/www/html/wp-content/plugins/block-scaffolding-wp wordpress "npm" "install"`
npm ERR! Exit status 243
npm ERR! 
npm ERR! Failed at the @xwp/block-scaffolding-wp@1.0.0 docker script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cannot run npm install from container
2 participants