From 151608146b2c9da040390e3028d60ccb6c15f85e Mon Sep 17 00:00:00 2001 From: Abhishek Raut <rauta@vmware.com> Date: Fri, 29 Jul 2016 23:21:29 -0700 Subject: [PATCH] Add documentation for OSC plugin commands This patch adds a new path under neutronclient docs to document the newly added OSC commands. All new CLI commands added via the openstack client plugin must now provide a user guide to these commands under doc/source/usage/osc/v2 Change-Id: Id16d2fb0712fe6dd4a45a765bf7b65410302f5b8 --- doc/source/index.rst | 1 + doc/source/usage/osc/v2/network-trunk.rst | 171 ++++++++++++++++++++++ doc/source/usage/osc_cli_plugins.rst | 33 +++++ 3 files changed, 205 insertions(+) create mode 100644 doc/source/usage/osc/v2/network-trunk.rst create mode 100644 doc/source/usage/osc_cli_plugins.rst diff --git a/doc/source/index.rst b/doc/source/index.rst index d7efbd272..be4c77057 100644 --- a/doc/source/index.rst +++ b/doc/source/index.rst @@ -35,6 +35,7 @@ Using neutronclient usage/cli usage/library + usage/osc_cli_plugins Developer Guide --------------- diff --git a/doc/source/usage/osc/v2/network-trunk.rst b/doc/source/usage/osc/v2/network-trunk.rst new file mode 100644 index 000000000..5a79310a4 --- /dev/null +++ b/doc/source/usage/osc/v2/network-trunk.rst @@ -0,0 +1,171 @@ +============= +network trunk +============= + +A **network trunk** is a container to group logical ports from different +networks and provide a single trunked vNIC for servers. It consists of +one parent port which is a regular VIF and multiple subports which allow +the server to connect to more networks. + +Network v2 + +network subport list +-------------------- + +List all subports for a given network trunk + +.. program:: network subport list +.. code:: bash + + os network subport list + --trunk <trunk> + +.. option:: --trunk <trunk> + + List subports belonging to this trunk (name or ID) (required) + +network trunk create +-------------------- + +Create a network trunk for a given project + +.. program:: network trunk create +.. code:: bash + + os network trunk create + --parent-port <parent-port> + [--subport <port=,segmentation-type=,segmentation-id=>] + [--enable | --disable] + [--project <project> [--project-domain <project-domain>]] + <name> + +.. option:: --parent-port <parent-port> + + Parent port belonging to this trunk (name or ID) (required) + +.. option:: --subport <port=,segmentation-type=,segmentation-id=> + + Subport to add. Subport is of form 'port=<name or ID>,segmentation-type=,segmentation-ID=' + (--subport) option can be repeated + +.. option:: --enable + + Enable trunk (default) + +.. option:: --disable + + Disable trunk + +.. option:: --project <project> + + Owner's project (name or ID) + +.. option:: --project-domain <project-domain> + + Domain the project belongs to (name or ID). + This can be used in case collisions between project names exist. + +network trunk delete +-------------------- + +Delete a given network trunk + +.. program:: network trunk delete +.. code:: bash + + os network trunk delete + <trunk> [<trunk> ...] + +.. _network_trunk_delete-trunk: +.. describe:: <trunk> + + Trunk(s) to delete (name or ID) + +network trunk list +------------------ + +List all network trunks + +.. program:: network trunk list +.. code:: bash + + os network trunk list + [--long] + +.. option:: --long + + List additional fields in output + +network trunk set +----------------- + +Set network trunk properties + +.. program:: network trunk set +.. code:: bash + + os network trunk set + [--name <name>] + [--subport <port=,segmentation-type=,segmentation-id=>] + [--enable | --disable] + <trunk> + +.. option:: --name <name> + + Set trunk name + +.. option:: --subport <port=,segmentation-type=,segmentation-id=> + + Subport to add. Subport is of form 'port=<name or ID>,segmentation-type=,segmentation-ID=' + (--subport) option can be repeated + +.. option:: --enable + + Enable trunk + +.. option:: --disable + + Disable trunk + +.. _network_trunk_set-trunk: +.. describe:: <trunk> + + Trunk to modify (name or ID) + +network trunk show +------------------ + +Show information of a given network trunk + +.. program:: network trunk show +.. code:: bash + + os network trunk show + <trunk> + +.. _network_trunk_show-trunk: +.. describe:: <trunk> + + Trunk to display (name or ID) + +network trunk unset +------------------- + +Unset subports from a given network trunk + +.. program:: network trunk unset +.. code:: bash + + os network trunk unset + --subport <subport> + <trunk> + +.. option:: --subport <subport> + + Subport to delete (name or ID of the port) (required) + (--subport) option can be repeated + +.. _network_trunk_unset-trunk: +.. describe:: <trunk> + + Unset subports from this trunk (name or ID) diff --git a/doc/source/usage/osc_cli_plugins.rst b/doc/source/usage/osc_cli_plugins.rst new file mode 100644 index 000000000..343c3a9d3 --- /dev/null +++ b/doc/source/usage/osc_cli_plugins.rst @@ -0,0 +1,33 @@ +.. + Licensed under the Apache License, Version 2.0 (the "License"); you may + not use this file except in compliance with the License. You may obtain + a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, WITHOUT + WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the + License for the specific language governing permissions and limitations + under the License. + + + Convention for heading levels in Neutron devref: + ======= Heading 0 (reserved for the title in a document) + ------- Heading 1 + ~~~~~~~ Heading 2 + +++++++ Heading 3 + ''''''' Heading 4 + (Avoid deeper levels because they do not render well.) + +Using Network CLI extensions to OpenStack Client +================================================ + +List of released CLI commands available in openstack client. These commands +can be referenced by doing ``openstack help network``. + +.. toctree:: + :glob: + :maxdepth: 2 + + osc/v2/*