[CORD-2310] Getting the local scenario to work
Change-Id: Ieacb79d90145447054ac5e8f14778d78ad79913d
(cherry picked from commit 7831f803de6a02a5fbfc00c48ef6c822abd9495d)
diff --git a/profile_manifests/base-cord.yml b/profile_manifests/base-cord.yml
index c0dcf77..06ee30f 100644
--- a/profile_manifests/base-cord.yml
+++ b/profile_manifests/base-cord.yml
@@ -35,6 +35,7 @@
- management-net.yaml
- addressmanager-service.yaml
- public-net.yaml
+ - xos-gui-extensions.yml
# An example of adding TOSCA for a service using the new engine.
#xos_new_tosca_config_templates:
@@ -43,6 +44,23 @@
xos_other_templates:
- fabric-network-cfg.json
+enabled_gui_extensions:
+ - name: sample
+ path: orchestration/xos-sample-gui-extension
+ - name: rcord
+ path: orchestration/profiles/rcord/xos/gui
+ extra_files:
+ - index.css
+ - name: veestat
+ path: orchestration/xos_services/vEE/xos/veestat
+ - name: vnaas
+ path: orchestration/xos_services/vnaas/xos/gui
+ extra_files:
+ - app/style/style.css
+ - mapconstants.js
+ - name: vtr
+ path: orchestration/xos_services/vtr/xos/gui
+
# paths defined in manifest/default.xml
xos_services:
- name: vtn
diff --git a/roles/cord-profile/templates/xos-tosca.config.yaml.j2 b/roles/cord-profile/templates/xos-tosca.config.yaml.j2
index 671200a..c5001bc 100644
--- a/roles/cord-profile/templates/xos-tosca.config.yaml.j2
+++ b/roles/cord-profile/templates/xos-tosca.config.yaml.j2
@@ -17,7 +17,7 @@
name: xos-tosca
-gprc_endpoint: "xos-core.{{ site_suffix }}"
+gprc_endpoint: "xos-core"
local_cert: /usr/local/share/ca-certificates/local_certs.crt
logging:
version: 1
diff --git a/roles/test-exampleservice/defaults/main.yml b/roles/test-exampleservice/defaults/main.yml
index 7e9c125..8079f10 100644
--- a/roles/test-exampleservice/defaults/main.yml
+++ b/roles/test-exampleservice/defaults/main.yml
@@ -19,7 +19,7 @@
xos_ui_port: 9000
-xos_tosca_host: "xos-tosca"
+xos_tosca_url: "http://xos-tosca/xos-tosca"
head_credentials_dir: "/opt/credentials"
diff --git a/roles/test-exampleservice/tasks/main.yml b/roles/test-exampleservice/tasks/main.yml
index c5bc324..64f03d9 100644
--- a/roles/test-exampleservice/tasks/main.yml
+++ b/roles/test-exampleservice/tasks/main.yml
@@ -20,7 +20,7 @@
- name: Configure XOS with profile specific TOSCA (new Engine)
uri:
- url: "http://{{ xos_tosca_host }}/xos-tosca/run"
+ url: "{{ xos_tosca_url }}/run"
method: POST
headers:
xos-username: "{{ xos_admin_user }}"
diff --git a/roles/xos-config-new-tosca/defaults/main.yml b/roles/xos-config-new-tosca/defaults/main.yml
index c0f3674..8316fe7 100644
--- a/roles/xos-config-new-tosca/defaults/main.yml
+++ b/roles/xos-config-new-tosca/defaults/main.yml
@@ -15,12 +15,14 @@
# xos-config/defaults/main.yml
-xos_tosca_host: "xos-tosca"
+xos_tosca_url: "http://xos-tosca/xos-tosca"
-head_credentials_dir: "/opt/credentials"
+credentials_dir: "{{ playbook_dir }}/credentials"
+
+head_cord_profile_dir: "/opt/cord_profile"
xos_admin_user: "xosadmin@opencord.org"
-xos_admin_pass: "{{ lookup('password', head_credentials_dir ~ '/xosadmin@opencord.org chars=ascii_letters,digits') }}"
+xos_admin_pass: "{{ lookup('password', credentials_dir ~ '/xosadmin@opencord.org chars=ascii_letters,digits') }}"
xos_tosca_config_templates: []
diff --git a/roles/xos-config-new-tosca/tasks/main.yml b/roles/xos-config-new-tosca/tasks/main.yml
index f254445..683bc59 100644
--- a/roles/xos-config-new-tosca/tasks/main.yml
+++ b/roles/xos-config-new-tosca/tasks/main.yml
@@ -17,12 +17,12 @@
- name: Configure XOS with profile specific TOSCA (new Engine)
uri:
- url: "http://{{ xos_tosca_host }}/xos-tosca/run"
+ url: "{{ xos_tosca_url }}/run"
method: POST
headers:
xos-username: "{{ xos_admin_user }}"
xos-password: "{{ xos_admin_pass }}"
- body: "{{ lookup('file','/opt/cord_profile/' + item ) }}"
+ body: "{{ lookup('file', head_cord_profile_dir + '/' + item ) }}"
status_code: 200
with_items: "{{ xos_new_tosca_config_templates }}"
tags: