├── .gitignore ├── image-patching ├── nuage_image_patching_scripts │ ├── __init__.py │ ├── utils │ │ ├── __init__.py │ │ ├── constants.py │ │ └── common.py │ ├── nuage_repo.sample │ ├── nuage_patching_config.yaml │ └── nuage_overcloud_full_patch.py ├── MANIFEST.in ├── setup.py └── setup.cfg ├── Documentation ├── 20.10 │ ├── sw1024.png │ ├── sw1027.png │ └── upgrade │ │ └── README.rst ├── 20.5 │ ├── sw1024.png │ └── sw1027.png └── 20.10_HWVTEP │ ├── sw1025.png │ └── sw1028.png ├── nuage-tripleo-heat-templates ├── roles │ └── README.md ├── environments │ ├── net-single-nic-hw-offload.yaml │ ├── mellanox-environment.yaml │ ├── nova-nuage-config.yaml │ ├── net-bond-with-vlans.yaml │ ├── compute-avrs-environment.yaml │ ├── ovs-hw-offload.yaml │ ├── compute-avrs-multirole-environment.yaml │ ├── containers-prepare-parameter.yaml │ ├── neutron-nuage-config.yaml │ └── network-environment.yaml ├── scripts │ ├── pull_nuage_containers │ │ ├── nuage_local_registry_images.yaml.j2 │ │ ├── nuage_container_config.yaml │ │ ├── nuage_overcloud_images.yaml.j2 │ │ └── nuage_container_pull.py │ ├── generate-cms-id │ │ ├── README.md │ │ ├── configure_vsd_cms_id.py │ │ └── restproxy.py │ └── create_roles │ │ └── create_all_roles.sh ├── LICENSE ├── nuage-overcloud-resource-registry.yaml ├── deployment │ ├── neutron │ │ ├── neutron-plugin-ml2-nuage-container-puppet.yaml │ │ ├── neutron-fastpath-agent.yaml │ │ └── neutron-plugin-ml2-nuage.yaml │ └── nova │ │ ├── nuage-compute-vrs.yaml │ │ └── neutron-compute-plugin-nuage.yaml └── network │ └── config │ ├── single-nic-hw-offload │ ├── computeovrs.yaml │ └── controller.yaml │ └── bond-with-vlans │ ├── computeavrs.yaml │ ├── computeavrsdual.yaml │ ├── computeavrssingle.yaml │ ├── computeovrs.yaml │ ├── compute.yaml │ ├── computesriov.yaml │ └── controller.yaml ├── .gitreview ├── nuage-ospd16-dockerfiles ├── heat-api │ ├── nuage.repo │ └── Dockerfile ├── horizon │ ├── nuage.repo │ └── Dockerfile ├── heat-api-cfn │ ├── nuage.repo │ └── Dockerfile ├── heat-engine │ ├── nuage.repo │ └── Dockerfile ├── nova-compute │ ├── nuage.repo │ └── Dockerfile ├── neutron-server │ ├── nuage.repo │ └── Dockerfile └── neutron-openvswitch-agent │ ├── nuage.repo │ └── Dockerfile ├── nuage-rpms ├── nuage-puppet-modules-16.1-20.10.1_40.noarch.rpm ├── nuage-puppet-modules-16.1-20.10.2_42.noarch.rpm ├── nuage-puppet-modules-16.1-20.10.3_44.noarch.rpm ├── nuage-puppet-modules-16.1-20.10.4_53.noarch.rpm ├── nuage-puppet-modules-16.1-20.10.5_54.noarch.rpm ├── nuage-puppet-modules-16.1-20.10.6_57.noarch.rpm ├── nuage-puppet-modules-16.1-20.10.7_59.noarch.rpm ├── nuage-puppet-modules-16.1-20.5.2_38.noarch.rpm ├── nuage-puppet-modules-16.1-20.5.3_39.noarch.rpm ├── nuage-puppet-modules-16.2-20.10.13_63.noarch.rpm ├── nuage-image-patching-scripts-16.1-20.10.1_309.noarch.rpm ├── nuage-image-patching-scripts-16.1-20.10.1_317.noarch.rpm ├── nuage-image-patching-scripts-16.1-20.10.1_327.noarch.rpm ├── nuage-image-patching-scripts-16.1-20.10.2_377.noarch.rpm ├── nuage-image-patching-scripts-16.1-20.10.3_423.noarch.rpm ├── nuage-image-patching-scripts-16.1-20.10.4_480.noarch.rpm ├── nuage-image-patching-scripts-16.1-20.10.5_551.noarch.rpm ├── nuage-image-patching-scripts-16.1-20.10.6_631.noarch.rpm ├── nuage-image-patching-scripts-16.1-20.10.7_722.noarch.rpm ├── nuage-image-patching-scripts-16.1-20.5.2_191.noarch.rpm ├── nuage-image-patching-scripts-16.1-20.5.3_231.noarch.rpm ├── nuage-image-patching-scripts-16.2-20.10.9_912.noarch.rpm ├── nuage-tripleo-heat-templates-16.1-20.10.1_309.noarch.rpm ├── nuage-tripleo-heat-templates-16.1-20.10.1_317.noarch.rpm ├── nuage-tripleo-heat-templates-16.1-20.10.1_327.noarch.rpm ├── nuage-tripleo-heat-templates-16.1-20.10.2_377.noarch.rpm ├── nuage-tripleo-heat-templates-16.1-20.10.3_423.noarch.rpm ├── nuage-tripleo-heat-templates-16.1-20.10.4_480.noarch.rpm ├── nuage-tripleo-heat-templates-16.1-20.10.5_551.noarch.rpm ├── nuage-tripleo-heat-templates-16.1-20.10.6_631.noarch.rpm ├── nuage-tripleo-heat-templates-16.1-20.10.7_722.noarch.rpm ├── nuage-tripleo-heat-templates-16.1-20.5.2_191.noarch.rpm ├── nuage-tripleo-heat-templates-16.1-20.5.3_231.noarch.rpm ├── nuage-tripleo-heat-templates-16.2-20.10.9_912.noarch.rpm ├── nuage-image-patching-scripts-16.2-20.10.13_1248.noarch.rpm └── nuage-tripleo-heat-templates-16.2-20.10.13_1248.noarch.rpm ├── README.md ├── .zuul.yaml ├── nuage-tripleo-heat-templates.spec.in └── LICENSE /.gitignore: -------------------------------------------------------------------------------- 1 | .idea/* 2 | *.pyc -------------------------------------------------------------------------------- /image-patching/nuage_image_patching_scripts/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /image-patching/nuage_image_patching_scripts/utils/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /image-patching/MANIFEST.in: -------------------------------------------------------------------------------- 1 | graft nuage_image_patching_scripts 2 | -------------------------------------------------------------------------------- /Documentation/20.10/sw1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/Documentation/20.10/sw1024.png -------------------------------------------------------------------------------- /Documentation/20.10/sw1027.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/Documentation/20.10/sw1027.png -------------------------------------------------------------------------------- /Documentation/20.5/sw1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/Documentation/20.5/sw1024.png -------------------------------------------------------------------------------- /Documentation/20.5/sw1027.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/Documentation/20.5/sw1027.png -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/roles/README.md: -------------------------------------------------------------------------------- 1 | # This dir contains all the roles you plan to have in your deployment with Nuage Integration -------------------------------------------------------------------------------- /Documentation/20.10_HWVTEP/sw1025.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/Documentation/20.10_HWVTEP/sw1025.png -------------------------------------------------------------------------------- /Documentation/20.10_HWVTEP/sw1028.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/Documentation/20.10_HWVTEP/sw1028.png -------------------------------------------------------------------------------- /.gitreview: -------------------------------------------------------------------------------- 1 | [gerrit] 2 | host=gerrit.an.nuagenetworks.net 3 | port=29418 4 | project=nuagenetworks/nuage-ospdirector.git 5 | defaultbranch=OSPD16 6 | -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/heat-api/nuage.repo: -------------------------------------------------------------------------------- 1 | [Nuage] 2 | name=nuage 3 | baseurl=http://url_to_nuage_repo 4 | enabled=1 5 | gpgcheck=1 6 | gpgkey=file:///tmp/RPM-GPG-KEY-Nuage 7 | -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/horizon/nuage.repo: -------------------------------------------------------------------------------- 1 | [Nuage] 2 | name=nuage 3 | baseurl=http://url_to_nuage_repo 4 | enabled=1 5 | gpgcheck=1 6 | gpgkey=file:///tmp/RPM-GPG-KEY-Nuage 7 | -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/heat-api-cfn/nuage.repo: -------------------------------------------------------------------------------- 1 | [Nuage] 2 | name=nuage 3 | baseurl=http://url_to_nuage_repo 4 | enabled=1 5 | gpgcheck=1 6 | gpgkey=file:///tmp/RPM-GPG-KEY-Nuage 7 | -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/heat-engine/nuage.repo: -------------------------------------------------------------------------------- 1 | [Nuage] 2 | name=nuage 3 | baseurl=http://url_to_nuage_repo 4 | enabled=1 5 | gpgcheck=1 6 | gpgkey=file:///tmp/RPM-GPG-KEY-Nuage 7 | -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/nova-compute/nuage.repo: -------------------------------------------------------------------------------- 1 | [Nuage] 2 | name=nuage 3 | baseurl=http://url_to_nuage_repo 4 | enabled=1 5 | gpgcheck=1 6 | gpgkey=file:///tmp/RPM-GPG-KEY-Nuage 7 | -------------------------------------------------------------------------------- /nuage-rpms/nuage-puppet-modules-16.1-20.10.1_40.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-puppet-modules-16.1-20.10.1_40.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-puppet-modules-16.1-20.10.2_42.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-puppet-modules-16.1-20.10.2_42.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-puppet-modules-16.1-20.10.3_44.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-puppet-modules-16.1-20.10.3_44.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-puppet-modules-16.1-20.10.4_53.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-puppet-modules-16.1-20.10.4_53.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-puppet-modules-16.1-20.10.5_54.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-puppet-modules-16.1-20.10.5_54.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-puppet-modules-16.1-20.10.6_57.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-puppet-modules-16.1-20.10.6_57.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-puppet-modules-16.1-20.10.7_59.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-puppet-modules-16.1-20.10.7_59.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-puppet-modules-16.1-20.5.2_38.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-puppet-modules-16.1-20.5.2_38.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-puppet-modules-16.1-20.5.3_39.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-puppet-modules-16.1-20.5.3_39.noarch.rpm -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/neutron-server/nuage.repo: -------------------------------------------------------------------------------- 1 | [Nuage] 2 | name=nuage 3 | baseurl=http://url_to_nuage_repo 4 | enabled=1 5 | gpgcheck=1 6 | gpgkey=file:///tmp/RPM-GPG-KEY-Nuage 7 | -------------------------------------------------------------------------------- /nuage-rpms/nuage-puppet-modules-16.2-20.10.13_63.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-puppet-modules-16.2-20.10.13_63.noarch.rpm -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/neutron-openvswitch-agent/nuage.repo: -------------------------------------------------------------------------------- 1 | [Nuage] 2 | name=nuage 3 | baseurl=http://url_to_nuage_repo 4 | enabled=1 5 | gpgcheck=1 6 | gpgkey=file:///tmp/RPM-GPG-KEY-Nuage 7 | -------------------------------------------------------------------------------- /nuage-rpms/nuage-image-patching-scripts-16.1-20.10.1_309.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-image-patching-scripts-16.1-20.10.1_309.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-image-patching-scripts-16.1-20.10.1_317.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-image-patching-scripts-16.1-20.10.1_317.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-image-patching-scripts-16.1-20.10.1_327.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-image-patching-scripts-16.1-20.10.1_327.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-image-patching-scripts-16.1-20.10.2_377.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-image-patching-scripts-16.1-20.10.2_377.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-image-patching-scripts-16.1-20.10.3_423.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-image-patching-scripts-16.1-20.10.3_423.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-image-patching-scripts-16.1-20.10.4_480.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-image-patching-scripts-16.1-20.10.4_480.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-image-patching-scripts-16.1-20.10.5_551.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-image-patching-scripts-16.1-20.10.5_551.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-image-patching-scripts-16.1-20.10.6_631.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-image-patching-scripts-16.1-20.10.6_631.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-image-patching-scripts-16.1-20.10.7_722.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-image-patching-scripts-16.1-20.10.7_722.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-image-patching-scripts-16.1-20.5.2_191.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-image-patching-scripts-16.1-20.5.2_191.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-image-patching-scripts-16.1-20.5.3_231.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-image-patching-scripts-16.1-20.5.3_231.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-image-patching-scripts-16.2-20.10.9_912.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-image-patching-scripts-16.2-20.10.9_912.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.1_309.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.1_309.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.1_317.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.1_317.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.1_327.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.1_327.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.2_377.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.2_377.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.3_423.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.3_423.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.4_480.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.4_480.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.5_551.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.5_551.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.6_631.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.6_631.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.7_722.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-tripleo-heat-templates-16.1-20.10.7_722.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-tripleo-heat-templates-16.1-20.5.2_191.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-tripleo-heat-templates-16.1-20.5.2_191.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-tripleo-heat-templates-16.1-20.5.3_231.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-tripleo-heat-templates-16.1-20.5.3_231.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-tripleo-heat-templates-16.2-20.10.9_912.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-tripleo-heat-templates-16.2-20.10.9_912.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-image-patching-scripts-16.2-20.10.13_1248.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-image-patching-scripts-16.2-20.10.13_1248.noarch.rpm -------------------------------------------------------------------------------- /nuage-rpms/nuage-tripleo-heat-templates-16.2-20.10.13_1248.noarch.rpm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nuagenetworks/nuage-ospdirector/HEAD/nuage-rpms/nuage-tripleo-heat-templates-16.2-20.10.13_1248.noarch.rpm -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/horizon/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM :8787/rhosp-rhel8/openstack-horizon: 2 | 3 | COPY RPM-GPG-KEY-Nuage /tmp/RPM-GPG-KEY-Nuage 4 | COPY nuage.repo /etc/yum.repos.d/nuage.repo 5 | RUN yum -y install --disablerepo "*" --enablerepo Nuage nuage-openstack-horizon nuage-openstack-neutronclient && yum clean all 6 | -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/nova-compute/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM :8787/rhosp-rhel8/nova-compute: 2 | 3 | USER root 4 | 5 | COPY RPM-GPG-KEY-Nuage /tmp/RPM-GPG-KEY-Nuage 6 | COPY nuage.repo /etc/yum.repos.d/nuage.repo 7 | RUN yum install --disablerepo "*" --enablerepo Nuage fp-vdev-remote os-vif-6wind-plugin -y && yum clean all 8 | 9 | USER nova 10 | -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/heat-api/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM :8787/rhosp-rhel8/openstack-heat-api: 2 | 3 | USER root 4 | 5 | COPY RPM-GPG-KEY-Nuage /tmp/RPM-GPG-KEY-Nuage 6 | COPY nuage.repo /etc/yum.repos.d/nuage.repo 7 | RUN yum -y install --disablerepo "*" --enablerepo Nuage nuage-openstack-neutronclient && yum clean all 8 | 9 | 10 | USER heat 11 | -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/heat-api-cfn/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM :8787/rhosp-rhel8/openstack-heat-api-cfn: 2 | 3 | USER root 4 | 5 | COPY RPM-GPG-KEY-Nuage /tmp/RPM-GPG-KEY-Nuage 6 | COPY nuage.repo /etc/yum.repos.d/nuage.repo 7 | RUN yum -y install --disablerepo "*" --enablerepo Nuage nuage-openstack-neutronclient && yum clean all 8 | 9 | 10 | USER heat 11 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/environments/net-single-nic-hw-offload.yaml: -------------------------------------------------------------------------------- 1 | resource_registry: 2 | # Port assignments for the Controller 3 | OS::TripleO::Controller::Net::SoftwareConfig: ../network/config/single-nic-hw-offload/controller.yaml 4 | # Port assignments for the ComputeOvrs 5 | OS::TripleO::ComputeOvrs::Net::SoftwareConfig: ../network/config/single-nic-hw-offload/computeovrs.yaml -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/neutron-openvswitch-agent/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM :8787/rhosp-rhel8/openstack-neutron-openvswitch-agent: 2 | 3 | USER root 4 | 5 | COPY RPM-GPG-KEY-Nuage /tmp/RPM-GPG-KEY-Nuage 6 | COPY nuage.repo /etc/yum.repos.d/nuage.repo 7 | RUN yum install --disablerepo "*" --enablerepo Nuage fp-vdev-remote networking-6wind -y && yum clean all 8 | 9 | USER neutron 10 | -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/heat-engine/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM :8787/rhosp-rhel8/openstack-heat-engine: 2 | 3 | USER root 4 | 5 | COPY RPM-GPG-KEY-Nuage /tmp/RPM-GPG-KEY-Nuage 6 | COPY nuage.repo /etc/yum.repos.d/nuage.repo 7 | 8 | RUN yum -y install --disablerepo "*" --enablerepo Nuage nuage-openstack-heat nuage-openstack-neutronclient && yum clean all 9 | 10 | 11 | 12 | USER heat 13 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/scripts/pull_nuage_containers/nuage_local_registry_images.yaml.j2: -------------------------------------------------------------------------------- 1 | container_images: 2 | {%- for image in nuage_config.nuage_images %} 3 | - imagename: {{ nuage_config['registry_url'] }}/nuagenetworks/rhosp{{ nuage_config['version'] }}-openstack-{{ image }}-{{ nuage_config['release'] }}:{{ nuage_config['tag'] }} 4 | push_destination: {{ nuage_config['local_registry'] }} 5 | {%- endfor %} 6 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # OSP Director Integration with Nuage 2 | 3 | This repository provides information, architecture, and deployment steps for integrating Red Hat OpenStack Platform Director (OSPD) with Nuage VSP. 4 | 5 | All the Nuage OSPD integration artifacts are released as github releases. You can download corresponding **tar.gz** files for specific nuage release at [Release](https://github.com/nuagenetworks/nuage-ospdirector/releases) 6 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright 2013-2020 Nokia 2 | 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, software 10 | distributed under the License is distributed on an "AS IS" BASIS, 11 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | See the License for the specific language governing permissions and 13 | limitations under the License. -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/environments/mellanox-environment.yaml: -------------------------------------------------------------------------------- 1 | parameter_defaults: 2 | ################ 3 | # Nic's params # 4 | ################ 5 | MellanoxTenantPort1: "ens15f0" 6 | MellanoxTenantPort2: "ens15f1" 7 | 8 | ######################## 9 | # FIRST Boot FW config # 10 | ######################## 11 | 12 | BIN_DIR_URL: "http://192.168.24.1/FW_16_25_0310/" 13 | NUM_OF_VFS: 64 14 | SRIOV_EN: True 15 | ESWITCH_IPV4_TTL_MODIFY_ENABLE: True 16 | PRIO_TAG_REQUIRED_EN: True 17 | DEV_WHITE_LIST: [] 18 | ESWITCH_HAIRPIN_TOT_BUFFER_SIZE: {"*": "17"} 19 | ESWITCH_HAIRPIN_DESCRIPTORS: {"*": "11"} 20 | -------------------------------------------------------------------------------- /nuage-ospd16-dockerfiles/neutron-server/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM :8787/rhosp-rhel8/openstack-neutron-server-ovn: 2 | 3 | USER root 4 | 5 | COPY RPM-GPG-KEY-Nuage /tmp/RPM-GPG-KEY-Nuage 6 | COPY nuage.repo /etc/yum.repos.d/nuage.repo 7 | RUN yum install --disablerepo "*" --enablerepo Nuage nuage-openstack-neutron nuage-openstack-neutronclient fp-vdev-remote networking-6wind -y && yum clean all 8 | 9 | 10 | #RUN mkdir -p /opt/nuage_upgrade 11 | #WORKDIR /opt/nuage_upgrade 12 | #COPY nuage-openstack-upgrade-6.0.5-174.tar.gz . 13 | #RUN tar -xzf nuage-openstack-upgrade-6.0.5-174.tar.gz 14 | #WORKDIR / 15 | 16 | USER neutron 17 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/scripts/pull_nuage_containers/nuage_container_config.yaml: -------------------------------------------------------------------------------- 1 | # OpenStack version number 2 | version: 16 3 | # Registry used for pulling AVRS container images 4 | # Currently supported values are [registry.connect.redhat.com] 5 | registry_url: registry.connect.redhat.com 6 | # Nuage Release and format is -- 7 | # for exmaple: Nuage release 20-10-6 please enter following 8 | release: 20-10-6 9 | # Tag for AVRS container images 10 | tag: latest 11 | # Undercloud Local Registry Hostname:Port, in a default deployment it should look like: .ctlplane.localdomain:8787 12 | local_registry: undercloud.ctlplane.localdomain:8787 13 | # List of AVRS containers 14 | nuage_images: ['nova-compute', 'neutron-openvswitch-agent'] 15 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/environments/nova-nuage-config.yaml: -------------------------------------------------------------------------------- 1 | # Heat environment file which can be used to enable 2 | # Nuage backend on the compute, configured via puppet 3 | parameter_defaults: 4 | NuageActiveController: '192.168.24.120' 5 | NuageStandbyController: '0.0.0.0' 6 | NuageBridgeMTU: '9000' 7 | NovaIPv6: 'True' 8 | NuageMetadataProxySharedSecret: 'NuageNetworksSharedSecret' 9 | NuageNovaApiEndpoint: 'internalURL' 10 | NovaOVSBridge: 'alubr0' 11 | NovaComputeLibvirtType: 'kvm' 12 | NovaComputeLibvirtVifDriver: 'nova.virt.libvirt.vif.LibvirtGenericVIFDriver' 13 | # VrsExtraConfigs can be used to configure extra parameters in /etc/default/openvswitch 14 | # For example to set "NETWORK_UPLINK_INTF" see below sample: 15 | # VrsExtraConfigs: {"NETWORK_UPLINK_INTF": "eno1"} 16 | VrsExtraConfigs: {} 17 | NuageGpgKeys: [] -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/scripts/pull_nuage_containers/nuage_overcloud_images.yaml.j2: -------------------------------------------------------------------------------- 1 | parameter_defaults: 2 | {% if 'nova-compute' in nuage_config['nuage_images'] %} 3 | ContainerNovaComputeAvrsImage: {{ nuage_config['local_registry'] }}/nuagenetworks/rhosp{{ nuage_config['version'] }}-openstack-nova-compute-{{ nuage_config['release'] }}:{{ nuage_config['tag'] }} 4 | ContainerNovaLibvirtAvrsConfigImage: {{ nuage_config['local_registry'] }}/nuagenetworks/rhosp{{ nuage_config['version'] }}-openstack-nova-compute-{{ nuage_config['release'] }}:{{ nuage_config['tag'] }} 5 | {% endif %} 6 | {% if 'neutron-openvswitch-agent' in nuage_config['nuage_images'] %} 7 | ContainerNeutronFastpathImage: {{ nuage_config['local_registry'] }}/nuagenetworks/rhosp{{ nuage_config['version'] }}-openstack-neutron-openvswitch-agent-{{ nuage_config['release'] }}:{{ nuage_config['tag'] }} 8 | {% endif %} 9 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/environments/net-bond-with-vlans.yaml: -------------------------------------------------------------------------------- 1 | resource_registry: 2 | # Network Interface templates to use (these files must exist). You can 3 | # override these by including one of the net-*.yaml environment files, 4 | # such as net-bond-with-vlans.yaml, or modifying the list here. 5 | # Port assignments for the Controller 6 | OS::TripleO::Controller::Net::SoftwareConfig: 7 | ../network/config/bond-with-vlans/controller.yaml 8 | # Port assignments for the Compute 9 | OS::TripleO::Compute::Net::SoftwareConfig: 10 | ../network/config/bond-with-vlans/compute.yaml 11 | # Port assignments for the ComputeSriov 12 | OS::TripleO::ComputeSriov::Net::SoftwareConfig: 13 | ../network/config/bond-with-vlans/computesriov.yaml 14 | # Port assignments for the ComputeOvrs 15 | OS::TripleO::ComputeOvrs::Net::SoftwareConfig: ../network/config/bond-with-vlans/computeovrs.yaml 16 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/scripts/generate-cms-id/README.md: -------------------------------------------------------------------------------- 1 | GENERATE CMS ID 2 | ---------------- 3 | 4 | Steps: 5 | 6 | 1. Copy the folder to a machine typically the Director Node (Undercloud Machine) that can reach VSD. 7 | 8 | 2. From the folder run the following command to generate CMS\_ID: 9 | 10 | ``` 11 | python configure\_vsd\_cms\_id.py --server : --serverauth : --organization --auth\_resource /me --serverssl True --base\_uri /nuage/api/" 12 | ``` 13 | 14 | Example command : 15 | ``` 16 | "python configure_vsd_cms_id.py --server 0.0.0.0:0 --serverauth username:password --organization organization --auth_resource /me --serverssl True --base_uri /nuage/api/v6" 17 | ``` 18 | 19 | 20 | 3 . The CMS ID will be displayed on the terminal as well as a copy of it will be stored in a file "cms\_id.txt" in the same folder. 21 | -------------------------------------------------------------------------------- /image-patching/setup.py: -------------------------------------------------------------------------------- 1 | # Copyright 2020 NOKIA 2 | # 3 | # Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | # not use this file except in compliance with the License. You may obtain 5 | # a copy of the License at 6 | # 7 | # http://www.apache.org/licenses/LICENSE-2.0 8 | # 9 | # Unless required by applicable law or agreed to in writing, software 10 | # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | # License for the specific language governing permissions and limitations 13 | # under the License. 14 | 15 | import setuptools 16 | 17 | 18 | # In python < 2.7.4, a lazy loading of package `pbr` will break 19 | # setuptools if some other modules registered functions in `atexit`. 20 | # solution from: http://bugs.python.org/issue15881#msg170215 21 | try: 22 | import multiprocessing # noqa 23 | 24 | except ImportError: 25 | pass 26 | 27 | setuptools.setup( 28 | setup_requires=['pbr'], 29 | pbr=True) 30 | -------------------------------------------------------------------------------- /image-patching/setup.cfg: -------------------------------------------------------------------------------- 1 | [metadata] 2 | name = nuage-image-patching-scripts 3 | summary = "Nuage OSPD Image Patching for Nuage Networks" 4 | author = Nuage Networks / NOKIA 5 | author-email = info@nuagenetworks.net 6 | home-page = http://www.nuagenetworks.net 7 | license = ASL 2.0 8 | classifier = 9 | Environment :: OpenStack 10 | Intended Audience :: Information Technology 11 | Intended Audience :: System Administrators 12 | License :: OSI Approved :: Apache Software License 13 | Operating System :: POSIX :: Linux 14 | Programming Language :: Python 15 | Programming Language :: Python :: 2 16 | Programming Language :: Python :: 2.7 17 | Programming Language :: Python :: 3 18 | Programming Language :: Python :: 3.6 19 | 20 | [files] 21 | packages = 22 | nuage_image_patching_scripts 23 | data_files = 24 | /etc/nuage-image-patching = nuage_image_patching_scripts/nuage_repo.sample 25 | /etc/nuage-image-patching = nuage_image_patching_scripts/nuage_patching_config.yaml 26 | 27 | [entry_points] 28 | console_scripts = 29 | nuage-image-patching = nuage_image_patching_scripts.nuage_overcloud_full_patch:main 30 | -------------------------------------------------------------------------------- /image-patching/nuage_image_patching_scripts/nuage_repo.sample: -------------------------------------------------------------------------------- 1 | ######################################################################################################################## 2 | ############## Repositories which user want to enable by default on the overcloud image while patching ################# 3 | ######################################################################################################################## 4 | 5 | # This repo should contain following packages: 6 | # nuage-puppet-modules 7 | # python-openvswitch-nuage 8 | # selinux-policy-nuage 9 | # nuage-bgp 10 | # nuage-openstack-neutronclient 11 | # nuage-openvswitch 12 | # nuage-metadata-agent 13 | [nuage] 14 | name=nuage_osp16 15 | baseurl=http:///nuage_osp16/nuage_repo 16 | enabled=1 17 | gpgcheck=1 18 | 19 | # These are some placeholder for some other repos that user want to enable for these packages. 20 | # This repo should contain following packages: 21 | # libvirt 22 | # perl-JSON 23 | # python2 24 | # python3-httplib2 25 | # python2-ipaddress 26 | [extra] 27 | name=satellite 28 | baseurl=http://satellite.com/extra_repo 29 | enabled=1 30 | gpgcheck=1 31 | -------------------------------------------------------------------------------- /.zuul.yaml: -------------------------------------------------------------------------------- 1 | - project: 2 | check: 3 | jobs: 4 | - nuage-ospd-deployment-16-patch-localmirror-vrs 5 | - nuage-ospd-tempest-16-patch-localmirror-vrs 6 | gate: 7 | jobs: 8 | - nuage-ospd-deployment-16-patch-localmirror-vrs 9 | - nuage-ospd-tempest-16-patch-localmirror-vrs 10 | 11 | - job: 12 | name: nuage-ospd-deployment-16-patch-localmirror-vrs 13 | branches: .* 14 | parent: ospd-deployment-16-patch-localmirror-vrs 15 | provides: nuage-ospd-deployment-16-patch-localmirror-vrs 16 | description: | 17 | Integrated gate job for OSPD 16 using a virtual undercloud and overcloud. 18 | nodeset: openstack-single-node-rhel7 19 | irrelevant-files: (.+\.rst)|(.+\.md)|(.+\.cfg)|(.+\.spec)|(.+setup\.py)|(.+LICENSE)|(.+PNG)|(.+png)|(.+JPEG)|(.+jpeg) 20 | 21 | - job: 22 | name: nuage-ospd-tempest-16-patch-localmirror-vrs 23 | parent: ospd-tempest-16-patch-localmirror-vrs 24 | dependencies: nuage-ospd-deployment-16-patch-localmirror-vrs 25 | requires: nuage-ospd-deployment-16-patch-localmirror-vrs 26 | branches: .* 27 | irrelevant-files: (.+\.rst)|(.+\.md)|(.+\.cfg)|(.+\.spec)|(.+setup\.py)|(.+LICENSE)|(.+PNG)|(.+png)|(.+JPEG)|(.+jpeg) 28 | 29 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/environments/compute-avrs-environment.yaml: -------------------------------------------------------------------------------- 1 | parameter_defaults: 2 | # An array of filters used by Nova to filter a node.These filters will be applied in the order they are listed, 3 | # so place your most restrictive filters first to make the filtering process more efficient. 4 | NovaSchedulerDefaultFilters: "RetryFilter,AvailabilityZoneFilter,ComputeFilter,ComputeCapabilitiesFilter,ImagePropertiesFilter,ServerGroupAntiAffinityFilter,ServerGroupAffinityFilter,PciPassthroughFilter,NUMATopologyFilter,AggregateInstanceExtraSpecsFilter" 5 | NeutronFastpathOptVolumes: 6 | - /run/fp_rpcd:/run/fp_rpcd 7 | ComputeAvrsParameters: 8 | KernelArgs: "default_hugepagesz=1G hugepagesz=1G hugepages=64 iommu=pt intel_iommu=on isolcpus=1-7,9-15" 9 | NovaComputeCpuSharedSet: [2-7] 10 | NovaComputeCpuDedicatedSet: [10-15] 11 | FastPathNics: "0000:06:00.1 0000:06:00.2" 12 | FastPathMask: "1,9" 13 | FastPathNicDescriptors: "--rx-cp-filter-mode=phys:dedicated-queue,virt:software-filter,excp:software-filter --tx-cp-filter-mode=all:software-filter --cp-filter-cpu-budget=10 --nb-rxd=4096 --nb-txd=4096 --rx-cp-filter-threshold=all:75% --tx-cp-filter-threshold=all:75%" 14 | FastPathOptions: "--mod-opt=fp-vswitch:--flows=40000 --max-nfct=500000" 15 | VmMemory: "auto" 16 | NbMbuf: "+65536" 17 | FastPathMemory: "auto" 18 | FastPathOffload: "off" 19 | 20 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates.spec.in: -------------------------------------------------------------------------------- 1 | Name: nuage-tripleo-heat-templates 2 | Summary: Heat templates for Nuage integration with TripleO 3 | # version will be edited by jenkins build script 4 | Version: @VERSION@ 5 | Release: %{release} 6 | License: ASL 2.0 7 | Group: System Environment/Base 8 | URL: https://github.com/nuagenetworks/nuage-ospdirector/tree/OSPD16/README.md 9 | Source: nuage-tripleo-heat-templates.tar.gz 10 | 11 | BuildArch: noarch 12 | Requires: python3-pyyaml 13 | Requires: openstack-tripleo-heat-templates 14 | 15 | %description 16 | Nuage OpenStack TripleO Heat Templates is a collection of templates and tools for 17 | building Heat Templates to do deployments of OpenStack with Nuage integration. 18 | 19 | %prep 20 | %setup -q -n nuage-tripleo-heat-templates 21 | 22 | %install 23 | install -d -m 755 %{buildroot}/%{_datadir}/%{name} 24 | cp -ar deployment %{buildroot}/%{_datadir}/%{name} 25 | cp -ar environments %{buildroot}/%{_datadir}/%{name} 26 | cp -ar firstboot %{buildroot}/%{_datadir}/%{name} 27 | cp -ar network %{buildroot}/%{_datadir}/%{name} 28 | cp -ar roles %{buildroot}/%{_datadir}/%{name} 29 | cp -ar scripts %{buildroot}/%{_datadir}/%{name} 30 | cp -ar LICENSE %{buildroot}/%{_datadir}/%{name} 31 | cp -ar nuage-overcloud-resource-registry.yaml %{buildroot}/%{_datadir}/%{name} 32 | 33 | %clean 34 | rm -rf $RPM_BUILD_ROOT 35 | 36 | %files 37 | %{_datadir}/%{name} -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/environments/ovs-hw-offload.yaml: -------------------------------------------------------------------------------- 1 | # A Heat environment file that enables OVS Hardware Offload in the overcloud. 2 | 3 | parameter_defaults: 4 | 5 | NovaSchedulerDefaultFilters: ['RetryFilter','AvailabilityZoneFilter','ComputeFilter','ComputeCapabilitiesFilter','ImagePropertiesFilter','ServerGroupAntiAffinityFilter','ServerGroupAffinityFilter','PciPassthroughFilter'] 6 | NovaSchedulerAvailableFilters: ["nova.scheduler.filters.all_filters","nova.scheduler.filters.pci_passthrough_filter.PciPassthroughFilter"] 7 | 8 | # Kernel arguments for ComputeOvrs node 9 | ComputeOvrsParameters: 10 | KernelArgs: "intel_iommu=on iommu=pt hugepagesz=1G hugepages=32 default_hugepagesz=1G pci=realloc" 11 | #NOTE: By default TunedProfileName is set to "cpu-partitioning" in ovrs-role.yaml. 12 | # If IsolCpusList is not set in your environment, then leave TunedProfileName below to set to empty string. 13 | # If planning on setting IsolCpusList in your environment 14 | # 1. You can comment the below line to set TunedProfileName to "cpu-partitioning" or 15 | # 2. You can pass your custom Tuned Profile to apply to the host 16 | TunedProfileName: "" 17 | OvsHwOffload: True 18 | # Mapping of SR-IOV PF interface to neutron physical_network. 19 | # In case of Vxlan/GRE physical_network should be null. 20 | # In case of flat/vlan the physical_network should as configured in neutron. 21 | NovaPCIPassthrough: 22 | - devname: "ens15f0" 23 | physical_network: null 24 | - devname: "ens15f1" 25 | physical_network: null -------------------------------------------------------------------------------- /image-patching/nuage_image_patching_scripts/nuage_patching_config.yaml: -------------------------------------------------------------------------------- 1 | # Absolute path and name of qcow2 image 2 | # type: string 3 | # required 4 | ImageName: "/root/overcloud-full.qcow2" 5 | 6 | # DeploymentType for your Deployment 7 | # type: string 8 | # required ( Please choose one of them ) 9 | # Eg: ["avrs"] --> AVRS + VRS/OVRS/SRIOV deployment 10 | # ["vrs"] --> VRS/OVRS/SRIOV deployment 11 | DeploymentType: ["vrs"] 12 | 13 | # User name for RHEL Subscription 14 | # type: string 15 | # optional 16 | RhelUserName: '' 17 | 18 | # Password for the RHEL Subscription 19 | # type: string 20 | # optional 21 | RhelPassword: '' 22 | 23 | # Pool to subscribe to for base packages, if deployment type is AVRS, than 24 | # this should be a pool id with access to OpenStack 16.x RPM's repository 25 | # type: string 26 | # optional 27 | RhelPool: '' 28 | 29 | # URL for RHEL Satellite Server 30 | # type: string 31 | # optional 32 | RhelSatUrl: '' 33 | 34 | # Organization for RHEL Satellite Subscription 35 | # type: string 36 | # optional 37 | RhelSatOrg: '' 38 | 39 | # Activation key for RHEL Satellite Subscription 40 | # type: string 41 | # optional 42 | RhelSatActKey: '' 43 | 44 | # Absolute path and filename of RPM GPG Key(s) 45 | # type: list 46 | # optional 47 | RpmPublicKey: [] 48 | 49 | # Absolute path and filename of Repo File 50 | # type: string 51 | # required 52 | RepoFile: '' 53 | 54 | # Log file name 55 | # type: string 56 | # optional 57 | logFileName: "nuage_image_patching.log" 58 | 59 | # If you are behind Proxy you can enter Proxy Server information here 60 | # type: string 61 | # optional 62 | ProxyHostname: '' 63 | ProxyPort: '' 64 | -------------------------------------------------------------------------------- /image-patching/nuage_image_patching_scripts/utils/constants.py: -------------------------------------------------------------------------------- 1 | # !/usr/bin/python3 2 | # Copyright 2020,2021 NOKIA 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an 12 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, 13 | # either express or implied. See the License for the specific 14 | # language governing permissions and limitations under the License. 15 | 16 | # List of Nuage packages 17 | NUAGE_PYTHON_OVS = "python-openvswitch-nuage" 18 | NUAGE_AVRS_PACKAGE = "nuage-openvswitch-6wind" 19 | NUAGE_PACKAGES = "nuage-puppet-modules " \ 20 | "nuage-openstack-neutronclient " \ 21 | "selinux-policy-nuage nuage-bgp" 22 | NUAGE_DEPENDENCIES = "python2 perl-JSON python3-httplib2 " \ 23 | "libvirt mstflint" 24 | 25 | NUAGE_VRS_PACKAGE = "nuage-openvswitch nuage-metadata-agent" 26 | VIRT_CUSTOMIZE_MEMSIZE = "2048" 27 | VIRT_CUSTOMIZE_ENV = "export LIBGUESTFS_BACKEND=direct;" 28 | PATCHING_SCRIPT = '' 29 | SCRIPT_NAME = 'patching_script.sh' 30 | TEMPORARY_PATH = '/tmp/' 31 | LOG_FILE_NAME = 'nuage_image_patching.log' 32 | VALID_DEPLOYMENT_TYPES = ['vrs', 'avrs'] 33 | RHEL_SUB_PORTAL = "portal" 34 | RHEL_SUB_SATELLITE = "satellite" 35 | RHEL_SUB_DISABLED = "disabled" 36 | RHOSP_VERSION = "16.1" 37 | RHEL_VERSION = '8.2' 38 | DNF_VERSION_CONTAINER_TOOLS = '2.0' 39 | DNF_VERSION_VIRT = '8.2' 40 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/nuage-overcloud-resource-registry.yaml: -------------------------------------------------------------------------------- 1 | resource_registry: 2 | # Below services are disabled on Controller for neutron_driver: null 3 | OS::TripleO::Services::NeutronDhcpAgent: OS::Heat::None 4 | OS::TripleO::Services::NeutronL3Agent: OS::Heat::None 5 | OS::TripleO::Services::NeutronMetadataAgent: OS::Heat::None 6 | OS::TripleO::Services::NeutronOvsAgent: OS::Heat::None 7 | 8 | # Below services are disabled on Controller for neutron_driver: ovn 9 | OS::TripleO::Services::OVNDBs: OS::Heat::None 10 | OS::TripleO::Services::OVNController: OS::Heat::None 11 | 12 | # Override the NeutronMl2PluginBase to use Nuage inside Docker container 13 | OS::TripleO::Docker::NeutronMl2PluginBase: deployment/neutron/neutron-plugin-ml2-nuage.yaml 14 | OS::TripleO::Services::NeutronCorePlugin: deployment/neutron/neutron-plugin-ml2-nuage-container-puppet.yaml 15 | 16 | # Below services are disabled on Compute for Nuage OpenvSwitch 17 | OS::TripleO::Services::OVNMetadataAgent: OS::Heat::None 18 | OS::TripleO::Services::ComputeNeutronOvsAgent: OS::Heat::None 19 | 20 | # Override the ComputeNeutronCorePlugin to use Nuage OpenvSwitch on compute nodes 21 | OS::TripleO::Services::ComputeNeutronCorePlugin: deployment/nova/nuage-compute-vrs.yaml 22 | 23 | # OVRS resources 24 | OS::TripleO::Services::NuageComputeOvrs: deployment/nova/nuage-compute-vrs.yaml 25 | OS::TripleO::ComputeOvrs::NodeUserData: firstboot/mellanox_fw_update.yaml 26 | 27 | # AVRS resources 28 | OS::TripleO::Services::ComputeNeutronCorePluginNuage: deployment/nova/neutron-compute-plugin-nuage.yaml 29 | OS::TripleO::Services::ComputeNeutronFastpathAgent: deployment/neutron/neutron-fastpath-agent.yaml 30 | OS::TripleO::Services::NovaComputeAvrs: deployment/nova/nuage-compute-avrs.yaml 31 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/environments/compute-avrs-multirole-environment.yaml: -------------------------------------------------------------------------------- 1 | parameter_defaults: 2 | NovaSchedulerDefaultFilters: "RetryFilter,AvailabilityZoneFilter,ComputeFilter,ComputeCapabilitiesFilter,ImagePropertiesFilter,ServerGroupAntiAffinityFilter,ServerGroupAffinityFilter,PciPassthroughFilter,NUMATopologyFilter,AggregateInstanceExtraSpecsFilter" 3 | NeutronFastpathOptVolumes: 4 | - /run/fp_rpcd:/run/fp_rpcd 5 | ComputeAvrsSingleParameters: 6 | KernelArgs: "default_hugepagesz=1G hugepagesz=1G hugepages=64 iommu=pt intel_iommu=on isolcpus=1-7" 7 | NovaComputeCpuSharedSet: [2-4] 8 | NovaComputeCpuDedicatedSet: [5-7] 9 | FastPathNics: "0000:06:00.1 0000:06:00.2" 10 | FastPathMask: "1" 11 | FastPathNicDescriptors: "--rx-cp-filter-mode=phys:dedicated-queue,virt:software-filter,excp:software-filter --tx-cp-filter-mode=all:software-filter --cp-filter-cpu-budget=10 --nb-rxd=4096 --nb-txd=4096 --rx-cp-filter-threshold=all:75% --tx-cp-filter-threshold=all:75%" 12 | FastPathOptions: "--mod-opt=fp-vswitch:--flows=40000 --max-nfct=500000" 13 | VmMemory: "auto" 14 | NbMbuf: "+65536" 15 | FastPathMemory: "auto" 16 | FastPathOffload: "off" 17 | 18 | ComputeAvrsDualParameters: 19 | KernelArgs: "default_hugepagesz=1G hugepagesz=1G hugepages=64 iommu=pt intel_iommu=on isolcpus=1-7,9-15" 20 | NovaComputeCpuSharedSet: [2-7] 21 | NovaComputeCpuDedicatedSet: [10-15] 22 | FastPathNics: "0000:06:00.1 0000:06:00.2" 23 | FastPathMask: "1,9" 24 | FastPathNicDescriptors: "--rx-cp-filter-mode=phys:dedicated-queue,virt:software-filter,excp:software-filter --tx-cp-filter-mode=all:software-filter --cp-filter-cpu-budget=10 --nb-rxd=4096 --nb-txd=4096 --rx-cp-filter-threshold=all:75% --tx-cp-filter-threshold=all:75%" 25 | FastPathOptions: "--mod-opt=fp-vswitch:--flows=40000 --max-nfct=500000" 26 | VmMemory: "auto" 27 | NbMbuf: "+65536" 28 | FastPathMemory: "auto" 29 | FastPathOffload: "off" 30 | 31 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/environments/containers-prepare-parameter.yaml: -------------------------------------------------------------------------------- 1 | parameter_defaults: 2 | NtpServer: ['135.1.1.111'] 3 | ContainerImageRegistryCredentials: 4 | registry.redhat.io: 5 | : "" 6 | registry.connect.redhat.com: 7 | : "" 8 | 9 | ContainerImagePrepare: 10 | - push_destination: true 11 | set: 12 | ceph_alertmanager_image: ose-prometheus-alertmanager 13 | ceph_alertmanager_namespace: registry.redhat.io/openshift4 14 | ceph_alertmanager_tag: 4.1 15 | ceph_grafana_image: rhceph-3-dashboard-rhel7 16 | ceph_grafana_namespace: registry.redhat.io/rhceph 17 | ceph_grafana_tag: 3 18 | ceph_image: rhceph-4-rhel8 19 | ceph_namespace: registry.redhat.io/rhceph 20 | ceph_node_exporter_image: ose-prometheus-node-exporter 21 | ceph_node_exporter_namespace: registry.redhat.io/openshift4 22 | ceph_node_exporter_tag: v4.1 23 | ceph_prometheus_image: ose-prometheus 24 | ceph_prometheus_namespace: registry.redhat.io/openshift4 25 | ceph_prometheus_tag: 4.1 26 | ceph_tag: latest 27 | name_prefix: openstack- 28 | name_suffix: '' 29 | namespace: registry.redhat.io/rhosp-rhel8 30 | neutron_driver: null 31 | rhel_containers: false 32 | tag: '16.1.6' # Update to qualified z-stream for nuage release 33 | tag_from_label: '{version}-{release}' 34 | excludes: 35 | - horizon 36 | - heat-engine 37 | - heat-api-cfn 38 | - neutron-server 39 | - heat-api 40 | 41 | - push_destination: true 42 | set: 43 | name_prefix: "rhosp16-openstack-" 44 | name_suffix: "-20-10-3" # Check documentation for the correct version 45 | namespace: registry.connect.redhat.com/nuagenetworks 46 | neutron_driver: null 47 | rhel_containers: false 48 | tag: 'latest' 49 | includes: 50 | - horizon 51 | - heat-engine 52 | - heat-api-cfn 53 | - neutron-server 54 | - heat-api 55 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/environments/neutron-nuage-config.yaml: -------------------------------------------------------------------------------- 1 | # A Heat environment file which can be used to enable a 2 | # a Neutron Nuage backend on the controller, configured via puppet 3 | parameter_defaults: 4 | NeutronNuageNetPartitionName: 'default_name' 5 | NeutronNuageVSDIp: '0.0.0.0:0' 6 | NeutronNuageVSDUsername: 'username' 7 | NeutronNuageVSDPassword: 'password' 8 | NeutronNuageVSDOrganization: 'organization' 9 | NeutronNuageBaseURIVersion: 'default_uri_version' 10 | NeutronNuageCMSId: '' 11 | UseForwardedFor: true 12 | NeutronPluginMl2PuppetTags: 'neutron_plugin_ml2,neutron_plugin_nuage' 13 | NeutronServicePlugins: 'NuagePortAttributes,NuageAPI,NuageL3,trunk' 14 | NeutronDBSyncExtraParams: '--config-file /etc/neutron/neutron.conf --config-file /etc/neutron/plugins/ml2/ml2_conf.ini --config-file /etc/neutron/plugins/nuage/plugin.ini' 15 | NeutronTypeDrivers: 'vxlan' 16 | NeutronNetworkType: 'vxlan' 17 | NeutronFirewallDriver: 'noop' 18 | NeutronMechanismDrivers: "nuage" 19 | # Use below NeutronMechanismDrivers config for AVRS deployments (order is important) 20 | # NeutronMechanismDrivers: "ovs-fp,nuage" 21 | NeutronPluginExtensions: 'nuage_network,nuage_subnet,nuage_port,port_security' 22 | NeutronFlatNetworks: '*' 23 | NovaOVSBridge: 'alubr0' 24 | NeutronMetadataProxySharedSecret: 'NuageNetworksSharedSecret' 25 | NeutronTunnelIdRanges: '' 26 | NeutronNetworkVLANRanges: '' 27 | NeutronVniRanges: '1001:2000' 28 | HeatEnginePluginDirs: ['/usr/lib/python3.6/site-packages/nuage-heat/'] 29 | HorizonCustomizationModule: 'nuage_horizon.customization' 30 | HorizonVhostExtraParams: 31 | add_listen: True 32 | priority: 10 33 | access_log_format: '%a %l %u %t \"%r\" %>s %b \"%%{}{Referer}i\" \"%%{}{User-Agent}i\"' 34 | directories: [{'allow_override': ['None'], 'path': '/usr/lib/python3.6/site-packages/nuage_horizon', 'require': 'all granted', 'options': ['FollowSymLinks']}] 35 | aliases: [{'alias': '%{root_url}/static/nuage', 'path': '/usr/lib/python3.6/site-packages/nuage_horizon/static'}, {'alias': '%{root_url}/static', 'path': '/usr/share/openstack-dashboard/static'}] 36 | ControllerExtraConfig: 37 | neutron::config::server_config: 38 | DEFAULT/ipam_driver: 39 | value: nuage_internal 40 | DEFAULT/enable_snat_by_default: 41 | value: false 42 | neutron::config::plugin_nuage_config: 43 | RESTPROXY/nuage_pat: 44 | value: legacy_disabled 45 | # Enable below config for AVRS deployments 46 | # neutron::config::plugin_ml2_config: 47 | # ml2_fp/ovs_agent_required: 48 | # value: False 49 | # ml2_fp/allowed_network_types: 50 | # value: 'vxlan,gre,vlan' -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/deployment/neutron/neutron-plugin-ml2-nuage-container-puppet.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | 3 | description: > 4 | OpenStack containerized Neutron ML2 Plugin Nuage configured with Puppet 5 | 6 | parameters: 7 | EndpointMap: 8 | default: { } 9 | description: Mapping of service endpoint -> protocol. Typically set 10 | via parameter_defaults in the resource registry. 11 | type: json 12 | ServiceData: 13 | default: { } 14 | description: Dictionary packing service data 15 | type: json 16 | ServiceNetMap: 17 | default: { } 18 | description: Mapping of service_name -> network name. Typically set 19 | via parameter_defaults in the resource registry. This 20 | mapping overrides those in ServiceNetMapDefaults. 21 | type: json 22 | ContainerNeutronConfigImage: 23 | description: The container image to use for the neutron config_volume 24 | type: string 25 | DefaultPasswords: 26 | type: json 27 | RoleName: 28 | default: '' 29 | description: Role name on which the service is applied 30 | type: string 31 | RoleParameters: 32 | default: { } 33 | description: Parameters specific to the role 34 | type: json 35 | 36 | resources: 37 | 38 | NeutronBase: 39 | type: OS::TripleO::Docker::NeutronMl2PluginBase 40 | properties: 41 | EndpointMap: { get_param: EndpointMap } 42 | ServiceData: { get_param: ServiceData } 43 | ServiceNetMap: { get_param: ServiceNetMap } 44 | DefaultPasswords: { get_param: DefaultPasswords } 45 | RoleName: { get_param: RoleName } 46 | RoleParameters: { get_param: RoleParameters } 47 | 48 | NeutronContainerBase: 49 | type: /usr/share/openstack-tripleo-heat-templates/deployment/neutron/neutron-plugin-ml2-container-puppet.yaml 50 | properties: 51 | EndpointMap: { get_param: EndpointMap } 52 | ServiceData: { get_param: ServiceData } 53 | ServiceNetMap: { get_param: ServiceNetMap } 54 | DefaultPasswords: { get_param: DefaultPasswords } 55 | RoleName: { get_param: RoleName } 56 | RoleParameters: { get_param: RoleParameters } 57 | 58 | outputs: 59 | role_data: 60 | description: Role data for the Neutron ML2 Plugin Nuage role. 61 | value: 62 | service_name: { get_attr: [ NeutronContainerBase, role_data, service_name ] } 63 | config_settings: { get_attr: [ NeutronContainerBase, role_data, config_settings ] } 64 | service_config_settings: { get_attr: [ NeutronContainerBase, role_data, service_config_settings ] } 65 | metadata_settings: { get_attr: [ NeutronContainerBase, role_data, metadata_settings ] } 66 | puppet_config: { get_attr: [ NeutronContainerBase, role_data, puppet_config ] } 67 | kolla_config: { } 68 | docker_config: { } 69 | deploy_steps_tasks: { get_attr: [ NeutronBase, role_data, deploy_steps_tasks ] } 70 | update_tasks: { get_attr: [ NeutronBase, role_data, update_tasks ] } 71 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/scripts/generate-cms-id/configure_vsd_cms_id.py: -------------------------------------------------------------------------------- 1 | # Copyright 2015 Alcatel-Lucent USA Inc. 2 | # 3 | # Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | # not use this file except in compliance with the License. You may obtain 5 | # a copy of the License at 6 | # 7 | # http://www.apache.org/licenses/LICENSE-2.0 8 | # 9 | # Unless required by applicable law or agreed to in writing, software 10 | # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | # License for the specific language governing permissions and limitations 13 | # under the License. 14 | import argparse 15 | import logging 16 | import sys 17 | from uuid import getnode 18 | 19 | 20 | def get_mac(): 21 | mac = getnode() 22 | return ':'.join(("%012X" % mac)[i:i + 2] for i in range(0, 12, 2)) 23 | 24 | DEFAULT_CMS_NAME = 'OpenStack_' + get_mac() 25 | 26 | from restproxy import RESTProxyServer 27 | 28 | logging.basicConfig() 29 | logger = logging.getLogger(__name__) 30 | logger.setLevel(logging.DEBUG) 31 | logger.addHandler(logging.StreamHandler()) 32 | 33 | REST_SUCCESS_CODES = list(range(200, 207)) 34 | 35 | 36 | def init_arg_parser(): 37 | 38 | parser = argparse.ArgumentParser() 39 | parser.add_argument('--server', action='store', required=True, 40 | help='VSD IP address') 41 | parser.add_argument('--serverauth', action='store', required=True, 42 | help='VSD login username and password') 43 | parser.add_argument('--organization', action='store', required=True, 44 | help='VSD organization') 45 | parser.add_argument('--auth_resource', action='store', required=True, 46 | help='VSD auth resource') 47 | parser.add_argument('--serverssl', action='store', required=True, 48 | help='VSD Server SSL') 49 | parser.add_argument('--base_uri', action='store', required=True, 50 | help='Nuage Base URI') 51 | parser.add_argument('--name', action='store', 52 | default=DEFAULT_CMS_NAME, 53 | help='The name of the CMS to create on VSD') 54 | return parser 55 | 56 | 57 | def main(): 58 | parser = init_arg_parser() 59 | args = parser.parse_args() 60 | 61 | try: 62 | restproxy = RESTProxyServer(server=args.server, 63 | base_uri=args.base_uri, 64 | serverssl=args.serverssl, 65 | serverauth=args.serverauth, 66 | auth_resource=args.auth_resource, 67 | organization=args.organization) 68 | except Exception as e: 69 | logger.error('Error in connecting to VSD:%s' % str(e)) 70 | sys.exit(1) 71 | 72 | response = restproxy.rest_call('POST', "/cms", {'name': args.name}) 73 | if response[0] not in REST_SUCCESS_CODES: 74 | logger.error('Failed to create CMS on VSD.') 75 | sys.exit(1) 76 | 77 | cms_id = response[3][0]['ID'] 78 | cfgfile = open("cms_id.txt",'w') 79 | cfgfile.write(cms_id) 80 | cfgfile.close() 81 | logger.info("CMS ID generated by Nuage VSD: %s", cms_id) 82 | logger.info("CMS ID has also been stored in auto-generated cms_id.txt file") 83 | 84 | 85 | if __name__ == '__main__': 86 | main() 87 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/scripts/create_roles/create_all_roles.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # TODO(vandewat|Oguz|Steven) Instead of this find/replace magic let's parse yaml / modify / dump 3 | 4 | set -o errexit 5 | set -o nounset 6 | 7 | if [ "${USER}" != "stack" ]; then 8 | echo "ERROR: Run the script as \"stack\" user." 9 | exit 1 10 | fi 11 | 12 | CURRENT_DIR=$(basename $(pwd)) 13 | if [ "${CURRENT_DIR}" != "create_roles" ]; then 14 | echo "ERROR: Run the script from create_roles directory please." 15 | exit 1 16 | fi 17 | 18 | source /home/stack/stackrc 19 | 20 | # Create ComputeOvrs role 21 | echo "creating ComputeOvrs Role" 22 | mkdir -p ../../roles 23 | openstack overcloud roles generate --roles-path ../../roles -o ../../roles/ComputeOvrs.yaml ComputeSriov 24 | sed -i -e 's/ ComputeSriov/ ComputeOvrs/g' ../../roles/ComputeOvrs.yaml 25 | sed -i -e 's/ Compute SR-IOV/ ComputeOvrs/g' ../../roles/ComputeOvrs.yaml 26 | sed -i -e "s/HostnameFormatDefault: '%stackname%-computesriov-%index%'/HostnameFormatDefault: '%stackname%-computeovrs-%index%'/g" ../../roles/ComputeOvrs.yaml 27 | sed -i -e '/- OS::TripleO::Services::NeutronSriovHostConfig/d' ../../roles/ComputeOvrs.yaml 28 | sed -i -e '/- OS::TripleO::Services::NeutronSriovAgent/d' ../../roles/ComputeOvrs.yaml 29 | 30 | FILE=../../roles/ComputeOvrs.yaml 31 | if [ -f "$FILE" ]; then 32 | echo "$FILE has been created" 33 | else 34 | echo "There was some issue creating $FILE" 35 | exit 1 36 | fi 37 | 38 | echo "Complete!! Created ComputeOvrs.yaml Role files " 39 | 40 | # Create ComputeAvrs role 41 | echo "creating ComputeAvrs Role" 42 | mkdir -p ../../roles 43 | openstack overcloud roles generate --roles-path ../../roles -o ../../roles/ComputeAvrs.yaml Compute 44 | sed -i -e 's/ Compute/ ComputeAvrs/g' ../../roles/ComputeAvrs.yaml 45 | sed -i -e "s/HostnameFormatDefault: '%stackname%-novacompute-%index%'/HostnameFormatDefault: '%stackname%-novacomputeavrs-%index%'/g" ../../roles/ComputeAvrs.yaml 46 | sed -i -e 's/- OS::TripleO::Services::NovaCompute/- OS::TripleO::Services::NovaComputeAvrs/g' ../../roles/ComputeAvrs.yaml 47 | sed -i -e "s/- OS::TripleO::Services::ComputeNeutronCorePlugin/- OS::TripleO::Services::ComputeNeutronCorePluginNuage/g" ../../roles/ComputeAvrs.yaml 48 | echo " - OS::TripleO::Services::ComputeNeutronFastpathAgent" >> ../../roles/ComputeAvrs.yaml 49 | 50 | FILE=../../roles/ComputeAvrs.yaml 51 | if [ -f "$FILE" ]; then 52 | echo "$FILE has been created" 53 | else 54 | echo "There was some issue creating $FILE" 55 | exit 1 56 | fi 57 | 58 | echo "Complete!! Created ComputeAvrs.yaml Role files " 59 | 60 | 61 | # Create ComputeAvrsSingle and ComputeAvrsDual roles 62 | roles=(ComputeAvrsSingle ComputeAvrsDual) 63 | echo "creating ${roles[*]} Role" 64 | 65 | mkdir -p ../../roles 66 | for role in "${roles[@]}"; do 67 | openstack overcloud roles generate --roles-path ../../roles -o ../../roles/${role}.yaml Compute 68 | sed -i -e "s/ Compute/ ${role}/g" ../../roles/${role}.yaml 69 | sed -i -e "s/HostnameFormatDefault: '%stackname%-novacompute-%index%'/HostnameFormatDefault: '%stackname%-nova${role,,}-%index%'/g" ../../roles/${role}.yaml 70 | sed -i -e "s/- OS::TripleO::Services::NovaCompute/- OS::TripleO::Services::NovaComputeAvrs/g" ../../roles/${role}.yaml 71 | sed -i -e "s/- OS::TripleO::Services::ComputeNeutronCorePlugin/- OS::TripleO::Services::ComputeNeutronCorePluginNuage/g" ../../roles/${role}.yaml 72 | echo " - OS::TripleO::Services::ComputeNeutronFastpathAgent" >> ../../roles/${role}.yaml 73 | FILE=../../roles/${role}.yaml 74 | if [ -f "$FILE" ]; then 75 | echo "$FILE has been created" 76 | else 77 | echo "There was some issue creating $FILE" 78 | exit 1 79 | fi 80 | done 81 | 82 | echo "Complete!! Created ${roles[*]} Roles files " -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/environments/network-environment.yaml: -------------------------------------------------------------------------------- 1 | parameter_defaults: 2 | # This section is where deployment-specific configuration is done 3 | # 4 | # NOTE: (Since Rocky) 5 | # ControlPlaneSubnetCidr: It is no longer a requirement to provide the 6 | # parameter. The attribute is resolved from the 7 | # ctlplane subnet(s). 8 | # ControlPlaneDefaultRoute: It is no longer a requirement to provide this 9 | # parameter. The attribute is resolved from the 10 | # ctlplane subnet(s). 11 | # EC2MetadataIp: It is no longer a requirement to provide this parameter. The 12 | # attribute is resolved from the ctlplane subnet(s). 13 | # 14 | 15 | # Customize the IP subnet to match the local environment 16 | StorageNetCidr: '172.16.1.0/24' 17 | # Customize the IP range to use for static IPs and VIPs 18 | StorageAllocationPools: [{'start': '172.16.1.4', 'end': '172.16.1.250'}] 19 | # Customize the VLAN ID to match the local environment 20 | StorageNetworkVlanID: 30 21 | 22 | 23 | # Customize the IP subnet to match the local environment 24 | StorageMgmtNetCidr: '172.16.3.0/24' 25 | # Customize the IP range to use for static IPs and VIPs 26 | StorageMgmtAllocationPools: [{'start': '172.16.3.4', 'end': '172.16.3.250'}] 27 | # Customize the VLAN ID to match the local environment 28 | StorageMgmtNetworkVlanID: 40 29 | 30 | 31 | # Customize the IP subnet to match the local environment 32 | InternalApiNetCidr: '172.16.2.0/24' 33 | # Customize the IP range to use for static IPs and VIPs 34 | InternalApiAllocationPools: [{'start': '172.16.2.4', 'end': '172.16.2.250'}] 35 | # Customize the VLAN ID to match the local environment 36 | InternalApiNetworkVlanID: 20 37 | 38 | 39 | # Customize the IP subnet to match the local environment 40 | TenantNetCidr: '172.16.0.0/24' 41 | # Customize the IP range to use for static IPs and VIPs 42 | TenantAllocationPools: [{'start': '172.16.0.4', 'end': '172.16.0.250'}] 43 | # Customize the VLAN ID to match the local environment 44 | TenantNetworkVlanID: 50 45 | # MTU of the underlying physical network. Neutron uses this value to 46 | # calculate MTU for all virtual network components. For flat and VLAN 47 | # networks, neutron uses this value without modification. For overlay 48 | # networks such as VXLAN, neutron automatically subtracts the overlay 49 | # protocol overhead from this value. 50 | TenantNetPhysnetMtu: 1500 51 | 52 | 53 | # Customize the IP subnet to match the local environment 54 | ExternalNetCidr: '10.0.0.0/24' 55 | # Customize the IP range to use for static IPs and VIPs 56 | # Leave room if the external network is also used for floating IPs 57 | ExternalAllocationPools: [{'start': '10.0.0.4', 'end': '10.0.0.250'}] 58 | # Gateway router for routable networks 59 | ExternalInterfaceDefaultRoute: '10.0.0.1' 60 | # Customize the VLAN ID to match the local environment 61 | ExternalNetworkVlanID: 10 62 | 63 | 64 | # Customize the IP subnet to match the local environment 65 | ManagementNetCidr: '10.0.1.0/24' 66 | # Customize the IP range to use for static IPs and VIPs 67 | ManagementAllocationPools: [{'start': '10.0.1.4', 'end': '10.0.1.250'}] 68 | # Gateway router for routable networks 69 | ManagementInterfaceDefaultRoute: '10.0.1.1' 70 | # Customize the VLAN ID to match the local environment 71 | ManagementNetworkVlanID: 60 72 | 73 | 74 | # Define the DNS servers (maximum 2) for the overcloud nodes 75 | # When the list is not set or empty, the nameservers on the ctlplane subnets will be used. 76 | # (ctlplane subnets nameservers are controlled by the ``undercloud_nameservers`` option in ``undercloud.conf``) 77 | DnsServers: ['135.1.1.111'] 78 | BondInterfaceOvsOptions: "mode=active-backup" 79 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/scripts/pull_nuage_containers/nuage_container_pull.py: -------------------------------------------------------------------------------- 1 | # !/usr/bin/python 2 | # Copyright 2020 NOKIA 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); you may 5 | # not use this file except in compliance with the License. You may obtain 6 | # a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12 | # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13 | # License for the specific language governing permissions and limitations 14 | # under the License. 15 | 16 | 17 | from jinja2 import Environment, FileSystemLoader 18 | import argparse 19 | import os 20 | import sys 21 | import subprocess 22 | import yaml 23 | import logging 24 | 25 | # Logging 26 | LOGFILE="nuage_containers_pull.log" 27 | logger = logging.getLogger('') 28 | logger.setLevel(logging.DEBUG) 29 | formatter = logging.Formatter( 30 | '%(asctime)s - %(name)s - %(levelname)s - %(message)s') 31 | consoleHandler = logging.StreamHandler(sys.stdout) 32 | consoleHandler.setFormatter(formatter) 33 | logger.addHandler(consoleHandler) 34 | handler = logging.FileHandler(LOGFILE) 35 | handler.setFormatter(formatter) 36 | logger.addHandler(handler) 37 | 38 | 39 | ##### 40 | # Check if the provided path to the file exists 41 | ##### 42 | 43 | def file_exists(filename): 44 | if os.path.isfile(filename): 45 | return True 46 | else: 47 | logger.error("%s is not present in the location of this " 48 | "script" % filename) 49 | sys.exit(1) 50 | 51 | ##### 52 | # Generates nuage_overcloud_images.yaml with Nuage container names 53 | # that need to be pulld by overcloud nodes during deployment 54 | ##### 55 | 56 | def generate_nuage_overcloud_images(nuage_config): 57 | dirPath = os.path.dirname(os.path.abspath(__file__)) 58 | envPath = dirPath.split('scripts')[0] + 'environments' 59 | if not os.path.isdir(envPath): 60 | logger.error("%s directory is not present " % envPath) 61 | sys.exit(1) 62 | ENV = Environment(loader=FileSystemLoader('%s/' % dirPath)) 63 | nuage_overcloud_images_file_name = 'nuage_overcloud_images.yaml' 64 | j2_nuage_overcloud_images_file_name = \ 65 | nuage_overcloud_images_file_name + '.j2' 66 | file_exists(dirPath + '/' + j2_nuage_overcloud_images_file_name) 67 | nuage_overcloudimages_file = ENV.get_template( 68 | j2_nuage_overcloud_images_file_name) 69 | logger.info("Rendering nuage_overcloud_images.yaml file") 70 | with open('%s/%s' % (envPath, nuage_overcloud_images_file_name), 71 | 'w') as overcloud_images_file: 72 | overcloud_images_file.write(nuage_overcloudimages_file.render( 73 | nuage_config=nuage_config)) 74 | logger.info("Redering nuage_overcloud_images.yaml is completed") 75 | 76 | 77 | ##### 78 | # This function is responsible to pull Nuage container images from 79 | # Red Hat Regsitry, retag them all with registry as local registry , 80 | # push the retagged images to local regstiry and once pushing is done, 81 | # remove them all from undercloud machine. 82 | ##### 83 | 84 | def pull_retag_push_nuage_images(nuage_config): 85 | logger.info("Pulling the Nuage Container images to Local registry") 86 | for image in nuage_config['nuage_images']: 87 | image_path = '{}/nuagenetworks/rhosp{}-openstack-{}-{}:{}'.format( 88 | nuage_config['registry_url'], 89 | nuage_config['version'], 90 | image, 91 | nuage_config['release'], 92 | nuage_config['tag']) 93 | pull_cmd = 'podman pull {}'.format(image_path) 94 | 95 | subprocess.call(pull_cmd, shell=True) 96 | 97 | push_cmd = 'sudo openstack tripleo container image push {} ' \ 98 | '--registry-url {} --local'.format( 99 | image_path, 100 | nuage_config['local_registry']) 101 | subprocess.call(push_cmd, shell=True) 102 | 103 | 104 | def main(): 105 | parser = argparse.ArgumentParser() 106 | parser.add_argument("--nuage-config", dest="nuage_config", 107 | type=str, required=True, 108 | help="path to nuage_container_config.yaml") 109 | args = parser.parse_args() 110 | 111 | with open(args.nuage_config) as nuage_config: 112 | nuage_config = yaml.load(nuage_config) 113 | 114 | generate_nuage_overcloud_images(nuage_config) 115 | pull_retag_push_nuage_images(nuage_config) 116 | 117 | 118 | if __name__ == "__main__": 119 | main() 120 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/network/config/single-nic-hw-offload/computeovrs.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | description: > 3 | Software Config to drive os-net-config to configure multiple interfaces for the ComputeOvrs role. 4 | parameters: 5 | ControlPlaneIp: 6 | default: '' 7 | description: IP address/subnet on the ctlplane network 8 | type: string 9 | StorageIpSubnet: 10 | default: '' 11 | description: IP address/subnet on the storage network 12 | type: string 13 | StorageMgmtIpSubnet: 14 | default: '' 15 | description: IP address/subnet on the storage_mgmt network 16 | type: string 17 | InternalApiIpSubnet: 18 | default: '' 19 | description: IP address/subnet on the internal_api network 20 | type: string 21 | TenantIpSubnet: 22 | default: '' 23 | description: IP address/subnet on the tenant network 24 | type: string 25 | ExternalIpSubnet: 26 | default: '' 27 | description: IP address/subnet on the external network 28 | type: string 29 | ManagementIpSubnet: 30 | default: '' 31 | description: IP address/subnet on the management network 32 | type: string 33 | StorageNetworkVlanID: 34 | default: 30 35 | description: Vlan ID for the storage network traffic. 36 | type: number 37 | StorageMgmtNetworkVlanID: 38 | default: 40 39 | description: Vlan ID for the storage_mgmt network traffic. 40 | type: number 41 | InternalApiNetworkVlanID: 42 | default: 20 43 | description: Vlan ID for the internal_api network traffic. 44 | type: number 45 | TenantNetworkVlanID: 46 | default: 50 47 | description: Vlan ID for the tenant network traffic. 48 | type: number 49 | ExternalNetworkVlanID: 50 | default: 10 51 | description: Vlan ID for the external network traffic. 52 | type: number 53 | ManagementNetworkVlanID: 54 | default: 60 55 | description: Vlan ID for the management network traffic. 56 | type: number 57 | ControlPlaneSubnetCidr: # Override this via parameter_defaults 58 | default: '24' 59 | description: The subnet CIDR of the control plane network. 60 | type: string 61 | ControlPlaneDefaultRoute: # Override this via parameter_defaults 62 | description: The default route of the control plane network. 63 | type: string 64 | ExternalInterfaceDefaultRoute: 65 | default: '10.0.0.1' 66 | description: default route for the external network 67 | type: string 68 | DnsServers: # Override this via parameter_defaults 69 | default: [] 70 | description: A list of DNS servers (2 max for some implementations) that will be added to resolv.conf. 71 | type: comma_delimited_list 72 | EC2MetadataIp: # Override this via parameter_defaults 73 | description: The IP address of the EC2 metadata server. 74 | type: string 75 | MellanoxTenantPort1: 76 | description: Mellanox Tenant Port1 77 | type: string 78 | resources: 79 | OsNetConfigImpl: 80 | type: OS::Heat::SoftwareConfig 81 | properties: 82 | group: script 83 | config: 84 | str_replace: 85 | template: 86 | get_file: /usr/share/openstack-tripleo-heat-templates/network/scripts/run-os-net-config.sh 87 | params: 88 | $network_config: 89 | network_config: 90 | - type: interface 91 | name: nic1 92 | use_dhcp: false 93 | dns_servers: 94 | get_param: DnsServers 95 | addresses: 96 | - ip_netmask: 97 | list_join: 98 | - / 99 | - - get_param: ControlPlaneIp 100 | - get_param: ControlPlaneSubnetCidr 101 | routes: 102 | - ip_netmask: 169.254.169.254/32 103 | next_hop: 104 | get_param: EC2MetadataIp 105 | - default: true 106 | next_hop: 107 | get_param: ControlPlaneDefaultRoute 108 | - type: interface 109 | name: nic2 110 | use_dhcp: false 111 | - type: vlan 112 | device: nic2 113 | vlan_id: 114 | get_param: StorageNetworkVlanID 115 | addresses: 116 | - ip_netmask: 117 | get_param: StorageIpSubnet 118 | - type: vlan 119 | device: nic2 120 | vlan_id: 121 | get_param: InternalApiNetworkVlanID 122 | addresses: 123 | - ip_netmask: 124 | get_param: InternalApiIpSubnet 125 | - type: sriov_pf 126 | name: 127 | get_param: MellanoxTenantPort1 128 | link_mode: switchdev 129 | numvfs: 15 130 | use_dhcp: false 131 | addresses: 132 | - ip_netmask: 133 | get_param: TenantIpSubnet 134 | outputs: 135 | OS::stack_id: 136 | description: The OsNetConfigImpl resource. 137 | value: 138 | get_resource: OsNetConfigImpl -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/deployment/nova/nuage-compute-vrs.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | 3 | description: > 4 | Nuage Compute and ComputeSriov Host Prep Tasks 5 | parameters: 6 | ServiceData: 7 | default: { } 8 | description: Dictionary packing service data 9 | type: json 10 | ServiceNetMap: 11 | default: { } 12 | description: Mapping of service_name -> network name. Typically set 13 | via parameter_defaults in the resource registry. This 14 | mapping overrides those in ServiceNetMapDefaults. 15 | type: json 16 | DefaultPasswords: 17 | default: { } 18 | type: json 19 | RoleName: 20 | default: '' 21 | description: Role name on which the service is applied 22 | type: string 23 | RoleParameters: 24 | default: { } 25 | description: Parameters specific to the role 26 | type: json 27 | EndpointMap: 28 | default: { } 29 | description: Mapping of service endpoint -> protocol. Typically set 30 | via parameter_defaults in the resource registry. 31 | type: json 32 | 33 | resources: 34 | NeutronComputePluginNuage: 35 | type: ./neutron-compute-plugin-nuage.yaml 36 | properties: 37 | ServiceData: { get_param: ServiceData } 38 | ServiceNetMap: { get_param: ServiceNetMap } 39 | DefaultPasswords: { get_param: DefaultPasswords } 40 | EndpointMap: { get_param: EndpointMap } 41 | RoleName: { get_param: RoleName } 42 | RoleParameters: { get_param: RoleParameters } 43 | 44 | EnsureNoAVRSIptables: 45 | type: OS::Heat::Value 46 | properties: 47 | value: 48 | # The 6wind iptables, eptables, .. that are in the nuage repo for 49 | # AVRS are seen as newer versions and thus yum update will 50 | # install those, even on the controller where they do not belong 51 | # a consequence of using 1 repo for all (not an issue in fresh 52 | # deploy) since there is no yum update there 53 | # To fix this, we will search which repo contains nuage bits 54 | # and add the relevant packages to its excludes 55 | # This is done in step 1 of deploy_steps_tasks and thus post Red Hat subscription 56 | # And also in step 1 of update_task does not really matter that much, since we expect that the new repo is in 57 | # place before the controller is updated 58 | - when: step|int == 1 59 | block: 60 | - name: Find the repo containing nuage bits 61 | vars: 62 | # For controller, we base our selves on the neutron client 63 | query_package: nuage-openstack-neutronclient 64 | shell: > 65 | repoquery -i {{ query_package }} 2>/dev/null 66 | register: repoquery_output 67 | - name: For all the repos containing nuage bits, exclude 6wind packages 68 | become: yes 69 | vars: 70 | exclude_packages: 71 | - iptables 72 | - iptables-libs 73 | - iptables-services 74 | - ebtables 75 | - iptables-utils 76 | shell: > 77 | yum config-manager 78 | --setopt={{ repo.split(':')[1] | trim }}.exclude={{ exclude_packages | join(',') }} 79 | --save 80 | loop: "{{ repoquery_output.stdout_lines }}" 81 | when: '"Repository " in repo' 82 | loop_control: 83 | loop_var: repo 84 | 85 | 86 | outputs: 87 | role_data: 88 | description: Role data for the Nuage Compute VRS 89 | value: 90 | service_name: 91 | get_attr: [ NeutronComputePluginNuage, role_data, service_name ] 92 | config_settings: 93 | get_attr: [ NeutronComputePluginNuage, role_data, config_settings ] 94 | step_config: 95 | get_attr: [ NeutronComputePluginNuage, role_data, step_config ] 96 | deploy_steps_tasks: 97 | list_concat: 98 | - get_attr: [ EnsureNoAVRSIptables, value ] 99 | - get_attr: [ NeutronComputePluginNuage, role_data, deploy_steps_tasks ] 100 | - - when: step|int == 1 101 | block: 102 | - name: Check if nuage vrs and metadata-agent are installed 103 | shell: rpm -q nuage-openvswitch nuage-metadata-agent 104 | failed_when: false 105 | register: nuage_check 106 | - name: Ensure VRS is operational in No patching scenarios 107 | when: nuage_check.rc != 0 108 | block: 109 | - name: Installing Nuage VRS Packages 110 | yum: 111 | name: "{{ packages }}" 112 | state: present 113 | vars: 114 | packages: 115 | - nuage-openvswitch 116 | - nuage-metadata-agent 117 | - name: Start and enable vrs 118 | service: 119 | name: openvswitch 120 | enabled: yes 121 | state: started 122 | update_tasks: 123 | list_concat: 124 | - get_attr: [ EnsureNoAVRSIptables, value ] 125 | - get_attr: [ NeutronComputePluginNuage, role_data, update_tasks ] 126 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/network/config/single-nic-hw-offload/controller.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | description: > 3 | Software Config to drive os-net-config to configure multiple interfaces for the Controller role. 4 | parameters: 5 | ControlPlaneIp: 6 | default: '' 7 | description: IP address/subnet on the ctlplane network 8 | type: string 9 | StorageIpSubnet: 10 | default: '' 11 | description: IP address/subnet on the storage network 12 | type: string 13 | StorageMgmtIpSubnet: 14 | default: '' 15 | description: IP address/subnet on the storage_mgmt network 16 | type: string 17 | InternalApiIpSubnet: 18 | default: '' 19 | description: IP address/subnet on the internal_api network 20 | type: string 21 | TenantIpSubnet: 22 | default: '' 23 | description: IP address/subnet on the tenant network 24 | type: string 25 | ExternalIpSubnet: 26 | default: '' 27 | description: IP address/subnet on the external network 28 | type: string 29 | ManagementIpSubnet: 30 | default: '' 31 | description: IP address/subnet on the management network 32 | type: string 33 | StorageNetworkVlanID: 34 | default: 30 35 | description: Vlan ID for the storage network traffic. 36 | type: number 37 | StorageMgmtNetworkVlanID: 38 | default: 40 39 | description: Vlan ID for the storage_mgmt network traffic. 40 | type: number 41 | InternalApiNetworkVlanID: 42 | default: 20 43 | description: Vlan ID for the internal_api network traffic. 44 | type: number 45 | TenantNetworkVlanID: 46 | default: 50 47 | description: Vlan ID for the tenant network traffic. 48 | type: number 49 | ExternalNetworkVlanID: 50 | default: 10 51 | description: Vlan ID for the external network traffic. 52 | type: number 53 | ManagementNetworkVlanID: 54 | default: 60 55 | description: Vlan ID for the management network traffic. 56 | type: number 57 | ControlPlaneSubnetCidr: # Override this via parameter_defaults 58 | default: '24' 59 | description: The subnet CIDR of the control plane network. 60 | type: string 61 | ControlPlaneDefaultRoute: # Override this via parameter_defaults 62 | description: The default route of the control plane network. 63 | type: string 64 | ExternalInterfaceDefaultRoute: 65 | default: '10.0.0.1' 66 | description: default route for the external network 67 | type: string 68 | DnsServers: # Override this via parameter_defaults 69 | default: [] 70 | description: A list of DNS servers (2 max for some implementations) that will be added to resolv.conf. 71 | type: comma_delimited_list 72 | EC2MetadataIp: # Override this via parameter_defaults 73 | description: The IP address of the EC2 metadata server. 74 | type: string 75 | resources: 76 | OsNetConfigImpl: 77 | type: OS::Heat::SoftwareConfig 78 | properties: 79 | group: script 80 | config: 81 | str_replace: 82 | template: 83 | get_file: /usr/share/openstack-tripleo-heat-templates/network/scripts/run-os-net-config.sh 84 | params: 85 | $network_config: 86 | network_config: 87 | - type: interface 88 | name: nic1 89 | use_dhcp: false 90 | dns_servers: 91 | get_param: DnsServers 92 | addresses: 93 | - ip_netmask: 94 | list_join: 95 | - / 96 | - - get_param: ControlPlaneIp 97 | - get_param: ControlPlaneSubnetCidr 98 | routes: 99 | - ip_netmask: 169.254.169.254/32 100 | next_hop: 101 | get_param: EC2MetadataIp 102 | - type: interface 103 | name: nic2 104 | use_dhcp: false 105 | - type: vlan 106 | device: nic2 107 | vlan_id: 108 | get_param: StorageNetworkVlanID 109 | addresses: 110 | - ip_netmask: 111 | get_param: StorageIpSubnet 112 | - type: vlan 113 | device: nic2 114 | vlan_id: 115 | get_param: StorageMgmtNetworkVlanID 116 | addresses: 117 | - ip_netmask: 118 | get_param: StorageMgmtIpSubnet 119 | - type: vlan 120 | device: nic2 121 | vlan_id: 122 | get_param: InternalApiNetworkVlanID 123 | addresses: 124 | - ip_netmask: 125 | get_param: InternalApiIpSubnet 126 | - type: interface 127 | name: nic3 128 | use_dhcp: false 129 | addresses: 130 | - ip_netmask: 131 | get_param: TenantIpSubnet 132 | - type: vlan 133 | device: nic2 134 | vlan_id: 135 | get_param: ExternalNetworkVlanID 136 | addresses: 137 | - ip_netmask: 138 | get_param: ExternalIpSubnet 139 | routes: 140 | - default: true 141 | next_hop: 142 | get_param: ExternalInterfaceDefaultRoute 143 | outputs: 144 | OS::stack_id: 145 | description: The OsNetConfigImpl resource. 146 | value: 147 | get_resource: OsNetConfigImpl -------------------------------------------------------------------------------- /Documentation/20.10/upgrade/README.rst: -------------------------------------------------------------------------------- 1 | .. Don't use default python highlighting for code blocks http://www.sphinx-doc.org/en/stable/markup/code.html 2 | 3 | =================================== 4 | Minor Update to Release 20.10.8 5 | =================================== 6 | 7 | .. contents:: 8 | :local: 9 | :depth: 3 10 | 11 | 12 | Use this documentation when updating between nuage minor releases. The process applies to updates from Release 20.10.5 to Release 20.10.8. During this process, the Nuage components are updated to 20.10.8. 13 | 14 | It is assumed the operator is familiar with Red Hat OpenStack Platform Director updates, VSP installation, the distribution-specific installation and update practices, and the specific requirements for operations in a production environment. 15 | 16 | 17 | Update Paths 18 | ------------- 19 | 20 | In this release, you can update only from OSP Director 16.1.6 + 20.10.5 to OSP Director 16.1.7 + 20.10.8. 21 | 22 | 23 | These update paths are not described in this document: 24 | 25 | * Update from OpenStack releases before Train 20.10.5 26 | * Update from VSP releases before Release 20.10.5 27 | 28 | 29 | Basic Configuration 30 | --------------------- 31 | 32 | The basic configuration includes: 33 | 34 | * One or more Controller node(s) 35 | * One or more Compute nodes (hypervisors) running the VRS, SR-IOV, AVRS nodes running Release 20.10.8 36 | 37 | 38 | 39 | Before the Update 40 | -------------------- 41 | 42 | 43 | 1. Get the new Nuage VSP RPMs 44 | 45 | The list of RPMs needed can be found in `Phase 2.1: Download the Nuage VSP RPMs` of the Fresh install guide for 20.10.8. 46 | Put these PRMs in a repository and synchronize it with, or directly upload these packages to Red Hat Satellite. 47 | 48 | Follow the Fresh install guide for 20.10.8 step `Phase 2.1: Download the Nuage VSP RPMs`. 49 | 50 | 51 | 52 | 2. Ensure both undercloud and overcloud have the new repositories enabled and old Nuage repositories disabled 53 | 54 | This steps depends a bit on how Red Hat Satellite is used. 55 | There are two options here, either by updating the current activation key with the new RPMs (scenario A), or multiple 56 | activation keys are used to separate the Nuage versions (scenario B). 57 | 58 | An tested example of how Scenario B can be solved will be explained here: 59 | 60 | The reason these steps are needed is that using the `rhsm_force_register` setting is only applied at the end of the 61 | update. While to update the Nuage RPMs we need this to be done before or during. 62 | 63 | Using the below guide, we can create an inventory file of the setup overcloud. 64 | https://access.redhat.com/documentation/en-us/red_hat_openstack_platform/16.1/html/keeping_red_hat_openstack_platform_updated/preparing-for-a-minor-update_keeping-updated#locking-the-environment-to-a-red-hat-enterprise-linux-release_keeping-updated 65 | 66 | :: 67 | 68 | tripleo-ansible-inventory --ansible_ssh_user heat-admin --static-yaml-inventory ~/inventory.yaml 69 | 70 | This inventory file we can now use in some automation scripts. Here is an example of how one can force a new 71 | activation key onto the deployment. 72 | 73 | 74 | :: 75 | 76 | 77 | - hosts: all 78 | gather_facts: false 79 | tasks: 80 | - name: update satellite activation key 81 | command: subscription-manager register --force --activationkey=nuage-20.10.8-16.1 --org=<> 82 | become: true 83 | 84 | This file can then be run using: 85 | 86 | :: 87 | 88 | ansible-playbook -i inventory.yaml -f 25 set-rh-key.yaml --limit overcloud 89 | 90 | The example limits the playbook to only the overcloud, but one should also make sure some of the 20.10.8 91 | Nuage RPMs are available on the undercloud. This action depends a lot on how your setup is done 92 | 93 | For the undercloud this can be simply done manually. 94 | 95 | Afterwards a spot check should be done on the overcloud and or undercloud to see if the new 20.10.8 RPMs are available. 96 | 97 | 98 | Update Workflow 99 | ------------------ 100 | 101 | 1. Back up the configuration files for your deployment. 102 | 103 | In the following example, all the templates and environment files for your deployment are in the /home/stack/nuage-ospdirector directory. To get new the Nuage 20.10.8 nuage-ospdirector/nuage-tripleoheat-templates, back up the files before replacing the existing ones with new 20.10.8 codebase. 104 | 105 | a. Back up the templates and environment files from /home/stack/nuage-ospdirector to /home/stack/nuage-ospdirector-bk. 106 | 107 | :: 108 | 109 | $ mv /home/stack/nuage-ospdirector /home/stack/nuage-ospdirector-bk 110 | 111 | 112 | 2. Update nuage-tripleo-heat-templates package by using 113 | 114 | :: 115 | 116 | $ sudo yum update nuage-tripleo-heat-templates 117 | 118 | 3. Copy nuage-tripleo-heat-templates to /home/stack before customizing environment files 119 | 120 | :: 121 | 122 | $ cp -r /usr/share/nuage-tripleo-heat-templates /home/stack/ 123 | 124 | 125 | 126 | 4. Regenerate roles data file by following below instructions 127 | 128 | Follow the instructions `Phase 3.4: Create the Dataplane Roles and Update the Node Profiles` of fresh install 129 | 130 | 131 | 5. Make sure your all of the templates and environment files are updated with the environment values for your deployment. 132 | 133 | Get the environment values from the /home/stack/nuage-ospdirector-bk directory and update all the templates and environment files for the deployment, such as neutron-nuage/nova-nuage/compute-avrs/ovs-hw-offload/mellanox-environment. 134 | 135 | 136 | 6. Get the latest Nuage docker images from the Red Hat Partner Registry 137 | 138 | These can be obtained by following these instructions in `Phase 2.3: Prepare Nuage Containers` from `20.10/README.rst <../../README.rst>`_ 139 | If AVRS is deployed, follow `Phase 2.4: Pull AVRS Containers` from the Red Hat Catalog as well. 140 | 141 | 142 | 7. To update the Overcloud deployment, follow these instructions: https://access.redhat.com/documentation/en-us/red_hat_openstack_platform/16.1/html/keeping_red_hat_openstack_platform_updated/assembly-updating_the_overcloud 143 | 144 | Here it is important to use the container-image-prepare file containing the references to Nuage containers resulted by `Step 6` 145 | 146 | 8. Reboot overcloud as described in the Red Hat Instructions 147 | 148 | 9. Once the overcloud update is complete, update nuage-topology-collector using: 149 | 150 | :: 151 | 152 | $ sudo yum update nuage-topology-collector -y 153 | 154 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/scripts/generate-cms-id/restproxy.py: -------------------------------------------------------------------------------- 1 | # Copyright 2015 Alcatel-Lucent USA Inc. 2 | # All Rights Reserved. 3 | 4 | import base64 5 | import json 6 | import socket 7 | import time 8 | import logging 9 | import ssl 10 | 11 | try: 12 | import http.client as http_client 13 | except ImportError: 14 | import httplib as http_client 15 | 16 | LOG = logging.getLogger(__name__) 17 | MAX_RETRIES = 5 18 | MAX_RETRIES_503 = 5 19 | 20 | 21 | class RESTProxyBaseException(Exception): 22 | message = "An unknown exception occurred." 23 | 24 | def __init__(self, **kwargs): 25 | try: 26 | super(RESTProxyBaseException, self).__init__(self.message % kwargs) 27 | self.msg = self.message % kwargs 28 | except Exception: 29 | if self.use_fatal_exceptions(): 30 | raise 31 | else: 32 | super(RESTProxyBaseException, self).__init__(self.message) 33 | 34 | def __unicode__(self): 35 | return str(self.msg) 36 | 37 | def use_fatal_exceptions(self): 38 | return False 39 | 40 | 41 | class RESTProxyError(RESTProxyBaseException): 42 | def __init__(self, message, error_code=None): 43 | self.code = 0 44 | if error_code: 45 | self.code = error_code 46 | 47 | if message is None: 48 | message = "None" 49 | 50 | if self.code == 409: 51 | self.message = message 52 | else: 53 | self.message = "Error in REST call to VSD: %s" % message 54 | super(RESTProxyError, self).__init__() 55 | 56 | 57 | class RESTProxyServer(object): 58 | def __init__(self, server, base_uri, serverssl, 59 | serverauth, auth_resource, 60 | organization, servertimeout=30): 61 | try: 62 | server_ip, port = server.split(":") 63 | except ValueError: 64 | server_ip = server 65 | port = None 66 | self.server = server_ip 67 | self.port = int(port) if port else None 68 | self.base_uri = base_uri 69 | self.serverssl = serverssl 70 | self.serverauth = serverauth 71 | self.auth_resource = auth_resource 72 | self.organization = organization 73 | self.timeout = servertimeout 74 | self.retry = 0 75 | self.retry_503 = 0 76 | self.auth = None 77 | self.success_codes = list(range(200, 207)) 78 | 79 | def _rest_call(self, action, resource, data, extra_headers=None): 80 | if self.retry >= MAX_RETRIES: 81 | LOG.error('RESTProxy: Max retries exceeded') 82 | # Get ready for the next set of operation 83 | self.retry = 0 84 | return 0, None, None, None 85 | uri = self.base_uri + resource 86 | body = json.dumps(data) 87 | headers = {} 88 | headers['Content-type'] = 'application/json' 89 | headers['X-Nuage-Organization'] = self.organization 90 | if self.auth: 91 | headers['Authorization'] = self.auth 92 | conn = None 93 | if extra_headers: 94 | headers.update(extra_headers) 95 | 96 | LOG.debug('Request uri: %s', uri) 97 | LOG.debug('Request headers: %s', headers) 98 | LOG.debug('Request body: %s', body) 99 | 100 | if self.serverssl: 101 | conn = http_client.HTTPSConnection( 102 | self.server, self.port, timeout=self.timeout, context=ssl._create_unverified_context()) 103 | if conn is None: 104 | LOG.error('RESTProxy: Could not establish HTTPS ' 105 | 'connection') 106 | return 0, None, None, None 107 | else: 108 | conn = http_client.HTTPConnection( 109 | self.server, self.port, timeout=self.timeout) 110 | if conn is None: 111 | LOG.error('RESTProxy: Could not establish HTTP ' 112 | 'connection') 113 | return 0, None, None, None 114 | 115 | try: 116 | conn.request(action, uri, body, headers) 117 | response = conn.getresponse() 118 | respstr = response.read() 119 | respdata = respstr 120 | LOG.debug('Response status is %(st)s and reason is %(res)s', 121 | {'st': response.status, 122 | 'res': response.reason}) 123 | LOG.debug('Response data is %s', respstr) 124 | if response.status in self.success_codes: 125 | try: 126 | respdata = json.loads(respstr) 127 | except ValueError: 128 | # response was not JSON, ignore the exception 129 | pass 130 | ret = (response.status, response.reason, respstr, respdata) 131 | except (socket.timeout, socket.error) as e: 132 | LOG.error('ServerProxy: %(action)s failure, %(e)r', locals()) 133 | # retry 134 | self.retry += 1 135 | return self._rest_call(action, resource, data, extra_headers) 136 | conn.close() 137 | if response.status == 503: 138 | if self.retry_503 < MAX_RETRIES_503: 139 | time.sleep(1) 140 | self.retry_503 += 1 141 | LOG.debug('VSD unavailable. Retrying') 142 | return self._rest_call(action, resource, data, 143 | extra_headers=extra_headers) 144 | else: 145 | LOG.debug('After 5 retries VSD is unavailable. Bailing out') 146 | self.retry = 0 147 | self.retry_503 = 0 148 | return ret 149 | 150 | def generate_nuage_auth(self): 151 | data = '' 152 | encoded_auth = base64.encodestring(self.serverauth.encode()).strip() 153 | self.auth = 'Basic ' + encoded_auth.decode() 154 | resp = self._rest_call('GET', self.auth_resource, data) 155 | if resp[0] in self.success_codes and resp[3][0]['APIKey']: 156 | respkey = resp[3][0]['APIKey'] 157 | else: 158 | if resp[0] == 0: 159 | assert 0, 'Could not establish conn with REST server. Abort' 160 | else: 161 | assert 0, 'Could not authenticate to REST server. Abort' 162 | uname = self.serverauth.split(':')[0] 163 | new_uname_pass = uname + ':' + respkey 164 | auth = 'Basic ' + base64.encodestring(new_uname_pass.encode()).strip().decode() 165 | self.auth = auth 166 | 167 | def rest_call(self, action, resource, data, extra_headers=None): 168 | response = self._rest_call(action, resource, data, 169 | extra_headers=extra_headers) 170 | ''' 171 | If at all authentication expires with VSD, re-authenticate. 172 | ''' 173 | if response[0] == 401 and response[1] == 'Unauthorized': 174 | self.generate_nuage_auth() 175 | return self._rest_call(action, resource, data, 176 | extra_headers=extra_headers) 177 | return response 178 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/network/config/bond-with-vlans/computeavrs.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | description: > 3 | Software Config to drive os-net-config with 2 bonded nics on a bridge with VLANs attached for the ComputeAvrs role. 4 | parameters: 5 | ControlPlaneIp: 6 | default: '' 7 | description: IP address/subnet on the ctlplane network 8 | type: string 9 | ControlPlaneStaticRoutes: 10 | default: [] 11 | description: > 12 | Routes for the ctlplane network traffic. 13 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 14 | Unless the default is changed, the parameter is automatically resolved 15 | from the subnet host_routes attribute. 16 | type: json 17 | ControlPlaneMtu: 18 | default: 1500 19 | description: The maximum transmission unit (MTU) size(in bytes) that is 20 | guaranteed to pass through the data path of the segments in the network. 21 | (The parameter is automatically resolved from the ctlplane network's mtu attribute.) 22 | type: number 23 | StorageIpSubnet: 24 | default: '' 25 | description: IP address/subnet on the storage network 26 | type: string 27 | StorageMgmtIpSubnet: 28 | default: '' 29 | description: IP address/subnet on the storage_mgmt network 30 | type: string 31 | StorageMtu: 32 | default: 1500 33 | description: The maximum transmission unit (MTU) size(in bytes) that is 34 | guaranteed to pass through the data path of the segments in the 35 | Storage network. 36 | type: number 37 | InternalApiIpSubnet: 38 | default: '' 39 | description: IP address/subnet on the internal_api network 40 | type: string 41 | InternalApiMtu: 42 | default: 1500 43 | description: The maximum transmission unit (MTU) size(in bytes) that is 44 | guaranteed to pass through the data path of the segments in the 45 | InternalApi network. 46 | type: number 47 | TenantIpSubnet: 48 | default: '' 49 | description: IP address/subnet on the tenant network 50 | type: string 51 | TenantMtu: 52 | default: 1500 53 | description: The maximum transmission unit (MTU) size(in bytes) that is 54 | guaranteed to pass through the data path of the segments in the 55 | Tenant network. 56 | ExternalIpSubnet: 57 | default: '' 58 | description: IP address/subnet on the external network 59 | type: string 60 | ManagementIpSubnet: 61 | default: '' 62 | description: IP address/subnet on the management network 63 | type: string 64 | BondInterfaceOvsOptions: 65 | default: bond_mode=active-backup 66 | description: 'The ovs_options or bonding_options string for the bond 67 | interface. Set things like lacp=active and/or bond_mode=balance-slb 68 | for OVS bonds or like mode=4 for Linux bonds using this option.' 69 | type: string 70 | StorageNetworkVlanID: 71 | default: 30 72 | description: Vlan ID for the storage network traffic. 73 | type: number 74 | StorageMgmtNetworkVlanID: 75 | default: 40 76 | description: Vlan ID for the storage_mgmt network traffic. 77 | type: number 78 | InternalApiNetworkVlanID: 79 | default: 20 80 | description: Vlan ID for the internal_api network traffic. 81 | type: number 82 | TenantNetworkVlanID: 83 | default: 50 84 | description: Vlan ID for the tenant network traffic. 85 | type: number 86 | ExternalNetworkVlanID: 87 | default: 10 88 | description: Vlan ID for the external network traffic. 89 | type: number 90 | ManagementNetworkVlanID: 91 | default: 60 92 | description: Vlan ID for the management network traffic. 93 | type: number 94 | ControlPlaneDefaultRoute: # Override this via parameter_defaults 95 | description: The default route of the control plane network. 96 | type: string 97 | ExternalInterfaceDefaultRoute: 98 | default: '10.0.0.1' 99 | description: default route for the external network 100 | type: string 101 | ControlPlaneSubnetCidr: # Override this via parameter_defaults 102 | default: '24' 103 | description: The subnet CIDR of the control plane network. 104 | type: string 105 | DnsServers: # Override this via parameter_defaults 106 | default: [] 107 | description: A list of DNS servers (2 max for some implementations) that will be added to resolv.conf. 108 | type: comma_delimited_list 109 | resources: 110 | MinViableMtu: 111 | # This resource resolves the minimum viable MTU for interfaces, bonds and 112 | # bridges that carry multiple VLANs. Each VLAN may have different MTU. The 113 | # bridge, bond or interface must have an MTU to allow the VLAN with the 114 | # largest MTU. 115 | type: OS::Heat::Value 116 | properties: 117 | type: number 118 | value: 119 | yaql: 120 | expression: $.data.max() 121 | data: 122 | - {get_param: ControlPlaneMtu} 123 | - {get_param: StorageMtu} 124 | - {get_param: InternalApiMtu} 125 | - {get_param: TenantMtu} 126 | 127 | OsNetConfigImpl: 128 | type: OS::Heat::SoftwareConfig 129 | properties: 130 | group: script 131 | config: 132 | str_replace: 133 | template: 134 | get_file: /usr/share/openstack-tripleo-heat-templates/network/scripts/run-os-net-config.sh 135 | params: 136 | $network_config: 137 | network_config: 138 | - type: interface 139 | name: nic1 140 | mtu: 141 | get_param: ControlPlaneMtu 142 | use_dhcp: false 143 | addresses: 144 | - ip_netmask: 145 | list_join: 146 | - / 147 | - - get_param: ControlPlaneIp 148 | - get_param: ControlPlaneSubnetCidr 149 | routes: 150 | list_concat_unique: 151 | - get_param: ControlPlaneStaticRoutes 152 | - - default: true 153 | next_hop: 154 | get_param: ControlPlaneDefaultRoute 155 | - type: linux_bond 156 | name: infra-bond 157 | dns_servers: 158 | get_param: DnsServers 159 | bonding_options: 160 | get_param: BondInterfaceOvsOptions 161 | members: 162 | - type: interface 163 | name: nic2 164 | - type: interface 165 | name: nic3 166 | - type: vlan 167 | device: infra-bond 168 | vlan_id: 169 | get_param: StorageNetworkVlanID 170 | addresses: 171 | - ip_netmask: 172 | get_param: StorageIpSubnet 173 | - type: vlan 174 | device: infra-bond 175 | vlan_id: 176 | get_param: InternalApiNetworkVlanID 177 | addresses: 178 | - ip_netmask: 179 | get_param: InternalApiIpSubnet 180 | - type: vlan 181 | device: tenant-bond 182 | vlan_id: 183 | get_param: TenantNetworkVlanID 184 | addresses: 185 | - ip_netmask: 186 | get_param: TenantIpSubnet 187 | outputs: 188 | OS::stack_id: 189 | description: The OsNetConfigImpl resource. 190 | value: 191 | get_resource: OsNetConfigImpl 192 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/network/config/bond-with-vlans/computeavrsdual.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | description: > 3 | Software Config to drive os-net-config with 2 bonded nics on a bridge with VLANs attached for the ComputeAvrsDual2 role. 4 | parameters: 5 | ControlPlaneIp: 6 | default: '' 7 | description: IP address/subnet on the ctlplane network 8 | type: string 9 | ControlPlaneStaticRoutes: 10 | default: [] 11 | description: > 12 | Routes for the ctlplane network traffic. 13 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 14 | Unless the default is changed, the parameter is automatically resolved 15 | from the subnet host_routes attribute. 16 | type: json 17 | ControlPlaneMtu: 18 | default: 1500 19 | description: The maximum transmission unit (MTU) size(in bytes) that is 20 | guaranteed to pass through the data path of the segments in the network. 21 | (The parameter is automatically resolved from the ctlplane network's mtu attribute.) 22 | type: number 23 | StorageIpSubnet: 24 | default: '' 25 | description: IP address/subnet on the storage network 26 | type: string 27 | StorageMgmtIpSubnet: 28 | default: '' 29 | description: IP address/subnet on the storage_mgmt network 30 | type: string 31 | StorageMtu: 32 | default: 1500 33 | description: The maximum transmission unit (MTU) size(in bytes) that is 34 | guaranteed to pass through the data path of the segments in the 35 | Storage network. 36 | type: number 37 | InternalApiIpSubnet: 38 | default: '' 39 | description: IP address/subnet on the internal_api network 40 | type: string 41 | InternalApiMtu: 42 | default: 1500 43 | description: The maximum transmission unit (MTU) size(in bytes) that is 44 | guaranteed to pass through the data path of the segments in the 45 | InternalApi network. 46 | type: number 47 | TenantIpSubnet: 48 | default: '' 49 | description: IP address/subnet on the tenant network 50 | type: string 51 | TenantMtu: 52 | default: 1500 53 | description: The maximum transmission unit (MTU) size(in bytes) that is 54 | guaranteed to pass through the data path of the segments in the 55 | Tenant network. 56 | ExternalIpSubnet: 57 | default: '' 58 | description: IP address/subnet on the external network 59 | type: string 60 | ManagementIpSubnet: 61 | default: '' 62 | description: IP address/subnet on the management network 63 | type: string 64 | BondInterfaceOvsOptions: 65 | default: bond_mode=active-backup 66 | description: 'The ovs_options or bonding_options string for the bond 67 | interface. Set things like lacp=active and/or bond_mode=balance-slb 68 | for OVS bonds or like mode=4 for Linux bonds using this option.' 69 | type: string 70 | StorageNetworkVlanID: 71 | default: 30 72 | description: Vlan ID for the storage network traffic. 73 | type: number 74 | StorageMgmtNetworkVlanID: 75 | default: 40 76 | description: Vlan ID for the storage_mgmt network traffic. 77 | type: number 78 | InternalApiNetworkVlanID: 79 | default: 20 80 | description: Vlan ID for the internal_api network traffic. 81 | type: number 82 | TenantNetworkVlanID: 83 | default: 50 84 | description: Vlan ID for the tenant network traffic. 85 | type: number 86 | ExternalNetworkVlanID: 87 | default: 10 88 | description: Vlan ID for the external network traffic. 89 | type: number 90 | ManagementNetworkVlanID: 91 | default: 60 92 | description: Vlan ID for the management network traffic. 93 | type: number 94 | ControlPlaneDefaultRoute: # Override this via parameter_defaults 95 | description: The default route of the control plane network. 96 | type: string 97 | ExternalInterfaceDefaultRoute: 98 | default: '10.0.0.1' 99 | description: default route for the external network 100 | type: string 101 | ControlPlaneSubnetCidr: # Override this via parameter_defaults 102 | default: '24' 103 | description: The subnet CIDR of the control plane network. 104 | type: string 105 | DnsServers: # Override this via parameter_defaults 106 | default: [] 107 | description: A list of DNS servers (2 max for some implementations) that will be added to resolv.conf. 108 | type: comma_delimited_list 109 | resources: 110 | MinViableMtu: 111 | # This resource resolves the minimum viable MTU for interfaces, bonds and 112 | # bridges that carry multiple VLANs. Each VLAN may have different MTU. The 113 | # bridge, bond or interface must have an MTU to allow the VLAN with the 114 | # largest MTU. 115 | type: OS::Heat::Value 116 | properties: 117 | type: number 118 | value: 119 | yaql: 120 | expression: $.data.max() 121 | data: 122 | - {get_param: ControlPlaneMtu} 123 | - {get_param: StorageMtu} 124 | - {get_param: InternalApiMtu} 125 | - {get_param: TenantMtu} 126 | 127 | OsNetConfigImpl: 128 | type: OS::Heat::SoftwareConfig 129 | properties: 130 | group: script 131 | config: 132 | str_replace: 133 | template: 134 | get_file: /usr/share/openstack-tripleo-heat-templates/network/scripts/run-os-net-config.sh 135 | params: 136 | $network_config: 137 | network_config: 138 | - type: interface 139 | name: nic1 140 | mtu: 141 | get_param: ControlPlaneMtu 142 | use_dhcp: false 143 | addresses: 144 | - ip_netmask: 145 | list_join: 146 | - / 147 | - - get_param: ControlPlaneIp 148 | - get_param: ControlPlaneSubnetCidr 149 | routes: 150 | list_concat_unique: 151 | - get_param: ControlPlaneStaticRoutes 152 | - - default: true 153 | next_hop: 154 | get_param: ControlPlaneDefaultRoute 155 | - type: linux_bond 156 | name: infra-bond 157 | dns_servers: 158 | get_param: DnsServers 159 | bonding_options: 160 | get_param: BondInterfaceOvsOptions 161 | members: 162 | - type: interface 163 | name: nic2 164 | - type: interface 165 | name: nic3 166 | - type: vlan 167 | device: infra-bond 168 | vlan_id: 169 | get_param: StorageNetworkVlanID 170 | addresses: 171 | - ip_netmask: 172 | get_param: StorageIpSubnet 173 | - type: vlan 174 | device: infra-bond 175 | vlan_id: 176 | get_param: InternalApiNetworkVlanID 177 | addresses: 178 | - ip_netmask: 179 | get_param: InternalApiIpSubnet 180 | - type: vlan 181 | device: tenant-bond 182 | vlan_id: 183 | get_param: TenantNetworkVlanID 184 | addresses: 185 | - ip_netmask: 186 | get_param: TenantIpSubnet 187 | outputs: 188 | OS::stack_id: 189 | description: The OsNetConfigImpl resource. 190 | value: 191 | get_resource: OsNetConfigImpl 192 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/network/config/bond-with-vlans/computeavrssingle.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | description: > 3 | Software Config to drive os-net-config with 2 bonded nics on a bridge with VLANs attached for the ComputeAvrsSingle2 role. 4 | parameters: 5 | ControlPlaneIp: 6 | default: '' 7 | description: IP address/subnet on the ctlplane network 8 | type: string 9 | ControlPlaneStaticRoutes: 10 | default: [] 11 | description: > 12 | Routes for the ctlplane network traffic. 13 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 14 | Unless the default is changed, the parameter is automatically resolved 15 | from the subnet host_routes attribute. 16 | type: json 17 | ControlPlaneMtu: 18 | default: 1500 19 | description: The maximum transmission unit (MTU) size(in bytes) that is 20 | guaranteed to pass through the data path of the segments in the network. 21 | (The parameter is automatically resolved from the ctlplane network's mtu attribute.) 22 | type: number 23 | StorageIpSubnet: 24 | default: '' 25 | description: IP address/subnet on the storage network 26 | type: string 27 | StorageMgmtIpSubnet: 28 | default: '' 29 | description: IP address/subnet on the storage_mgmt network 30 | type: string 31 | StorageMtu: 32 | default: 1500 33 | description: The maximum transmission unit (MTU) size(in bytes) that is 34 | guaranteed to pass through the data path of the segments in the 35 | Storage network. 36 | type: number 37 | InternalApiIpSubnet: 38 | default: '' 39 | description: IP address/subnet on the internal_api network 40 | type: string 41 | InternalApiMtu: 42 | default: 1500 43 | description: The maximum transmission unit (MTU) size(in bytes) that is 44 | guaranteed to pass through the data path of the segments in the 45 | InternalApi network. 46 | type: number 47 | TenantIpSubnet: 48 | default: '' 49 | description: IP address/subnet on the tenant network 50 | type: string 51 | TenantMtu: 52 | default: 1500 53 | description: The maximum transmission unit (MTU) size(in bytes) that is 54 | guaranteed to pass through the data path of the segments in the 55 | Tenant network. 56 | ExternalIpSubnet: 57 | default: '' 58 | description: IP address/subnet on the external network 59 | type: string 60 | ManagementIpSubnet: 61 | default: '' 62 | description: IP address/subnet on the management network 63 | type: string 64 | BondInterfaceOvsOptions: 65 | default: bond_mode=active-backup 66 | description: 'The ovs_options or bonding_options string for the bond 67 | interface. Set things like lacp=active and/or bond_mode=balance-slb 68 | for OVS bonds or like mode=4 for Linux bonds using this option.' 69 | type: string 70 | StorageNetworkVlanID: 71 | default: 30 72 | description: Vlan ID for the storage network traffic. 73 | type: number 74 | StorageMgmtNetworkVlanID: 75 | default: 40 76 | description: Vlan ID for the storage_mgmt network traffic. 77 | type: number 78 | InternalApiNetworkVlanID: 79 | default: 20 80 | description: Vlan ID for the internal_api network traffic. 81 | type: number 82 | TenantNetworkVlanID: 83 | default: 50 84 | description: Vlan ID for the tenant network traffic. 85 | type: number 86 | ExternalNetworkVlanID: 87 | default: 10 88 | description: Vlan ID for the external network traffic. 89 | type: number 90 | ManagementNetworkVlanID: 91 | default: 60 92 | description: Vlan ID for the management network traffic. 93 | type: number 94 | ControlPlaneDefaultRoute: # Override this via parameter_defaults 95 | description: The default route of the control plane network. 96 | type: string 97 | ExternalInterfaceDefaultRoute: 98 | default: '10.0.0.1' 99 | description: default route for the external network 100 | type: string 101 | ControlPlaneSubnetCidr: # Override this via parameter_defaults 102 | default: '24' 103 | description: The subnet CIDR of the control plane network. 104 | type: string 105 | DnsServers: # Override this via parameter_defaults 106 | default: [] 107 | description: A list of DNS servers (2 max for some implementations) that will be added to resolv.conf. 108 | type: comma_delimited_list 109 | resources: 110 | MinViableMtu: 111 | # This resource resolves the minimum viable MTU for interfaces, bonds and 112 | # bridges that carry multiple VLANs. Each VLAN may have different MTU. The 113 | # bridge, bond or interface must have an MTU to allow the VLAN with the 114 | # largest MTU. 115 | type: OS::Heat::Value 116 | properties: 117 | type: number 118 | value: 119 | yaql: 120 | expression: $.data.max() 121 | data: 122 | - {get_param: ControlPlaneMtu} 123 | - {get_param: StorageMtu} 124 | - {get_param: InternalApiMtu} 125 | - {get_param: TenantMtu} 126 | 127 | OsNetConfigImpl: 128 | type: OS::Heat::SoftwareConfig 129 | properties: 130 | group: script 131 | config: 132 | str_replace: 133 | template: 134 | get_file: /usr/share/openstack-tripleo-heat-templates/network/scripts/run-os-net-config.sh 135 | params: 136 | $network_config: 137 | network_config: 138 | - type: interface 139 | name: nic1 140 | mtu: 141 | get_param: ControlPlaneMtu 142 | use_dhcp: false 143 | addresses: 144 | - ip_netmask: 145 | list_join: 146 | - / 147 | - - get_param: ControlPlaneIp 148 | - get_param: ControlPlaneSubnetCidr 149 | routes: 150 | list_concat_unique: 151 | - get_param: ControlPlaneStaticRoutes 152 | - - default: true 153 | next_hop: 154 | get_param: ControlPlaneDefaultRoute 155 | - type: linux_bond 156 | name: infra-bond 157 | dns_servers: 158 | get_param: DnsServers 159 | bonding_options: 160 | get_param: BondInterfaceOvsOptions 161 | members: 162 | - type: interface 163 | name: nic2 164 | - type: interface 165 | name: nic3 166 | - type: vlan 167 | device: infra-bond 168 | vlan_id: 169 | get_param: StorageNetworkVlanID 170 | addresses: 171 | - ip_netmask: 172 | get_param: StorageIpSubnet 173 | - type: vlan 174 | device: infra-bond 175 | vlan_id: 176 | get_param: InternalApiNetworkVlanID 177 | addresses: 178 | - ip_netmask: 179 | get_param: InternalApiIpSubnet 180 | - type: vlan 181 | device: tenant-bond 182 | vlan_id: 183 | get_param: TenantNetworkVlanID 184 | addresses: 185 | - ip_netmask: 186 | get_param: TenantIpSubnet 187 | outputs: 188 | OS::stack_id: 189 | description: The OsNetConfigImpl resource. 190 | value: 191 | get_resource: OsNetConfigImpl 192 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/network/config/bond-with-vlans/computeovrs.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | description: > 3 | Software Config to drive os-net-config with 2 bonded nics on a bridge with VLANs attached for the ComputeOvrs role. 4 | parameters: 5 | ControlPlaneIp: 6 | default: '' 7 | description: IP address/subnet on the ctlplane network 8 | type: string 9 | ControlPlaneStaticRoutes: 10 | default: [] 11 | description: > 12 | Routes for the ctlplane network traffic. 13 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 14 | Unless the default is changed, the parameter is automatically resolved 15 | from the subnet host_routes attribute. 16 | type: json 17 | ControlPlaneMtu: 18 | default: 1500 19 | description: The maximum transmission unit (MTU) size(in bytes) that is 20 | guaranteed to pass through the data path of the segments in the network. 21 | (The parameter is automatically resolved from the ctlplane network's mtu attribute.) 22 | type: number 23 | StorageIpSubnet: 24 | default: '' 25 | description: IP address/subnet on the storage network 26 | type: string 27 | StorageMgmtIpSubnet: 28 | default: '' 29 | description: IP address/subnet on the storage_mgmt network 30 | type: string 31 | StorageMtu: 32 | default: 1500 33 | description: The maximum transmission unit (MTU) size(in bytes) that is 34 | guaranteed to pass through the data path of the segments in the 35 | Storage network. 36 | type: number 37 | InternalApiIpSubnet: 38 | default: '' 39 | description: IP address/subnet on the internal_api network 40 | type: string 41 | InternalApiMtu: 42 | default: 1500 43 | description: The maximum transmission unit (MTU) size(in bytes) that is 44 | guaranteed to pass through the data path of the segments in the 45 | InternalApi network. 46 | type: number 47 | TenantIpSubnet: 48 | default: '' 49 | description: IP address/subnet on the tenant network 50 | type: string 51 | TenantMtu: 52 | default: 1500 53 | description: The maximum transmission unit (MTU) size(in bytes) that is 54 | guaranteed to pass through the data path of the segments in the 55 | Tenant network. 56 | ExternalIpSubnet: 57 | default: '' 58 | description: IP address/subnet on the external network 59 | type: string 60 | ManagementIpSubnet: 61 | default: '' 62 | description: IP address/subnet on the management network 63 | type: string 64 | BondInterfaceOvsOptions: 65 | default: bond_mode=active-backup 66 | description: 'The ovs_options or bonding_options string for the bond 67 | interface. Set things like lacp=active and/or bond_mode=balance-slb 68 | for OVS bonds or like mode=4 for Linux bonds using this option.' 69 | type: string 70 | StorageNetworkVlanID: 71 | default: 30 72 | description: Vlan ID for the storage network traffic. 73 | type: number 74 | StorageMgmtNetworkVlanID: 75 | default: 40 76 | description: Vlan ID for the storage_mgmt network traffic. 77 | type: number 78 | InternalApiNetworkVlanID: 79 | default: 20 80 | description: Vlan ID for the internal_api network traffic. 81 | type: number 82 | TenantNetworkVlanID: 83 | default: 50 84 | description: Vlan ID for the tenant network traffic. 85 | type: number 86 | ExternalNetworkVlanID: 87 | default: 10 88 | description: Vlan ID for the external network traffic. 89 | type: number 90 | ManagementNetworkVlanID: 91 | default: 60 92 | description: Vlan ID for the management network traffic. 93 | type: number 94 | ControlPlaneDefaultRoute: # Override this via parameter_defaults 95 | description: The default route of the control plane network. 96 | type: string 97 | ExternalInterfaceDefaultRoute: 98 | default: '10.0.0.1' 99 | description: default route for the external network 100 | type: string 101 | ControlPlaneSubnetCidr: # Override this via parameter_defaults 102 | default: '24' 103 | description: The subnet CIDR of the control plane network. 104 | type: string 105 | DnsServers: # Override this via parameter_defaults 106 | default: [] 107 | description: A list of DNS servers (2 max for some implementations) that will be added to resolv.conf. 108 | type: comma_delimited_list 109 | MellanoxTenantPort1: 110 | description: Mellanox Tenant Port1 111 | type: string 112 | MellanoxTenantPort2: 113 | description: Mellanox Tenant Port2 114 | type: string 115 | resources: 116 | MinViableMtu: 117 | # This resource resolves the minimum viable MTU for interfaces, bonds and 118 | # bridges that carry multiple VLANs. Each VLAN may have different MTU. The 119 | # bridge, bond or interface must have an MTU to allow the VLAN with the 120 | # largest MTU. 121 | type: OS::Heat::Value 122 | properties: 123 | type: number 124 | value: 125 | yaql: 126 | expression: $.data.max() 127 | data: 128 | - {get_param: ControlPlaneMtu} 129 | - {get_param: StorageMtu} 130 | - {get_param: InternalApiMtu} 131 | - {get_param: TenantMtu} 132 | 133 | OsNetConfigImpl: 134 | type: OS::Heat::SoftwareConfig 135 | properties: 136 | group: script 137 | config: 138 | str_replace: 139 | template: 140 | get_file: /usr/share/openstack-tripleo-heat-templates/network/scripts/run-os-net-config.sh 141 | params: 142 | $network_config: 143 | network_config: 144 | - type: interface 145 | name: nic1 146 | mtu: 147 | get_param: ControlPlaneMtu 148 | use_dhcp: false 149 | addresses: 150 | - ip_netmask: 151 | list_join: 152 | - / 153 | - - get_param: ControlPlaneIp 154 | - get_param: ControlPlaneSubnetCidr 155 | routes: 156 | list_concat_unique: 157 | - get_param: ControlPlaneStaticRoutes 158 | - - default: true 159 | next_hop: 160 | get_param: ControlPlaneDefaultRoute 161 | # Linux bond for Offload VRS Compute nodes 162 | - type: linux_bond 163 | name: infra-bond 164 | dns_servers: 165 | get_param: DnsServers 166 | bonding_options: 167 | get_param: BondInterfaceOvsOptions 168 | members: 169 | - type: interface 170 | name: nic2 171 | - type: interface 172 | name: nic3 173 | - type: vlan 174 | device: infra-bond 175 | vlan_id: 176 | get_param: StorageNetworkVlanID 177 | addresses: 178 | - ip_netmask: 179 | get_param: StorageIpSubnet 180 | - type: vlan 181 | device: infra-bond 182 | vlan_id: 183 | get_param: InternalApiNetworkVlanID 184 | addresses: 185 | - ip_netmask: 186 | get_param: InternalApiIpSubnet 187 | - type: linux_bond 188 | name: tenant-bond 189 | dns_servers: 190 | get_param: DnsServers 191 | bonding_options: 192 | get_param: BondInterfaceOvsOptions 193 | members: 194 | - type: sriov_pf 195 | name: 196 | get_param: MellanoxTenantPort1 197 | link_mode: switchdev 198 | numvfs: 8 199 | promisc: true 200 | use_dhcp: false 201 | primary: true 202 | - type: sriov_pf 203 | name: 204 | get_param: MellanoxTenantPort2 205 | link_mode: switchdev 206 | numvfs: 8 207 | promisc: true 208 | use_dhcp: false 209 | - type: vlan 210 | device: tenant-bond 211 | vlan_id: 212 | get_param: TenantNetworkVlanID 213 | addresses: 214 | - ip_netmask: 215 | get_param: TenantIpSubnet 216 | outputs: 217 | OS::stack_id: 218 | description: The OsNetConfigImpl resource. 219 | value: 220 | get_resource: OsNetConfigImpl 221 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/network/config/bond-with-vlans/compute.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | description: > 3 | Software Config to drive os-net-config with 2 bonded nics on a bridge with VLANs attached for the Compute role. 4 | parameters: 5 | ControlPlaneIp: 6 | default: '' 7 | description: IP address/subnet on the ctlplane network 8 | type: string 9 | ControlPlaneSubnetCidr: 10 | default: '' 11 | description: > 12 | The subnet CIDR of the control plane network. (The parameter is 13 | automatically resolved from the ctlplane subnet's cidr attribute.) 14 | type: string 15 | ControlPlaneDefaultRoute: 16 | default: '' 17 | description: The default route of the control plane network. (The parameter 18 | is automatically resolved from the ctlplane subnet's gateway_ip attribute.) 19 | type: string 20 | ControlPlaneStaticRoutes: 21 | default: [] 22 | description: > 23 | Routes for the ctlplane network traffic. 24 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 25 | Unless the default is changed, the parameter is automatically resolved 26 | from the subnet host_routes attribute. 27 | type: json 28 | ControlPlaneMtu: 29 | default: 1500 30 | description: The maximum transmission unit (MTU) size(in bytes) that is 31 | guaranteed to pass through the data path of the segments in the network. 32 | (The parameter is automatically resolved from the ctlplane network's mtu attribute.) 33 | type: number 34 | 35 | StorageIpSubnet: 36 | default: '' 37 | description: IP address/subnet on the storage network 38 | type: string 39 | StorageNetworkVlanID: 40 | default: 30 41 | description: Vlan ID for the storage network traffic. 42 | type: number 43 | StorageMtu: 44 | default: 1500 45 | description: The maximum transmission unit (MTU) size(in bytes) that is 46 | guaranteed to pass through the data path of the segments in the 47 | Storage network. 48 | type: number 49 | StorageInterfaceRoutes: 50 | default: [] 51 | description: > 52 | Routes for the storage network traffic. 53 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 54 | Unless the default is changed, the parameter is automatically resolved 55 | from the subnet host_routes attribute. 56 | type: json 57 | InternalApiIpSubnet: 58 | default: '' 59 | description: IP address/subnet on the internal_api network 60 | type: string 61 | InternalApiNetworkVlanID: 62 | default: 20 63 | description: Vlan ID for the internal_api network traffic. 64 | type: number 65 | InternalApiMtu: 66 | default: 1500 67 | description: The maximum transmission unit (MTU) size(in bytes) that is 68 | guaranteed to pass through the data path of the segments in the 69 | InternalApi network. 70 | type: number 71 | InternalApiInterfaceRoutes: 72 | default: [] 73 | description: > 74 | Routes for the internal_api network traffic. 75 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 76 | Unless the default is changed, the parameter is automatically resolved 77 | from the subnet host_routes attribute. 78 | type: json 79 | TenantIpSubnet: 80 | default: '' 81 | description: IP address/subnet on the tenant network 82 | type: string 83 | TenantNetworkVlanID: 84 | default: 50 85 | description: Vlan ID for the tenant network traffic. 86 | type: number 87 | TenantMtu: 88 | default: 1500 89 | description: The maximum transmission unit (MTU) size(in bytes) that is 90 | guaranteed to pass through the data path of the segments in the 91 | Tenant network. 92 | type: number 93 | TenantInterfaceRoutes: 94 | default: [] 95 | description: > 96 | Routes for the tenant network traffic. 97 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 98 | Unless the default is changed, the parameter is automatically resolved 99 | from the subnet host_routes attribute. 100 | type: json 101 | DnsServers: # Override this via parameter_defaults 102 | default: [] 103 | description: > 104 | DNS servers to use for the Overcloud (2 max for some implementations). 105 | If not set the nameservers configured in the ctlplane subnet's 106 | dns_nameservers attribute will be used. 107 | type: comma_delimited_list 108 | DnsSearchDomains: # Override this via parameter_defaults 109 | default: [] 110 | description: A list of DNS search domains to be added (in order) to resolv.conf. 111 | type: comma_delimited_list 112 | BondInterfaceOvsOptions: 113 | default: bond_mode=active-backup 114 | description: 'The ovs_options or bonding_options string for the bond 115 | interface. Set things like lacp=active and/or bond_mode=balance-slb 116 | for OVS bonds or like mode=4 for Linux bonds using this option.' 117 | type: string 118 | resources: 119 | 120 | MinViableMtu: 121 | # This resource resolves the minimum viable MTU for interfaces, bonds and 122 | # bridges that carry multiple VLANs. Each VLAN may have different MTU. The 123 | # bridge, bond or interface must have an MTU to allow the VLAN with the 124 | # largest MTU. 125 | type: OS::Heat::Value 126 | properties: 127 | type: number 128 | value: 129 | yaql: 130 | expression: $.data.max() 131 | data: 132 | - {get_param: ControlPlaneMtu} 133 | - {get_param: StorageMtu} 134 | - {get_param: InternalApiMtu} 135 | - {get_param: TenantMtu} 136 | 137 | OsNetConfigImpl: 138 | type: OS::Heat::SoftwareConfig 139 | properties: 140 | group: script 141 | config: 142 | str_replace: 143 | template: 144 | get_file: /usr/share/openstack-tripleo-heat-templates/network/scripts/run-os-net-config.sh 145 | params: 146 | $network_config: 147 | network_config: 148 | - type: interface 149 | name: nic1 150 | mtu: 151 | get_param: ControlPlaneMtu 152 | use_dhcp: false 153 | addresses: 154 | - ip_netmask: 155 | list_join: 156 | - / 157 | - - get_param: ControlPlaneIp 158 | - get_param: ControlPlaneSubnetCidr 159 | routes: 160 | list_concat_unique: 161 | - get_param: ControlPlaneStaticRoutes 162 | - - default: true 163 | next_hop: 164 | get_param: ControlPlaneDefaultRoute 165 | - type: linux_bond 166 | name: bond1 167 | mtu: 168 | get_attr: [MinViableMtu, value] 169 | bonding_options: 170 | get_param: BondInterfaceOvsOptions 171 | use_dhcp: false 172 | dns_servers: 173 | get_param: DnsServers 174 | members: 175 | - type: interface 176 | name: nic2 177 | mtu: 178 | get_attr: [MinViableMtu, value] 179 | primary: true 180 | - type: interface 181 | name: nic3 182 | mtu: 183 | get_attr: [MinViableMtu, value] 184 | - type: vlan 185 | device: bond1 186 | mtu: 187 | get_param: StorageMtu 188 | vlan_id: 189 | get_param: StorageNetworkVlanID 190 | addresses: 191 | - ip_netmask: 192 | get_param: StorageIpSubnet 193 | routes: 194 | list_concat_unique: 195 | - get_param: StorageInterfaceRoutes 196 | - type: vlan 197 | device: bond1 198 | mtu: 199 | get_param: InternalApiMtu 200 | vlan_id: 201 | get_param: InternalApiNetworkVlanID 202 | addresses: 203 | - ip_netmask: 204 | get_param: InternalApiIpSubnet 205 | routes: 206 | list_concat_unique: 207 | - get_param: InternalApiInterfaceRoutes 208 | - type: vlan 209 | device: bond1 210 | mtu: 211 | get_param: TenantMtu 212 | vlan_id: 213 | get_param: TenantNetworkVlanID 214 | addresses: 215 | - ip_netmask: 216 | get_param: TenantIpSubnet 217 | routes: 218 | list_concat_unique: 219 | - get_param: TenantInterfaceRoutes 220 | outputs: 221 | OS::stack_id: 222 | description: The OsNetConfigImpl resource. 223 | value: 224 | get_resource: OsNetConfigImpl -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/deployment/neutron/neutron-fastpath-agent.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | description: > 3 | OpenStack Neutron openvswitch service 4 | parameters: 5 | ContainerNeutronFastpathImage: 6 | description: image 7 | type: string 8 | ContainerNeutronConfigImage: 9 | description: The container image to use for the neutron config_volume 10 | type: string 11 | DockerOpenvswitchUlimit: 12 | default: ['nofile=16384'] 13 | description: ulimit for Openvswitch Container 14 | type: comma_delimited_list 15 | NeutronFastpathAgentLoggingSource: 16 | type: json 17 | default: 18 | tag: openstack.neutron.agent.fastpath 19 | file: /var/log/containers/neutron/fastpath-agent.log 20 | ServiceData: 21 | default: {} 22 | description: Dictionary packing service data 23 | type: json 24 | ServiceNetMap: 25 | default: {} 26 | description: Mapping of service_name -> network name. Typically set 27 | via parameter_defaults in the resource registry. This 28 | mapping overrides those in ServiceNetMapDefaults. 29 | type: json 30 | DefaultPasswords: 31 | default: {} 32 | type: json 33 | RoleName: 34 | default: '' 35 | description: Role name on which the service is applied 36 | type: string 37 | RoleParameters: 38 | default: {} 39 | description: Parameters specific to the role 40 | type: json 41 | EndpointMap: 42 | default: {} 43 | description: Mapping of service endpoint -> protocol. Typically set 44 | via parameter_defaults in the resource registry. 45 | type: json 46 | DeployIdentifier: 47 | default: '' 48 | type: string 49 | description: > 50 | Setting this to a unique value will re-run any deployment tasks which 51 | perform configuration on a Heat stack-update. 52 | PythonInterpreter: 53 | type: string 54 | description: The python interpreter to use for python and ansible actions 55 | default: "$(command -v python3 || command -v python)" 56 | MonitoringSubscriptionNeutronFastpath: 57 | default: 'overcloud-neutron-fastpath-agent' 58 | type: string 59 | NeutronFastpathOptVolumes: 60 | default: [] 61 | description: list of optional volumes to be mounted 62 | type: comma_delimited_list 63 | resources: 64 | ContainersCommon: 65 | type: /usr/share/openstack-tripleo-heat-templates/deployment/containers-common.yaml 66 | # Merging role-specific parameters (RoleParameters) with the default parameters. 67 | # RoleParameters will have the precedence over the default parameters. 68 | RoleParametersValue: 69 | type: OS::Heat::Value 70 | properties: 71 | type: json 72 | value: {get_param: RoleParameters} 73 | NeutronBase: 74 | type: /usr/share/openstack-tripleo-heat-templates/deployment/neutron/neutron-base.yaml 75 | properties: 76 | EndpointMap: {get_param: EndpointMap} 77 | ServiceData: {get_param: ServiceData} 78 | ServiceNetMap: {get_param: ServiceNetMap} 79 | DefaultPasswords: {get_param: DefaultPasswords} 80 | RoleName: {get_param: RoleName} 81 | RoleParameters: {get_param: RoleParameters} 82 | NeutronLogging: 83 | type: OS::TripleO::Services::Logging::NeutronCommon 84 | properties: 85 | NeutronServiceName: openvswitch-agent 86 | outputs: 87 | role_data: 88 | description: Role data for Neutron openvswitch service 89 | value: 90 | service_name: neutron_fastpath_agent 91 | monitoring_subscription: {get_param: MonitoringSubscriptionNeutronFastpath} 92 | config_settings: 93 | map_merge: 94 | - get_attr: [NeutronBase, role_data, config_settings] 95 | - get_attr: [RoleParametersValue, value] 96 | - get_attr: [NeutronLogging, config_settings] 97 | service_config_settings: 98 | map_merge: 99 | - get_attr: [NeutronBase, role_data, service_config_settings] 100 | - rsyslog: 101 | tripleo_logging_sources_neutron_ovs_agent: 102 | - {get_param: NeutronFastpathAgentLoggingSource} 103 | - collectd: 104 | tripleo.collectd.plugins.neutron_ovs_agent: 105 | - ovs_events 106 | - ovs_stats 107 | collectd::plugin::ovs_events::socket: '/var/run/openvswitch/db.sock' 108 | collectd::plugin::ovs_stats::socket: '/var/run/openvswitch/db.sock' 109 | puppet_config: 110 | config_volume: neutron 111 | puppet_tags: neutron_config,neutron_plugin_ml2 112 | step_config: | 113 | include ::tripleo::profile::base::neutron 114 | config_image: {get_param: ContainerNeutronConfigImage} 115 | # We need to mount /run for puppet_config step. This is because 116 | # puppet-vswitch runs the commands "ovs-vsctl list open_vswitch ." 117 | # when running vswitch::ovs::enable_hw_offload: true 118 | # ovs-vsctl talks to the ovsdb-server (hosting conf.db) 119 | # on the unix domain socket - /run/openvswitch/db.sock 120 | volumes: 121 | - /lib/modules:/lib/modules:ro 122 | - /run/openvswitch:/run/openvswitch:shared,z 123 | kolla_config: 124 | /var/lib/kolla/config_files/neutron_fastpath_agent.json: 125 | command: /neutron-fastpath-agent-launcher.sh 126 | config_files: 127 | - source: "/var/lib/kolla/config_files/src/*" 128 | dest: "/" 129 | merge: true 130 | preserve_properties: true 131 | permissions: 132 | - path: /var/log/neutron 133 | owner: neutron:neutron 134 | recurse: true 135 | container_config_scripts: 136 | neutron-fastpath-agent-launcher.sh: 137 | mode: "0755" 138 | content: 139 | str_replace: 140 | template: | 141 | #!/bin/bash 142 | set -xe 143 | /usr/bin/python3 /usr/bin/neutron-fastpath-agent \ 144 | --config-file /etc/neutron/rootwrap.conf \ 145 | --config-file /etc/neutron/neutron.conf \ 146 | --config-dir /etc/neutron/conf.d/common \ 147 | --log-file /var/log/neutron/neutron-fastpath-agent.log 148 | params: 149 | PYTHON: {get_param: PythonInterpreter} 150 | docker_config: 151 | step_4: 152 | neutron_fastpath_agent: 153 | start_order: 10 154 | image: {get_param: ContainerNeutronFastpathImage} 155 | net: host 156 | pid: host 157 | privileged: true 158 | security_opt: 'label=disable' 159 | restart: always 160 | depends_on: 161 | - openvswitch.service 162 | healthcheck: {get_attr: [ContainersCommon, healthcheck_rpc_port]} 163 | ulimit: {get_param: DockerOpenvswitchUlimit} 164 | volumes: 165 | list_concat: 166 | - {get_attr: [ContainersCommon, volumes]} 167 | - {get_attr: [NeutronLogging, volumes]} 168 | - {get_param: NeutronFastpathOptVolumes} 169 | - 170 | - /var/lib/kolla/config_files/neutron_fastpath_agent.json:/var/lib/kolla/config_files/config.json:ro 171 | - /var/lib/config-data/puppet-generated/neutron:/var/lib/kolla/config_files/src:ro 172 | - /var/lib/container-config-scripts/neutron-fastpath-agent-launcher.sh:/neutron-fastpath-agent-launcher.sh:ro 173 | - /lib/modules:/lib/modules:ro 174 | - /run/openvswitch:/run/openvswitch:shared,z 175 | environment: 176 | KOLLA_CONFIG_STRATEGY: COPY_ALWAYS 177 | metadata_settings: 178 | get_attr: [NeutronBase, role_data, metadata_settings] 179 | host_prep_tasks: 180 | list_concat: 181 | - {get_attr: [NeutronLogging, host_prep_tasks]} 182 | - 183 | - block: 184 | - name: load openvswitch module 185 | import_role: 186 | name: tripleo-module-load 187 | vars: 188 | modules: 189 | - name: openvswitch 190 | - name: Copy in cleanup script 191 | copy: 192 | content: {get_file: /usr/share/openstack-tripleo-heat-templates/deployment/neutron/neutron-cleanup} 193 | dest: '/usr/libexec/neutron-cleanup' 194 | force: yes 195 | mode: '0755' 196 | - name: Copy in cleanup service 197 | copy: 198 | content: {get_file: /usr/share/openstack-tripleo-heat-templates/deployment/neutron/neutron-cleanup.service} 199 | dest: '/usr/lib/systemd/system/neutron-cleanup.service' 200 | force: yes 201 | - name: Enabling the cleanup service 202 | service: 203 | name: neutron-cleanup 204 | enabled: yes 205 | - name: enable virt_sandbox_use_netlink for healtcheck 206 | seboolean: 207 | name: virt_sandbox_use_netlink 208 | persistent: yes 209 | state: yes 210 | - name: Run iptables -t raw -L to workaround a rhel8.0 bug (remove once rhbz#1673609 is fixed) 211 | shell: | 212 | iptables -t raw -nL 213 | ip6tables -t raw -nL 214 | -------------------------------------------------------------------------------- /image-patching/nuage_image_patching_scripts/utils/common.py: -------------------------------------------------------------------------------- 1 | # !/usr/bin/python3 2 | # Copyright 2020,2021 NOKIA 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an 12 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, 13 | # either express or implied. See the License for the specific 14 | # language governing permissions and limitations under the License. 15 | 16 | import subprocess 17 | import sys 18 | import logging 19 | import os 20 | from nuage_image_patching_scripts.utils import constants 21 | 22 | 23 | logger = logging.getLogger(constants.LOG_FILE_NAME) 24 | 25 | 26 | ##### 27 | # Function to run commands on the console 28 | ##### 29 | 30 | 31 | def cmds_run(cmds): 32 | if not cmds: 33 | return 34 | output_list = [] 35 | for cmd in cmds: 36 | proc = subprocess.Popen( 37 | cmd, 38 | stdout=subprocess.PIPE, 39 | stderr=subprocess.PIPE, 40 | shell=True, 41 | close_fds=True) 42 | (out, err) = proc.communicate() 43 | if err and err.split(): 44 | logger.error( 45 | "error occurred during command:\n %s\n error:\n %s \n " 46 | "exiting" % (cmd, err)) 47 | sys.exit(1) 48 | output_list.append(out.decode()) 49 | 50 | if len(cmds) == 1: 51 | if output_list[0]: 52 | logger.debug("%s" % output_list[0]) 53 | return output_list[0] 54 | else: 55 | if output_list: 56 | logger.debug("%s" % output_list) 57 | return output_list 58 | 59 | 60 | def virt_customize(command): 61 | return cmds_run( 62 | [constants.VIRT_CUSTOMIZE_ENV + 'virt-customize ' 63 | '--run-command %s' % 64 | command]) 65 | 66 | 67 | def virt_customize_run(command): 68 | return cmds_run([constants.VIRT_CUSTOMIZE_ENV + 'virt-customize ' 69 | '--run %s' % 70 | command]) 71 | 72 | 73 | def virt_copy(command): 74 | return cmds_run([constants.VIRT_CUSTOMIZE_ENV + 'virt-copy-in ' 75 | '-a %s' % command]) 76 | 77 | 78 | ##### 79 | # Check if the provided path to the file exists 80 | ##### 81 | 82 | 83 | def file_exists(filename): 84 | if os.path.isfile(filename): 85 | return True 86 | else: 87 | logger.error("%s is not present in the location of this " 88 | "script" % filename) 89 | sys.exit(1) 90 | 91 | 92 | ##### 93 | # Function to add RHEL subscription using guestfish 94 | ##### 95 | 96 | 97 | def start_script(): 98 | cmds = '''#!/bin/bash 99 | set -xe 100 | ''' 101 | constants.PATCHING_SCRIPT += cmds 102 | 103 | 104 | ##### 105 | # Function that writes commands to a file 106 | ##### 107 | 108 | def write_to_file(contents): 109 | if os.path.isfile(constants.SCRIPT_NAME): 110 | os.remove(constants.SCRIPT_NAME) 111 | 112 | with open(constants.SCRIPT_NAME, 'a') as script: 113 | script.writelines(contents) 114 | 115 | ##### 116 | # Importing Gpgkeys to Overcloud image 117 | ##### 118 | 119 | 120 | def importing_gpgkeys(image, gpgkeys): 121 | cmd = ''' 122 | #### Importing GPG keys 123 | ''' 124 | constants.PATCHING_SCRIPT += cmd 125 | for gpgkey in gpgkeys: 126 | file_exist = os.path.isfile(gpgkey) 127 | file_name = os.path.basename(gpgkey) 128 | if file_exist: 129 | virt_copy('%s %s %s' % (image, gpgkey, 130 | constants.TEMPORARY_PATH)) 131 | rpm_import = ''' 132 | rpm --import %s%s 133 | ''' % (constants.TEMPORARY_PATH, file_name) 134 | constants.PATCHING_SCRIPT += rpm_import 135 | 136 | else: 137 | logger.error("Nuage package signing key is not present " 138 | "in %s ," 139 | "Installation cannot proceed. Please place " 140 | "the " 141 | "signing key in the correct location and" 142 | " retry" % 143 | gpgkey) 144 | 145 | sys.exit(1) 146 | 147 | 148 | #### 149 | # Copying repo file to overcloud image 150 | #### 151 | 152 | 153 | def copy_repo_file(image, repofile): 154 | if os.path.isfile(repofile): 155 | virt_copy('%s %s /etc/yum.repos.d/' % (image, repofile)) 156 | else: 157 | logger.error("Repo file doesn't exists at %s" 158 | "Please provide the correct path of RepoFile" % 159 | repofile) 160 | sys.exit(1) 161 | 162 | 163 | ##### 164 | # Function to add RHEL subscription using guestfish 165 | # https://access.redhat.com/documentation/en-us/red_hat_openstack_platform/16.1/html/partner_integration/overcloud_images 166 | ##### 167 | 168 | 169 | def rhel_subscription(username, password, pool, satellite_url, satellite_org, 170 | satellite_key, proxy_hostname, proxy_port, 171 | rhel_sub_type, deployment_type): 172 | subscription_command = '' 173 | if proxy_hostname and proxy_port: 174 | subscription_command += ( 175 | "subscription-manager config" 176 | " --server.proxy_hostname=%s " 177 | " --server.proxy_port=%s\n" 178 | % (proxy_hostname, proxy_port) 179 | ) 180 | # this does not allow multiple runs of the patching script 181 | if rhel_sub_type == constants.RHEL_SUB_SATELLITE: 182 | subscription_command += ( 183 | "hostname nuage-patching\n" 184 | "sudo curl -k %(0)s/pub/katello-ca-consumer-latest.noarch.rpm -o " 185 | "%(1)skatello-ca-consumer-latest.noarch.rpm\n" 186 | "sudo rpm -Uvh %(1)skatello-ca-consumer-latest.noarch.rpm\n" 187 | "rm -rf %(1)skatello-ca-consumer-latest.noarch.rpm\n" 188 | % {'0': satellite_url, '1': constants.TEMPORARY_PATH} 189 | ) 190 | subscription_command += ( 191 | "subscription-manager register" 192 | " --org='%s' --activationkey='%s'\n" % 193 | (satellite_org, satellite_key) 194 | ) 195 | else: 196 | subscription_command += ( 197 | "subscription-manager register " 198 | "--username='%s' --password='%s' --force \n" % (username, password) 199 | ) 200 | subscription_command += ( 201 | "subscription-manager attach --pool='%s'\n" % pool 202 | ) 203 | subscription_command += ( 204 | "subscription-manager release --set=%s\n" % 205 | constants.RHEL_VERSION 206 | ) 207 | # Documentation suggest to also enable the following repos 208 | # but testing shows enabling "fast-datapath-for-rhel-8-x86_64-rpms" and 209 | # "ansible-2.9-for-rhel-8-x86_64-rpms" do not really make a difference 210 | # and openstack-16.1-for-rhel-8-x86_64-rpms is also only need for avrs deployments 211 | # But enabeling anyway for future 212 | subscription_command += ( 213 | "subscription-manager repos " 214 | "--enable=rhel-8-for-x86_64-baseos-eus-rpms " 215 | "--enable=rhel-8-for-x86_64-appstream-eus-rpms " 216 | "--enable=rhel-8-for-x86_64-highavailability-eus-rpms " 217 | "--enable=fast-datapath-for-rhel-8-x86_64-rpms " 218 | "--enable=ansible-2.9-for-rhel-8-x86_64-rpms " 219 | "--enable=openstack-16.1-for-rhel-8-x86_64-rpms " 220 | "--enable=advanced-virt-for-rhel-8-x86_64-rpms \n " 221 | ) 222 | constants.PATCHING_SCRIPT += subscription_command 223 | 224 | 225 | def select_dnf_modules_versions(): 226 | constants.PATCHING_SCRIPT += ( 227 | "dnf module disable -y container-tools:rhel8\n" 228 | "dnf module enable -y container-tools:%s\n" 229 | "dnf module disable -y virt:rhel\n" 230 | "dnf module enable -y virt:%s" 231 | % (constants.DNF_VERSION_CONTAINER_TOOLS, constants.DNF_VERSION_VIRT, ) 232 | ) 233 | 234 | 235 | ##### 236 | # Function to remove the RHEL subscription 237 | ##### 238 | 239 | 240 | def rhel_remove_subscription(rhel_sub_type=None): 241 | cmd = ''' 242 | #### Removing RHEL Subscription 243 | subscription-manager remove --all\n 244 | subscription-manager unregister 245 | ''' 246 | if rhel_sub_type == constants.RHEL_SUB_SATELLITE: 247 | cmd += ( 248 | "rpm -qa" 249 | "| grep katello-ca-consumer" 250 | "| xargs sudo rpm -e" 251 | ) 252 | constants.PATCHING_SCRIPT += cmd 253 | 254 | ##### 255 | # Function to install packages nuage python ovs 256 | ##### 257 | 258 | 259 | def install_nuage_python_ovs_packages(): 260 | cmd = ''' 261 | #### Install Nuage Python OpenvSwitch 262 | yum install --setopt=skip_missing_names_on_install=False -y %s 263 | yum clean all 264 | ''' % constants.NUAGE_PYTHON_OVS 265 | constants.PATCHING_SCRIPT += cmd 266 | 267 | ##### 268 | # Function to remove packages that are not needed 269 | ##### 270 | 271 | 272 | def uninstall_packages(): 273 | cmd = ''' 274 | #### Removing Upstream OpenvSwitch 275 | ovs_package_name=$(rpm -qa | awk -F- \ 276 | '/^(openvswitch[0-9]+\.[0-9]+-|openvswitch-2)/{print $1}') 277 | yum remove -y $ovs_package_name network-scripts-$ovs_package_name --noautoremove 278 | yum clean all 279 | ''' 280 | constants.PATCHING_SCRIPT += cmd 281 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/network/config/bond-with-vlans/computesriov.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | description: > 3 | Software Config to drive os-net-config with 2 bonded nics on a bridge with VLANs attached for the Compute role. 4 | parameters: 5 | ControlPlaneIp: 6 | default: '' 7 | description: IP address/subnet on the ctlplane network 8 | type: string 9 | ControlPlaneSubnetCidr: 10 | default: '' 11 | description: > 12 | The subnet CIDR of the control plane network. (The parameter is 13 | automatically resolved from the ctlplane subnet's cidr attribute.) 14 | type: string 15 | ControlPlaneDefaultRoute: 16 | default: '' 17 | description: The default route of the control plane network. (The parameter 18 | is automatically resolved from the ctlplane subnet's gateway_ip attribute.) 19 | type: string 20 | ControlPlaneStaticRoutes: 21 | default: [] 22 | description: > 23 | Routes for the ctlplane network traffic. 24 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 25 | Unless the default is changed, the parameter is automatically resolved 26 | from the subnet host_routes attribute. 27 | type: json 28 | ControlPlaneMtu: 29 | default: 1500 30 | description: The maximum transmission unit (MTU) size(in bytes) that is 31 | guaranteed to pass through the data path of the segments in the network. 32 | (The parameter is automatically resolved from the ctlplane network's mtu attribute.) 33 | type: number 34 | 35 | StorageIpSubnet: 36 | default: '' 37 | description: IP address/subnet on the storage network 38 | type: string 39 | StorageNetworkVlanID: 40 | default: 30 41 | description: Vlan ID for the storage network traffic. 42 | type: number 43 | StorageMtu: 44 | default: 1500 45 | description: The maximum transmission unit (MTU) size(in bytes) that is 46 | guaranteed to pass through the data path of the segments in the 47 | Storage network. 48 | type: number 49 | StorageInterfaceRoutes: 50 | default: [] 51 | description: > 52 | Routes for the storage network traffic. 53 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 54 | Unless the default is changed, the parameter is automatically resolved 55 | from the subnet host_routes attribute. 56 | type: json 57 | InternalApiIpSubnet: 58 | default: '' 59 | description: IP address/subnet on the internal_api network 60 | type: string 61 | InternalApiNetworkVlanID: 62 | default: 20 63 | description: Vlan ID for the internal_api network traffic. 64 | type: number 65 | InternalApiMtu: 66 | default: 1500 67 | description: The maximum transmission unit (MTU) size(in bytes) that is 68 | guaranteed to pass through the data path of the segments in the 69 | InternalApi network. 70 | type: number 71 | InternalApiInterfaceRoutes: 72 | default: [] 73 | description: > 74 | Routes for the internal_api network traffic. 75 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 76 | Unless the default is changed, the parameter is automatically resolved 77 | from the subnet host_routes attribute. 78 | type: json 79 | TenantIpSubnet: 80 | default: '' 81 | description: IP address/subnet on the tenant network 82 | type: string 83 | TenantNetworkVlanID: 84 | default: 50 85 | description: Vlan ID for the tenant network traffic. 86 | type: number 87 | TenantMtu: 88 | default: 1500 89 | description: The maximum transmission unit (MTU) size(in bytes) that is 90 | guaranteed to pass through the data path of the segments in the 91 | Tenant network. 92 | type: number 93 | TenantInterfaceRoutes: 94 | default: [] 95 | description: > 96 | Routes for the tenant network traffic. 97 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 98 | Unless the default is changed, the parameter is automatically resolved 99 | from the subnet host_routes attribute. 100 | type: json 101 | DnsServers: # Override this via parameter_defaults 102 | default: [] 103 | description: > 104 | DNS servers to use for the Overcloud (2 max for some implementations). 105 | If not set the nameservers configured in the ctlplane subnet's 106 | dns_nameservers attribute will be used. 107 | type: comma_delimited_list 108 | DnsSearchDomains: # Override this via parameter_defaults 109 | default: [] 110 | description: A list of DNS search domains to be added (in order) to resolv.conf. 111 | type: comma_delimited_list 112 | BondInterfaceOvsOptions: 113 | default: bond_mode=active-backup 114 | description: 'The ovs_options or bonding_options string for the bond 115 | interface. Set things like lacp=active and/or bond_mode=balance-slb 116 | for OVS bonds or like mode=4 for Linux bonds using this option.' 117 | type: string 118 | resources: 119 | 120 | MinViableMtu: 121 | # This resource resolves the minimum viable MTU for interfaces, bonds and 122 | # bridges that carry multiple VLANs. Each VLAN may have different MTU. The 123 | # bridge, bond or interface must have an MTU to allow the VLAN with the 124 | # largest MTU. 125 | type: OS::Heat::Value 126 | properties: 127 | type: number 128 | value: 129 | yaql: 130 | expression: $.data.max() 131 | data: 132 | - {get_param: ControlPlaneMtu} 133 | - {get_param: StorageMtu} 134 | - {get_param: InternalApiMtu} 135 | - {get_param: TenantMtu} 136 | 137 | OsNetConfigImpl: 138 | type: OS::Heat::SoftwareConfig 139 | properties: 140 | group: script 141 | config: 142 | str_replace: 143 | template: 144 | get_file: /usr/share/openstack-tripleo-heat-templates/network/scripts/run-os-net-config.sh 145 | params: 146 | $network_config: 147 | network_config: 148 | - type: interface 149 | name: nic1 150 | mtu: 151 | get_param: ControlPlaneMtu 152 | use_dhcp: false 153 | addresses: 154 | - ip_netmask: 155 | list_join: 156 | - / 157 | - - get_param: ControlPlaneIp 158 | - get_param: ControlPlaneSubnetCidr 159 | routes: 160 | list_concat_unique: 161 | - get_param: ControlPlaneStaticRoutes 162 | - - default: true 163 | next_hop: 164 | get_param: ControlPlaneDefaultRoute 165 | # Linux bond for non-DPDK traffic required when using DPDK 166 | - type: linux_bond 167 | name: bond1 168 | mtu: 169 | get_attr: [MinViableMtu, value] 170 | bonding_options: 171 | get_param: BondInterfaceOvsOptions 172 | use_dhcp: false 173 | dns_servers: 174 | get_param: DnsServers 175 | members: 176 | - type: interface 177 | name: nic2 178 | mtu: 179 | get_attr: [MinViableMtu, value] 180 | primary: true 181 | - type: interface 182 | name: nic3 183 | mtu: 184 | get_attr: [MinViableMtu, value] 185 | - type: vlan 186 | device: bond1 187 | mtu: 188 | get_param: StorageMtu 189 | vlan_id: 190 | get_param: StorageNetworkVlanID 191 | addresses: 192 | - ip_netmask: 193 | get_param: StorageIpSubnet 194 | routes: 195 | list_concat_unique: 196 | - get_param: StorageInterfaceRoutes 197 | - type: vlan 198 | device: bond1 199 | mtu: 200 | get_param: InternalApiMtu 201 | vlan_id: 202 | get_param: InternalApiNetworkVlanID 203 | addresses: 204 | - ip_netmask: 205 | get_param: InternalApiIpSubnet 206 | routes: 207 | list_concat_unique: 208 | - get_param: InternalApiInterfaceRoutes 209 | - type: linux_bond 210 | name: tenant-bond 211 | mtu: 212 | get_attr: [MinViableMtu, value] 213 | bonding_options: 214 | get_param: BondInterfaceOvsOptions 215 | use_dhcp: false 216 | dns_servers: 217 | get_param: DnsServers 218 | members: 219 | - type: interface 220 | name: ens15f0 221 | mtu: 222 | get_attr: [MinViableMtu, value] 223 | primary: true 224 | - type: interface 225 | name: ens15f1 226 | mtu: 227 | get_attr: [MinViableMtu, value] 228 | - type: vlan 229 | device: tenant-bond 230 | mtu: 231 | get_param: TenantMtu 232 | vlan_id: 233 | get_param: TenantNetworkVlanID 234 | addresses: 235 | - ip_netmask: 236 | get_param: TenantIpSubnet 237 | routes: 238 | list_concat_unique: 239 | - get_param: TenantInterfaceRoutes 240 | outputs: 241 | OS::stack_id: 242 | description: The OsNetConfigImpl resource. 243 | value: 244 | get_resource: OsNetConfigImpl -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | 2 | Apache License 3 | Version 2.0, January 2004 4 | http://www.apache.org/licenses/ 5 | 6 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 7 | 8 | 1. Definitions. 9 | 10 | "License" shall mean the terms and conditions for use, reproduction, 11 | and distribution as defined by Sections 1 through 9 of this document. 12 | 13 | "Licensor" shall mean the copyright owner or entity authorized by 14 | the copyright owner that is granting the License. 15 | 16 | "Legal Entity" shall mean the union of the acting entity and all 17 | other entities that control, are controlled by, or are under common 18 | control with that entity. For the purposes of this definition, 19 | "control" means (i) the power, direct or indirect, to cause the 20 | direction or management of such entity, whether by contract or 21 | otherwise, or (ii) ownership of fifty percent (50%) or more of the 22 | outstanding shares, or (iii) beneficial ownership of such entity. 23 | 24 | "You" (or "Your") shall mean an individual or Legal Entity 25 | exercising permissions granted by this License. 26 | 27 | "Source" form shall mean the preferred form for making modifications, 28 | including but not limited to software source code, documentation 29 | source, and configuration files. 30 | 31 | "Object" form shall mean any form resulting from mechanical 32 | transformation or translation of a Source form, including but 33 | not limited to compiled object code, generated documentation, 34 | and conversions to other media types. 35 | 36 | "Work" shall mean the work of authorship, whether in Source or 37 | Object form, made available under the License, as indicated by a 38 | copyright notice that is included in or attached to the work 39 | (an example is provided in the Appendix below). 40 | 41 | "Derivative Works" shall mean any work, whether in Source or Object 42 | form, that is based on (or derived from) the Work and for which the 43 | editorial revisions, annotations, elaborations, or other modifications 44 | represent, as a whole, an original work of authorship. For the purposes 45 | of this License, Derivative Works shall not include works that remain 46 | separable from, or merely link (or bind by name) to the interfaces of, 47 | the Work and Derivative Works thereof. 48 | 49 | "Contribution" shall mean any work of authorship, including 50 | the original version of the Work and any modifications or additions 51 | to that Work or Derivative Works thereof, that is intentionally 52 | submitted to Licensor for inclusion in the Work by the copyright owner 53 | or by an individual or Legal Entity authorized to submit on behalf of 54 | the copyright owner. For the purposes of this definition, "submitted" 55 | means any form of electronic, verbal, or written communication sent 56 | to the Licensor or its representatives, including but not limited to 57 | communication on electronic mailing lists, source code control systems, 58 | and issue tracking systems that are managed by, or on behalf of, the 59 | Licensor for the purpose of discussing and improving the Work, but 60 | excluding communication that is conspicuously marked or otherwise 61 | designated in writing by the copyright owner as "Not a Contribution." 62 | 63 | "Contributor" shall mean Licensor and any individual or Legal Entity 64 | on behalf of whom a Contribution has been received by Licensor and 65 | subsequently incorporated within the Work. 66 | 67 | 2. Grant of Copyright License. Subject to the terms and conditions of 68 | this License, each Contributor hereby grants to You a perpetual, 69 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 70 | copyright license to reproduce, prepare Derivative Works of, 71 | publicly display, publicly perform, sublicense, and distribute the 72 | Work and such Derivative Works in Source or Object form. 73 | 74 | 3. Grant of Patent License. Subject to the terms and conditions of 75 | this License, each Contributor hereby grants to You a perpetual, 76 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 77 | (except as stated in this section) patent license to make, have made, 78 | use, offer to sell, sell, import, and otherwise transfer the Work, 79 | where such license applies only to those patent claims licensable 80 | by such Contributor that are necessarily infringed by their 81 | Contribution(s) alone or by combination of their Contribution(s) 82 | with the Work to which such Contribution(s) was submitted. If You 83 | institute patent litigation against any entity (including a 84 | cross-claim or counterclaim in a lawsuit) alleging that the Work 85 | or a Contribution incorporated within the Work constitutes direct 86 | or contributory patent infringement, then any patent licenses 87 | granted to You under this License for that Work shall terminate 88 | as of the date such litigation is filed. 89 | 90 | 4. Redistribution. You may reproduce and distribute copies of the 91 | Work or Derivative Works thereof in any medium, with or without 92 | modifications, and in Source or Object form, provided that You 93 | meet the following conditions: 94 | 95 | (a) You must give any other recipients of the Work or 96 | Derivative Works a copy of this License; and 97 | 98 | (b) You must cause any modified files to carry prominent notices 99 | stating that You changed the files; and 100 | 101 | (c) You must retain, in the Source form of any Derivative Works 102 | that You distribute, all copyright, patent, trademark, and 103 | attribution notices from the Source form of the Work, 104 | excluding those notices that do not pertain to any part of 105 | the Derivative Works; and 106 | 107 | (d) If the Work includes a "NOTICE" text file as part of its 108 | distribution, then any Derivative Works that You distribute must 109 | include a readable copy of the attribution notices contained 110 | within such NOTICE file, excluding those notices that do not 111 | pertain to any part of the Derivative Works, in at least one 112 | of the following places: within a NOTICE text file distributed 113 | as part of the Derivative Works; within the Source form or 114 | documentation, if provided along with the Derivative Works; or, 115 | within a display generated by the Derivative Works, if and 116 | wherever such third-party notices normally appear. The contents 117 | of the NOTICE file are for informational purposes only and 118 | do not modify the License. You may add Your own attribution 119 | notices within Derivative Works that You distribute, alongside 120 | or as an addendum to the NOTICE text from the Work, provided 121 | that such additional attribution notices cannot be construed 122 | as modifying the License. 123 | 124 | You may add Your own copyright statement to Your modifications and 125 | may provide additional or different license terms and conditions 126 | for use, reproduction, or distribution of Your modifications, or 127 | for any such Derivative Works as a whole, provided Your use, 128 | reproduction, and distribution of the Work otherwise complies with 129 | the conditions stated in this License. 130 | 131 | 5. Submission of Contributions. Unless You explicitly state otherwise, 132 | any Contribution intentionally submitted for inclusion in the Work 133 | by You to the Licensor shall be under the terms and conditions of 134 | this License, without any additional terms or conditions. 135 | Notwithstanding the above, nothing herein shall supersede or modify 136 | the terms of any separate license agreement you may have executed 137 | with Licensor regarding such Contributions. 138 | 139 | 6. Trademarks. This License does not grant permission to use the trade 140 | names, trademarks, service marks, or product names of the Licensor, 141 | except as required for reasonable and customary use in describing the 142 | origin of the Work and reproducing the content of the NOTICE file. 143 | 144 | 7. Disclaimer of Warranty. Unless required by applicable law or 145 | agreed to in writing, Licensor provides the Work (and each 146 | Contributor provides its Contributions) on an "AS IS" BASIS, 147 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 148 | implied, including, without limitation, any warranties or conditions 149 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A 150 | PARTICULAR PURPOSE. You are solely responsible for determining the 151 | appropriateness of using or redistributing the Work and assume any 152 | risks associated with Your exercise of permissions under this License. 153 | 154 | 8. Limitation of Liability. In no event and under no legal theory, 155 | whether in tort (including negligence), contract, or otherwise, 156 | unless required by applicable law (such as deliberate and grossly 157 | negligent acts) or agreed to in writing, shall any Contributor be 158 | liable to You for damages, including any direct, indirect, special, 159 | incidental, or consequential damages of any character arising as a 160 | result of this License or out of the use or inability to use the 161 | Work (including but not limited to damages for loss of goodwill, 162 | work stoppage, computer failure or malfunction, or any and all 163 | other commercial damages or losses), even if such Contributor 164 | has been advised of the possibility of such damages. 165 | 166 | 9. Accepting Warranty or Additional Liability. While redistributing 167 | the Work or Derivative Works thereof, You may choose to offer, 168 | and charge a fee for, acceptance of support, warranty, indemnity, 169 | or other liability obligations and/or rights consistent with this 170 | License. However, in accepting such obligations, You may act only 171 | on Your own behalf and on Your sole responsibility, not on behalf 172 | of any other Contributor, and only if You agree to indemnify, 173 | defend, and hold each Contributor harmless for any liability 174 | incurred by, or claims asserted against, such Contributor by reason 175 | of your accepting any such warranty or additional liability. 176 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/deployment/neutron/neutron-plugin-ml2-nuage.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | 3 | description: > 4 | OpenStack Neutron ML2/Nuage plugin configured with Puppet 5 | 6 | parameters: 7 | ServiceData: 8 | default: { } 9 | description: Dictionary packing service data 10 | type: json 11 | ServiceNetMap: 12 | default: { } 13 | description: Mapping of service_name -> network name. Typically set 14 | via parameter_defaults in the resource registry. This 15 | mapping overrides those in ServiceNetMapDefaults. 16 | type: json 17 | DefaultPasswords: 18 | default: { } 19 | type: json 20 | RoleName: 21 | default: '' 22 | description: Role name on which the service is applied 23 | type: string 24 | RoleParameters: 25 | default: { } 26 | description: Parameters specific to the role 27 | type: json 28 | EndpointMap: 29 | default: { } 30 | description: Mapping of service endpoint -> protocol. Typically set 31 | via parameter_defaults in the resource registry. 32 | type: json 33 | # Config specific parameters, to be provided via parameter_defaults 34 | NeutronNuageNetPartitionName: 35 | description: Specifies the title that you will see on the VSD 36 | type: string 37 | default: 'default_name' 38 | NeutronNuageVSDIp: 39 | description: IP address and port of the Virtual Services Directory 40 | type: string 41 | NeutronNuageVSDUsername: 42 | description: Username to be used to log into VSD 43 | type: string 44 | NeutronNuageVSDPassword: 45 | description: Password to be used to log into VSD 46 | type: string 47 | NeutronNuageVSDOrganization: 48 | description: Organization parameter required to log into VSD 49 | type: string 50 | default: 'organization' 51 | NeutronNuageBaseURIVersion: 52 | description: URI version to be used based on the VSD release 53 | type: string 54 | default: 'default_uri_version' 55 | NeutronNuageCMSId: 56 | description: Cloud Management System ID (CMS ID) to distinguish between OS instances on the same VSD 57 | type: string 58 | UseForwardedFor: 59 | description: Treat X-Forwarded-For as the canonical remote address. Only enable this if you have a sanitizing proxy. 60 | type: boolean 61 | default: false 62 | NuageDefaultAllowNonIP: 63 | description: To allow non-IP traffic by default 64 | type: boolean 65 | default: false 66 | NuageGpgKeys: 67 | type: comma_delimited_list 68 | default: [ ] 69 | description: Nuage GPG keys 70 | 71 | resources: 72 | NeutronMl2Base: 73 | type: /usr/share/openstack-tripleo-heat-templates/deployment/neutron/neutron-plugin-ml2.yaml 74 | properties: 75 | ServiceData: { get_param: ServiceData } 76 | ServiceNetMap: { get_param: ServiceNetMap } 77 | DefaultPasswords: { get_param: DefaultPasswords } 78 | EndpointMap: { get_param: EndpointMap } 79 | RoleName: { get_param: RoleName } 80 | RoleParameters: { get_param: RoleParameters } 81 | 82 | EnsureNoAVRSIptables: 83 | type: OS::Heat::Value 84 | properties: 85 | value: 86 | # The 6wind iptables, eptables, .. that are in the nuage repo for 87 | # AVRS are seen as newer versions and thus yum update will 88 | # install those, even on the controller where they do not belong 89 | # a consequence of using 1 repo for all (not an issue in fresh 90 | # deploy) since there is no yum update there 91 | # To fix this, we will search which repo contains nuage bits 92 | # and add the relevant packages to its excludes 93 | # This is done in step 1 of deploy_steps_tasks and thus post Red Hat subscription 94 | # And also in step 1 of update_task does not really matter that much, since we expect that the new repo is in 95 | # place before the controller is updated 96 | - when: step|int == 1 97 | block: 98 | - name: Find the repo containing nuage bits 99 | vars: 100 | # For controller, we base our selves on the neutron client 101 | query_package: nuage-openstack-neutronclient 102 | shell: > 103 | repoquery -i {{ query_package }} 2>/dev/null 104 | register: repoquery_output 105 | - name: For all the repos containing nuage bits, exclude 6wind packages 106 | become: yes 107 | vars: 108 | exclude_packages: 109 | - iptables 110 | - iptables-libs 111 | - iptables-services 112 | - ebtables 113 | - iptables-utils 114 | shell: > 115 | yum config-manager 116 | --setopt={{ repo.split(':')[1] | trim }}.exclude={{ exclude_packages | join(',') }} 117 | --save 118 | loop: "{{ repoquery_output.stdout_lines }}" 119 | when: '"Repository " in repo' 120 | loop_control: 121 | loop_var: repo 122 | 123 | NoPatchInstallNuageControlller: 124 | type: OS::Heat::Value 125 | properties: 126 | value: 127 | # This is done in step 1 of deploy_steps_tasks and thus post Red Hat subscription 128 | - when: step|int == 1 129 | block: 130 | # With the discontinuing of patching this should always be true the first time it is run 131 | - name: Check if Nuage is installed or not 132 | shell: rpm -q nuage-openstack-neutronclient selinux-policy-nuage 133 | register: nuage_check 134 | failed_when: false 135 | - when: nuage_check.rc != 0 136 | name: Installing Nuage Packages and Dependencies 137 | block: 138 | # Only install when nuage is not installed already. 139 | - name: set nuage_gpg_keys fact 140 | set_fact: 141 | nuage_gpg_keys: { get_param: NuageGpgKeys } 142 | - name: Adding nuage_gpg_keys on overcloud node 143 | rpm_key: 144 | state: present 145 | key: "{{ item }}" 146 | with_items: 147 | - "{{ nuage_gpg_keys }}" 148 | when: 149 | - nuage_gpg_keys != [] 150 | - debug: 151 | msg: "No NuageGpgKeys Environment variable is set for this deployment" 152 | when: 153 | - nuage_gpg_keys == [] 154 | - name: Install Nuage Neutron Client on overcloud controller node 155 | yum: 156 | name: "{{ packages }}" 157 | state: present 158 | vars: 159 | packages: 160 | - nuage-openstack-neutronclient 161 | - selinux-policy-nuage 162 | 163 | outputs: 164 | role_data: 165 | description: Role data for the Neutron ML2/Nuage plugin 166 | value: 167 | service_name: neutron_plugin_ml2_nuage 168 | config_settings: 169 | map_merge: 170 | - get_attr: [ NeutronMl2Base, role_data, config_settings ] 171 | - neutron::plugins::ml2::nuage::nuage_net_partition_name: { get_param: NeutronNuageNetPartitionName } 172 | neutron::plugins::ml2::nuage::nuage_vsd_ip: { get_param: NeutronNuageVSDIp } 173 | neutron::plugins::ml2::nuage::nuage_vsd_username: { get_param: NeutronNuageVSDUsername } 174 | neutron::plugins::ml2::nuage::nuage_vsd_password: { get_param: NeutronNuageVSDPassword } 175 | neutron::plugins::ml2::nuage::nuage_vsd_organization: { get_param: NeutronNuageVSDOrganization } 176 | neutron::plugins::ml2::nuage::nuage_base_uri_version: { get_param: NeutronNuageBaseURIVersion } 177 | neutron::plugins::ml2::nuage::nuage_cms_id: { get_param: NeutronNuageCMSId } 178 | neutron::plugins::ml2::nuage::nuage_default_allow_non_ip: { get_param: NuageDefaultAllowNonIP } 179 | nova::api::use_forwarded_for: { get_param: UseForwardedFor } 180 | step_config: | 181 | include tripleo::profile::base::neutron::plugins::ml2 182 | metadata_settings: 183 | get_attr: [ NeutronMl2Base, role_data, metadata_settings ] 184 | deploy_steps_tasks: 185 | list_concat: 186 | - get_attr: [ EnsureNoAVRSIptables, value ] 187 | - get_attr: [ NoPatchInstallNuageControlller, value ] 188 | update_tasks: 189 | list_concat: 190 | - get_attr: [ EnsureNoAVRSIptables, value ] 191 | - - when: (step|int == 3) 192 | block: 193 | # Could be that the below is no longer relevant in the newest 194 | # versions of nuage 195 | - name: check if nuage-openvswitch is installed 196 | shell: rpm -q nuage-openvswitch 197 | register: nuage_openvswitch_check 198 | ignore_errors: True 199 | - block: 200 | - name: check if python-openvswitch-nuage is present in the repo 201 | command: repoquery --all python-openvswitch-nuage 202 | register: python_openvswitch_nuage_output 203 | - name: Installing python-openvswitch-nuage 204 | yum: 205 | name: python-openvswitch-nuage 206 | state: present 207 | when: python_openvswitch_nuage_output.stdout != '' 208 | - name: Check if nuage-bgp is installed 209 | shell: rpm -qa | grep -q nuage-bgp 210 | failed_when: false 211 | register: nuage_bgp_check 212 | - name: Check and update nuage-bgp package 213 | block: 214 | - name: check if nuage-bgp is updating 215 | shell: yum check-update nuage-bgp 216 | register: nuage_bgp_update_check 217 | failed_when: nuage_bgp_update_check.rc not in [0, 100] 218 | changed_when: nuage_bgp_update_check.rc == 100 219 | - name: Updating nuage-bgp package 220 | block: 221 | - name: Update nuage-bgp with noscripts flag 222 | shell: yum --setopt=tsflags=noscripts install nuage-bgp -y 223 | - name: Reload daemon and restart nuage-bgp 224 | systemd: 225 | state: restarted 226 | daemon_reload: yes 227 | name: nuage-bgp 228 | when: nuage_bgp_update_check.rc == 100 229 | when: nuage_bgp_check.rc == 0 230 | when: nuage_openvswitch_check.rc == 0 231 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/deployment/nova/neutron-compute-plugin-nuage.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | 3 | description: > 4 | OpenStack Neutron Compute Nuage plugin 5 | parameters: 6 | ServiceData: 7 | default: { } 8 | description: Dictionary packing service data 9 | type: json 10 | ServiceNetMap: 11 | default: { } 12 | description: Mapping of service_name -> network name. Typically set 13 | via parameter_defaults in the resource registry. This 14 | mapping overrides those in ServiceNetMapDefaults. 15 | type: json 16 | DefaultPasswords: 17 | default: { } 18 | type: json 19 | RoleName: 20 | default: '' 21 | description: Role name on which the service is applied 22 | type: string 23 | RoleParameters: 24 | default: { } 25 | description: Parameters specific to the role 26 | type: json 27 | EndpointMap: 28 | default: { } 29 | description: Mapping of service endpoint -> protocol. Typically set 30 | via parameter_defaults in the resource registry. 31 | type: json 32 | NovaPassword: 33 | description: The password for the nova service and db account 34 | type: string 35 | hidden: true 36 | NuageMetadataPort: 37 | description: TCP Port to listen for metadata server requests 38 | type: string 39 | default: '9697' 40 | NuageActiveController: 41 | description: IP address of the Active Virtualized Services Controller (VSC) 42 | type: string 43 | NuageStandbyController: 44 | description: IP address of the Standby Virtualized Services Controller (VSC) 45 | type: string 46 | NuageNovaMetadataPort: 47 | description: TCP Port used by Nova metadata server 48 | type: string 49 | default: '8775' 50 | NuageMetadataProxySharedSecret: 51 | description: Shared secret to sign the instance-id request 52 | type: string 53 | NuageNovaClientVersion: 54 | description: Client Version Nova 55 | type: string 56 | default: '2' 57 | NuageNovaOsUsername: 58 | description: Nova username in keystone_authtoken 59 | type: string 60 | default: 'nova' 61 | NuageMetadataAgentStartWithOvs: 62 | description: Set to true if nuage-metadata-agent needs to be started with nuage-openvswitch-switch 63 | type: boolean 64 | default: true 65 | NuageNovaApiEndpoint: 66 | description: One of publicURL, internalURL, adminURL in "keystone endpoint-list" 67 | type: string 68 | default: 'publicURL' 69 | NuageNovaRegionName: 70 | description: Region name in "keystone endpoint-list" 71 | type: string 72 | default: 'regionOne' 73 | NuageBridgeMTU: 74 | description: Support for non-default MTU configured on each Compute node 75 | type: string 76 | default: '' 77 | OvsHwOffload: 78 | default: false 79 | description: | 80 | Enable OVS Hardware Offload. 81 | type: boolean 82 | tags: 83 | - role_specific 84 | VrsExtraConfigs: 85 | description: Extra config params and values for nuage-openvswitch 86 | default: { } 87 | type: json 88 | tags: 89 | - role_specific 90 | NuageGpgKeys: 91 | type: comma_delimited_list 92 | default: [ ] 93 | description: Nuage GPG keys 94 | 95 | resources: 96 | RoleParametersValue: 97 | type: OS::Heat::Value 98 | properties: 99 | type: json 100 | value: 101 | map_replace: 102 | - map_replace: 103 | - nuage::vrs::enable_hw_offload: OvsHwOffload 104 | nuage::vrs::vrs_extra_configs: VrsExtraConfigs 105 | - values: { get_param: [ RoleParameters ] } 106 | - values: 107 | OvsHwOffload: { get_param: OvsHwOffload } 108 | VrsExtraConfigs: { get_param: VrsExtraConfigs } 109 | 110 | outputs: 111 | role_data: 112 | description: Role data for the Neutron Compute Nuage plugin 113 | value: 114 | service_name: neutron_compute_plugin_nuage 115 | config_settings: 116 | map_merge: 117 | - get_attr: [ RoleParametersValue, value ] 118 | - nuage::vrs::active_controller: { get_param: NuageActiveController } 119 | nuage::vrs::standby_controller: { get_param: NuageStandbyController } 120 | nuage::vrs::bridge_mtu: { get_param: NuageBridgeMTU } 121 | nuage::metadataagent::metadata_port: { get_param: NuageMetadataPort } 122 | nuage::metadataagent::nova_metadata_port: { get_param: NuageNovaMetadataPort } 123 | nuage::metadataagent::metadata_secret: { get_param: NuageMetadataProxySharedSecret } 124 | nuage::metadataagent::nova_client_version: { get_param: NuageNovaClientVersion } 125 | nuage::metadataagent::nova_os_username: { get_param: NuageNovaOsUsername } 126 | nuage::metadataagent::metadata_agent_start_with_ovs: { get_param: NuageMetadataAgentStartWithOvs } 127 | nuage::metadataagent::nova_api_endpoint_type: { get_param: NuageNovaApiEndpoint } 128 | nuage::metadataagent::nova_region_name: { get_param: NuageNovaRegionName } 129 | tripleo::profile::base::neutron::agents::nuage::nova_os_tenant_name: 'service' 130 | tripleo::profile::base::neutron::agents::nuage::nova_os_password: {get_param: NovaPassword} 131 | tripleo::profile::base::neutron::agents::nuage::nova_auth_ip: {get_param: [EndpointMap, KeystoneInternal, host]} 132 | step_config: | 133 | include ::tripleo::profile::base::neutron::agents::nuage 134 | deploy_steps_tasks: 135 | - when: step|int == 1 136 | block: 137 | - name: Check if nuage base packages are installed or not 138 | shell: rpm -q nuage-puppet-modules python-openvswitch-nuage selinux-policy-nuage nuage-bgp 139 | failed_when: false 140 | register: nuage_base_check 141 | - name: Installing nuage base packages 142 | when: nuage_base_check.rc != 0 143 | block: 144 | - name: set nuage_gpg_keys fact 145 | set_fact: 146 | nuage_gpg_keys: { get_param: NuageGpgKeys } 147 | - name: Adding nuage_gpg_keys on overcloud node 148 | rpm_key: 149 | state: present 150 | key: "{{ item }}" 151 | with_items: 152 | - "{{ nuage_gpg_keys }}" 153 | when: 154 | - nuage_gpg_keys != [] 155 | - debug: 156 | msg: "No NuageGpgKeys Environment variable is set for this deployment" 157 | when: 158 | - nuage_gpg_keys == [] 159 | - name: Install python openvswitch nuage 160 | yum: 161 | name: python-openvswitch-nuage 162 | state: latest 163 | - name: Get upstream openvswitch name 164 | register: ovs_pkg_name 165 | shell: 166 | rpm -qa | awk -F- '/^(openvswitch[0-9]+\.[0-9]+-|openvswitch-2)/{print $1}' 167 | - name: Remove upstream openvswitch amd network-scripts-openvswitch 168 | yum: 169 | name: "{{ item }}" 170 | state: absent 171 | with_items: 172 | - "{{ ovs_pkg_name.stdout }}" 173 | - "network-scripts-{{ ovs_pkg_name.stdout }}" 174 | when: "{{ (ovs_pkg_name.stdout | length) > 0 }}" 175 | - name: Installing nuage packages dependencies and base packages 176 | yum: 177 | name: "{{ packages }}" 178 | state: latest 179 | vars: 180 | packages: 181 | - perl-JSON 182 | - python2 183 | - python3-httplib2 184 | - libvirt 185 | - nuage-puppet-modules 186 | - selinux-policy-nuage 187 | - nuage-bgp 188 | - name: Ensure libvirtd is not active on compute (outside of nova container) 189 | # Disable the libvirt service 190 | # Otherwise after a reboot of the overcloud hypervisor 191 | # the libvirtd service will be interfering with the overcloud 192 | # libvirt container. 193 | # Libvirt is needed on overcloud for VRS to get vm-node 194 | service: 195 | name: libvirtd 196 | state: stopped 197 | enabled: no 198 | - when: step|int == 2 199 | block: 200 | - name: Check if manager is present 201 | shell: > 202 | /usr/bin/ovs-vsctl get-manager 203 | failed_when: false 204 | register: manager_check 205 | - name: Start a vsctl manager so nova can directly access the ovs database 206 | shell: > 207 | /usr/bin/ovs-vsctl --timeout=5 --id=@manager -- create Manager 208 | "target=\"ptcp:6640:127.0.0.1\"" -- add Open_vSwitch . 209 | manager_options @manager 210 | when: "'ptcp:6640:127.0.0.1' not in manager_check.stdout" 211 | update_tasks: 212 | #common - Applies to all steps 213 | #step0 - Validation 214 | #step1 - Stop all OpenStack services. 215 | #step2 - Stop all Pacemaker-controlled services 216 | #step3 - Package update and new package installation 217 | #step4 - Start OpenStack service required for database upgrade 218 | #step5 - Upgrade database 219 | - block: 220 | - name: check if python-openvswitch-nuage is present in the repo 221 | command: repoquery --all python-openvswitch-nuage 222 | register: python_openvswitch_nuage_output 223 | - name: Installing python-openvswitch-nuage 224 | yum: 225 | name: python-openvswitch-nuage 226 | state: latest 227 | when: python_openvswitch_nuage_output.stdout != '' 228 | - name: Check if nuage-bgp is installed 229 | shell: rpm -qa | grep -q nuage-bgp 230 | failed_when: false 231 | register: nuage_bgp_check 232 | - name: Check and update nuage-bgp package 233 | block: 234 | - name: check if nuage-bgp is updating 235 | shell: yum check-update nuage-bgp 236 | register: nuage_bgp_update_check 237 | failed_when: nuage_bgp_update_check.rc not in [0, 100] 238 | changed_when: nuage_bgp_update_check.rc == 100 239 | - name: Updating nuage-bgp package 240 | block: 241 | - name: Update nuage-bgp with noscripts flag 242 | shell: yum --setopt=tsflags=noscripts install nuage-bgp -y 243 | - name: Reload daemon and restart nuage-bgp 244 | systemd: 245 | state: restarted 246 | daemon_reload: yes 247 | name: nuage-bgp 248 | when: nuage_bgp_update_check.rc == 100 249 | when: nuage_bgp_check.rc == 0 250 | when: (step|int == 3) -------------------------------------------------------------------------------- /image-patching/nuage_image_patching_scripts/nuage_overcloud_full_patch.py: -------------------------------------------------------------------------------- 1 | # !/usr/bin/python3 2 | # Copyright 2020,2021 NOKIA 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an 12 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, 13 | # either express or implied. See the License for the specific 14 | # language governing permissions and limitations under the License. 15 | 16 | import argparse 17 | import yaml 18 | import sys 19 | import logging 20 | from nuage_image_patching_scripts.utils import constants as constants 21 | from nuage_image_patching_scripts.utils.common import * 22 | 23 | ''' 24 | This script is used to patch an existing OpenStack 25 | image with Nuage components 26 | This script takes in following input parameters: 27 | RhelUserName : User name for the RHEL subscription 28 | RhelPassword : Password for the RHEL subscription 29 | RhelPool : RHEL Pool to subscribe 30 | RhelSatUrl : RHEL Satellite url 31 | RhelSatOrg : RHEL Satellite organisation 32 | RhelSatActKey : RHEL Satellite activation key 33 | RepoFile : Name for the file repo hosting the Nuage RPMs 34 | DeploymentType : ["avrs"] --> AVRS + VRS/OVRS/SRIOV deployment 35 | ["vrs"] --> VRS/OVRS/SRIOV deployment 36 | VRSRepoNames : Name for the repo hosting the Nuage O/VRS RPMs 37 | RpmPublicKey : RPM GPG Key 38 | logFile : Log file name 39 | 40 | The following sequence is executed by the script 41 | 1. Subscribe to RHEL and the pool 42 | 2. Uninstall OVS 43 | 3. Download AVRS packages to the image if AVRS is enabled 44 | 4. Install NeutronClient, Nuage-BGP, Selinux Policy Nuage, 45 | Nuage Puppet Module packages. 46 | 5. Install VRS, Nuage Metadata Agent 47 | 6. Unsubscribe from RHEL 48 | ''' 49 | 50 | logger = logging.getLogger(constants.LOG_FILE_NAME) 51 | logger.setLevel(logging.DEBUG) 52 | formatter = logging.Formatter( 53 | '%(asctime)s - %(name)s - %(levelname)s - %(message)s') 54 | consoleHandler = logging.StreamHandler(sys.stdout) 55 | consoleHandler.setFormatter(formatter) 56 | logger.addHandler(consoleHandler) 57 | rhel_subs_type = '' 58 | 59 | 60 | ##### 61 | # Function to install Nuage packages that are required 62 | ##### 63 | 64 | def install_nuage_packages(): 65 | cmds = ''' 66 | #### Installing Nuage Packages 67 | yum install --setopt=skip_missing_names_on_install=False -y %s 68 | yum install --setopt=skip_missing_names_on_install=False -y %s 69 | yum install --setopt=skip_missing_names_on_install=False -y %s 70 | yum clean all 71 | ''' % (constants.NUAGE_DEPENDENCIES, constants.NUAGE_VRS_PACKAGE, 72 | constants.NUAGE_PACKAGES) 73 | constants.PATCHING_SCRIPT += cmds + '\n' 74 | # Disable the libvirt service 75 | # Otherwise after a reboot of the overcloud hypervisor 76 | # the libvirtd service will be interfering with the overcloud 77 | # libvirt container. 78 | # Libvirt is needed on overcloud for VRS to get vm-node 79 | constants.PATCHING_SCRIPT += ( 80 | "systemctl disable libvirtd; " 81 | "systemctl stop libvirtd \n" 82 | ) 83 | 84 | 85 | 86 | ##### 87 | # Function to download Nuage AVRS packages that are required 88 | # The packages qemu-kvm libvirt python3-libvirt libvirt-libs 89 | # python2-ipaddress python2-six have dependencies rhel8 modular or 90 | # the package is a rhel8 modular rpm. Modular rpms are not processed 91 | # properly by createrepo. Hence, they need to be installed on the 92 | # overcloud image. 93 | ##### 94 | 95 | def download_avrs_packages(): 96 | cmds = ''' 97 | #### Downloading Nuage Avrs and 6wind Packages 98 | yum install -y yum-utils 99 | mkdir -p /6wind 100 | yum install --setopt=skip_missing_names_on_install=False -y createrepo \ 101 | qemu-kvm libvirt python3-libvirt libvirt-libs python2-ipaddress python2-six \ 102 | 103 | rpm -q kernel | awk '{ print substr($1,8) }' > /kernel-version 104 | yumdownloader -y --setopt=skip_missing_names_on_install=False \ 105 | --downloadonly --downloaddir=/6wind *6windgate* iptables*6windgate* \ 106 | ebtables*6windgate* --resolve 107 | yumdownloader -y --setopt=skip_missing_names_on_install=False \ 108 | --downloadonly --downloaddir=/6wind python3-pyelftools* \ 109 | %s nuage-metadata-agent virtual-accelerator* --resolve 110 | yumdownloader -y --setopt=skip_missing_names_on_install=False \ 111 | --downloadonly --downloaddir=/6wind selinux-policy-nuage-avrs* --resolve 112 | yumdownloader -y --setopt=skip_missing_names_on_install=False \ 113 | --downloadonly --downloaddir=/6wind python3-pyroute2 114 | 115 | yum clean all 116 | ''' % constants.NUAGE_AVRS_PACKAGE 117 | constants.PATCHING_SCRIPT += cmds + '\n' 118 | 119 | 120 | ##### 121 | # Function to check if deployment types provided are valid 122 | ##### 123 | 124 | def check_deployment_type(nuage_config): 125 | msg = "DeploymentType config option %s is not correct " \ 126 | "or supported " \ 127 | " Please enter:\n ['vrs'] --> for VRS/OVRS/SRIOV deployment\n " \ 128 | "['avrs'] --> for AVRS + VRS/OVRS/SRIOV deployment\n " % \ 129 | nuage_config["DeploymentType"] 130 | if (all(deployment_type in constants.VALID_DEPLOYMENT_TYPES 131 | for deployment_type in nuage_config["DeploymentType"])): 132 | logger.info("Overcloud Image will be patched with Nuage %s " 133 | "rpms" % nuage_config["DeploymentType"]) 134 | else: 135 | logger.error(msg) 136 | sys.exit(1) 137 | 138 | 139 | def check_rhel_subscription_type(nuage_config): 140 | """ 141 | Check which type of red hat subscription to use 142 | """ 143 | key_set_satellite = ["RhelSatUrl", "RhelSatOrg", "RhelSatActKey"] 144 | key_set_portal = ["RhelPassword", "RhelUserName", "RhelPool"] 145 | 146 | if all(nuage_config.get(key) for key in 147 | key_set_satellite): # RH satellite 148 | return constants.RHEL_SUB_SATELLITE 149 | elif all(nuage_config.get(key) for key in 150 | key_set_portal): # RH portal 151 | return constants.RHEL_SUB_PORTAL 152 | elif all(not nuage_config.get(key) for key in 153 | key_set_portal + key_set_satellite): # RH disabled 154 | return constants.RHEL_SUB_DISABLED 155 | else: # RH incomplete configuration 156 | logger.error( 157 | 'INCOMPLETE Red Hat subscription configuration detected: \n' 158 | ' - For Red Hat Portal please specify: ' 159 | '[RhelPassword, RhelUserName, RhelPool] \n' 160 | ' - For Red Hat Satellite please specify: ' 161 | '[RhelUrl, RhelSatOrg, RhelSatActKey]') 162 | sys.exit(1) 163 | 164 | 165 | def check_config(nuage_config): 166 | global rhel_subs_type 167 | logger.info("Verifying pre-requisite packages for script") 168 | libguestfs = cmds_run(['rpm -q libguestfs-tools-c']) 169 | if 'not installed' in libguestfs: 170 | logger.info("Please install libguestfs-tools-c package " 171 | "for the script to run") 172 | sys.exit(1) 173 | 174 | rhel_subs_type = check_rhel_subscription_type(nuage_config) 175 | 176 | if not nuage_config.get("ImageName"): 177 | logger.error("Please provide missing config %s value " 178 | "in your config file. \n" % "ImageName") 179 | sys.exit(1) 180 | 181 | if not nuage_config.get( 182 | "RepoFile") and not rhel_subs_type == constants.RHEL_SUB_SATELLITE: 183 | logger.error("Please provide missing config %s value " 184 | "in your config file. \n" % "RepoFile") 185 | sys.exit(1) 186 | 187 | file_exists(nuage_config["ImageName"]) 188 | 189 | check_deployment_type(nuage_config) 190 | 191 | 192 | #### 193 | # Image Patching 194 | #### 195 | 196 | 197 | def image_patching(nuage_config): 198 | global rhel_subs_type 199 | start_script() 200 | 201 | if nuage_config.get("RpmPublicKey"): 202 | logger.info("Importing gpgkey(s) to overcloud image") 203 | importing_gpgkeys(nuage_config["ImageName"], 204 | nuage_config["RpmPublicKey"]) 205 | 206 | if (rhel_subs_type == constants.RHEL_SUB_PORTAL 207 | or rhel_subs_type == constants.RHEL_SUB_SATELLITE): 208 | rhel_subscription(username=nuage_config.get("RhelUserName"), 209 | password=nuage_config.get("RhelPassword"), 210 | pool=nuage_config.get("RhelPool"), 211 | satellite_url=nuage_config.get("RhelSatUrl"), 212 | satellite_org=nuage_config.get("RhelSatOrg"), 213 | satellite_key=nuage_config.get("RhelSatActKey"), 214 | proxy_hostname=nuage_config.get("ProxyHostname"), 215 | proxy_port=nuage_config.get("ProxyPort"), 216 | rhel_sub_type=rhel_subs_type, 217 | deployment_type=nuage_config.get("DeploymentType")) 218 | 219 | select_dnf_modules_versions() 220 | install_nuage_python_ovs_packages() 221 | uninstall_packages() 222 | 223 | if nuage_config.get("RepoFile"): 224 | # If: RH satellite 225 | # - Add nuage packages to the RH satellite 226 | # - Use RepoFile for nuage packages, RH satellite for RH packages 227 | # Else: check_config checks if file is missing 228 | logger.info("Copying RepoFile to the overcloud image") 229 | copy_repo_file(nuage_config["ImageName"], nuage_config["RepoFile"]) 230 | 231 | if "avrs" in nuage_config["DeploymentType"]: 232 | download_avrs_packages() 233 | 234 | install_nuage_packages() 235 | 236 | if (rhel_subs_type == constants.RHEL_SUB_PORTAL 237 | or rhel_subs_type == constants.RHEL_SUB_SATELLITE): 238 | rhel_remove_subscription(rhel_sub_type=rhel_subs_type) 239 | 240 | write_to_file(constants.PATCHING_SCRIPT) 241 | logger.info("Running the patching script on Overcloud image") 242 | 243 | virt_customize_run( 244 | ' %s -a %s --memsize %s --selinux-relabel' % ( 245 | constants.SCRIPT_NAME, nuage_config["ImageName"], 246 | constants.VIRT_CUSTOMIZE_MEMSIZE)) 247 | 248 | logger.info("Reset the Machine ID") 249 | cmds_run([constants.VIRT_CUSTOMIZE_ENV + "virt-sysprep --operation " 250 | "machine-id -a %s" % 251 | nuage_config["ImageName"]]) 252 | logger.info("Done") 253 | 254 | 255 | def main(): 256 | parser = argparse.ArgumentParser() 257 | parser.add_argument("--nuage-config", dest="nuage_config", 258 | required=True, 259 | help="path to nuage_patching_config.yaml") 260 | args = parser.parse_args() 261 | 262 | with open(args.nuage_config) as nuage_config: 263 | try: 264 | nuage_config = yaml.load(nuage_config) 265 | except yaml.YAMLError as exc: 266 | logger.error( 267 | 'Error parsing file {filename}: {exc}. \n' 268 | 'Please fix and try again with correct yaml file.' 269 | .format(filename=args.nuage_config, exc=exc)) 270 | sys.exit(1) 271 | 272 | if nuage_config.get("logFileName"): 273 | handler = logging.FileHandler(nuage_config["logFileName"]) 274 | handler.setFormatter(formatter) 275 | logger.addHandler(handler) 276 | 277 | logger.info("nuage_overcloud_full_patch.py was " 278 | "run with following config options %s " % nuage_config) 279 | check_config(nuage_config) 280 | image_patching(nuage_config) 281 | 282 | 283 | if __name__ == "__main__": 284 | main() 285 | -------------------------------------------------------------------------------- /nuage-tripleo-heat-templates/network/config/bond-with-vlans/controller.yaml: -------------------------------------------------------------------------------- 1 | heat_template_version: rocky 2 | description: > 3 | Software Config to drive os-net-config with 2 bonded nics on a bridge with VLANs attached for the Controller role. 4 | parameters: 5 | ControlPlaneIp: 6 | default: '' 7 | description: IP address/subnet on the ctlplane network 8 | type: string 9 | ControlPlaneSubnetCidr: 10 | default: '' 11 | description: > 12 | The subnet CIDR of the control plane network. (The parameter is 13 | automatically resolved from the ctlplane subnet's cidr attribute.) 14 | type: string 15 | ControlPlaneDefaultRoute: 16 | default: '' 17 | description: The default route of the control plane network. (The parameter 18 | is automatically resolved from the ctlplane subnet's gateway_ip attribute.) 19 | type: string 20 | ControlPlaneStaticRoutes: 21 | default: [] 22 | description: > 23 | Routes for the ctlplane network traffic. 24 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 25 | Unless the default is changed, the parameter is automatically resolved 26 | from the subnet host_routes attribute. 27 | type: json 28 | ControlPlaneMtu: 29 | default: 1500 30 | description: The maximum transmission unit (MTU) size(in bytes) that is 31 | guaranteed to pass through the data path of the segments in the network. 32 | (The parameter is automatically resolved from the ctlplane network's mtu attribute.) 33 | type: number 34 | 35 | StorageIpSubnet: 36 | default: '' 37 | description: IP address/subnet on the storage network 38 | type: string 39 | StorageNetworkVlanID: 40 | default: 30 41 | description: Vlan ID for the storage network traffic. 42 | type: number 43 | StorageMtu: 44 | default: 1500 45 | description: The maximum transmission unit (MTU) size(in bytes) that is 46 | guaranteed to pass through the data path of the segments in the 47 | Storage network. 48 | type: number 49 | StorageInterfaceRoutes: 50 | default: [] 51 | description: > 52 | Routes for the storage network traffic. 53 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 54 | Unless the default is changed, the parameter is automatically resolved 55 | from the subnet host_routes attribute. 56 | type: json 57 | StorageMgmtIpSubnet: 58 | default: '' 59 | description: IP address/subnet on the storage_mgmt network 60 | type: string 61 | StorageMgmtNetworkVlanID: 62 | default: 40 63 | description: Vlan ID for the storage_mgmt network traffic. 64 | type: number 65 | StorageMgmtMtu: 66 | default: 1500 67 | description: The maximum transmission unit (MTU) size(in bytes) that is 68 | guaranteed to pass through the data path of the segments in the 69 | StorageMgmt network. 70 | type: number 71 | StorageMgmtInterfaceRoutes: 72 | default: [] 73 | description: > 74 | Routes for the storage_mgmt network traffic. 75 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 76 | Unless the default is changed, the parameter is automatically resolved 77 | from the subnet host_routes attribute. 78 | type: json 79 | InternalApiIpSubnet: 80 | default: '' 81 | description: IP address/subnet on the internal_api network 82 | type: string 83 | InternalApiNetworkVlanID: 84 | default: 20 85 | description: Vlan ID for the internal_api network traffic. 86 | type: number 87 | InternalApiMtu: 88 | default: 1500 89 | description: The maximum transmission unit (MTU) size(in bytes) that is 90 | guaranteed to pass through the data path of the segments in the 91 | InternalApi network. 92 | type: number 93 | InternalApiInterfaceRoutes: 94 | default: [] 95 | description: > 96 | Routes for the internal_api network traffic. 97 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 98 | Unless the default is changed, the parameter is automatically resolved 99 | from the subnet host_routes attribute. 100 | type: json 101 | TenantIpSubnet: 102 | default: '' 103 | description: IP address/subnet on the tenant network 104 | type: string 105 | TenantNetworkVlanID: 106 | default: 50 107 | description: Vlan ID for the tenant network traffic. 108 | type: number 109 | TenantMtu: 110 | default: 1500 111 | description: The maximum transmission unit (MTU) size(in bytes) that is 112 | guaranteed to pass through the data path of the segments in the 113 | Tenant network. 114 | type: number 115 | TenantInterfaceRoutes: 116 | default: [] 117 | description: > 118 | Routes for the tenant network traffic. 119 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 120 | Unless the default is changed, the parameter is automatically resolved 121 | from the subnet host_routes attribute. 122 | type: json 123 | ExternalIpSubnet: 124 | default: '' 125 | description: IP address/subnet on the external network 126 | type: string 127 | ExternalNetworkVlanID: 128 | default: 10 129 | description: Vlan ID for the external network traffic. 130 | type: number 131 | ExternalMtu: 132 | default: 1500 133 | description: The maximum transmission unit (MTU) size(in bytes) that is 134 | guaranteed to pass through the data path of the segments in the 135 | External network. 136 | type: number 137 | ExternalInterfaceDefaultRoute: 138 | default: '' 139 | description: default route for the external network 140 | type: string 141 | ExternalInterfaceRoutes: 142 | default: [] 143 | description: > 144 | Routes for the external network traffic. 145 | JSON route e.g. [{'destination':'10.0.0.0/16', 'nexthop':'10.0.0.1'}] 146 | Unless the default is changed, the parameter is automatically resolved 147 | from the subnet host_routes attribute. 148 | type: json 149 | DnsServers: # Override this via parameter_defaults 150 | default: [] 151 | description: > 152 | DNS servers to use for the Overcloud (2 max for some implementations). 153 | If not set the nameservers configured in the ctlplane subnet's 154 | dns_nameservers attribute will be used. 155 | type: comma_delimited_list 156 | DnsSearchDomains: # Override this via parameter_defaults 157 | default: [] 158 | description: A list of DNS search domains to be added (in order) to resolv.conf. 159 | type: comma_delimited_list 160 | BondInterfaceOvsOptions: 161 | default: bond_mode=active-backup 162 | description: 'The ovs_options or bonding_options string for the bond 163 | interface. Set things like lacp=active and/or bond_mode=balance-slb 164 | for OVS bonds or like mode=4 for Linux bonds using this option.' 165 | type: string 166 | resources: 167 | 168 | MinViableMtu: 169 | # This resource resolves the minimum viable MTU for interfaces, bonds and 170 | # bridges that carry multiple VLANs. Each VLAN may have different MTU. The 171 | # bridge, bond or interface must have an MTU to allow the VLAN with the 172 | # largest MTU. 173 | type: OS::Heat::Value 174 | properties: 175 | type: number 176 | value: 177 | yaql: 178 | expression: $.data.max() 179 | data: 180 | - {get_param: ControlPlaneMtu} 181 | - {get_param: StorageMtu} 182 | - {get_param: StorageMgmtMtu} 183 | - {get_param: InternalApiMtu} 184 | - {get_param: TenantMtu} 185 | - {get_param: ExternalMtu} 186 | 187 | OsNetConfigImpl: 188 | type: OS::Heat::SoftwareConfig 189 | properties: 190 | group: script 191 | config: 192 | str_replace: 193 | template: 194 | get_file: /usr/share/openstack-tripleo-heat-templates/network/scripts/run-os-net-config.sh 195 | params: 196 | $network_config: 197 | network_config: 198 | - type: interface 199 | name: nic1 200 | mtu: 201 | get_param: ControlPlaneMtu 202 | use_dhcp: false 203 | addresses: 204 | - ip_netmask: 205 | list_join: 206 | - / 207 | - - get_param: ControlPlaneIp 208 | - get_param: ControlPlaneSubnetCidr 209 | routes: 210 | list_concat_unique: 211 | - get_param: ControlPlaneStaticRoutes 212 | - type: linux_bond 213 | name: bond1 214 | mtu: 215 | get_attr: [MinViableMtu, value] 216 | bonding_options: 217 | get_param: BondInterfaceOvsOptions 218 | use_dhcp: false 219 | dns_servers: 220 | get_param: DnsServers 221 | members: 222 | - type: interface 223 | name: nic2 224 | mtu: 225 | get_attr: [MinViableMtu, value] 226 | primary: true 227 | - type: interface 228 | name: nic3 229 | mtu: 230 | get_attr: [MinViableMtu, value] 231 | - type: vlan 232 | device: bond1 233 | mtu: 234 | get_param: StorageMtu 235 | vlan_id: 236 | get_param: StorageNetworkVlanID 237 | addresses: 238 | - ip_netmask: 239 | get_param: StorageIpSubnet 240 | routes: 241 | list_concat_unique: 242 | - get_param: StorageInterfaceRoutes 243 | - type: vlan 244 | device: bond1 245 | mtu: 246 | get_param: StorageMgmtMtu 247 | vlan_id: 248 | get_param: StorageMgmtNetworkVlanID 249 | addresses: 250 | - ip_netmask: 251 | get_param: StorageMgmtIpSubnet 252 | routes: 253 | list_concat_unique: 254 | - get_param: StorageMgmtInterfaceRoutes 255 | - type: vlan 256 | device: bond1 257 | mtu: 258 | get_param: InternalApiMtu 259 | vlan_id: 260 | get_param: InternalApiNetworkVlanID 261 | addresses: 262 | - ip_netmask: 263 | get_param: InternalApiIpSubnet 264 | routes: 265 | list_concat_unique: 266 | - get_param: InternalApiInterfaceRoutes 267 | - type: vlan 268 | device: bond1 269 | mtu: 270 | get_param: TenantMtu 271 | vlan_id: 272 | get_param: TenantNetworkVlanID 273 | addresses: 274 | - ip_netmask: 275 | get_param: TenantIpSubnet 276 | routes: 277 | list_concat_unique: 278 | - get_param: TenantInterfaceRoutes 279 | - type: vlan 280 | device: bond1 281 | mtu: 282 | get_param: ExternalMtu 283 | vlan_id: 284 | get_param: ExternalNetworkVlanID 285 | addresses: 286 | - ip_netmask: 287 | get_param: ExternalIpSubnet 288 | routes: 289 | list_concat_unique: 290 | - get_param: ExternalInterfaceRoutes 291 | - - default: true 292 | next_hop: 293 | get_param: ExternalInterfaceDefaultRoute 294 | outputs: 295 | OS::stack_id: 296 | description: The OsNetConfigImpl resource. 297 | value: 298 | get_resource: OsNetConfigImpl --------------------------------------------------------------------------------