X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=osmclient%2Ftemplates%2Fvnfd.yaml.j2;h=b0a6c486772bedb67e1510de2e4f277770ca8421;hb=1cbff09ebd242dcba9e0011c083e13e5623f1f5d;hp=0dfc1f2aabb7c0e0ac10cb22ceb46f48a11b4f76;hpb=d1e681dec82db20288abcc84cc9a4f2648060316;p=osm%2Fosmclient.git diff --git a/osmclient/templates/vnfd.yaml.j2 b/osmclient/templates/vnfd.yaml.j2 index 0dfc1f2..b0a6c48 100644 --- a/osmclient/templates/vnfd.yaml.j2 +++ b/osmclient/templates/vnfd.yaml.j2 @@ -14,321 +14,205 @@ # License for the specific language governing permissions and limitations # under the License. -vnfd-catalog: - schema-version: "v3.0" - vnfd: - - id: {{ name }}_vnfd - name: {{ name }}_vnfd - short-name: {{ name }}_vnfd - description: Generated by OSM package generator - vendor: OSM - version: '1.0' - - {%- if detailed is sameas true %} - #Place the logo as png in icons directory and provide the name here - #logo: - - {%- endif %} - - # Management interface - mgmt-interface: - cp: vnf-cp0 - - # At least one VDU need to be specified - vdu: - # Additional VDUs can be created by copying the - # VDU descriptor below - - id: {{ name }}_vnfd-VM - name: {{ name }}_vnfd-VM - description: {{ name }}_vnfd-VM - count: 1 - {%- if detailed is sameas true %} - #pdu-type: - #mgmt-vpci: - {%- endif %} - - # Flavour of the VM to be instantiated for the VDU - vm-flavor: - vcpu-count: {{ vcpu }} - memory-mb: {{ memory }} - storage-gb: {{ storage }} - - # Image including the full path - image: "{{ image }}" - {%- if detailed is sameas true %} - #image-checksum: - {%- endif %} - - interface: - # Specify the external interfaces - # There can be multiple interfaces defined - - name: eth0 - type: EXTERNAL - virtual-interface: - type: PARAVIRT - {%- if detailed is sameas true %} - #vpci: - #bandwidth: - {%- endif %} - external-connection-point-ref: vnf-cp0 - {%- if detailed is sameas true %} - #internal-connection-point-ref: - #mac-address - #mgmt-interface: - {%- endif %} - - {%- for x in range(1, interfaces + 1 ) %} - - name: eth{{ x }} - type: EXTERNAL - virtual-interface: - type: PARAVIRT - {%- if detailed is sameas true %} - #vpci: - #bandwidth: - {%- endif %} - external-connection-point-ref: vnf-cp{{ x }} - {%- if detailed is sameas true %} - #internal-connection-point-ref: - #mac-address - #mgmt-interface: - {%- endif %} - {%- endfor %} - - {%- if detailed is sameas true %} - #guest-epa: - # mempage-size: - # # Choice cpu-pinning / cpu-quota - # cpu-pinning-policy: [DEDICATED, SHARED, ANY] - # cpu-thread-pinning-policy: [AVOID, SEPARATED, ISOLATE, PREFER] - # cpu-quota: - # limit: - # reserve: - # shares: - # mem-quota: - # limit: - # reserve: - # shares: - # disk-io-quota: - # limit: - # reserve: - # shares: - # vif-quota: - # limit: - # reserve: - # shares: - - #alarm: - #- alarm-id: - # vnf-monitoring-param-ref: - # operation: - # value: - # actions: - # ok: - # - url: - # insufficient-data: - # - url: - # alarm: - # - url: - # - #alternative-images: - #- vim-type: - # image: - # image-checksum: - # - #vdu-configuration: - # # Configure the VNF or VDU through Juju. - # juju: - # charm: - # proxy: - # vca-relationships: - # relation: - # - requires: - # provides: - # config-primitive: - # - name: - # parameter: - # - name: - # data-type: - # mandatory: - # default-value: - # parameter-pool: - # read-only: - # hidden: - # initial-config-primitive: - # - seq: - # name: - # parameter: - # - name: - # data-type: - # value: - # terminate-config-primitive: - # - seq: - # name: - # parameter: - # - name: - # data-type: - # value: - # metrics: - # - name: - # config-access: - # ssh-access: - # required: - # default-user: - # - #monitoring-param: - #- id: - # nfvi-metric: - # interface-name-ref: - # - ## Choice cloud-init / cloud-init-file - #cloud-init: - #cloud-init-file: - #supplemental-boot-data: - # boot-data-drive: - # - #internal-connection-point: - #- id: - # name: - # short-name: - # type: - # port-security-enabled: - # internal-vld-ref: - # - #interface: - #- name: - # position: - # mgmt-interface: - # type: - # mac-address: - # # Choice: connection-point-type | internal-connection-point-ref / external-connection-point-ref - # internal-connection-point-ref: - # external-connection-point-ref: - # virtual-interface: - # type: # PARAVIRT,OM-MGMT,PCI-PASSTHROUGH,SR-IOV,VIRTIO,E1000,RTL8139,PCNET - # vpci: - # bandwidth: - # - #volumes: - #- name: - # description: - # size: - # device-bus: # ide, usb, virtio, iscsi - # device-type: # disk, cdrom, floopy, lun - # # Choice volume-source | ephemeral / image - # ephemeral: - # image: - # image-checksum: - - #scaling-group-descriptor: - #- name: - # min-instance-count: - # max-instance-count: - # scaling-policy: - # - name: - # scaling-type: - # enabled: - # scale-in-operator-type: - # scale-out-operator-type: - # threshold-time: - # cooldown-time: - # scaling-criteria: - # - name: - # scale-in-threshold: - # scale-in-relational-operation: - # scale-out-threshold: - # scale-out-relational-operation: - # vnf-monitoring-param-ref: - # vdu: - # - vdu-id-ref: - # count: - # scaling-config-action: - # - trigger: - # vnf-config-primitive-name-ref: - - # List of monitoring params at NS level - #monitoring-param: - #- id: - # name: - # aggregation-type: - # # Choice monitoring-type | vdu-monitoring-param / vnf-metric / vdu-metric - # vdu-monitoring-param: - # vdu-ref: - # vdu-monitoring-param-ref: - # vnf-metric: - # vnfm-metric-name-ref: - # vdu-metric: - # vdu-ref: - # vdu-metric-name-ref: - # - # Placement groups at VNF Level - #placement-groups: - #- name: - # requirement: - # strategy: # COLOCATION, ISOLATION - # member-vdus: - # - member-vdu-ref: - {%- endif %} - {%- if vdus > 1 %} - {% for y in range(1, vdus ) %} - - id: {{ name }}_vnfd{{y}}-VM - name: {{ name }}_vnfd{{y}}-VM - description: {{ name }}_vnfd{{y}}-VM - count: 1 - {%- if detailed is sameas true %} - #pdu-type: - #mgmt-vpci: - {%- endif %} - - # Flavour of the VM to be instantiated for the VDU - vm-flavor: - vcpu-count: {{ vcpu }} - memory-mb: {{ memory }} - storage-gb: {{ storage }} - - # Image including the full path - image: "{{ image }}" - {%- if detailed is sameas true %} - #image-checksum: - {%- endif %} - - interface: - # Specify the external interfaces - # There can be multiple interfaces defined - - name: eth0 - type: EXTERNAL - virtual-interface: - type: PARAVIRT - {%- if detailed is sameas true %} - #vpci: - #bandwidth: - {%- endif %} - external-connection-point-ref: vnf-cp0 - {%- if detailed is sameas true %} - #internal-connection-point-ref: - #mac-address - #mgmt-interface: - {%- endif %} - - {%- for z in range(1, interfaces + 1 ) %} - - name: eth{{ z }} - type: EXTERNAL - virtual-interface: - type: PARAVIRT - {%- if detailed is sameas true %} - #vpci: - #bandwidth: - {%- endif %} - external-connection-point-ref: vnf-cp{{ z }} - {%- if detailed is sameas true %} - #internal-connection-point-ref: - #mac-address - #mgmt-interface: - {%- endif %} - {%- endfor %} - {%- endfor %} - {%- endif %} - connection-point: - - name: vnf-cp0 - {%- for x in range(1, interfaces + 1 ) %} - - name: vnf-cp{{ x }} - {%- endfor %} \ No newline at end of file +vnfd: + id: {{ name }}_vnfd + product-name: {{ name }}_vnfd + description: Generated by OSM package generator + provider: OSM + version: '1.0' + mgmt-cp: vnf-cp0-ext + virtual-storage-desc: + - id: {{ name }}_vnfd-VM-storage + size-of-storage: {{ storage }} + {%- if detailed is sameas true %} + #disk-io-quota: + # limit: + # reserve: + # shares: + {%- endif %} + virtual-compute-desc: + - id: {{ name }}_vnfd-VM-compute + virtual-cpu: + num-virtual-cpu: {{ vcpu }} + {%- if detailed is sameas true %} + #pinning: + # # Choice cpu-pinning / cpu-quota + # policy: [dynamic, static] + # thread-policy: [AVOID, SEPARATED, ISOLATE, PREFER] + # cpu-quota: + # limit: + # reserve: + # shares: + {%- endif %} + virtual-memory: + size: {{ memory }} + {%- if detailed is sameas true %} + #guest-epa: + # mempage-size: + # mem-quota: + # limit: + # reserve: + # shares: + {%- endif %} + sw-image-desc: + - id: "{{ image }}" + name: "{{ image }}" + image: "{{ image }}" + {%- if detailed is sameas true %} + #- id: + # name: + # image: + # vim-type: + {%- endif %} + df: + - id: default-df + instantiation-level: + - id: default-instantiation-level + vdu-level: + - vdu-id: {{ name }}_vnfd-VM + number-of-instances: 1 + vdu-profile: + - id: {{ name }}_vnfd-VM + min-number-of-instances: 1 + max-number-of-instances: 1 + {%- if detailed is sameas true %} + #lcm-operations-configuration: + # operate-vnf-op-config: + # day1-2: + # - id: {{ name }}_vnfd-VM + # # Configure the VNF or VDU through Juju. + # juju: + # charm: + # proxy: + # vca-relationships: + # relation: + # - requires: + # provides: + # config-primitive: + # - name: + # parameter: + # - name: + # data-type: + # mandatory: + # default-value: + # parameter-pool: + # read-only: + # hidden: + # initial-config-primitive: + # - seq: + # name: + # parameter: + # - name: + # data-type: + # value: + # terminate-config-primitive: + # - seq: + # name: + # parameter: + # - name: + # data-type: + # value: + # metrics: + # - name: + # config-access: + # ssh-access: + # required: + # default-user: + #scaling-aspect: + #- id: + # name: + # max-scale-level: + # scaling-policy: + # - name: + # scaling-type: + # enabled: + # scale-in-operator-type: + # scale-out-operator-type: + # threshold-time: + # cooldown-time: + # scaling-criteria: + # - name: + # scale-in-threshold: + # scale-in-relational-operation: + # scale-out-threshold: + # scale-out-relational-operation: + # vnf-monitoring-param-ref: + # scaling-config-action: + # - trigger: + # vnf-config-primitive-name-ref: + # aspect-delta-details: + # id: -delta + # vdu-delta: + # - number-of-instances: 1 + # id: {{ name }}_vnfd-VM + {%- endif %} + {%- if detailed is sameas true %} + ## Placement groups at VNF Level + #placement-groups: + #- name: + # requirement: + # strategy: # COLOCATION, ISOLATION + # member-vdus: + # - member-vdu-ref: + {%- endif %} + # At least one VDU need to be specified + # Additional VDUs can be created by copying the + # VDU descriptor below + vdu: + - id: {{ name }}_vnfd-VM + name: {{ name }}_vnfd-VM + description: {{ name }}_vnfd-VM + sw-image-desc: "{{ image }}" + {%- if detailed is sameas true %} + ## Choice cloud-init / cloud-init-file + #cloud-init: + #cloud-init-file: + #supplemental-boot-data: + # boot-data-drive: + #alarm: + #- alarm-id: + # vnf-monitoring-param-ref: + # operation: + # value: + # actions: + # ok: + # - url: + # insufficient-data: + # - url: + # alarm: + # - url: + #pdu-type: + #alternative-sw-image-desc: + #- id: + # name: + # image: + # vim-type: + {%- endif %} + virtual-storage-desc: + - {{ name }}_vnfd-VM-storage + virtual-compute-desc: {{ name }}_vnfd-VM-compute + {%- if detailed is sameas true %} + #monitoring-parameter: + #- id: + # name: + # performance-metric: + {%- endif %} + int-cpd: + - id: eth0-int + virtual-network-interface-requirement: + - name: eth0 + virtual-interface: + type: PARAVIRT + {%- if detailed is sameas true %} + #vpci: + #bandwidth: + {%- endif %} + ext-cpd: + - id: vnf-cp0-ext + int-cpd: + vdu-id: {{ name }}_vnfd-VM + cpd: eth0-int + {%- if detailed is sameas true %} + #port-security-enabled: + #port-security-disable-strategy: + {%- endif %} \ No newline at end of file