X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;ds=sidebyside;f=heat%2FvFW_CNF_CDS%2Ftemplates%2Fcba%2FDefinitions%2FvFW_CNF_CDS.json;fp=heat%2FvFW_CNF_CDS%2Ftemplates%2Fcba%2FDefinitions%2FvFW_CNF_CDS.json;h=c17caca281ea1df83cda12b07e708bb3fb0a6082;hb=06bf0ac45889ffe00fc6e27e68ffa15c2f519e6f;hp=6c71ca22987021cde843a277c77936efa0bb7673;hpb=d2c5f361fa3a246dfa23c2c582ec498322a97282;p=demo.git diff --git a/heat/vFW_CNF_CDS/templates/cba/Definitions/vFW_CNF_CDS.json b/heat/vFW_CNF_CDS/templates/cba/Definitions/vFW_CNF_CDS.json index 6c71ca22..c17caca2 100644 --- a/heat/vFW_CNF_CDS/templates/cba/Definitions/vFW_CNF_CDS.json +++ b/heat/vFW_CNF_CDS/templates/cba/Definitions/vFW_CNF_CDS.json @@ -5,7 +5,7 @@ "author-email": "lukasz.rajewski@orange.com", "user-groups": "ADMIN, OPERATION", "template_name": "vFW_CNF_CDS", - "template_version": "7.0.0", + "template_version": "8.0.0", "template_tags": "Samuli Silvius, Lukasz Rajewski, vFW_CNF_CDS", "template_type": "DEFAULT" }, @@ -164,6 +164,9 @@ ], "on_success": [ "config-apply" + ], + "on_failure": [ + "handle_error" ] }, "config-apply": { @@ -185,7 +188,29 @@ { "call_operation": "ComponentScriptExecutor.process" } + ], + "on_success": [ + "collect-results" + ], + "on_failure": [ + "handle_error" + ] + }, + "handle_error": { + "description": "Simple error verification script", + "target": "simple-error-check", + "activities": [ + { + "call_operation": "ComponentScriptExecutor.process" + } + ], + "on_success": [ + "collect-results" ] + }, + "collect-results": { + "description": "Final collection of results", + "target": "collect-results" } }, "inputs": { @@ -322,11 +347,11 @@ }, "artifacts": { "ssh-service-config": { - "type": "artifact-k8sprofile-content", + "type": "artifact-k8sconfig-content", "file": "Templates/k8s-configs/ssh-service.tar.gz" }, "ssh-service-config-customizable": { - "type": "artifact-k8sprofile-content", + "type": "artifact-k8sconfig-content", "file": "Templates/k8s-configs/ssh-service-config" }, "ssh-service-config-customizable-mapping": { @@ -345,6 +370,7 @@ "artifact-prefix-names": [ "helm_vpkg" ], + "k8s-config-operation-type": "create", "resource-assignment-map": { "get_attribute": [ "config-setup-process", @@ -358,6 +384,20 @@ } } } + }, + "artifacts": { + "ssh-service-default": { + "type": "artifact-k8sconfig-content", + "file": "Templates/k8s-configs/ssh-service-config/values.yaml" + }, + "ssh-service-config": { + "type": "artifact-k8sconfig-content", + "file": "Templates/k8s-configs/ssh-service-values/values.yaml.vtl" + }, + "ssh-service-config-mapping": { + "type": "artifact-mapping-resource", + "file": "Templates/k8s-configs/ssh-service-values/ssh-service-mapping.json" + } } }, "simple-status-check": { @@ -379,6 +419,25 @@ } } }, + "simple-error-check": { + "type": "component-script-executor", + "interfaces": { + "ComponentScriptExecutor": { + "operations": { + "process": { + "inputs": { + "script-type": "kotlin", + "script-class-reference": "org.onap.ccsdk.cds.blueprintsprocessor.services.execution.scripts.SimpleErrorCheck", + "instance-dependencies": [ + "blueprintPropertiesService" + ], + "dynamic-properties": "*simple-status-properties" + } + } + } + } + } + }, "config-setup-process": { "type": "component-resource-resolution", "interfaces": { @@ -433,6 +492,27 @@ } } } + }, + "collect-results": { + "type": "component-script-executor", + "interfaces": { + "ComponentScriptExecutor": { + "operations": { + "process": { + "implementation": { + "primary": "component-script", + "timeout": 180, + "operation_host": "SELF" + }, + "inputs": { + "script-type": "kotlin", + "script-class-reference": "org.onap.ccsdk.cds.blueprintsprocessor.services.execution.scripts.CollectorScript" + }, + "outputs": {} + } + } + } + } } } }