aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--build/build.conf3
-rw-r--r--deploy/adapters/ansible/openstack_mitaka_xenial/roles/dashboard/templates/openstack-dashboard.conf.j216
-rw-r--r--deploy/adapters/ansible/openstack_mitaka_xenial/roles/keystone/templates/wsgi-keystone.conf.j250
-rw-r--r--deploy/adapters/ansible/roles/dashboard/tasks/main.yml2
-rw-r--r--deploy/adapters/cobbler/snippets/preseed_post_install_network_config2
-rwxr-xr-xdeploy/compass_vm.sh23
-rw-r--r--deploy/conf/base.conf1
-rwxr-xr-xdeploy/launch.sh4
-rw-r--r--deploy/rename_nics.py2
9 files changed, 99 insertions, 4 deletions
diff --git a/build/build.conf b/build/build.conf
index c6e0f7a1..15e2e1df 100644
--- a/build/build.conf
+++ b/build/build.conf
@@ -112,5 +112,6 @@ export SPECIAL_PIP_PACKAGE="https://bootstrap.pypa.io/ez_setup.py \
https://pypi.python.org/packages/source/p/python-dateutil/python-dateutil-2.4.2.tar.gz "
export PIP_PACKAGE="https://pypi.python.org/packages/0d/af/8ccfb73834a6ddf9d57ecac61466557b7ca0722620bbb16d2d069ce312db/networking-odl-2.0.0.tar.gz \
- https://pypi.python.org/packages/90/4f/74b730294de1db393e3e82211b5d2115f9a763849abca7d014348a550d2a/oslosphinx-4.5.0.tar.gz"
+ https://pypi.python.org/packages/90/4f/74b730294de1db393e3e82211b5d2115f9a763849abca7d014348a550d2a/oslosphinx-4.5.0.tar.gz \
+ https://pypi.python.org/packages/74/f0/386f7f73aa6628c1bef53874c5d453b556356d77732add69000aa53b353b/policy2tosca-1.0.tar.gz "
diff --git a/deploy/adapters/ansible/openstack_mitaka_xenial/roles/dashboard/templates/openstack-dashboard.conf.j2 b/deploy/adapters/ansible/openstack_mitaka_xenial/roles/dashboard/templates/openstack-dashboard.conf.j2
new file mode 100644
index 00000000..96472779
--- /dev/null
+++ b/deploy/adapters/ansible/openstack_mitaka_xenial/roles/dashboard/templates/openstack-dashboard.conf.j2
@@ -0,0 +1,16 @@
+{% set work_threads = (ansible_processor_vcpus + 1) // 2 %}
+{% if work_threads > 10 %}
+{% set work_threads = 10 %}
+{% endif %}
+
+<VirtualHost {{ internal_ip }}:80>
+ WSGIScriptAlias /horizon {{ horizon_dir }}/wsgi/django.wsgi
+ WSGIDaemonProcess horizon user=horizon group=horizon processes=4 threads={{ work_threads }}
+ WSGIProcessGroup horizon
+ Alias /static {{ horizon_dir }}/static/
+ Alias /horizon/static {{ horizon_dir }}/static/
+ <Directory {{ horizon_dir }}/wsgi>
+ Order allow,deny
+ Allow from all
+ </Directory>
+</VirtualHost>
diff --git a/deploy/adapters/ansible/openstack_mitaka_xenial/roles/keystone/templates/wsgi-keystone.conf.j2 b/deploy/adapters/ansible/openstack_mitaka_xenial/roles/keystone/templates/wsgi-keystone.conf.j2
new file mode 100644
index 00000000..55c89839
--- /dev/null
+++ b/deploy/adapters/ansible/openstack_mitaka_xenial/roles/keystone/templates/wsgi-keystone.conf.j2
@@ -0,0 +1,50 @@
+{% set work_threads = (ansible_processor_vcpus + 1) // 2 %}
+{% if work_threads > 10 %}
+{% set work_threads = 10 %}
+{% endif %}
+
+<VirtualHost {{ internal_ip }}:5000>
+ WSGIDaemonProcess keystone-public processes=4 threads={{ work_threads }} user=keystone group=keystone display-name=%{GROUP}
+ WSGIProcessGroup keystone-public
+ WSGIScriptAlias / /usr/bin/keystone-wsgi-public
+ WSGIApplicationGroup %{GLOBAL}
+ WSGIPassAuthorization On
+ <IfVersion >= 2.4>
+ ErrorLogFormat "%{cu}t %M"
+ </IfVersion>
+ ErrorLog /var/log/{{ http_service_name }}/keystone.log
+ CustomLog /var/log/{{ http_service_name }}/keystone_access.log combined
+
+ <Directory /usr/bin>
+ <IfVersion >= 2.4>
+ Require all granted
+ </IfVersion>
+ <IfVersion < 2.4>
+ Order allow,deny
+ Allow from all
+ </IfVersion>
+ </Directory>
+</VirtualHost>
+
+<VirtualHost {{ internal_ip }}:35357>
+ WSGIDaemonProcess keystone-admin processes=4 threads={{ work_threads }} user=keystone group=keystone display-name=%{GROUP}
+ WSGIProcessGroup keystone-admin
+ WSGIScriptAlias / /usr/bin/keystone-wsgi-admin
+ WSGIApplicationGroup %{GLOBAL}
+ WSGIPassAuthorization On
+ <IfVersion >= 2.4>
+ ErrorLogFormat "%{cu}t %M"
+ </IfVersion>
+ ErrorLog /var/log/{{ http_service_name }}/keystone.log
+ CustomLog /var/log/{{ http_service_name }}/keystone_access.log combined
+
+ <Directory /usr/bin>
+ <IfVersion >= 2.4>
+ Require all granted
+ </IfVersion>
+ <IfVersion < 2.4>
+ Order allow,deny
+ Allow from all
+ </IfVersion>
+ </Directory>
+</VirtualHost>
diff --git a/deploy/adapters/ansible/roles/dashboard/tasks/main.yml b/deploy/adapters/ansible/roles/dashboard/tasks/main.yml
index da6990c4..229e3cfe 100644
--- a/deploy/adapters/ansible/roles/dashboard/tasks/main.yml
+++ b/deploy/adapters/ansible/roles/dashboard/tasks/main.yml
@@ -28,7 +28,7 @@
- name: remove ubuntu theme
action: "{{ ansible_pkg_mgr }} name=openstack-dashboard-ubuntu-theme state=absent"
- when: ansible_os_family == 'Debian'
+ when: ansible_os_family == 'Debian' and not enable_ubuntu_theme
notify:
- restart dashboard services
diff --git a/deploy/adapters/cobbler/snippets/preseed_post_install_network_config b/deploy/adapters/cobbler/snippets/preseed_post_install_network_config
index 42df3cb6..cb79c556 100644
--- a/deploy/adapters/cobbler/snippets/preseed_post_install_network_config
+++ b/deploy/adapters/cobbler/snippets/preseed_post_install_network_config
@@ -441,7 +441,7 @@ echo "" >> /etc/network/interfaces
used_logical_interface_$iname=$iname
- #if $iface_type in ("slave","bond_slave","bridge_slave","bonded_bridge_slave","static")
+ #if $iface_type in ("slave","bond_slave","bridge_slave","bonded_bridge_slave")
#set $static = 1
#end if
echo "auto $iname" >> /etc/network/interfaces
diff --git a/deploy/compass_vm.sh b/deploy/compass_vm.sh
index 0c213e31..63c1998b 100755
--- a/deploy/compass_vm.sh
+++ b/deploy/compass_vm.sh
@@ -48,6 +48,29 @@ function install_compass() {
fi
}
+function exec_cmd_on_compass() {
+ ssh $ssh_args root@$MGMT_IP "$@"
+}
+
+function _inject_dashboard_conf() {
+ if [[ "$ENABLE_UBUNTU_THEME" == "true" ]]; then
+ cmd="
+ sed -i '/enable_ubuntu_theme/d' /etc/compass/templates/ansible_installer/openstack_mitaka/vars/HA-ansible-multinodes.tmpl; \
+ echo enable_ubuntu_theme: True >> /etc/compass/templates/ansible_installer/openstack_mitaka/vars/HA-ansible-multinodes.tmpl
+ "
+ else
+ cmd="
+ sed -i '/enable_ubuntu_theme/d' /etc/compass/templates/ansible_installer/openstack_mitaka/vars/HA-ansible-multinodes.tmpl; \
+ echo enable_ubuntu_theme: False >> /etc/compass/templates/ansible_installer/openstack_mitaka/vars/HA-ansible-multinodes.tmpl
+ "
+ fi
+ exec_cmd_on_compass $cmd
+}
+
+function inject_compass_conf() {
+ _inject_dashboard_conf
+}
+
function wait_ok() {
set +x
log_info "wait_compass_ok enter"
diff --git a/deploy/conf/base.conf b/deploy/conf/base.conf
index 24eb703d..6926b581 100644
--- a/deploy/conf/base.conf
+++ b/deploy/conf/base.conf
@@ -24,6 +24,7 @@ export DASHBOARD_URL=""
export ENABLE_SECGROUP=${ENABLE_SECGROUP:-"true"}
export ENABLE_VPNAAS="false"
export ENABLE_FWAAS="false"
+export ENABLE_UBUNTU_THEME=${ENABLE_UBUNTU_THEME:-"true"}
function next_ip {
ip_addr=$1
diff --git a/deploy/launch.sh b/deploy/launch.sh
index 489c06d8..348d11e2 100755
--- a/deploy/launch.sh
+++ b/deploy/launch.sh
@@ -68,6 +68,10 @@ if [[ -z "$REDEPLOY_HOST" || "$REDEPLOY_HOST" == "false" ]]; then
if ! set_compass_machine; then
log_error "set_compass_machine fail"
fi
+
+ # FIXME: refactor compass adapter and conf code, instead of doing
+ # hack conf injection.
+ inject_compass_conf
fi
if [[ "$DEPLOY_HOST" == "true" || $REDEPLOY_HOST == "true" ]]; then
diff --git a/deploy/rename_nics.py b/deploy/rename_nics.py
index 6163188e..a95d1e02 100644
--- a/deploy/rename_nics.py
+++ b/deploy/rename_nics.py
@@ -17,7 +17,7 @@ def rename_nics(dha_info, rsa_file, compass_ip):
exec_cmd("ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null \
-i %s root@%s \
- 'cobbler system edit --name=%s --interface=%s --mac=%s --interface_type=static'" \
+ 'cobbler system edit --name=%s --interface=%s --mac=%s --static=1'" \
% (rsa_file, compass_ip, host_name, nic_name, mac))
exec_cmd("ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null \