Marco Platania | b9e219f | 2019-06-16 16:09:20 -0400 | [diff] [blame] | 1 | # |
| 2 | # ============LICENSE_START==================================================== |
| 3 | # ============================================================================= |
| 4 | # Copyright (c) 2019 AT&T Intellectual Property. All rights reserved. |
| 5 | # ============================================================================= |
| 6 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 7 | # you may not use this file except in compliance with the License. |
| 8 | # You may obtain a copy of the License at |
| 9 | # |
| 10 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 11 | # |
| 12 | # Unless required by applicable law or agreed to in writing, software |
| 13 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 15 | # See the License for the specific language governing permissions and |
| 16 | # limitations under the License. |
| 17 | # ============LICENSE_END====================================================== |
| 18 | |
| 19 | tosca_definitions_version: cloudify_dsl_1_3 |
| 20 | |
| 21 | description: > |
| 22 | This blueprint deploys/manages the TCA module as a Docker container |
| 23 | |
| 24 | imports: |
| 25 | - http://www.getcloudify.org/spec/cloudify/3.4/types.yaml |
| 26 | - https://nexus.onap.org/service/local/repositories/raw/content/org.onap.dcaegen2.platform.plugins/R4/k8splugin/1.4.13/k8splugin_types.yaml |
| 27 | # - https://nexus.onap.org/service/local/repositories/raw/content/org.onap.dcaegen2.platform.plugins/R4/dcaepolicyplugin/2.3.0/dcaepolicyplugin_types.yaml |
| 28 | - https://nexus.onap.org/service/local/repositories/raw/content/org.onap.dcaegen2.platform.plugins/R4/clamppolicyplugin/1.0.0/clamppolicyplugin_types.yaml |
| 29 | inputs: |
| 30 | aaiEnrichmentHost: |
| 31 | type: string |
| 32 | default: "aai.onap.svc.cluster.local" |
| 33 | aaiEnrichmentPort: |
| 34 | type: string |
| 35 | default: "8443" |
| 36 | enableAAIEnrichment: |
| 37 | type: string |
| 38 | default: true |
| 39 | dmaap_host: |
| 40 | type: string |
| 41 | default: message-router.onap |
| 42 | dmaap_port: |
| 43 | type: string |
| 44 | default: "3904" |
| 45 | enableRedisCaching: |
| 46 | type: string |
| 47 | default: false |
| 48 | redisHosts: |
| 49 | type: string |
| 50 | default: dcae-redis.onap.svc.cluster.local:6379 |
| 51 | tag_version: |
| 52 | type: string |
| 53 | default: "nexus3.onap.org:10001/onap/org.onap.dcaegen2.deployments.tca-cdap-container:1.1.1" |
| 54 | consul_host: |
| 55 | type: string |
| 56 | default: consul-server.onap |
| 57 | consul_port: |
| 58 | type: string |
| 59 | default: "8500" |
| 60 | cbs_host: |
| 61 | type: string |
| 62 | default: "config-binding-service" |
| 63 | cbs_port: |
| 64 | type: string |
| 65 | default: "10000" |
| 66 | policy_id: |
| 67 | type: string |
| 68 | default: "onap.restart.tca" |
| 69 | external_port: |
| 70 | type: string |
| 71 | description: Kubernetes node port on which CDAPgui is exposed |
| 72 | default: "32012" |
| 73 | policy_model_id: |
| 74 | type: string |
| 75 | default: "onap.policies.monitoring.cdap.tca.hi.lo.app" |
| 76 | node_templates: |
| 77 | tca_k8s: |
| 78 | type: dcae.nodes.ContainerizedServiceComponent |
| 79 | relationships: |
| 80 | - target: tca_policy |
| 81 | type: cloudify.relationships.depends_on |
| 82 | properties: |
Bartek Grzybowski | 3161bfe | 2020-02-19 13:37:31 +0100 | [diff] [blame] | 83 | service_component_type: 'dcaegen2-analytics-tca' |
| 84 | docker_config: {} |
| 85 | image: |
| 86 | get_input: tag_version |
| 87 | log_info: |
| 88 | log_directory: "/opt/app/TCAnalytics/logs" |
| 89 | application_config: |
| 90 | app_config: |
| 91 | appDescription: DCAE Analytics Threshold Crossing Alert Application |
| 92 | appName: dcae-tca |
| 93 | tcaAlertsAbatementTableName: TCAAlertsAbatementTable |
| 94 | tcaAlertsAbatementTableTTLSeconds: '1728000' |
| 95 | tcaSubscriberOutputStreamName: TCASubscriberOutputStream |
| 96 | tcaVESAlertsTableName: TCAVESAlertsTable |
| 97 | tcaVESAlertsTableTTLSeconds: '1728000' |
| 98 | tcaVESMessageStatusTableName: TCAVESMessageStatusTable |
| 99 | tcaVESMessageStatusTableTTLSeconds: '86400' |
| 100 | thresholdCalculatorFlowletInstances: '2' |
| 101 | app_preferences: |
| 102 | aaiEnrichmentHost: |
| 103 | get_input: aaiEnrichmentHost |
| 104 | aaiEnrichmentIgnoreSSLCertificateErrors: 'true' |
| 105 | aaiEnrichmentPortNumber: '8443' |
| 106 | aaiEnrichmentProtocol: https |
| 107 | aaiEnrichmentUserName: dcae@dcae.onap.org |
| 108 | aaiEnrichmentUserPassword: demo123456! |
| 109 | aaiVMEnrichmentAPIPath: /aai/v11/search/nodes-query |
| 110 | aaiVNFEnrichmentAPIPath: /aai/v11/network/generic-vnfs/generic-vnf |
| 111 | enableAAIEnrichment: |
| 112 | get_input: enableAAIEnrichment |
| 113 | enableRedisCaching: |
| 114 | get_input: enableRedisCaching |
| 115 | redisHosts: |
| 116 | get_input: redisHosts |
| 117 | enableAlertCEFFormat: 'false' |
| 118 | publisherContentType: application/json |
| 119 | publisherHostName: |
| 120 | get_input: dmaap_host |
| 121 | publisherHostPort: |
| 122 | get_input: dmaap_port |
| 123 | publisherMaxBatchSize: '1' |
| 124 | publisherMaxRecoveryQueueSize: '100000' |
| 125 | publisherPollingInterval: '20000' |
| 126 | publisherProtocol: http |
| 127 | publisherTopicName: unauthenticated.DCAE_CL_OUTPUT |
| 128 | subscriberConsumerGroup: OpenDCAE-clamp |
| 129 | subscriberConsumerId: c12 |
| 130 | subscriberContentType: application/json |
| 131 | subscriberHostName: |
| 132 | get_input: dmaap_host |
| 133 | subscriberHostPort: |
| 134 | get_input: dmaap_port |
| 135 | subscriberMessageLimit: '-1' |
| 136 | subscriberPollingInterval: '30000' |
| 137 | subscriberProtocol: http |
| 138 | subscriberTimeoutMS: '-1' |
| 139 | subscriberTopicName: unauthenticated.VES_MEASUREMENT_OUTPUT |
| 140 | tca_policy: '' |
Marco Platania | b9e219f | 2019-06-16 16:09:20 -0400 | [diff] [blame] | 141 | service_component_type: dcaegen2-analytics_tca |
| 142 | interfaces: |
| 143 | cloudify.interfaces.lifecycle: |
| 144 | start: |
| 145 | inputs: |
| 146 | envs: |
Bartek Grzybowski | 3161bfe | 2020-02-19 13:37:31 +0100 | [diff] [blame] | 147 | MAAPHOST: |
| 148 | { get_input: dmaap_host } |
| 149 | DMAAPPORT: |
| 150 | { get_input: dmaap_port } |
| 151 | DMAAPPUBTOPIC: "unauthenticated.DCAE_CL_OUTPUT" |
| 152 | DMAAPSUBTOPIC: "unauthenticated.VES_MEASUREMENT_OUTPUT" |
| 153 | AAIHOST: |
| 154 | { get_input: aaiEnrichmentHost } |
| 155 | AAIPORT: |
| 156 | { get_input: aaiEnrichmentPort } |
| 157 | CONSUL_HOST: |
| 158 | { get_input: consul_host } |
| 159 | CONSUL_PORT: |
| 160 | { get_input: consul_port } |
| 161 | CBS_HOST: |
| 162 | { get_input: cbs_host } |
| 163 | CBS_PORT: |
| 164 | { get_input: cbs_port } |
| 165 | CONFIG_BINDING_SERVICE: "config_binding_service" |
Marco Platania | b9e219f | 2019-06-16 16:09:20 -0400 | [diff] [blame] | 166 | ports: |
| 167 | - concat: ["11011:", { get_input: external_port }] |
| 168 | tca_policy: |
| 169 | type: clamp.nodes.policy |
| 170 | properties: |
| 171 | policy_id: |
Bartek Grzybowski | 3161bfe | 2020-02-19 13:37:31 +0100 | [diff] [blame] | 172 | get_input: policy_id |
Bartek Grzybowski | 7d43e6c | 2020-02-19 09:55:02 +0100 | [diff] [blame] | 173 | policy_model_id: |
Bartek Grzybowski | 3161bfe | 2020-02-19 13:37:31 +0100 | [diff] [blame] | 174 | get_input: policy_model_id |