XOS/NEM charts, use a global registry var, split docker image name/tag/pullPolicy

Change-Id: I7f3457882830de050d1357254fc5483faf91d03f
diff --git a/xos-profiles/demo-exampleservice/Chart.yaml b/xos-profiles/demo-exampleservice/Chart.yaml
index 926af58..2e6dec1 100644
--- a/xos-profiles/demo-exampleservice/Chart.yaml
+++ b/xos-profiles/demo-exampleservice/Chart.yaml
@@ -1,5 +1,4 @@
 ---
-
 # Copyright 2018-present Open Networking Foundation
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
@@ -14,8 +13,12 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-apiVersion: v1
-appVersion: "1.0"
-description: A Helm chart that launches and configures ExampleService. It's assumed that base-kubernetes profile is installed.
 name: demo-exampleservice
-version: 0.1.0
+description: A Helm chart that launches and configures ExampleService. It's assumed that base-kubernetes profile is installed.
+icon: https://guide.opencord.org/logos/cord.svg
+
+version: 1.0.0
+
+# xosproject/tosca-loader version
+appVersion: 1.1.3
+
diff --git a/xos-profiles/demo-exampleservice/requirements.yaml b/xos-profiles/demo-exampleservice/requirements.yaml
index 4da802b..d27a2ef 100644
--- a/xos-profiles/demo-exampleservice/requirements.yaml
+++ b/xos-profiles/demo-exampleservice/requirements.yaml
@@ -15,8 +15,8 @@
 
 dependencies:
 - name: exampleservice
-  version: 2.1.0
+  version: 2.1.2
   repository: file://../../xos-services/exampleservice
 - name: addressmanager
-  version: 2.0.0
+  version: 2.0.1
   repository: file://../../xos-services/addressmanager
diff --git a/xos-profiles/demo-exampleservice/templates/tosca-job.yaml b/xos-profiles/demo-exampleservice/templates/tosca-job.yaml
index 0bba3f6..53cce60 100644
--- a/xos-profiles/demo-exampleservice/templates/tosca-job.yaml
+++ b/xos-profiles/demo-exampleservice/templates/tosca-job.yaml
@@ -35,8 +35,8 @@
       restartPolicy: OnFailure
       containers:
         - name: {{ .Chart.Name }}-tosca-loader
-          image: {{ tpl .Values.tosca_loaderImage . | quote }}
-          imagePullPolicy: {{ .Values.imagePullPolicy }}
+          image: {{ .Values.global.registry }}{{ .Values.image.repository }}:{{ tpl .Values.image.tag . }}
+          imagePullPolicy: {{ .Values.image.pullPolicy }}
           env:
             - name: XOS_USER
               value: {{ .Values.xosAdminUser }}
diff --git a/xos-profiles/demo-exampleservice/values.yaml b/xos-profiles/demo-exampleservice/values.yaml
index e621e99..496a20f 100644
--- a/xos-profiles/demo-exampleservice/values.yaml
+++ b/xos-profiles/demo-exampleservice/values.yaml
@@ -13,7 +13,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-# Default values for the base-openstack profile.
+# Default values for the demo-exampleservice profile.
 # This is a YAML-formatted file.
 # Declare variables to be passed into your templates.
 
@@ -22,9 +22,10 @@
 nameOverride: ""
 fullnameOverride: ""
 
-imagePullPolicy: 'IfNotPresent'
-
-tosca_loaderImage: "xosproject/tosca-loader:1.0.1"
+image:
+  repository: 'xosproject/tosca-loader'
+  tag: '{{ .Chart.AppVersion }}'
+  pullPolicy: 'Always'
 
 xosAdminUser: "admin@opencord.org"
 xosAdminPassword: "letmein"
@@ -39,3 +40,4 @@
 global:
   proxySshEnabled: true
   proxySshUser: root
+  registry: ''