Replies: 2 comments 4 replies
-
|
Hi, I don't know what your set up is like on Hetzner with Dokploy but what user are you running this as? Run If the uid and gid is not 1000:1000, that could be the problem. It would be easy to fix, you need to build and run your project with a UID that matches your system. The docker-django-example/.env.example Line 23 in 25de410 Typically the first non-root user on a Linux system is 1000:1000 by default so no adjustments are needed. I never heard of Dokploy so I'm not sure what it's doing behind the scenes. Usually to run Docker on a server you would install it and then assign your non-root user to the docker group, and then you can run Docker commands without root and all permissions would work as long as the UID / GID is lined up (when bind volumes are involved). Ultimately this is all related to the bind volume for the public directory so you can mount it into nginx not running in a container. If you didn't care about that or you have other ways to host static files you can remove that volume all together and it will work with no further adjustments. |
Beta Was this translation helpful? Give feedback.
-
|
Thanks for your helpful answer as always @nickjj.
This is what I get when I run
I think this is the key distinction. Dokploy runs as root and probably that affects how Docker works.
Yeah. I just realized I tried to do something I couldn't do in #68, which is run collectstatic on build time, but I have (as I stated there) 10+ mandatory env vars and this will become unwieldy to keep And having a named volume in And I changed the |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
This is more my lackluster understanding than anything else.
Previously I was hosted on Railway and couldn't use the
compose.yamlfrom this template (which I've adopted). I'm now moving to Hetzner + Dokploy, andbin/docker-entrypoint-webis failing:I believe it's this line:
Claude claims this is because Dokploy runs as root, and so this directory is owned by root and the user python can't write to it. It's suggesting I create a named volume. Is that the way to go?
Beta Was this translation helpful? Give feedback.
All reactions