-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Restarting app causes 502 until full stop and restart of entire docker-compose stack #1289
Comments
@Redsandro did you find a solution to this? |
@DekiChan I did not find a solution yet, and I still have this problem. I did wrap as many try-and-catches at every level so the container never ever ever ever crashes. But it still happens now and then. Some upstream vectors just can't be anticipated 100% of the time. |
@Redsandro, quite embarrassingly I figured out we're using However, I solved the issue by using combination of |
YOU ARE THE BEST!!! Nginx INSIDE Docker My solution is: location / { |
Problem:
When a request from shodan.io crashes the smtp-server (see nodemailer/smtp-server#128) in my api app served over https, it is automatically restarted due to
docker-compose.yml
restart: always
.However, the app doesn't work after restarting:
nginx-proxy
returns502
.Expected
docker-compose restart api
and the logs shows it's listening, I'm still getting 502.docker-compose restart
restarting everything includingnginx-proxy
andletsencrypt-nginx-proxy-companion
, the logs show listening, but I'm still getting 502.What works:
A full
docker-compose stop && docker-compose up -d
brings up the app and everything works. I don't understand the effective difference betweendocker-compose restart
anddocker-compose stop && docker-compose up -d
, which puzzles me.But I need to automate this error recovery. I thought
restart:always
should be sufficient. Is anyone else experiencing something similar? I searched, but I am human. Are there any known issues related to this?docker-compose.yml
The text was updated successfully, but these errors were encountered: