From 191324087c0fc0524f8566de8eeec3e35e34dcca Mon Sep 17 00:00:00 2001 From: wutianwei Date: Tue, 4 Jul 2017 17:46:39 +0800 Subject: fetch openrc for functest We use openstack-ansible to deploy the openstack, the position of openrc is different from the before. change the apt source when use local apt repository Change-Id: I1c5492b294a8645f452868c9cf2fec2e0802f823 Signed-off-by: wutianwei --- .../ansible/roles/post-openstack/tasks/main.yml | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'deploy/adapters/ansible/roles/post-openstack/tasks') diff --git a/deploy/adapters/ansible/roles/post-openstack/tasks/main.yml b/deploy/adapters/ansible/roles/post-openstack/tasks/main.yml index d5182c95..63df7260 100644 --- a/deploy/adapters/ansible/roles/post-openstack/tasks/main.yml +++ b/deploy/adapters/ansible/roles/post-openstack/tasks/main.yml @@ -21,3 +21,20 @@ shell: "export ANSIBLE_LOG_PATH=/var/ansible/run/openstack_ocata-opnfv2/ansible.log; \ cd /opt/openstack-ansible/playbooks; \ openstack-ansible http.yml > /dev/null" + +- name: run ansible yml to fetch openrc + shell: "export ANSIBLE_LOG_PATH=/var/ansible/run/openstack_ocata-opnfv2/ansible.log; \ + cd /opt/openstack-ansible/playbooks; \ + openstack-ansible fetch-openrc.yml > /dev/null" + +- name: replace internalURL with publicURL in openrc + replace: + dest: /opt/openrc + regexp: "{{internal_vip}}" + replace: "{{ public_vip['ip']}}" + +- name: change the endpoint type + replace: + dest: /opt/openrc + regexp: "internalURL" + replace: "publicURL" -- cgit 1.2.3-korg