I have an nginx proxy pointing at an external server. When the external server is down, the nginx proxy returns a 502 bad gateway.
Instead, I'd like nginx to also refuse the connection - How can I do this?
Server Fault is a question and answer site for system and network administrators. It only takes a minute to sign up.
Sign up to join this communityAfter further thought, I think this can't be done. When nginx is making the request to the external server, it has already accepted the connection from the client