diff --git a/doc/source/devref/vnf_component_usage_guide.rst b/doc/source/devref/vnf_component_usage_guide.rst index 34627c419..21568aa3f 100644 --- a/doc/source/devref/vnf_component_usage_guide.rst +++ b/doc/source/devref/vnf_component_usage_guide.rst @@ -40,7 +40,8 @@ How to setup environment To make use of VNFC in Tacker, we have to upload the image to the glance in which heat-config and heat-config agents are installed. The installation steps can be referred `here `_. +hot/software-config/elements/README.rst>`_. The tool +'tools/vnfc/build_image.sh' can be used to generate such a kind of image. Currently VNFC feature works by using `heat software config `_ which diff --git a/tools/vnfc/build_image.sh b/tools/vnfc/build_image.sh new file mode 100755 index 000000000..8cf8a9868 --- /dev/null +++ b/tools/vnfc/build_image.sh @@ -0,0 +1,26 @@ +#!/bin/bash + +VNFC_IMAGE=/tmp/tacker_vnfc_images +rm -rf $VNFC_IMAGE +mkdir $VNFC_IMAGE + +pip install diskimage-builder +pip install dib-utils +CURRENT_DIR=`pwd` +cd $VNFC_IMAGE +git clone https://git.openstack.org/openstack/tripleo-image-elements.git +git clone https://git.openstack.org/openstack/heat-templates.git + +export ELEMENTS_PATH=tripleo-image-elements/elements:heat-templates/hot/software-config/elements +disk-image-create vm \ + fedora selinux-permissive \ + os-collect-config \ + os-refresh-config \ + os-apply-config \ + heat-config \ + heat-config-ansible \ + heat-config-cfn-init \ + heat-config-puppet \ + heat-config-salt \ + heat-config-script \ + -o fedora-software-config.qcow2