diff options
author | carey.xu <carey.xuhan@huawei.com> | 2015-11-26 18:00:55 +0800 |
---|---|---|
committer | carey.xu <carey.xuhan@huawei.com> | 2015-12-01 07:29:39 +0800 |
commit | e93d595baf9b3fbbc0ec213ad725ce438772d8a4 (patch) | |
tree | e9e2a5e6a3e5abc4cd9a44228e47796c5e86fc4b /deploy | |
parent | a5d9a6384c09ff8e84c7e6bfefb9b9202b0c2341 (diff) |
support libverty on ubuntu
JIRA: COMPASS-169
Change-Id: I4656cf43eb3db0ba61fae4b03416b9c0239bb50b
Signed-off-by: carey.xu <carey.xuhan@huawei.com>
Diffstat (limited to 'deploy')
-rw-r--r-- | deploy/adapters/ansible/openstack_liberty/.gitkeep | 0 | ||||
-rw-r--r-- | deploy/adapters/ansible/roles/common/vars/Debian.yml | 2 | ||||
-rw-r--r-- | deploy/adapters/ansible/roles/ha/templates/keepalived.conf | 6 | ||||
-rw-r--r-- | deploy/conf/cluster.conf | 6 | ||||
-rwxr-xr-x | deploy/prepare.sh | 2 | ||||
-rwxr-xr-x | deploy/qemu_hook.sh | 10 |
6 files changed, 20 insertions, 6 deletions
diff --git a/deploy/adapters/ansible/openstack_liberty/.gitkeep b/deploy/adapters/ansible/openstack_liberty/.gitkeep new file mode 100644 index 00000000..e69de29b --- /dev/null +++ b/deploy/adapters/ansible/openstack_liberty/.gitkeep diff --git a/deploy/adapters/ansible/roles/common/vars/Debian.yml b/deploy/adapters/ansible/roles/common/vars/Debian.yml index bc273a10..8dce2729 100644 --- a/deploy/adapters/ansible/roles/common/vars/Debian.yml +++ b/deploy/adapters/ansible/roles/common/vars/Debian.yml @@ -1,7 +1,7 @@ --- packages: - ubuntu-cloud-keyring - - python-dev + #- python-dev - openvswitch-datapath-dkms - openvswitch-switch - crudini diff --git a/deploy/adapters/ansible/roles/ha/templates/keepalived.conf b/deploy/adapters/ansible/roles/ha/templates/keepalived.conf index d6f424cd..c2af86b0 100644 --- a/deploy/adapters/ansible/roles/ha/templates/keepalived.conf +++ b/deploy/adapters/ansible/roles/ha/templates/keepalived.conf @@ -14,9 +14,8 @@ vrrp_instance internal_vip { virtual_router_id {{ vrouter_id_internal }} state BACKUP nopreempt - preempt_delay 30 advert_int 1 - priority 100 + priority {{ 50 + (host_index[inventory_hostname] * 50) }} authentication { auth_type PASS @@ -33,9 +32,8 @@ vrrp_instance public_vip { virtual_router_id {{ vrouter_id_public }} state BACKUP nopreempt - preempt_delay 30 advert_int 1 - priority 100 + priority {{ 50 + (host_index[inventory_hostname] * 50) }} authentication { auth_type PASS diff --git a/deploy/conf/cluster.conf b/deploy/conf/cluster.conf index 39e6d467..200fae65 100644 --- a/deploy/conf/cluster.conf +++ b/deploy/conf/cluster.conf @@ -1,8 +1,12 @@ export ADAPTER_OS_PATTERN=${ADAPTER_OS_PATTERN:-'(?i)ubuntu-14\.04\.3.*'} +export ADAPTER_TARGET_SYSTEM_PATTERN="^openstack$" + export REPO_NAME=${REPO_NAME:-"trusty-juno-ppa"} export ADAPTER_NAME="openstack_juno" -export ADAPTER_TARGET_SYSTEM_PATTERN="^openstack$" export ADAPTER_FLAVOR_PATTERN="HA-ansible-multinodes-juno" +#export REPO_NAME=${REPO_NAME:-"trusty-liberty-ppa"} +#export ADAPTER_NAME="openstack_liberty" +#export ADAPTER_FLAVOR_PATTERN="HA-ansible-multinodes-liberty" #export ADAPTER_OS_PATTERN=${ADAPTER_OS_PATTERN:-'(?i)CentOS-7.*1503-01.*'} #export REPO_NAME=${REPO_NAME:-"centos7-kilo-ppa"} diff --git a/deploy/prepare.sh b/deploy/prepare.sh index 8a9ecef0..ce8b7aca 100755 --- a/deploy/prepare.sh +++ b/deploy/prepare.sh @@ -52,4 +52,6 @@ function prepare_env() { chmod 755 $WORK_DIR -R virtualenv $WORK_DIR/venv + + sudo cp ${COMPASS_DIR}/deploy/qemu_hook.sh /etc/libvirt/hooks/qemu } diff --git a/deploy/qemu_hook.sh b/deploy/qemu_hook.sh new file mode 100755 index 00000000..9c6ff6cf --- /dev/null +++ b/deploy/qemu_hook.sh @@ -0,0 +1,10 @@ +#!/bin/bash +if [ "$2" == "started" ]; then + timestamp=$(date +"%Y-%m-%d %H:%M:%S") + exists=$(ifconfig | grep macvtap|awk '{print $1}') + + for i in $exists; do + ifconfig $i allmulti + echo "$timestamp ALLMULTI set on $i" >> /var/log/libvirt_hook_qemu.log + done +fi |