Adding support for mod_wsgi

This commit is contained in:
root 2016-01-25 00:24:48 +00:00
parent fa48bfd0fc
commit b8f61638f0
4 changed files with 8 additions and 6 deletions

View File

@ -23,7 +23,7 @@
- { src: "ironic-ports.conf.j2", dest: "/etc/apache2/ports.conf" }
- { src: "ironic-httpd.conf.j2", dest: "/etc/apache2/sites-available/ironic-httpd.conf" }
notify:
- Restart Apache
- Restart ironic services
tags:
- ironic-httpd
@ -32,7 +32,7 @@
path: "/etc/apache2/sites-enabled/000-default.conf"
state: "absent"
notify:
- Restart Apache
- Restart ironic services
tags:
- ironic-httpd
@ -44,7 +44,7 @@
with_items:
- { src: "/etc/apache2/sites-available/ironic-httpd.conf", dest: "/etc/apache2/sites-enabled/ironic-httpd.conf", state: "link" }
notify:
- Restart Apache
- Restart ironic services
tags:
- ironic-httpd
@ -56,6 +56,6 @@
group: "{{ ironic_system_group_name }}"
mode: "0755"
notify:
- Restart Apache
- Restart ironic services
tags:
- ironic-config

View File

@ -68,6 +68,8 @@
- { path: "{{ ironic_system_home_folder }}/master_images" }
- { path: "/var/lock/ironic" }
- { path: "/var/run/ironic" }
- { path: "/var/www/cgi-bin", owner: root, group: root }
- { path: "/var/www/cgi-bin/ironic" }
tags:
- ironic-api
- ironic-conductor

View File

@ -1,7 +1,7 @@
# {{ ansible_managed }}
<VirtualHost *:{{ ironic_service_port }}>
WSGIDaemonProcess ironic-api user={{ ironic_system_user_name }} group={{ ironic_group_name }} processes={{ ironic_wsgi_processes }} threads={{ ironic_wsgi_threads }} display-name=%{GROUP}
WSGIDaemonProcess ironic-api user={{ ironic_system_user_name }} group={{ ironic_system_group_name }} processes={{ ironic_wsgi_processes }} threads={{ ironic_wsgi_threads }} display-name=%{GROUP}
WSGIScriptAlias / /var/www/cgi-bin/ironic/ironic.wsgi
SetEnv APACHE_RUN_USER {{ ironic_system_user_name }}
SetEnv APACHE_RUN_GROUP {{ ironic_system_group_name }}

View File

@ -18,7 +18,7 @@
import os
{% if ironic_venv_enable | bool %}
{% if ironic_venv_enabled | bool %}
activate_this = os.path.expanduser("{{ ironic_venv_bin }}/activate_this.py")
execfile(activate_this, dict(__file__=activate_this))
{% endif %}