summaryrefslogtreecommitdiffstats
path: root/prototypes
diff options
context:
space:
mode:
Diffstat (limited to 'prototypes')
-rwxr-xr-xprototypes/bifrost/scripts/osa-bifrost-deployment.sh6
-rw-r--r--prototypes/openstack-ansible/playbooks/configure-xcimaster.yml17
-rw-r--r--prototypes/openstack-ansible/var/ubuntu.yml2
3 files changed, 16 insertions, 9 deletions
diff --git a/prototypes/bifrost/scripts/osa-bifrost-deployment.sh b/prototypes/bifrost/scripts/osa-bifrost-deployment.sh
index 33ad10887..fb66ae9e3 100755
--- a/prototypes/bifrost/scripts/osa-bifrost-deployment.sh
+++ b/prototypes/bifrost/scripts/osa-bifrost-deployment.sh
@@ -20,11 +20,9 @@ USE_VENV="false"
BUILD_IMAGE=true
PROVISION_WAIT_TIMEOUT=${PROVISION_WAIT_TIMEOUT:-3600}
-# ensure the branch is set
-export OPENSTACK_BRANCH=${OPENSTACK_BRANCH:-master}
-
# ensure the right inventory files is used based on branch
-if [ $OPENSTACK_BRANCH = "master" ]; then
+CURRENT_BIFROST_BRANCH=$(git rev-parse --abbrev-ref HEAD)
+if [ $CURRENT_BIFROST_BRANCH = "master" ]; then
export BIFROST_INVENTORY_SOURCE=${BIFROST_INVENTORY_SOURCE:-'/tmp/baremetal.json'}
else
export BIFROST_INVENTORY_SOURCE=${BIFROST_INVENTORY_SOURCE:-'/tmp/baremetal.csv'}
diff --git a/prototypes/openstack-ansible/playbooks/configure-xcimaster.yml b/prototypes/openstack-ansible/playbooks/configure-xcimaster.yml
index b6c79a418..fbbde640c 100644
--- a/prototypes/openstack-ansible/playbooks/configure-xcimaster.yml
+++ b/prototypes/openstack-ansible/playbooks/configure-xcimaster.yml
@@ -10,10 +10,19 @@
creates: /root/.ssh/id_rsa
- name: fetch public key
fetch: src="/root/.ssh/id_rsa.pub" dest="/"
- - name: remove the directory
- shell: "rm -rf {{OSA_PATH}} {{OSA_ETC_PATH}}"
- - name: git openstack ansible
- shell: "git clone {{OSA_URL}} {{OSA_PATH}} -b {{OPENSTACK_BRANCH}}"
+ - name: remove openstack-ansible directories
+ file:
+ path={{ item }}
+ state=absent
+ recurse=no
+ with_items:
+ - "{{OSA_PATH}}"
+ - "{{OSA_ETC_PATH}}"
+ - name: clone openstack-ansible
+ git:
+ repo: "{{OSA_URL}}"
+ dest: "{{OSA_PATH}}"
+ version: "{{OPENSTACK_OSA_VERSION}}"
- name: copy opnfv-setup-openstack.yml to /opt/openstack-ansible/playbooks
copy:
src: ../file/opnfv-setup-openstack.yml
diff --git a/prototypes/openstack-ansible/var/ubuntu.yml b/prototypes/openstack-ansible/var/ubuntu.yml
index 321a7c4e5..eb595beaa 100644
--- a/prototypes/openstack-ansible/var/ubuntu.yml
+++ b/prototypes/openstack-ansible/var/ubuntu.yml
@@ -2,7 +2,7 @@
OSA_URL: https://git.openstack.org/openstack/openstack-ansible
OSA_PATH: /opt/openstack-ansible
OSA_ETC_PATH: /etc/openstack_deploy
-OPENSTACK_BRANCH: "{{ lookup('env','OPENSTACK_BRANCH') }}"
+OPENSTACK_OSA_VERSION: "{{ lookup('env','OPENSTACK_OSA_VERSION') }}"
XCIMASTER_IP: 192.168.122.2
host_info: {'xcimaster':{'MGMT_IP': '172.29.236.10','VLAN_IP': '192.168.122.2', 'STORAGE_IP': '172.29.244.10'},'controller00':{'MGMT_IP': '172.29.236.11','VLAN_IP': '192.168.122.3', 'STORAGE_IP': '172.29.244.11'},'controller01':{'MGMT_IP': '172.29.236.12','VLAN_IP': '192.168.122.4', 'STORAGE_IP': '172.29.244.12'},'controller02':{'MGMT_IP': '172.29.236.13','VLAN_IP': '192.168.122.5', 'STORAGE_IP': '172.29.240.13'},'compute00':{'MGMT_IP': '172.29.236.14','VLAN_IP': '192.168.122.6','VLAN_IP_SECOND': '173.29.241.1','VXLAN_IP': '172.29.240.14', 'STORAGE_IP': '172.29.244.14'},'compute01':{'MGMT_IP': '172.29.236.15','VLAN_IP': '192.168.122.7','VLAN_IP_SECOND': '173.29.241.2','VXLAN_IP': '172.29.240.15', 'STORAGE_IP': '172.29.244.15'}}