Adds support for autoscaling based on vnf-metric
[osm/POL.git] / osm_policy_module / tests / unit / utils / examples / cirros_vdu_scaling_vnfd_1.yaml
1 vnfd:vnfd-catalog:
2     vnfd:
3     -   id: cirros_vdu_scaling_vnf
4         name: cirros_vdu_scaling_vnf
5         short-name: cirros_vdu_scaling_vnf
6         description: Simple VNF example with a cirros and a scaling group descriptor
7         vendor: OSM
8         version: '1.0'
9         # Place the logo as png in icons directory and provide the name here
10         logo: cirros-64.png
11         # Management interface
12         mgmt-interface:
13             cp: eth0
14         # Atleast one VDU need to be specified
15         vdu:
16         -   id: cirros_vnfd-VM
17             name: cirros_vnfd-VM
18             description: cirros_vnfd-VM
19             count: 1
20
21             # Flavour of the VM to be instantiated for the VDU
22             # flavor below can fit into m1.micro
23             vm-flavor:
24                 vcpu-count: 1
25                 memory-mb: 256
26                 storage-gb: 2
27             # Image/checksum or image including the full path
28             image: 'cirros034'
29             #checksum:
30             interface:
31             # Specify the external interfaces
32             # There can be multiple interfaces defined
33             -   name: eth0
34                 type: EXTERNAL
35                 virtual-interface:
36                     type: VIRTIO
37                     bandwidth: '0'
38                     vpci: 0000:00:0a.0
39                 external-connection-point-ref: eth0
40             monitoring-param:
41             -   id: "cirros_vnfd-VM_cpu_util"
42                 nfvi-metric: "cpu_utilization" # The associated NFVI metric to be monitored. Id of the metric
43                 #interface-name-ref: reference to interface name, required for some metrics
44         connection-point:
45         -   name: eth0
46             type: VPORT
47         scaling-group-descriptor:
48         -   name: "scale_cirros_vnfd-VM"
49             min-instance-count: 1
50             max-instance-count: 10
51             scaling-policy:
52             -   name: "auto_cpu_util_above_threshold"
53                 scaling-type: "automatic"
54                 threshold-time: 10
55                 cooldown-time: 60
56                 scaling-criteria:
57                 -   name: "group1_cpu_util_above_threshold"
58                     scale-in-threshold: 20
59                     scale-in-relational-operation: "LT"
60                     scale-out-threshold: 80
61                     scale-out-relational-operation: "GT"
62                     vnf-monitoring-param-ref: "cirros_vnf_cpu_util"
63             vdu:
64             -   vdu-id-ref: cirros_vnfd-VM
65                 count: 1
66             # scaling-config-action:            # Para utilizar charms
67             # -   trigger: post-scale-out
68             #     vnf-config-primitive-name-ref:
69         monitoring-param:
70         -   id: "cirros_vnf_cpu_util"
71             name: "cirros_vnf_cpu_util"
72             aggregation-type: AVERAGE
73             vdu-monitoring-param:
74               vdu-ref: "cirros_vnfd-VM"
75               vdu-monitoring-param-ref: "cirros_vnfd-VM_cpu_util"