aboutsummaryrefslogtreecommitdiffstats
path: root/heat/vFW_CNF_CDS/templates/cba/Definitions/vFW_CNF_CDS.json
diff options
context:
space:
mode:
authorLukasz Rajewski <lukasz.rajewski@orange.com>2021-03-24 19:15:31 +0100
committerLukasz Rajewski <lukasz.rajewski@orange.com>2021-03-28 22:21:25 +0200
commit06bf0ac45889ffe00fc6e27e68ffa15c2f519e6f (patch)
treeecf4c17542c62ee6c0433edcbccac5707370a8f1 /heat/vFW_CNF_CDS/templates/cba/Definitions/vFW_CNF_CDS.json
parentd2c5f361fa3a246dfa23c2c582ec498322a97282 (diff)
Real vFW CNF config-assign and config-deploy
Implementation of vFW CNF config-assign and config-deploy with utilization of CDS native components for configuration API Change-Id: I016b186e1fcad0bf1285292f2e93e12a1d96b63e Issue-ID: INT-1868 Signed-off-by: Lukasz Rajewski <lukasz.rajewski@orange.com>
Diffstat (limited to 'heat/vFW_CNF_CDS/templates/cba/Definitions/vFW_CNF_CDS.json')
-rw-r--r--heat/vFW_CNF_CDS/templates/cba/Definitions/vFW_CNF_CDS.json86
1 files changed, 83 insertions, 3 deletions
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": {}
+ }
+ }
+ }
+ }
}
}
}