Skip to content

Write permissions for docker process on "web" directory? #13

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
thisbesonic opened this issue Feb 4, 2018 · 5 comments
Open

Write permissions for docker process on "web" directory? #13

thisbesonic opened this issue Feb 4, 2018 · 5 comments

Comments

@thisbesonic
Copy link

thisbesonic commented Feb 4, 2018

Hi!

Awesome project! I used vagrant and want to switch to docker. I will probably migrate many projects.
First though I need to find out why docker-php can't write to the "web" folder.

Are there extra steps I need to do apart from your guide, or does the docker process need some special access rights? (I am on linux)

Thank you!

@nanoninja
Copy link
Owner

nanoninja commented Feb 16, 2018

Hi @slottybon,

Thank you for appreciating the project.

In order for this to work I think I have to make my own image with Nginx because there are proprietary problems (www-data) in the file sharing between the host machine and the container at the writing level.

It is possible to fix the problem manually but it is not the best solution.

@thisbesonic
Copy link
Author

Alright.
I don't see myself fixing this, so for the time being I will stay with Vagrant.
I will star your repo and wait for the issue to be fixed by you or docker folks though.

@Jehong-Ahn
Copy link

@slottybon, did you mean web/?

The root of the nginx project is web/public.
https://github.com/nanoninja/docker-nginx-php-mysql/blob/master/etc/nginx/default.conf#L11

@vnzhlv-zh
Copy link

@toonitw is it not possible to change it?
When I'm trying something like that: "/var/www/site.loc:/var/www/html" I get this error: "/var/www/html/public/index.php" is not found (2: No such file or directory),

@Jehong-Ahn
Copy link

@vanzhilov There are two ways.

  1. Move your app to site.loc/public
  2. Or modify nginx configuration as root /var/www/html
    https://github.com/nanoninja/docker-nginx-php-mysql/blob/master/etc/nginx/default.conf#L11

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

No branches or pull requests

4 participants