summaryrefslogtreecommitdiffstats
path: root/deploy/adapters
diff options
context:
space:
mode:
Diffstat (limited to 'deploy/adapters')
-rw-r--r--deploy/adapters/ansible/openstack/templates/nova.conf5
-rw-r--r--deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf5
-rw-r--r--deploy/adapters/ansible/roles/heat/templates/heat.j25
-rw-r--r--deploy/adapters/ansible/roles/setup-network/files/setup_networks/setup_networks.py9
-rw-r--r--deploy/adapters/cobbler/snippets/kickstart_post_install_network_config7
-rw-r--r--deploy/adapters/cobbler/snippets/preseed_post_install_network_config16
-rw-r--r--deploy/adapters/cobbler/snippets/preseed_software_ansible2
7 files changed, 20 insertions, 29 deletions
diff --git a/deploy/adapters/ansible/openstack/templates/nova.conf b/deploy/adapters/ansible/openstack/templates/nova.conf
index 3cd2c03b..eb7ec053 100644
--- a/deploy/adapters/ansible/openstack/templates/nova.conf
+++ b/deploy/adapters/ansible/openstack/templates/nova.conf
@@ -3,11 +3,6 @@
{% set _ = memcached_servers.append('%s:11211'% host) %}
{% endfor %}
{% set memcached_servers = memcached_servers|join(',') %}
-{% if ansible_processor_vcpus > 10 %}
-{% set api_workers = ansible_processor_vcpus // 10 %}
-{% else %}
-{% set api_workers = 1 %}
-{% endif %}
[DEFAULT]
dhcpbridge_flagfile=/etc/nova/nova.conf
diff --git a/deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf b/deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf
index 8b035653..4ad2da2e 100644
--- a/deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf
+++ b/deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf
@@ -3,11 +3,6 @@
{% set _ = memcached_servers.append('%s:11211'% host) %}
{% endfor %}
{% set memcached_servers = memcached_servers|join(',') %}
-{% if ansible_processor_vcpus > 5 %}
-{% set api_workers = ansible_processor_vcpus // 5 %}
-{% else %}
-{% set api_workers = 1 %}
-{% endif %}
[DEFAULT]
rootwrap_config = /etc/cinder/rootwrap.conf
diff --git a/deploy/adapters/ansible/roles/heat/templates/heat.j2 b/deploy/adapters/ansible/roles/heat/templates/heat.j2
index d73bd70b..a8feb940 100644
--- a/deploy/adapters/ansible/roles/heat/templates/heat.j2
+++ b/deploy/adapters/ansible/roles/heat/templates/heat.j2
@@ -3,11 +3,6 @@
{% set _ = memcached_servers.append('%s:11211'% host) %}
{% endfor %}
{% set memcached_servers = memcached_servers|join(',') %}
-{% if ansible_processor_vcpus > 5 %}
-{% set api_workers = ansible_processor_vcpus // 5 %}
-{% else %}
-{% set api_workers = 1 %}
-{% endif %}
[DEFAULT]
heat_metadata_server_url = http://{{ internal_vip.ip }}:8000
diff --git a/deploy/adapters/ansible/roles/setup-network/files/setup_networks/setup_networks.py b/deploy/adapters/ansible/roles/setup-network/files/setup_networks/setup_networks.py
index ab13e088..64c0469e 100644
--- a/deploy/adapters/ansible/roles/setup-network/files/setup_networks/setup_networks.py
+++ b/deploy/adapters/ansible/roles/setup-network/files/setup_networks/setup_networks.py
@@ -10,6 +10,8 @@
import yaml
import netaddr
import os
+import platform
+import re
import log as logging
LOG = logging.getLogger("net-init")
@@ -88,6 +90,11 @@ def main(config):
setup_ips(config["ip_settings"], config["sys_intf_mappings"])
if __name__ == "__main__":
- os.system("service openvswitch-switch status|| service openvswitch-switch start") # noqa
+ if re.search('Ubuntu', platform.platform()):
+ os.system("service openvswitch-switch start")
+ elif re.search('redhat|centos', platform.platform()):
+ os.system("service openvswitch start")
+ else:
+ os.system("echo 'ERROR: no service named openvswitch'")
config = yaml.load(open(config_path))
main(config)
diff --git a/deploy/adapters/cobbler/snippets/kickstart_post_install_network_config b/deploy/adapters/cobbler/snippets/kickstart_post_install_network_config
index 2c089f92..1a5a7f66 100644
--- a/deploy/adapters/cobbler/snippets/kickstart_post_install_network_config
+++ b/deploy/adapters/cobbler/snippets/kickstart_post_install_network_config
@@ -426,9 +426,12 @@ declare -A used_logical_interfaces
used_logical_interfaces[$iname]=$iname
- #if $iface_type in ("slave","bond_slave","bridge_slave","bonded_bridge_slave")
+ #if $iface_type in ("slave","bridge_slave","bonded_bridge_slave")
#set $static = 1
#end if
+ #if $ip == ""
+ #set $static = ""
+ #end if
echo "DEVICE=$iname" > $devfile
echo "ONBOOT=yes" >> $devfile
@@ -514,7 +517,7 @@ echo "GATEWAY=$if_gateway" >> $devfile
echo "NETMASK=$netmask" >> $devfile
#end if
#else
-echo "BOOTPROTO=dhcp" >> $devfile
+echo "BOOTPROTO=manual" >> $devfile
#if $len($name_servers) > 0
echo "PEERDNS=no" >> $devfile
#end if
diff --git a/deploy/adapters/cobbler/snippets/preseed_post_install_network_config b/deploy/adapters/cobbler/snippets/preseed_post_install_network_config
index cb79c556..f15b6be2 100644
--- a/deploy/adapters/cobbler/snippets/preseed_post_install_network_config
+++ b/deploy/adapters/cobbler/snippets/preseed_post_install_network_config
@@ -50,14 +50,7 @@ echo "physical interfaces: \${physical_interfaces}" >> /tmp/network_log
# map physical interface to mac address
mac_names=""
for physical_interface in \${physical_interfaces}; do
- set \$(ip link show \${physical_interface})
-#if $osversion == "trusty"
- mac=\$(echo \$@ | cut -d' ' -f17)
-#elif $osversion == "xenial"
- mac=\$(echo \$@ | cut -d' ' -f17)
-#else
- mac=\$(echo \$@ | cut -d' ' -f13)
-#end if
+ mac=\$(ip link show \${physical_interface} | awk 'match(\$0,/link\/ether/) {print \$2}')
mac_name=\$(echo \${mac} |tr 'a-z' 'A-Z' | tr ':' '_')
if [ -z "\${mac_name}" ]; then
mac_names="\${mac_name}"
@@ -441,15 +434,18 @@ echo "" >> /etc/network/interfaces
used_logical_interface_$iname=$iname
- #if $iface_type in ("slave","bond_slave","bridge_slave","bonded_bridge_slave")
+ #if $iface_type in ("slave","bridge_slave","bonded_bridge_slave")
#set $static = 1
#end if
+ #if $ip == ""
+ #set $static = ""
+ #end if
echo "auto $iname" >> /etc/network/interfaces
#if $static
echo "iface $iname inet static" >> /etc/network/interfaces
#else
-echo "iface $iname inet dhcp" >> /etc/network/interfaces
+echo "iface $iname inet manual" >> /etc/network/interfaces
#end if
#if $iface_type not in ("master","bond","bridge","bonded_bridge_slave")
diff --git a/deploy/adapters/cobbler/snippets/preseed_software_ansible b/deploy/adapters/cobbler/snippets/preseed_software_ansible
index cde79356..5516c893 100644
--- a/deploy/adapters/cobbler/snippets/preseed_software_ansible
+++ b/deploy/adapters/cobbler/snippets/preseed_software_ansible
@@ -1 +1 @@
-d-i pkgsel/include string ntp ssh openssh-server wget vim
+d-i pkgsel/include string ntp ssh openssh-server wget vim ifenslave