0c75e2dac372685861db305bf9311244ed4faa78
[sdc/sdc-distribution-client.git] /
1 tosca_definitions_version: tosca_simple_yaml_1_0
2
3 description: >
4   Service template with topology_template, act as a nested system inside another system.
5
6 imports:
7   - definitions.yaml
8
9 topology_template:
10   description: Template of a database including its hosting stack.
11
12   inputs:
13     mq_server_ip:
14       type: string
15       description: IP address of the message queuing server to receive messages from.
16     receiver_port:
17       type: string
18       description: Port to be used for receiving messages.
19     my_cpus:
20       type: integer
21       description: Number of CPUs for the server.
22       constraints:
23         - valid_values: [ 1, 2, 4, 8 ]
24
25   node_templates:
26     websrv:
27       type: tosca.nodes.WebServer
28       capabilities:
29         data_endpoint:
30           properties:
31             port_name: { get_input: receiver_port }
32       requirements:
33         - host:
34             node: server
35
36     server:
37       type: tosca.nodes.Compute
38       capabilities:
39         host:
40           properties:
41             disk_size: 10 GB
42             num_cpus: { get_input: my_cpus }
43             mem_size: 4096 MB
44         os:
45           properties:
46             architecture: x86_64
47             type: Linux
48             distribution: Ubuntu
49             version: 14.04
50
51   groups:
52     webserver_group:
53       type: mycompany.mytypes.groups.placement
54       description: bla bla bla
55       members: [ websrv, server ]