openstack-ansible-os_nova/templates/nova-placement-nginx.conf.j2
Major Hayden b3c6035b7a
Remove trailing slash in nginx config
The nginx configuration file passes along traffic to the placement
API if the URI is '/placement/' but the service is registered with
keystone as just '/placement' (no trailing slash). This causes
nginx to send back the default page when nova services try to talk
to the placement API.

This patch fixes the nginx configuration to match the URI for the
registered service.

Closes-Bug: 1689824
Change-Id: I309730a6daa8c3ea15fca78ab9ce910383019869
2017-05-10 09:53:49 -04:00

24 lines
603 B
Django/Jinja

# {{ ansible_managed }}
server {
listen {{ nova_placement_service_port }};
{% for line in nova_placement_nginx_extra_conf %}
{{ line }}
{%- endfor %}
access_log /var/log/nova/nova-placement-api-access.log custom;
error_log /var/log/nova/nova-placement-api-error.log info;
location /placement {
try_files $uri @nova-placement-api;
}
location @nova-placement-api {
include uwsgi_params;
uwsgi_pass 127.0.0.1:{{ nova_placement_uwsgi_socket_port }};
uwsgi_param SCRIPT_NAME '/placement';
uwsgi_modifier1 30;
}
}