|
|
@ -17,7 +17,7 @@ LOCATIONS=$(
|
|
|
|
# all services have metrics under /metrics/SERVICE, except for thrimebletrimmer
|
|
|
|
# all services have metrics under /metrics/SERVICE, except for thrimebletrimmer
|
|
|
|
generate_location "/metrics/$name" "http://$name:$port/metrics"
|
|
|
|
generate_location "/metrics/$name" "http://$name:$port/metrics"
|
|
|
|
done
|
|
|
|
done
|
|
|
|
[ -n "$THRIMBLETRIMMER" ] && echo -e "\t\tlocation = / { return 301 \$scheme://\$host/thrimbletrimmer/dashboard.html; }\n\t\tlocation /thrimbletrimmer { }"
|
|
|
|
[ -n "$THRIMBLETRIMMER" ] && echo -e "\t\tlocation = / { return 301 /thrimbletrimmer/dashboard.html; }\n\t\tlocation /thrimbletrimmer { }"
|
|
|
|
)
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
|
|
cat > /etc/nginx/nginx.conf <<EOF
|
|
|
|
cat > /etc/nginx/nginx.conf <<EOF
|
|
|
@ -33,6 +33,7 @@ http {
|
|
|
|
listen 80;
|
|
|
|
listen 80;
|
|
|
|
gzip on;
|
|
|
|
gzip on;
|
|
|
|
gzip_comp_level 9;
|
|
|
|
gzip_comp_level 9;
|
|
|
|
|
|
|
|
absolute_redirect off;
|
|
|
|
$LOCATIONS
|
|
|
|
$LOCATIONS
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|