Answer the question
In order to leave comments, you need to log in
How can I add a page response timeout for Nginx Upstream validation?
Let's say there is such a simple upstream.conf configuration
upstream backend {
server 192.168.1.44:8081;
server 192.168.1.60:8081;
server 192.168.1.62:8081;
}
server {
listen 8081;
location / {
proxy_pass http://backend;
}
}
Answer the question
In order to leave comments, you need to log in
Once again, many thanks to Lynn "Coffeeman"
With this nginx config inside the container, we managed to do what we intended.
In this case, nginx will wait until the specified timeout expires, if it is set in a particular container.
server {
listen 80;
listen [::]:80;
location / {
echo_sleep 11;
default_type 'text/html';
echo $hostname;
}
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question