From 480b8c24143e1413ed3ac371b7414fd531cace92 Mon Sep 17 00:00:00 2001 From: wangzh21 Date: Tue, 14 Aug 2018 15:57:24 +0800 Subject: [PATCH] Update python-cyborgclient doc 1.Remove the wrong document 2.Update env api version Change-Id: Ieb88341a636a0d77d64986aff5a09eca05746fe7 --- README.rst | 4 +- doc/source/configuration/index.rst | 5 -- doc/source/index.rst | 1 - doc/source/install/common_configure.rst | 10 --- doc/source/install/common_prerequisites.rst | 75 --------------------- doc/source/install/get_started.rst | 9 --- doc/source/install/index.rst | 21 +++--- doc/source/install/install-obs.rst | 34 ---------- doc/source/install/install-rdo.rst | 33 --------- doc/source/install/install-ubuntu.rst | 31 --------- doc/source/install/install.rst | 20 ------ doc/source/install/next-steps.rst | 9 --- doc/source/install/verify.rst | 24 ------- 13 files changed, 10 insertions(+), 266 deletions(-) delete mode 100644 doc/source/configuration/index.rst delete mode 100644 doc/source/install/common_configure.rst delete mode 100644 doc/source/install/common_prerequisites.rst delete mode 100644 doc/source/install/get_started.rst delete mode 100644 doc/source/install/install-obs.rst delete mode 100644 doc/source/install/install-rdo.rst delete mode 100644 doc/source/install/install-ubuntu.rst delete mode 100644 doc/source/install/install.rst delete mode 100644 doc/source/install/next-steps.rst delete mode 100644 doc/source/install/verify.rst diff --git a/README.rst b/README.rst index 01e85e0..d9a99b9 100644 --- a/README.rst +++ b/README.rst @@ -81,12 +81,12 @@ params, but it's easier to just set them as environment variables:: You will also need to define the authentication url with ``--os-auth-url`` and the version of the API with ``--os-accelerator-api-version``. Or set them -as environment variables as well, ``OS_ACCELERATOR_API_VERSION=3``. If you +as environment variables as well, ``OS_ACCELERATOR_API_VERSION=1``. If you are using Keystone, you need to set the ``OS_AUTH_URL`` to the keystone endpoint:: export OS_AUTH_URL=http://controller:5000/v3 - export OS_ACCELERATOR_API_VERSION=3 + export OS_ACCELERATOR_API_VERSION=1 Since Keystone can return multiple regions in the Service Catalog, you can specify the one you want with ``--os-region-name`` (or diff --git a/doc/source/configuration/index.rst b/doc/source/configuration/index.rst deleted file mode 100644 index 75cbfb2..0000000 --- a/doc/source/configuration/index.rst +++ /dev/null @@ -1,5 +0,0 @@ -============= -Configuration -============= - -Configuration of python-cyborgclient. diff --git a/doc/source/index.rst b/doc/source/index.rst index fe298c2..b71783e 100644 --- a/doc/source/index.rst +++ b/doc/source/index.rst @@ -16,7 +16,6 @@ Contents: install/index library/index contributor/index - configuration/index cli/index user/index admin/index diff --git a/doc/source/install/common_configure.rst b/doc/source/install/common_configure.rst deleted file mode 100644 index 1a35f02..0000000 --- a/doc/source/install/common_configure.rst +++ /dev/null @@ -1,10 +0,0 @@ -2. Edit the ``/etc/cyborgclient/cyborgclient.conf`` file and complete the following - actions: - - * In the ``[database]`` section, configure database access: - - .. code-block:: ini - - [database] - ... - connection = mysql+pymysql://cyborgclient:CYBORGCLIENT_DBPASS@controller/cyborgclient diff --git a/doc/source/install/common_prerequisites.rst b/doc/source/install/common_prerequisites.rst deleted file mode 100644 index 0a5bb53..0000000 --- a/doc/source/install/common_prerequisites.rst +++ /dev/null @@ -1,75 +0,0 @@ -Prerequisites -------------- - -Before you install and configure the Cyborg Python Client service, -you must create a database, service credentials, and API endpoints. - -#. To create the database, complete these steps: - - * Use the database access client to connect to the database - server as the ``root`` user: - - .. code-block:: console - - $ mysql -u root -p - - * Create the ``cyborgclient`` database: - - .. code-block:: none - - CREATE DATABASE cyborgclient; - - * Grant proper access to the ``cyborgclient`` database: - - .. code-block:: none - - GRANT ALL PRIVILEGES ON cyborgclient.* TO 'cyborgclient'@'localhost' \ - IDENTIFIED BY 'CYBORGCLIENT_DBPASS'; - GRANT ALL PRIVILEGES ON cyborgclient.* TO 'cyborgclient'@'%' \ - IDENTIFIED BY 'CYBORGCLIENT_DBPASS'; - - Replace ``CYBORGCLIENT_DBPASS`` with a suitable password. - - * Exit the database access client. - - .. code-block:: none - - exit; - -#. Source the ``admin`` credentials to gain access to - admin-only CLI commands: - - .. code-block:: console - - $ . admin-openrc - -#. To create the service credentials, complete these steps: - - * Create the ``cyborgclient`` user: - - .. code-block:: console - - $ openstack user create --domain default --password-prompt cyborgclient - - * Add the ``admin`` role to the ``cyborgclient`` user: - - .. code-block:: console - - $ openstack role add --project service --user cyborgclient admin - - * Create the cyborgclient service entities: - - .. code-block:: console - - $ openstack service create --name cyborgclient --description "Cyborg Python Client" cyborg python client - -#. Create the Cyborg Python Client service API endpoints: - - .. code-block:: console - - $ openstack endpoint create --region RegionOne \ - cyborg python client public http://controller:XXXX/vY/%\(tenant_id\)s - $ openstack endpoint create --region RegionOne \ - cyborg python client internal http://controller:XXXX/vY/%\(tenant_id\)s - $ openstack endpoint create --region RegionOne \ - cyborg python client admin http://controller:XXXX/vY/%\(tenant_id\)s diff --git a/doc/source/install/get_started.rst b/doc/source/install/get_started.rst deleted file mode 100644 index d18881a..0000000 --- a/doc/source/install/get_started.rst +++ /dev/null @@ -1,9 +0,0 @@ -===================================== -Cyborg Python Client service overview -===================================== -The Cyborg Python Client service provides... - -The Cyborg Python Client service consists of the following components: - -``cyborgclient-api`` service - Accepts and responds to end user compute API calls... diff --git a/doc/source/install/index.rst b/doc/source/install/index.rst index 87db748..c1ba995 100644 --- a/doc/source/install/index.rst +++ b/doc/source/install/index.rst @@ -1,17 +1,12 @@ -=============================================== -Cyborg Python Client service installation guide -=============================================== +======================================= +Cyborg Python Client installation guide +======================================= -.. toctree:: - :maxdepth: 2 +At the command line:: - get_started.rst - install.rst - verify.rst - next-steps.rst + $ pip install python-cyborgclient -The Cyborg Python Client service (cyborgclient) provides... +Or, if you have virtualenvwrapper installed:: -This chapter assumes a working setup of OpenStack following the -`OpenStack Installation Tutorial -`_. + $ mkvirtualenv python-cyborgclient + $ pip install python-cyborgclient diff --git a/doc/source/install/install-obs.rst b/doc/source/install/install-obs.rst deleted file mode 100644 index 1dd6593..0000000 --- a/doc/source/install/install-obs.rst +++ /dev/null @@ -1,34 +0,0 @@ -.. _install-obs: - - -Install and configure for openSUSE and SUSE Linux Enterprise -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -This section describes how to install and configure the Cyborg Python Client service -for openSUSE Leap 42.1 and SUSE Linux Enterprise Server 12 SP1. - -.. include:: common_prerequisites.rst - -Install and configure components --------------------------------- - -#. Install the packages: - - .. code-block:: console - - # zypper --quiet --non-interactive install - -.. include:: common_configure.rst - - -Finalize installation ---------------------- - -Start the Cyborg Python Client services and configure them to start when -the system boots: - -.. code-block:: console - - # systemctl enable openstack-cyborgclient-api.service - - # systemctl start openstack-cyborgclient-api.service diff --git a/doc/source/install/install-rdo.rst b/doc/source/install/install-rdo.rst deleted file mode 100644 index 65e6520..0000000 --- a/doc/source/install/install-rdo.rst +++ /dev/null @@ -1,33 +0,0 @@ -.. _install-rdo: - -Install and configure for Red Hat Enterprise Linux and CentOS -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - - -This section describes how to install and configure the Cyborg Python Client service -for Red Hat Enterprise Linux 7 and CentOS 7. - -.. include:: common_prerequisites.rst - -Install and configure components --------------------------------- - -#. Install the packages: - - .. code-block:: console - - # yum install - -.. include:: common_configure.rst - -Finalize installation ---------------------- - -Start the Cyborg Python Client services and configure them to start when -the system boots: - -.. code-block:: console - - # systemctl enable openstack-cyborgclient-api.service - - # systemctl start openstack-cyborgclient-api.service diff --git a/doc/source/install/install-ubuntu.rst b/doc/source/install/install-ubuntu.rst deleted file mode 100644 index b542233..0000000 --- a/doc/source/install/install-ubuntu.rst +++ /dev/null @@ -1,31 +0,0 @@ -.. _install-ubuntu: - -Install and configure for Ubuntu -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -This section describes how to install and configure the Cyborg Python Client -service for Ubuntu 14.04 (LTS). - -.. include:: common_prerequisites.rst - -Install and configure components --------------------------------- - -#. Install the packages: - - .. code-block:: console - - # apt-get update - - # apt-get install - -.. include:: common_configure.rst - -Finalize installation ---------------------- - -Restart the Cyborg Python Client services: - -.. code-block:: console - - # service openstack-cyborgclient-api restart diff --git a/doc/source/install/install.rst b/doc/source/install/install.rst deleted file mode 100644 index 4e170da..0000000 --- a/doc/source/install/install.rst +++ /dev/null @@ -1,20 +0,0 @@ -.. _install: - -Install and configure -~~~~~~~~~~~~~~~~~~~~~ - -This section describes how to install and configure the -Cyborg Python Client service, code-named cyborgclient, on the controller node. - -This section assumes that you already have a working OpenStack -environment with at least the following components installed: -.. (add the appropriate services here and further notes) - -Note that installation and configuration vary by distribution. - -.. toctree:: - :maxdepth: 2 - - install-obs.rst - install-rdo.rst - install-ubuntu.rst diff --git a/doc/source/install/next-steps.rst b/doc/source/install/next-steps.rst deleted file mode 100644 index f009e25..0000000 --- a/doc/source/install/next-steps.rst +++ /dev/null @@ -1,9 +0,0 @@ -.. _next-steps: - -Next steps -~~~~~~~~~~ - -Your OpenStack environment now includes the cyborgclient service. - -To add additional services, see -https://docs.openstack.org/project-install-guide/ocata/. diff --git a/doc/source/install/verify.rst b/doc/source/install/verify.rst deleted file mode 100644 index ea8769a..0000000 --- a/doc/source/install/verify.rst +++ /dev/null @@ -1,24 +0,0 @@ -.. _verify: - -Verify operation -~~~~~~~~~~~~~~~~ - -Verify operation of the Cyborg Python Client service. - -.. note:: - - Perform these commands on the controller node. - -#. Source the ``admin`` project credentials to gain access to - admin-only CLI commands: - - .. code-block:: console - - $ . admin-openrc - -#. List service components to verify successful launch and registration - of each process: - - .. code-block:: console - - $ openstack cyborg python client service list