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
Sites volume permission error #803
Comments
wait for few seconds for Mariadb container to start with configurations and env variables. wait for the configuration container to stop successfully. |
Thank you for your response. I believe all mentioned is fine. MySQL container seems fine
Here is the rest:
redis seems to be fine the same way as mariadb
but other containers can't connect to it, this is the same for erpnext-one-queue-short-1 and erpnext-one-queue-long-1 and erpnext-one-queue-default-1:
here is a websocket container error log
and this one is also interesting erpnext-one-frontend-1:
|
Also, networking between containers seems to be fine as well, as I can connect to MariaDB from the backend container using I have one last clue to try, I will post my results in a few mins |
Hm, nothing. I've tried again from the beginning, which means I have re-created
So I guess my original approach of changing paths in the .yaml file to some accessible directories on my system was right. I've been changing /home/frappe/frappe-bench/sites to /var/erpnext/{subdirs}, and had created this empty dir before. Here is a snippet of the erpnext-one.yaml to show what paths I am referring to.
|
changing paths won't solve the problem. the permission to docker volumes need to be fixed. the sites directory needs to be owned by uid:gid 1000:1000 manually chown the volumes from /var/lib/docker/volumes or use additional container with root privileges to chown the volume |
Thank you for all the clues. I've been successful today with adding a |
follow discussion on PR |
https://discuss.erpnext.com/t/how-can-i-get-erpnext-running-under-docker-for-a-quick-look/90288 PWD setup working locally on my linux (non-root user, docker compose v2): pwd-setup-locally.mp4 |
Make sure only 1 docker daemon is installed and it has appropriate access. docker installed through snap may cause problem. Check this thread https://discuss.erpnext.com/t/how-can-i-get-erpnext-running-under-docker-for-a-quick-look/90288/18 |
I guess this happens when I try to setup a server as root user directly instead of using non-root user with docker permission. |
This could be the cause, yes. I’ve used sudo for sure, but that could result in the same behaviour as using root account directly. |
@timemaster5 can you access your database from backend container cli using:
|
https://docs.docker.com/engine/install/linux-postinstall/ I use docker as non root user added to docker group as mentioned in docker docs. |
I'll close this. open new issue if you still face the problem. |
Description of the issue
I follow this guide: https://github.com/frappe/frappe_docker/blob/main/docs/single-server-example.md
And this step is failing every time, even though I have all the environment variables correctly set :
The problem is with the mariadb, bench is trying to connect to 127.0.0.1 instead of to
mariadb-database
containerContext information (for bug reports)
Ubuntu 21.10, Docker 20.10.12 with compose 2.5.0
Steps to reproduce the issue
Observed result
Mariadb connection error
Expected result
Correctly created site
Stacktrace / full error message if available
The text was updated successfully, but these errors were encountered: