Commit 1e1dd32f authored by Dom Sekotill's avatar Dom Sekotill
Browse files

Add fallback fastcgi port: upstream:9000

'upstream' can be added to a container's host file with Docker's
--add-host argument or Kubernetes' HostAliases, or made available with
DNS.
parent 04426092
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -3,6 +3,11 @@ map $http_x_forwarded_proto $forwarded_https {
	https on;
}

upstream fastcgi {
	server localhost:9000 fail_timeout=120;
	server upstream:9000 backup;
}

server {
	listen 80;
	server_name _;
@@ -19,7 +24,7 @@ server {
		fastcgi_param HTTPS $forwarded_https;
		fastcgi_param SERVER_ADDR $http_x_forwarded_host;
		fastcgi_param SERVER_PORT $http_x_forwarded_port;
		fastcgi_pass localhost:9000;
		fastcgi_pass fastcgi;
	}

	# block the XMLRPC script