From b1674b6a82f4adc73c64e3de76c1d8db0cd87345 Mon Sep 17 00:00:00 2001 From: Drew Thorstensen Date: Wed, 10 Aug 2016 13:57:35 -0500 Subject: [PATCH] [DOCS] Move over the Neutron Plugins docs This change moves the Neutron Plugin documents for Plumgrid and Nuage over to the Neutron role. Moving forward, specific project configurations are maintained in the appropriate role book. Change-Id: I5d2d6a38419a879862c98f21e094d094a4857b62 --- README.rst | 33 +------- doc/source/app-nuage.rst | 148 ++++++++++++++++++++++++++++++++++ doc/source/app-plumgrid.rst | 156 ++++++++++++++++++++++++++++++++++++ doc/source/index.rst | 40 +++++---- doc/source/overview.rst | 24 ++++++ examples/playbook.yml | 7 ++ 6 files changed, 364 insertions(+), 44 deletions(-) create mode 100644 doc/source/app-nuage.rst create mode 100644 doc/source/app-plumgrid.rst create mode 100644 doc/source/overview.rst create mode 100644 examples/playbook.yml diff --git a/README.rst b/README.rst index 98929ebe..bbe9bc40 100644 --- a/README.rst +++ b/README.rst @@ -1,30 +1,5 @@ -OpenStack Neutron -################# -:tags: openstack, neutron, cloud, ansible -:category: \*nix +========================= +OpenStack-Ansible neutron +========================= -Role for deployment, setup and installation of Neutron. - -This role will install the following: - * neutron-server - * neutron-agents - -.. code-block:: yaml - - - name: Installation and setup of Neutron - hosts: neutron_all - user: root - roles: - - { role: "os_neutron", tags: [ "os-neutron" ] } - vars: - neutron_galera_address: "{{ internal_lb_vip_address }}" - -Tags -==== - -This role supports two tags: ``neutron-install`` and ``neutron-config`` - -The ``neutron-install`` tag can be used to install and upgrade. - -The ``neutron-config`` tag can be used to maintain configuration of the -service. \ No newline at end of file +Ansible role that installs and configures OpenStack neutron. diff --git a/doc/source/app-nuage.rst b/doc/source/app-nuage.rst new file mode 100644 index 00000000..158ade85 --- /dev/null +++ b/doc/source/app-nuage.rst @@ -0,0 +1,148 @@ +========================================= +Scenario - Using the Nuage neutron plugin +========================================= + +Introduction +~~~~~~~~~~~~ + +Follow these steps to deploy Nuage Networks VCS with OpenStack-Ansible +(OSA): + +- Install prerequisites. + +- Configure neutron to use the Nuage Networks neutron plugin. + +- Configure the Nuage Networks neutron plugin. + +- Download Nuage Networks VCS components and playbooks. + +- Execute the playbooks. + +Prerequisites +~~~~~~~~~~~~~ + +#. The deployment environment is configured according to OSA best + practices such as cloning OSA software and bootstrapping Ansible. + See `OpenStack-Ansible Install Guide + `_ + +#. VCS stand-alone components, VSD and VSC, are configured and + deployed. See the Nuage Networks VSD and VSC Install Guides. + +#. Nuage VRS playbooks were cloned to the deployment host from + `https://github.com/nuagenetworks/nuage-openstack-ansible + `_. This + guide assumes a deployment host path of + ``/opt/nuage-openstack-ansible``. + +Configure Nuage neutron plugin +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +Configuring the neutron plugin requires creating or editing of +parameters in the following two files: + +- ``/etc/openstack_deploy/user_nuage_vars.yml`` + +- ``/etc/openstack_deploy/user_variables.yml`` + +On the deployment host, copy the Nuage user variables file from +``/opt/nuage-openstack-ansible/etc/user_nuage_vars.yml`` to the +``/etc/openstack_deploy/`` folder. + + .. code-block:: shell-session + + # cp /opt/nuage-openstack-ansible/etc/user_nuage_vars.yml \ + /etc/openstack_deploy/ + +Next, modify the following parameters in that file as per your Nuage +VCS environment: + +#. Replace *VSD Enterprise Name* with the name of VSD Enterprise: + + .. code-block:: yaml + + nuage_net_partition_name: "" + +#. Replace *VSD IP* and *VSD GUI Port* as per your VSD configuration: + + .. code-block:: yaml + + nuage_vsd_ip: ":" + +#. Replace *VSD Username, VSD Password*, and *VSD Organization Name* + with your login credentials for the VSD GUI: + + .. code-block:: yaml + + nuage_vsd_username: "" + + nuage_vsd_password: "" + + nuage_vsd_organization: "" + +#. Replace *Nuage VSP Version* with the Nuage VSP release for + Integration. For example, for Nuage VSP release 3.2 this value + would be *v3\_2*. + + .. code-block:: yaml + + nuage_base_uri_version: "" + +#. Replace *Nuage VSD CMS Id* with the ``CMS-Id`` generated by VSD to + manage your OpenStack cluster: + + .. code-block:: yaml + + nuage_cms_id: "" + +#. Replace *Active VSC-IP* with the IP address of your active VSC node + and *Standby VSC-IP* with the IP address of your standby VSC node: + + .. code-block:: yaml + + active_controller: "" + + standby_controller: "" + +#. Replace *Local Package Repository* with the link of the local + repository hosting the Nuage VRS packages. For example: + ``http://192.0.2.10/debs/3.2/vrs/`` + + .. code-block:: yaml + + nuage_vrs_debs_repo: "deb " + +#. On the Deployment host, add the following lines to the + ``/etc/openstack_deploy/user_variables.yml`` file, replacing the + *Local PyPi Mirror URL* with the link to the PyPi server hosting + the Nuage OpenStack Python packages in “.whl” format: + + .. code-block:: yaml + + neutron_plugin_type: "nuage" + nova_network_type: "nuage" + pip_links: + - { name: "openstack_release", link: "{{ openstack_repo_url \ + }}/os-releases/{{ openstack_release }}/" } + - { name: "nuage_repo", link: "" } + +Installation +~~~~~~~~~~~~ + +#. After you set up the multi-node OpenStack cluster, start the + OpenStack deployment as listed in the OpenStack-Ansible Install + guide by running all playbooks in sequence on the deployment host. + +#. After OpenStack deployment is complete, deploy Nuage VRS on all + compute target hosts in the OpenStack cluster by running the Nuage + VRS playbooks in ``/opt/nuage-openstack-ansible/nuage_playbook`` on + your deployment host: + + .. code-block:: shell-session + + # cd /opt/nuage-openstack-ansible/nuage_playbooks + # openstack-ansible nuage_all.yml + + .. note:: To obtain Nuage Networks VSP software packages, user + documentation, and licenses, contact + info@nuagenetworks.net. diff --git a/doc/source/app-plumgrid.rst b/doc/source/app-plumgrid.rst new file mode 100644 index 00000000..141bc08d --- /dev/null +++ b/doc/source/app-plumgrid.rst @@ -0,0 +1,156 @@ +============================================ +Scenario - Using the PLUMgrid Neutron plugin +============================================ + +Installing source and host networking +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +#. Clone the PLUMgrid Ansible repository in the ``/opt/`` directory: + + .. code-block:: shell-session + + # git clone -b TAG \ + https://github.com/plumgrid/plumgrid-ansible.git \ + /opt/plumgrid-ansible + + Replace *``TAG``* with the current stable release tag. + +#. PLUMgrid controls networking for the entire cluster. The bridges + ``br-vxlan`` and ``br-vlan`` are present to prevent relevant + containers from exiting with errors on infra hosts. They do not + need to be attached to any host interface or a valid network. + +#. PLUMgrid requires two networks: a `Management` and a `Fabric` + network. The Management network is typically shared through the + standard ``br-mgmt`` bridge and the Fabric network must be + specified in the PLUMgrid configuration file as described below. + The Fabric interface must be untagged and unbridged. + +Neutron configuration +~~~~~~~~~~~~~~~~~~~~~ + +To set up the neutron configuration to install PLUMgrid as the core +neutron plugin, create a userspace variable file named +``/etc/openstack_deploy/user_pg_neutron.yml`` and insert the following +parameters: + +#. Set the ``neutron_plugin_type`` parameter to ``plumgrid``: + + .. code-block:: yaml + + # Neutron Plugins + neutron_plugin_type: plumgrid + +#. In the same file, disable the installation of unnecessary + ``neutron-agents`` in the ``neutron_services`` dictionary by + setting their ``service_en`` parameters to ``False``: + + .. code-block:: yaml + + neutron_metering: False + neutron_l3: False + neutron_lbaas: False + neutron_lbaasv2: False + neutron_vpnaas: False + + +PLUMgrid configuration +~~~~~~~~~~~~~~~~~~~~~~ + +On the deployment host, create a PLUMgrid user variables file using +the sample in ``/opt/plumgrid-ansible/etc/user_pg_vars.yml.example``. +Copy that file to ``/etc/openstack_deploy/user_pg_vars.yml``. You must +configure the following parameters: + +#. Replace ``PG_REPO_HOST`` with a valid repository URL hosting + PLUMgrid packages: + + .. code-block:: yaml + + plumgrid_repo: PG_REPO_HOST + +#. Replace ``INFRA_IPs`` with comma-separated Infrastructure Node IPs + and ``PG_VIP`` with an unallocated IP on the management network. + This IP is used to access the PLUMgrid UI: + + .. code-block:: yaml + + plumgrid_ip: INFRA_IPs + pg_vip: PG_VIP + +#. Replace ``FABRIC_IFC`` with the name of the interface to be used + for PLUMgrid Fabric. + + .. note:: + + PLUMgrid Fabric must be an untagged unbridged raw interface such + as ``eth0``. + + .. code-block:: yaml + + fabric_interface: FABRIC_IFC + +#. Fill in the ``fabric_ifc_override`` and ``mgmt_override`` dicts + with node ``hostname: interface_name`` to override the default + interface names. + +#. Obtain a PLUMgrid License file, rename to ``pg_license`` and place + it under ``/var/lib/plumgrid/pg_license`` on the deployment host. + +Gateway hosts +~~~~~~~~~~~~~ + +PLUMgrid-enabled OpenStack clusters contain one or more gateway nodes +used for providing connectivity with external resources, such as +external networks, bare-metal servers, or network service appliances. +In addition to the `Management` and `Fabric` networks required by +PLUMgrid nodes, gateways require dedicated external interfaces +referred to as ``gateway_devs`` in the configuration files. + +#. Add a ``gateway_hosts`` section to + ``/etc/openstack_deploy/openstack_user_config.yml``: + + .. code-block:: yaml + + gateway_hosts: + gateway1: + ip: GW01_IP_ADDRESS + gateway2: + ip: GW02_IP_ADDRESS + + Replace ``*_IP_ADDRESS`` with the IP address of the ``br-mgmt`` + container management bridge on each Gateway host. + +#. Add a ``gateway_hosts`` section to the end of the PLUMgrid + ``user_pg_vars.yml`` file: + + .. note:: + + This section must contain the hostnames and ``gateway_dev`` + names for each gateway in the cluster. + + .. code-block:: yaml + + gateway_hosts: + - hostname: gateway1 + gateway_devs: + - eth3 + - eth4 + +Installation +~~~~~~~~~~~~ + +#. Run the PLUMgrid playbooks before running the + ``openstack-setup.yml`` playbook: + + .. code-block:: shell-session + + # cd /opt/plumgrid-ansible/plumgrid_playbooks + # openstack-ansible plumgrid_all.yml + +.. note:: + + Contact PLUMgrid at info@plumgrid.com for an Installation Pack. + This pack includes a full trial commercial license, packages, + deployment documentation, and automation scripts for the entire + work flow. diff --git a/doc/source/index.rst b/doc/source/index.rst index 06d975d7..f9270af5 100644 --- a/doc/source/index.rst +++ b/doc/source/index.rst @@ -1,22 +1,32 @@ -os_neutron Role Docs -==================== +================================== +Neutron role for OpenStack-Ansible +================================== -The os_neutron role is used to to deploy, configure and install OpenStack -Networking. +.. toctree:: + :maxdepth: 2 -This role will install the following: + overview.rst + app-nuage.rst + app-plumgrid.rst + +:tags: openstack, neutron, cloud, ansible +:category: \*nix + +This role will install the following Upstart services: * neutron-server * neutron-agents -Basic Role Example -^^^^^^^^^^^^^^^^^^ +Example playbook +~~~~~~~~~~~~~~~~ -.. code-block:: yaml +.. literalinclude:: ../../examples/playbook.yml + :language: yaml - - name: Installation and setup of Neutron - hosts: neutron_all - user: root - roles: - - { role: "os_neutron", tags: [ "os-neutron" ] } - vars: - neutron_galera_address: "{{ internal_lb_vip_address }}" +Tags +~~~~ + +This role supports two tags: ``neutron-install`` and ``neutron-config`` + +The ``neutron-install`` tag can be used to install and upgrade. + +The ``neutron-config`` tag can be used to manage configuration. diff --git a/doc/source/overview.rst b/doc/source/overview.rst new file mode 100644 index 00000000..5b2d6a9d --- /dev/null +++ b/doc/source/overview.rst @@ -0,0 +1,24 @@ +======== +Overview +======== + +Default variables +~~~~~~~~~~~~~~~~~ + +.. literalinclude:: ../../defaults/main.yml + :language: yaml + :start-after: under the License. + +Example playbook +~~~~~~~~~~~~~~~~ + +.. literalinclude:: ../../examples/playbook.yml + :language: yaml + +Tags +~~~~ + +This role supports two tags: ``neutron-install`` and +``neutron-config``. The ``neutron-install`` tag can be used to install +and upgrade. The ``neutron-config`` tag can be used to maintain the +configuration of the service. diff --git a/examples/playbook.yml b/examples/playbook.yml new file mode 100644 index 00000000..f6909851 --- /dev/null +++ b/examples/playbook.yml @@ -0,0 +1,7 @@ +- name: Installation and setup of Neutron + hosts: neutron_all + user: root + roles: + - { role: "os_neutron", tags: [ "neutron-install", "neutron-config" ] } + vars: + neutron_galera_address: "{{ internal_lb_vip_address }}"