summarylogtreecommitdiffstats
path: root/nginx_component.conf
blob: 3f9cc308af9ef142d51ccf7ee671f32cdc89bd1c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
if ($badagent) {
	# Nginx is too rigid to support a server-block-level ```if (condition) proxy_pass <URL>```, so we just redirect to a reserved location, and serve iocaine there.
	rewrite ^ /BAUNVF6NRJE5QA2T$request_uri;
}

location /BAUNVF6NRJE5QA2T {
	access_log off;
	error_log /dev/null;

	proxy_set_header Host $host;
	proxy_pass http://127.0.0.1:42069;
#	proxy_pass http://unix:/run/iocaine/iocaine.sock;
}