Open jmpmcmanus opened 1 year ago
I have the same problem
I'm trying to finish this book before new years(so today) and I'm stuck on the same problem.
@jmpmcmanus and @alfonsomiralles did either of you get it sorted?
There seems to be an issue with Daphne related to UNIX sockets. You can run Daphne via host/port instead of UNIX socket:
docker-compose.yml
daphne:
command: ["../wait-for-it.sh", "db:5432", "--",
"daphne", "-b", "0.0.0.0", "-p", "9001",
"educa.asgi:application"]
# ...
Nginx config:
upstream daphne {
server daphne:9001;
}
There seems to be an issue with Daphne related to UNIX sockets. You can run Daphne via host/port instead of UNIX socket:
docker-compose.yml
daphne: command: ["../wait-for-it.sh", "db:5432", "--", "daphne", "-b", "0.0.0.0", "-p", "9001", "educa.asgi:application"] # ...
Nginx config:
upstream daphne { server daphne:9001; }
It is working! Thanks a lot!
In chapter 17 I'm getting the following error related to daphne:
CRITICAL Listen failure: Couldn't listen on any:b'/code/educa/daphne.sock': Cannot acquire lock.
I tried stoping the docker-compose deleting the daphne.sock and restarting docker-compose and get the same error. A daphne.sock.lock file is also created, which is actually link to: daphne.sock.lock --> 1. I remove that as well before starting docker-compose again.
Jim