aboutsummaryrefslogtreecommitdiffstats
path: root/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/fulltest/nestedSingleCompute/nestedNodesGetAttrIn/in/hot-nimbus-pcm_v0.4.yaml
blob: df4590810b9b3c661293e744b7daea1203999c33 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
heat_template_version: 2013-05-23

description: heat template that creates PCRF Cluman stack

parameters:
  pcm_server_names:
    type: comma_delimited_list
    label: PCRF CM server names
    description: name of the PCRF CM instance
  pcm_image_name:
    type: string
    label: PCRF CM image name
    description: PCRF CM image name
  pcm_flavor_name:
    type: string
    label: PCRF CM flavor name
    description: flavor name of PCRF CM instance
  oam_server_names:
    type: comma_delimited_list
    label: PCRF CM server names
    description: name of the PCRF CM instance
  oam_image_name:
    type: string
    label: PCRF CM image name
    description: PCRF CM image name
  oam_flavor_name:
    type: string
    label: PCRF CM flavor name
    description: flavor name of PCRF CM instance
  availabilityzone_name:
    type: string
    label: availabilityzone name
    description: availabilityzone name
  cps_net_name:
    type: string
    label: CPS network name
    description: CPS network name
  cps_net_ips:
    type: comma_delimited_list
    label: CPS network ips
    description: CPS network ips
  cps_net_mask:
    type: string
    label: CPS network mask
    description: CPS network mask
  oam_net_name:
    type: string
    label: OAM network name
    description: OAM network name
  oam_net_ips:
    type: comma_delimited_list
    label: OAM network ips
    description: OAM network ips
  oam_net_gw:
    type: string
    label: CPS network gateway
    description: CPS network gateway
  oam_net_mask:
    type: string
    label: CPS network mask
    description: CPS network mask
  pcm_volumes:
    type: comma_delimited_list
    label: CPS Cluman Cinder Volume
    description: CPS Cluman Cinder Volume
  security_group_name:
    type: string
    label: security group name
    description: the name of security group
  compute_image_name:
    type: string
  net_name:
    type: string

resources:
  server_compute:
    type: OS::Nova::Server
    properties:
      config_drive: {get_attr: [compute_port_0]}
      name: { compute_name }
      image: { get_param: compute_image_name }
      flavor: { compute_flavor_name }
      #get attribute from a nested resource
      user_data_format: { get_attr: [server_pcm_001 , oam_net_gw] }
      #get attribute from a regular consolidation entity resource
      metadata: { get_attr: [compute_port_0, device_id]}

  server_pcm_001:
    type: nested-pcm_v0.1.yaml
    properties:
      pcm_server_name: { get_param: [pcm_server_names, 0] }
      pcm_image_name: { get_param: pcm_image_name }
      pcm_flavor_name: { get_param: pcm_flavor_name }
      availabilityzone_name: { get_param: availabilityzone_name }
      security_group_name: { get_param: security_group_name }
      pcm_vol: { get_param: [pcm_volumes, 0] }
      cps_net_name: { get_param: cps_net_name }
      cps_net_ip: { get_param: [cps_net_ips, 0] }
      cps_net_mask: { get_param: cps_net_mask }
      oam_net_name: { get_param: oam_net_name }
      oam_net_ip: { get_param: [oam_net_ips, 0] }
      oam_net_mask: { get_param: oam_net_mask }
      oam_net_gw: { get_param: oam_net_gw }
      #get attribute from another nested resource of same type
      user_data_format: { get_attr: [server_pcm_002 , oam_net_gw] }
      #get attribute from another nested resource of different type
      key_name: { get_attr: [server_oam_001 , accessIPv4] }
      #get attribute from a regular consolidation entity resource
      metadata: { get_attr: [compute_port_0, device_id]}

  server_pcm_002:
    type: nested-pcm_v0.1.yaml
    properties:
      pcm_server_name: { get_param: [pcm_server_names, 0] }
      pcm_image_name: { get_param: pcm_image_name }
      pcm_flavor_name: { get_param: pcm_flavor_name }

  server_oam_001:
    type: nested-oam_v0.1.yaml
    properties:
      oam_server_name: { get_param: [oam_server_names, 0] }
      oam_image_name: { get_param: oam_image_name }
      oam_flavor_name: { get_param: oam_flavor_name }
      availabilityzone_name: { get_param: availabilityzone_name }
      security_group_name: { get_param: security_group_name }
      pcm_vol: { get_param: [pcm_volumes, 0] }
      cps_net_name: { get_param: cps_net_name }
      cps_net_ip: { get_param: [cps_net_ips, 0] }
      cps_net_mask: { get_param: cps_net_mask }
      oam_net_name: { get_param: oam_net_name }
      oam_net_ip: { get_param: [oam_net_ips, 0] }
      oam_net_mask: { get_param: oam_net_mask }
      oam_net_gw: { get_param: oam_net_gw }

  compute_port_0:
    type: OS::Neutron::Port
    properties:
      network: { get_param: net_name }

  packet_mirror_network:
    type: OS::Neutron::Net
    properties:
      #get attribute from a nested resource
      name: { get_attr: [server_pcm_001 , instance_name] }
      #get attribute from a regular consolidation entity resource
      tenant_id: { get_attr: [server_compute, instance_name]}