Merge "[fuel] Add support to use public net netmask from IDF"
authorAlexandru Avadanii <Alexandru.Avadanii@enea.com>
Mon, 22 Jan 2018 16:49:57 +0000 (16:49 +0000)
committerGerrit Code Review <gerrit@opnfv.org>
Mon, 22 Jan 2018 16:49:57 +0000 (16:49 +0000)
1  2 
config/installers/fuel/pod_config.yml.j2

@@@ -1,10 -1,3 +1,10 @@@
 +##############################################################################
 +# Copyright (c) 2018 Mirantis Inc., Enea AB and others.
 +# All rights reserved. This program and the accompanying materials
 +# are made available under the terms of the Apache License, Version 2.0
 +# which accompanies this distribution, and is available at
 +# http://www.apache.org/licenses/LICENSE-2.0
 +##############################################################################
  ---
  {%- if conf.idf is defined and conf.idf.fuel is defined -%}
    {%- if conf.idf.net_config is defined -%}
@@@ -12,6 -5,7 +12,7 @@@
        {%- set net_mgmt = conf.idf.net_config.mgmt.network -%}
        {%- set net_private = conf.idf.net_config.private.network -%}
        {%- set net_public = conf.idf.net_config.public.network -%}
+       {%- set net_public_mask = conf.idf.net_config.public.mask -%}
        {%- set vlan_mgmt = conf.idf.net_config.mgmt.vlan -%}
        {%- set vlan_private = conf.idf.net_config.private.vlan -%}
        {%- if conf.idf.net_config.public.dns is defined -%}
@@@ -26,6 -20,7 +27,7 @@@
        {%- set net_mgmt = '172.16.10.0' -%}
        {%- set net_private = '10.1.0.0' -%}
        {%- set net_public = '172.30.10.0' -%}
+       {%- set net_public_mask = '24' -%}
        {%- set vlan_mgmt = '300' -%}
        {%- set vlan_private = '1000' -%}
        {%- set pxe_interface = 0 -%}
@@@ -36,7 -31,7 +38,7 @@@
    {%- endif -%}
    {%- if net_public_gw is not defined -%}
        {%- set net_public_gw =  net_public | ipaddr_index('1')  -%}
-   {%- endif %}
+   {%- endif -%}
  parameters:
    _param:
  
@@@ -46,7 -41,6 +48,7 @@@
      opnfv_jump_bridge_public: {{ conf.idf.fuel.jumphost.bridges.public }}
  
      opnfv_infra_config_address: {{ net_mgmt | ipaddr_index(100) }}
 +    opnfv_infra_config_pxe_address: {{ net_admin | ipaddr_index(2) }}
      opnfv_infra_maas_node01_address: {{ net_mgmt | ipaddr_index(3) }}
      opnfv_infra_maas_node01_deploy_address: {{ net_admin | ipaddr_index(3) }}
      opnfv_infra_kvm_address: {{ net_mgmt | ipaddr_index(140) }}
@@@ -55,8 -49,9 +57,8 @@@
      opnfv_infra_kvm_node03_address: {{ net_mgmt | ipaddr_index(143) }}
  
      opnfv_infra_maas_pxe_network_address: {{ net_admin }}
 -    opnfv_infra_maas_pxe_address: {{ net_admin | ipaddr_index(3) }}
 -    opnfv_infra_maas_pxe_start_address: {{ net_admin | ipaddr_index(5) }}
 -    opnfv_infra_maas_pxe_end_address: {{ net_admin | ipaddr_index(250) }}
 +    opnfv_infra_maas_pxe_start_address: {{ net_admin | ipaddr_index(4) }}
 +    opnfv_infra_maas_pxe_end_address: {{ net_admin | ipaddr_index(100) }}
  
      opnfv_openstack_gateway_node01_address: {{ net_mgmt | ipaddr_index(124) }}
      opnfv_openstack_gateway_node02_address: {{ net_mgmt | ipaddr_index(125) }}
@@@ -67,7 -62,6 +69,7 @@@
      opnfv_openstack_proxy_address: {{ net_public | ipaddr_index(103) }}
      opnfv_openstack_proxy_node01_address: {{ net_public | ipaddr_index(104) }}
      opnfv_openstack_proxy_node02_address: {{ net_public | ipaddr_index(105) }}
 +    opnfv_openstack_proxy_control_address: {{ net_mgmt | ipaddr_index(103) }}
      opnfv_openstack_proxy_node01_control_address: {{ net_mgmt | ipaddr_index(104) }}
      opnfv_openstack_proxy_node02_control_address: {{ net_mgmt | ipaddr_index(105) }}
      opnfv_openstack_control_address: {{ net_mgmt | ipaddr_index(10) }}
  
      opnfv_opendaylight_server_node01_single_address: {{ net_mgmt | ipaddr_index(111) }}
  
+     opnfv_net_public: {{ net_public }}/{{ net_public_mask }}
+     opnfv_net_public_mask: {{ net_public_mask | netmask }}
      opnfv_net_public_gw: {{ net_public_gw }}
+     opnfv_net_public_pool_start: {{ net_public | ipaddr_index(80) }}
+     opnfv_net_public_pool_end: {{ net_public | ipaddr_index(100) }}
      opnfv_name_servers: {{ dns_public }}
      opnfv_dns_server01: '{{ dns_public[0] }}'