Git Product home page Git Product logo

Comments (6)

dominikbraun avatar dominikbraun commented on May 18, 2024 1

The error is fixed now.

Don't run any ./psh.phar scripts using sudo. Otherwise the permissions for node_modules are invalid.

All scripts must work without sudo. If docker:start does not work without sudo, make sure your user is in the system's docker group.

from shopware.

keulinho avatar keulinho commented on May 18, 2024

Are you using a local setup or do you use docker?
What permissions are set on the node_modules folder? And are there any other node modules already installed when it crashes?
You definitley need write permissions to the node_modules folder, do you use a different user for running the install command that doesn't has the write permissions?

from shopware.

dominikbraun avatar dominikbraun commented on May 18, 2024

Some more precise information:

  1. I'm running the installation with Docker
  2. The node_modules directory has the permissions rwx/r-x/r-x and is owned by root
  3. There are modules in the folder, but I'm not sure if they were created during the install
  4. I'm running ./psh.phar install as root in the container (after accessing it with ./psh.phar docker:ssh)
  5. I started the Docker daemon via sudo dockerd

from shopware.

pweyck avatar pweyck commented on May 18, 2024

node_modules should not be owned by root. Did you run ./psh.phar docker:ssh as root?

To fix the permissions for your current user, run this with your development directory:
sudo find $DEVELOPMENT_DIR -not -user "$(id -u)" -and -not -user 999 -exec chown "$(id -u):$(id -g)" {} \;

This command changes the ownership of all files and directories that are not owned by your current user (id -u) or 999 (uid of the mysql user in the container) to your current user.

from shopware.

dominikbraun avatar dominikbraun commented on May 18, 2024

Did you run ./psh.phar docker:ssh as root?

Yes. The reason is that otherwise (logged in as application), I don't have permissions to some composer directories:

[ErrorException] copy(./composer/cache/files/composer/xdebug-handler/...): failed to open stream: Permission denied

However, it seems that running ./psh.phar docker:ssh without sudo is the way to go...

from shopware.

pweyck avatar pweyck commented on May 18, 2024

It seems like your ~/.composer and maybe your ~/.npm directory is owned by root. ./psh.phar docker:start should check that and fail if that's not the case.

from shopware.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.