Docker compose, nginx and wordpress can't upload files to volume - permission denied #711
glenelkinsdev
started this conversation in
General
Replies: 1 comment
-
The wordpress/php container you're building isn't the one that we maintain ./Vipirs-Website:/usr/share/nginx/html
vipirs-uploads:/usr/share/nginx/html/website/wp-content/uploads:rw I'd try asking over at the Docker Community Forums, Docker Community Slack, or Stack Overflow. Since these repos aren't really a user-help forum |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Bashing my head against a wall for hours here, i can't upload files in wordpress due to permission denied, i have logged into the website container and tried different users with chown like www-data, nginx, 1000 and all chmod to 755 yet i still can't upload files.
Wordpress clearly can see the uploads folder as it says:
The uploaded file could not be moved to wp-content/uploads/2022/05.
so it's looking at the correct location and seeing the 05 folder but just can't write the file to it. I'm using a docker volume for the uploads folder which is mapped to the container wp-content/uploads path. When i log into the container i can see the files that are stored on the volume, just can't write to it.
If it helps here is an output on the website container of the uploads folder:
I have tried to chmod the uploads folder to nginx, www-data and it just won't work and i'm now at a loss.
Here is the docker compose:
Weirdly if i also try to use a bind mount it still won't write to it.
Beta Was this translation helpful? Give feedback.
All reactions