diff --git a/devstack/README-NFP-Advanced-Mode b/devstack/README-NFP-Advanced-Mode index 4b55ee6f5..08d3f2e05 100644 --- a/devstack/README-NFP-Advanced-Mode +++ b/devstack/README-NFP-Advanced-Mode @@ -12,25 +12,38 @@ Fresh Installation Steps: (3) Configure local.conf # Modify NFP_DEVSTACK_MODE to 'advanced' - # Configure following external network details, + # Configure the following external network details. + # If configured, install step creates resources required for external access. + # If not configured, user needs to create these resources as described in step 5 below. EXT_NET_GATEWAY= EXT_NET_ALLOCATION_POOL_START= EXT_NET_ALLOCATION_POOL_END= EXT_NET_CIDR= - # Configure the Configurator VM image path(optional), + + # Configure the Configurator (NFP Controller) VM image path(optional), # If configured, install step uploads the specified image # If not configured, install step will build a new one and upload it ConfiguratorQcow2Image= - # Configure the Service VM image paths(optional), + + # Configure Service VM image paths(optional), # If configured, install step uploads the specified images # If not configured, install step ignores uploading these service images VyosQcow2Image= HaproxyQcow2Image= + # Configure PUBLIC_INTERFACE with the public interface name (4) Install devstack. # ./stack.sh +(5) Create required basic GBP resources + # In step 3 above, if you have chosen not to create resources for external access, you may need + # to create them explicitly as described below. + # Note: This step is not required to excercise east west traffic + # Create external-network, external-subnet, external-segment, nat-pool, network-service-policy + # Configure "default_external_segment_name" option from "group_policy_implicit_policy" group + # with external-segment name created above from neutron.conf + # Restart neutron-server service Re-installation Steps: ====================== diff --git a/devstack/lib/nfp b/devstack/lib/nfp index 3cfb2bd3d..ecbeec562 100644 --- a/devstack/lib/nfp +++ b/devstack/lib/nfp @@ -125,7 +125,7 @@ function create_ep_and_nsp { default gbp nsp-create\ - --network-service-params type=ip_pool,name=vip_ip,value=nat_pool\ + --network-service-params type=ip_pool,name=fip,value=nat_pool\ svc_mgmt_fip_policy } @@ -191,9 +191,10 @@ function create_nfp_gbp_resources { --service-flavor service_vendor=vyos,device_type=nova\ --vendor NFP\ vpn_profile - - create_ext_net - create_ep_and_nsp + if [[ $EXT_NET_GATEWAY && $EXT_NET_ALLOCATION_POOL_START && $EXT_NET_ALLOCATION_POOL_END && $EXT_NET_CIDR ]]; then + create_ext_net + create_ep_and_nsp + fi fi diff --git a/devstack/local.conf.nfp b/devstack/local.conf.nfp index 40d3a2099..588792459 100644 --- a/devstack/local.conf.nfp +++ b/devstack/local.conf.nfp @@ -24,6 +24,8 @@ if [[ $ENABLE_NFP = True ]]; then if [[ $NFP_DEVSTACK_MODE = advanced ]]; then # External Network + # If configured, install step creates external network, external policy and network service policy + # If not configured, user has to create external network, external policy and network service policy EXT_NET_GATEWAY= EXT_NET_ALLOCATION_POOL_START= EXT_NET_ALLOCATION_POOL_END= diff --git a/devstack/plugin.sh b/devstack/plugin.sh index 5786b8e32..3db5496e9 100755 --- a/devstack/plugin.sh +++ b/devstack/plugin.sh @@ -35,7 +35,9 @@ function nfp_configure_neutron { iniset $NEUTRON_CONF admin_owned_resources_apic_tscp plumbing_resource_owner_user "neutron" iniset $NEUTRON_CONF admin_owned_resources_apic_tscp plumbing_resource_owner_password $ADMIN_PASSWORD iniset $NEUTRON_CONF admin_owned_resources_apic_tscp plumbing_resource_owner_tenant_name "service" - iniset $NEUTRON_CONF group_policy_implicit_policy default_external_segment_name "default" + if [[ $EXT_NET_GATEWAY && $EXT_NET_ALLOCATION_POOL_START && $EXT_NET_ALLOCATION_POOL_END && $EXT_NET_CIDR ]]; then + iniset $NEUTRON_CONF group_policy_implicit_policy default_external_segment_name "default" + fi iniset $NEUTRON_CONF nfp_node_driver is_service_admin_owned "True" iniset $NEUTRON_CONF nfp_node_driver svc_management_ptg_name "svc_management_ptg" }