Piotr Darosz | c2ac232 | 2019-03-07 13:04:52 +0100 | [diff] [blame] | 1 | tosca_definitions_version: cloudify_dsl_1_3 |
| 2 | |
| 3 | imports: |
| 4 | - http://www.getcloudify.org/spec/cloudify/3.4/types.yaml |
| 5 | - https://nexus.onap.org/service/local/repositories/raw/content/org.onap.dcaegen2.platform.plugins/R4/k8splugin/1.4.4/k8splugin_types.yaml |
| 6 | - https://nexus.onap.org/service/local/repositories/raw/content/org.onap.dcaegen2.platform.plugins/R4/dcaepolicyplugin/2.3.0/dcaepolicyplugin_types.yaml |
| 7 | inputs: |
| 8 | first_app_docker_image: |
| 9 | type: string |
| 10 | default: "image1" |
| 11 | second_app_docker_image: |
| 12 | type: string |
| 13 | default: "image2" |
| 14 | third_app_docker_image: |
| 15 | type: string |
| 16 | default: "image3" |
| 17 | dmaap_ip: |
| 18 | type: string |
| 19 | default: "message-router:3904" |
| 20 | dmaap_topic: |
| 21 | type: string |
| 22 | default: "/events/unauthenticated.DCAE_CL_OUTPUT" |
| 23 | policy_id: |
| 24 | type: string |
| 25 | default: "policy_id" |
| 26 | node_templates: |
| 27 | second_app: |
| 28 | type: dcae.nodes.ContainerizedServiceComponentUsingDmaap |
| 29 | properties: |
| 30 | service_component_type: dcaegen2-analytics-tca |
| 31 | service_component_name_override: second_app |
| 32 | image: { get_input: second_app_docker_image } |
xg353y | a6d09fb | 2019-03-28 10:05:25 +0100 | [diff] [blame] | 33 | policy_id: |
sebdet | 4545e77 | 2019-05-09 11:03:53 +0200 | [diff] [blame] | 34 | policy_model_id: "type2" |
Piotr Darosz | c2ac232 | 2019-03-07 13:04:52 +0100 | [diff] [blame] | 35 | interfaces: |
| 36 | cloudify.interfaces.lifecycle: |
| 37 | start: |
| 38 | inputs: |
| 39 | envs: |
| 40 | grpc_server.host: "first_app.onap" |
| 41 | dmaap_ip: {get_input: dmaap_ip} |
| 42 | dmapp_topic: {get_input: dmaap_topic} |
| 43 | policy_id: {get_input: policy_id} |
| 44 | ports: |
| 45 | - 8080:8080 |
| 46 | relationships: |
| 47 | - type: cloudify.relationships.connected_to |
| 48 | target: first_app |
| 49 | - type: clamp_node.relationships.gets_input_from |
| 50 | target: first_app |
| 51 | first_app: |
| 52 | type: dcae.nodes.ContainerizedPlatformComponent |
| 53 | properties: |
| 54 | name: first_app |
| 55 | dns_name: "first_app" |
| 56 | image: { get_input: first_app_docker_image } |
| 57 | container_port: 6565 |
xg353y | a6d09fb | 2019-03-28 10:05:25 +0100 | [diff] [blame] | 58 | policy_id: |
sebdet | 4545e77 | 2019-05-09 11:03:53 +0200 | [diff] [blame] | 59 | policy_model_id: "type1" |
Piotr Darosz | c2ac232 | 2019-03-07 13:04:52 +0100 | [diff] [blame] | 60 | interfaces: |
| 61 | cloudify.interfaces.lifecycle: |
| 62 | start: |
| 63 | inputs: |
| 64 | envs: |
| 65 | dmaap_ip: {get_input: dmaap_ip} |
| 66 | dmapp_topic: {get_input: dmaap_topic} |
| 67 | policy_id: {get_input: policy_id} |
| 68 | ports: |
| 69 | - 8081:8081 |
| 70 | relationships: |
| 71 | - type: cloudify.relationships.connected_to |
| 72 | target: third_app |
| 73 | - type: clamp_node.relationships.gets_input_from |
| 74 | target: third_app |
| 75 | |
| 76 | third_app: |
| 77 | type: dcae.nodes.ContainerizedPlatformComponent |
| 78 | properties: |
| 79 | name: third_app |
| 80 | dns_name: "third_app" |
| 81 | image: { get_input: third_app_docker_image } |
| 82 | container_port: 443 |
xg353y | a6d09fb | 2019-03-28 10:05:25 +0100 | [diff] [blame] | 83 | policy_id: |
sebdet | 4545e77 | 2019-05-09 11:03:53 +0200 | [diff] [blame] | 84 | policy_model_id: "type3" |
Piotr Darosz | c2ac232 | 2019-03-07 13:04:52 +0100 | [diff] [blame] | 85 | interfaces: |
| 86 | cloudify.interfaces.lifecycle: |
| 87 | start: |
| 88 | inputs: |
| 89 | envs: |
| 90 | dmaap_ip: {get_input: dmaap_ip} |
| 91 | dmapp_topic: {get_input: dmaap_topic} |
| 92 | policy_id: {get_input: policy_id} |
| 93 | ports: |
| 94 | - 8082:8082 |
| 95 | tca_policy: |
| 96 | type: dcae.nodes.policy |
| 97 | properties: |
| 98 | policy_id: { get_input: policy_id } |