GithubHelp home page GithubHelp logo

Comments (3)

viktor-c avatar viktor-c commented on July 20, 2024 3

As pointed by @Braintelligence you can change the ownership of the folder where you installed grav. For this to work your user has to be part of the www-data group. This group has id 33, which appears in this command chown -R 33:33 /srv/doc-user

My workaround was like follows:

  1. Go to the Terminal/Konsole in Linux
  2. get the id of your running user. id My output looks like this: id
    uid=1000(viktor) gid=1000(viktor) Groups=1000(viktor),...,130(docker)
    we will use 1000 as UID and GUID in the following code. Replace with your ID
  3. In your Dockerfile change following lines:
RUN chown www-data:www-data /var/www
USER www-data

with these

ARG UID=1000
ARG GUID=1000
RUN chown www-data:www-data /var/www
RUN useradd -u $UID newuser
RUN usermod -a -G newuser www-data
USER www-data
  1. Build and run your grav container

Like this you will add a new user in the grav container. This user has the same ID as your localuser has. Then it will add the group of this user to www-data. As such www-data will have access to your local folder. And so will you.
:)

from docker-grav.

Braintelligence avatar Braintelligence commented on July 20, 2024 1

You have to chown -R 33:33 /srv/doc-user

from docker-grav.

justpeterpan avatar justpeterpan commented on July 20, 2024

It's a problem with your user rights.

from docker-grav.

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.