Creating your own VNF package (Release ONE)

From OSM Public Wiki
Jump to: navigation, search

VNF without primitives

Using web form

You can access this web page and follow the instructions:

Using the CLI tool

  • Clone the descriptor-packages repo:
git clone
  • Run the following command to create a folder with all the files required for a single-VM VNF package:
./descriptor-packages/src/ -t vnfd --image <IMAGE_PATH> -c <VNF_NAME>
  • A folder called <VNF_NAME>_vnfd will be created with all the files required for a VNF package.
  • Edit the descriptor file <VNF_NAME>_vnfd.yaml.
    • By default, the descriptor is prepared for a single-VM VNF.
    • Add as many VMs as required.
    • Add also Internal VLDs as required.
  • Add any artifacts needed by the VNF (eg, charm, icons, images etc ...) to the appropriate folder and make sure it is referenced in the descriptor.
  • Once done, you can generate the tar.gz VNF package with the command:
./descriptor-packages/src/ -t vnfd -N <VNF_NAME>_vnfd
#Note: the argument -N is optional and is intended to keep the package files after creating the package

Note: If the descriptor is more complex such as a multi-VM VNF the GUI based composer tool is recommended to create the descriptor.

Using the GUI based composer

Creating and onboarding a VNF descriptor

The GUI composer tool is recommended for editing complex VNFs such as multi-VM VNFs

  • Bring up the OSM GUI.
  • Navigate to the "catalog" page and click on the "+" sign to choose "ADD VNFD" option.
  • A new VNF will be added to the canvas. By default the VNF will contain a single VM/VDU.
  • Use the "model driven" editor on the right most side of the page to update the various fields in the VNF descriptor.
  • Use the "ADD VDU" and "ADD IVLD" buttons to add additional VDUs and Internal VLDs needed by the VNF.
  • Select the VDUs and VLDs created and update the fields as needed using the model driven editor on the right.
  • For VDUs that need connection to an Internal VLD, add internal connection points to the VDU. Once added, the connection points will be visible on the canvas.
  • Make the connection to Internal VLD and VDU by clicking in the VDU and drawing a line to the VLD.
  • Once all the edits to the descriptor are completed, click "ONBOARD" to onboard the descriptor.

Exporting a VNF descriptor package

A descriptor that has been on-boarded (through package onboard or through the GUI composer) will be available for export to create a descriptor package.

#Note: Release1  does not include the artifacts that was in the on-boarded package in the exported package.

Adding additional artifacts to a VNF descriptor package

The release1 implementation does not allow the editing of artifacts within a VNF package. So only descriptors can be generated using the GUI composer tool. If additional artifacts need to be included in the VNF package, then:

  • Export the VNF package to myvnf.tar.gz.
  • Untar the package using tar -zxvf myvnf.tar.gz.
  • Copy the needed artifacts to the appropriate directory and update the descriptor to refer to them.
  • Recreate the package using the CLI tool

VNF with primitives

You will have to create a proxy charm for the VNF. You can follow the general instructions below:

  • Clone the descriptor-packages repo:
git clone

You can then follow the ping-pong example in OSM descriptor packages to integrate the charm into VNF primitives