Merge "updated k8s bp"
diff --git a/blueprints/inventory.yaml-template b/blueprints/inventory.yaml-template
index 4da253c..142eec8 100644
--- a/blueprints/inventory.yaml-template
+++ b/blueprints/inventory.yaml-template
@@ -38,21 +38,23 @@
 
   docker_host_override:
     description: Target docker host to deploy applications to
-  asdc_address:
+  sdc_address:
     description: SDC host
-  asdc_uri:
+  sdc_uri:
     description: SDC url
-  asdc_user:
+  sdc_msg_bus_address:
+    description: Message router hostname that SDC will send distribution events through
+  sdc_user:
     description: SDC username
-  asdc_password:
+  sdc_password:
     description: SDC password
-  asdc_environment_name:
+  sdc_environment_name:
     description: SDC environment name
-  asdc_use_secure_https:
+  sdc_use_secure_https:
     description: Boolean to toggle whether to do certificate validation for https calls to SDC API
     type: boolean
     default: false
-  asdc_use_https_dmaap:
+  sdc_use_https_dmaap:
     description: Boolean to toggle whether to use https for calls to message router API
     type: boolean
     default: false
@@ -76,19 +78,20 @@
         "service-change-handler"
       application_config:
         asdcDistributionClient:
-          asdcAddress: { get_input: asdc_address }
-          asdcUri: { get_input: asdc_uri }
-          user: { get_input: asdc_user }
-          password: { get_input: asdc_password }
+          asdcAddress: { get_input: sdc_address }
+          asdcUri: { get_input: sdc_uri }
+          msgBusAddress: { get_input: sdc_msg_bus_address }
+          user: { get_input: sdc_user }
+          password: { get_input: sdc_password }
           pollingInterval: 20
           pollingTimeout: 20
           consumerGroup: dcae
           consumerId: dcae-sch
-          environmentName: { get_input: asdc_environment_name }
+          environmentName: { get_input: sdc_environment_name }
           keyStorePath:
           keyStorePassword:
-          activateServerTLSAuth: { get_input: asdc_use_secure_https }
-          useHttpsWithDmaap: { get_input: asdc_use_https_dmaap }
+          activateServerTLSAuth: { get_input: sdc_use_secure_https }
+          useHttpsWithDmaap: { get_input: sdc_use_https_dmaap }
           isFilterInEmptyResources: false
         dcaeInventoryClient:
           uri: http://inventory:8080
@@ -129,13 +132,6 @@
           checkConnectionWhileIdle: false
           evictionInterval: 10s
           minIdleTime: 1 minute
-        dcaeControllerConnection:
-          host: dcae-controller-hostname
-          port: 9998
-          basePath: resources
-          user: 
-          password: 
-          required: false
         databusControllerConnection:
           host: databus-controller-hostname
           port: 8443
diff --git a/blueprints/k8s-deployment_handler.yaml-template b/blueprints/k8s-deployment_handler.yaml-template
index 3aae790..9d4c5b8 100644
--- a/blueprints/k8s-deployment_handler.yaml-template
+++ b/blueprints/k8s-deployment_handler.yaml-template
@@ -72,3 +72,13 @@
           version: 'v4'
         log_info:
           log_directory: '/opt/app/dh/log'
+    # Inject CM password through environment variable
+    # so that it does not appear in Consul
+    interfaces:
+      cloudify.interfaces.lifecycle:
+        start:
+          inputs:
+            envs:
+              CLOUDIFY_PASSWORD: { get_secret: cmpass }
+              CLOUDIFY_USER: admin
+
diff --git a/blueprints/k8s-inventory.yaml-template b/blueprints/k8s-inventory.yaml-template
index 663e7df..87c9053 100644
--- a/blueprints/k8s-inventory.yaml-template
+++ b/blueprints/k8s-inventory.yaml-template
@@ -32,21 +32,23 @@
 
 inputs:
 
-  asdc_address:
+  sdc_address:
     description: SDC host
-  asdc_uri:
+  sdc_uri:
     description: SDC url
-  asdc_user:
+  sdc_msg_bus_address:
+    description: Message router hostname that SDC will send distribution events through
+  sdc_user:
     description: SDC username
-  asdc_password:
+  sdc_password:
     description: SDC password
-  asdc_environment_name:
+  sdc_environment_name:
     description: SDC environment name
-  asdc_use_secure_https:
+  sdc_use_secure_https:
     description: Boolean to toggle whether to do certificate validation for https calls to SDC API
     type: boolean
     default: false
-  asdc_use_https_dmaap:
+  sdc_use_https_dmaap:
     description: Boolean to toggle whether to use https for calls to message router API
     type: boolean
     default: false
@@ -70,19 +72,20 @@
         "service-change-handler"
       application_config:
         asdcDistributionClient:
-          asdcAddress: { get_input: asdc_address }
-          asdcUri: { get_input: asdc_uri }
-          user: { get_input: asdc_user }
-          password: { get_input: asdc_password }
+          asdcAddress: { get_input: sdc_address }
+          asdcUri: { get_input: sdc_uri }
+          msgBusAddress: { get_input: sdc_msg_bus_address }
+          user: { get_input: sdc_user }
+          password: { get_input: sdc_password }
           pollingInterval: 20
           pollingTimeout: 20
           consumerGroup: dcae
           consumerId: dcae-sch
-          environmentName: { get_input: asdc_environment_name }
+          environmentName: { get_input: sdc_environment_name }
           keyStorePath:
           keyStorePassword:
-          activateServerTLSAuth: { get_input: asdc_use_secure_https }
-          useHttpsWithDmaap: { get_input: asdc_use_https_dmaap }
+          activateServerTLSAuth: { get_input: sdc_use_secure_https }
+          useHttpsWithDmaap: { get_input: sdc_use_https_dmaap }
           isFilterInEmptyResources: false
         dcaeInventoryClient:
           uri: http://inventory:8080
@@ -121,13 +124,6 @@
           checkConnectionWhileIdle: false
           evictionInterval: 10s
           minIdleTime: 1 minute
-        dcaeControllerConnection:
-          host: dcae-controller-hostname
-          port: 9998
-          basePath: resources
-          user: 
-          password: 
-          required: false
         databusControllerConnection:
           host: databus-controller-hostname
           port: 8443