kolla-ansible/ansible/roles/cinder/templates/cinder-wsgi.conf.j2

38 lines
1.3 KiB
Django/Jinja

{% if cinder_enable_tls_backend | bool %}
{% if kolla_base_distro in ['centos'] %}
LoadModule ssl_module /usr/lib64/httpd/modules/mod_ssl.so
{% else %}
LoadModule ssl_module /usr/lib/apache2/modules/mod_ssl.so
{% endif %}
{% endif %}
Listen {{ api_interface_address | put_address_in_context('url') }}:{{ cinder_api_listen_port }}
ServerSignature Off
ServerTokens Prod
TraceEnable off
TimeOut {{ kolla_httpd_timeout }}
KeepAliveTimeout {{ kolla_httpd_keep_alive }}
{% if cinder_logging_debug | bool %}
LogLevel info
{% endif %}
<VirtualHost *:{{ cinder_api_listen_port }}>
WSGIDaemonProcess cinder-api processes={{ openstack_service_workers }} threads=1 user=cinder group=cinder display-name=cinder-api
WSGIProcessGroup cinder-api
WSGIScriptAlias / /var/www/cgi-bin/cinder/cinder-wsgi
WSGIApplicationGroup %{GLOBAL}
WSGIPassAuthorization On
<IfVersion >= 2.4>
ErrorLogFormat "%{cu}t %M"
</IfVersion>
ErrorLog /var/log/kolla/cinder/cinder-api-error.log
LogFormat "%{X-Forwarded-For}i %l %u %t \"%r\" %>s %b %D \"%{Referer}i\" \"%{User-Agent}i\"" logformat
CustomLog /var/log/kolla/cinder/cinder-api-access.log logformat
{% if cinder_enable_tls_backend | bool %}
SSLEngine On
SSLCertificateFile /etc/cinder/certs/cinder-cert.pem
SSLCertificateKeyFile /etc/cinder/certs/cinder-key.pem
{% endif %}
</VirtualHost>