Tune up documentation to be more useful
The cookiecutter template includes more documentation than we need, so remove lots of extraneous stuff and lay in the basics. Change-Id: I6ed22f70153b00844e8de05d186ecc780debc48c
This commit is contained in:
parent
3d038f5ccc
commit
1ae04e7d41
|
@ -1,15 +1,18 @@
|
||||||
If you would like to contribute to the development of OpenStack, you must
|
If you would like to contribute to the development of OpenStack, you must
|
||||||
follow the steps in this page:
|
follow the steps in this page:
|
||||||
|
|
||||||
http://docs.openstack.org/infra/manual/developers.html
|
http://docs.openstack.org/infra/manual/developers.html
|
||||||
|
|
||||||
If you already have a good understanding of how the system works and your
|
If you already have a good understanding of how the system works and your
|
||||||
OpenStack accounts are set up, you can skip to the development workflow
|
OpenStack accounts are set up, you can skip to the development workflow
|
||||||
section of this documentation to learn how changes to OpenStack should be
|
section of this documentation to learn how changes to OpenStack should be
|
||||||
submitted for review via the Gerrit tool:
|
submitted for review via the Gerrit tool:
|
||||||
|
|
||||||
http://docs.openstack.org/infra/manual/developers.html#development-workflow
|
http://docs.openstack.org/infra/manual/developers.html#development-workflow
|
||||||
|
|
||||||
Pull requests submitted through GitHub will be ignored.
|
Pull requests submitted through GitHub will be ignored.
|
||||||
|
|
||||||
Bugs should be filed on Launchpad: https://bugs.launchpad.net/nova
|
Bugs should be filed on Launchpad: https://bugs.launchpad.net/nova
|
||||||
|
|
||||||
|
Developers of os-resource-classes can be found in the ``#openstack-placement``
|
||||||
|
IRC channel on the ``chat.freenode.net``.
|
||||||
|
|
22
README.rst
22
README.rst
|
@ -2,17 +2,25 @@
|
||||||
os-resource-classes
|
os-resource-classes
|
||||||
===============================
|
===============================
|
||||||
|
|
||||||
**WIP**
|
|
||||||
|
|
||||||
Resource Classes for OpenStack
|
|
||||||
|
|
||||||
A list of standardized resource classes for OpenStack.
|
A list of standardized resource classes for OpenStack.
|
||||||
|
|
||||||
|
A resource class is a distinct type of inventory that exists in
|
||||||
|
a cloud environment, for example ``VCPU``, ``DISK_GB``. They are
|
||||||
|
upper case with underscores. They often include a unit in their
|
||||||
|
name.
|
||||||
|
|
||||||
|
This package provides a collection of symbols representing those
|
||||||
|
standard resource classes which are expected to be available in
|
||||||
|
any OpenStack deployment.
|
||||||
|
|
||||||
|
There also exists a concept of custom resource classes. These
|
||||||
|
are countable types that are custom to a particular environment.
|
||||||
|
The OpenStack `placement API`_ provides a way to create these. A
|
||||||
|
custom resource class always begins with a ``CUSTOM_`` prefix.
|
||||||
|
|
||||||
* Free software: Apache license
|
* Free software: Apache license
|
||||||
* Documentation: https://docs.openstack.org/os-resource-classes/latest
|
* Documentation: https://docs.openstack.org/os-resource-classes/latest
|
||||||
* Source: https://git.openstack.org/cgit/openstack/os-resource-classes
|
* Source: https://git.openstack.org/cgit/openstack/os-resource-classes
|
||||||
* Bugs: https://bugs.launchpad.net/nova
|
* Bugs: https://bugs.launchpad.net/nova
|
||||||
|
|
||||||
--------
|
.. _placement API: https://developer.openstack.org/api-ref/placement/
|
||||||
|
|
||||||
* TODO
|
|
||||||
|
|
|
@ -1,5 +0,0 @@
|
||||||
====================
|
|
||||||
Administrators guide
|
|
||||||
====================
|
|
||||||
|
|
||||||
Administrators guide of os-resource-classes.
|
|
|
@ -1,5 +0,0 @@
|
||||||
================================
|
|
||||||
Command line interface reference
|
|
||||||
================================
|
|
||||||
|
|
||||||
CLI reference of os-resource-classes.
|
|
|
@ -1,5 +0,0 @@
|
||||||
=============
|
|
||||||
Configuration
|
|
||||||
=============
|
|
||||||
|
|
||||||
Configuration of os-resource-classes.
|
|
|
@ -1,4 +0,0 @@
|
||||||
============
|
|
||||||
Contributing
|
|
||||||
============
|
|
||||||
.. include:: ../../../CONTRIBUTING.rst
|
|
|
@ -1,9 +1,4 @@
|
||||||
===========================
|
============
|
||||||
Contributor Documentation
|
Contributing
|
||||||
===========================
|
============
|
||||||
|
.. include:: ../../../CONTRIBUTING.rst
|
||||||
.. toctree::
|
|
||||||
:maxdepth: 2
|
|
||||||
|
|
||||||
contributing
|
|
||||||
|
|
||||||
|
|
|
@ -3,28 +3,19 @@
|
||||||
You can adapt this file completely to your liking, but it should at least
|
You can adapt this file completely to your liking, but it should at least
|
||||||
contain the root `toctree` directive.
|
contain the root `toctree` directive.
|
||||||
|
|
||||||
===================================================
|
===================
|
||||||
Welcome to the documentation of os_resource_classes
|
os-resource-classes
|
||||||
===================================================
|
===================
|
||||||
|
|
||||||
Contents:
|
.. include:: ../../README.rst
|
||||||
|
|
||||||
.. toctree::
|
.. toctree::
|
||||||
:maxdepth: 2
|
|
||||||
|
|
||||||
readme
|
|
||||||
install/index
|
install/index
|
||||||
library/index
|
|
||||||
contributor/index
|
|
||||||
configuration/index
|
|
||||||
cli/index
|
|
||||||
user/index
|
user/index
|
||||||
admin/index
|
contributor/index
|
||||||
reference/index
|
|
||||||
|
|
||||||
Indices and tables
|
Search
|
||||||
==================
|
======
|
||||||
|
|
||||||
* :ref:`genindex`
|
|
||||||
* :ref:`modindex`
|
|
||||||
* :ref:`search`
|
* :ref:`search`
|
||||||
|
|
|
@ -1,10 +0,0 @@
|
||||||
2. Edit the ``/etc/os_resource_classes/os_resource_classes.conf`` file and complete the following
|
|
||||||
actions:
|
|
||||||
|
|
||||||
* In the ``[database]`` section, configure database access:
|
|
||||||
|
|
||||||
.. code-block:: ini
|
|
||||||
|
|
||||||
[database]
|
|
||||||
...
|
|
||||||
connection = mysql+pymysql://os_resource_classes:OS_RESOURCE_CLASSES_DBPASS@controller/os_resource_classes
|
|
|
@ -1,75 +0,0 @@
|
||||||
Prerequisites
|
|
||||||
-------------
|
|
||||||
|
|
||||||
Before you install and configure the Resource Classes for OpenStack 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 ``os_resource_classes`` database:
|
|
||||||
|
|
||||||
.. code-block:: none
|
|
||||||
|
|
||||||
CREATE DATABASE os_resource_classes;
|
|
||||||
|
|
||||||
* Grant proper access to the ``os_resource_classes`` database:
|
|
||||||
|
|
||||||
.. code-block:: none
|
|
||||||
|
|
||||||
GRANT ALL PRIVILEGES ON os_resource_classes.* TO 'os_resource_classes'@'localhost' \
|
|
||||||
IDENTIFIED BY 'OS_RESOURCE_CLASSES_DBPASS';
|
|
||||||
GRANT ALL PRIVILEGES ON os_resource_classes.* TO 'os_resource_classes'@'%' \
|
|
||||||
IDENTIFIED BY 'OS_RESOURCE_CLASSES_DBPASS';
|
|
||||||
|
|
||||||
Replace ``OS_RESOURCE_CLASSES_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 ``os_resource_classes`` user:
|
|
||||||
|
|
||||||
.. code-block:: console
|
|
||||||
|
|
||||||
$ openstack user create --domain default --password-prompt os_resource_classes
|
|
||||||
|
|
||||||
* Add the ``admin`` role to the ``os_resource_classes`` user:
|
|
||||||
|
|
||||||
.. code-block:: console
|
|
||||||
|
|
||||||
$ openstack role add --project service --user os_resource_classes admin
|
|
||||||
|
|
||||||
* Create the os_resource_classes service entities:
|
|
||||||
|
|
||||||
.. code-block:: console
|
|
||||||
|
|
||||||
$ openstack service create --name os_resource_classes --description "Resource Classes for OpenStack" resource classes for openstack
|
|
||||||
|
|
||||||
#. Create the Resource Classes for OpenStack service API endpoints:
|
|
||||||
|
|
||||||
.. code-block:: console
|
|
||||||
|
|
||||||
$ openstack endpoint create --region RegionOne \
|
|
||||||
resource classes for openstack public http://controller:XXXX/vY/%\(tenant_id\)s
|
|
||||||
$ openstack endpoint create --region RegionOne \
|
|
||||||
resource classes for openstack internal http://controller:XXXX/vY/%\(tenant_id\)s
|
|
||||||
$ openstack endpoint create --region RegionOne \
|
|
||||||
resource classes for openstack admin http://controller:XXXX/vY/%\(tenant_id\)s
|
|
|
@ -1,9 +0,0 @@
|
||||||
===============================================
|
|
||||||
Resource Classes for OpenStack service overview
|
|
||||||
===============================================
|
|
||||||
The Resource Classes for OpenStack service provides...
|
|
||||||
|
|
||||||
The Resource Classes for OpenStack service consists of the following components:
|
|
||||||
|
|
||||||
``os_resource_classes-api`` service
|
|
||||||
Accepts and responds to end user compute API calls...
|
|
|
@ -1,17 +1,13 @@
|
||||||
=========================================================
|
==================
|
||||||
Resource Classes for OpenStack service installation guide
|
Installation Guide
|
||||||
=========================================================
|
==================
|
||||||
|
|
||||||
.. toctree::
|
``os-resource-classes`` is availabe on `PyPI`_ and may be installed using
|
||||||
:maxdepth: 2
|
`pip`_::
|
||||||
|
|
||||||
get_started.rst
|
pip install os-resource-classes
|
||||||
install.rst
|
|
||||||
verify.rst
|
|
||||||
next-steps.rst
|
|
||||||
|
|
||||||
The Resource Classes for OpenStack service (os_resource_classes) provides...
|
See :doc:`/user/index` for how to use it once it is installed.
|
||||||
|
|
||||||
This chapter assumes a working setup of OpenStack following the
|
.. _PyPI: https://pypi.org/project/os-resource-classes/
|
||||||
`OpenStack Installation Tutorial
|
.. _pip: https://pypi.org/project/pip/
|
||||||
<https://docs.openstack.org/project-install-guide/ocata/>`_.
|
|
||||||
|
|
|
@ -1,34 +0,0 @@
|
||||||
.. _install-obs:
|
|
||||||
|
|
||||||
|
|
||||||
Install and configure for openSUSE and SUSE Linux Enterprise
|
|
||||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
||||||
|
|
||||||
This section describes how to install and configure the Resource Classes for OpenStack 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 Resource Classes for OpenStack services and configure them to start when
|
|
||||||
the system boots:
|
|
||||||
|
|
||||||
.. code-block:: console
|
|
||||||
|
|
||||||
# systemctl enable openstack-os_resource_classes-api.service
|
|
||||||
|
|
||||||
# systemctl start openstack-os_resource_classes-api.service
|
|
|
@ -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 Resource Classes for OpenStack 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 Resource Classes for OpenStack services and configure them to start when
|
|
||||||
the system boots:
|
|
||||||
|
|
||||||
.. code-block:: console
|
|
||||||
|
|
||||||
# systemctl enable openstack-os_resource_classes-api.service
|
|
||||||
|
|
||||||
# systemctl start openstack-os_resource_classes-api.service
|
|
|
@ -1,31 +0,0 @@
|
||||||
.. _install-ubuntu:
|
|
||||||
|
|
||||||
Install and configure for Ubuntu
|
|
||||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
||||||
|
|
||||||
This section describes how to install and configure the Resource Classes for OpenStack
|
|
||||||
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 Resource Classes for OpenStack services:
|
|
||||||
|
|
||||||
.. code-block:: console
|
|
||||||
|
|
||||||
# service openstack-os_resource_classes-api restart
|
|
|
@ -1,20 +0,0 @@
|
||||||
.. _install:
|
|
||||||
|
|
||||||
Install and configure
|
|
||||||
~~~~~~~~~~~~~~~~~~~~~
|
|
||||||
|
|
||||||
This section describes how to install and configure the
|
|
||||||
Resource Classes for OpenStack service, code-named os_resource_classes, 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
|
|
|
@ -1,9 +0,0 @@
|
||||||
.. _next-steps:
|
|
||||||
|
|
||||||
Next steps
|
|
||||||
~~~~~~~~~~
|
|
||||||
|
|
||||||
Your OpenStack environment now includes the os_resource_classes service.
|
|
||||||
|
|
||||||
To add additional services, see
|
|
||||||
https://docs.openstack.org/project-install-guide/ocata/.
|
|
|
@ -1,24 +0,0 @@
|
||||||
.. _verify:
|
|
||||||
|
|
||||||
Verify operation
|
|
||||||
~~~~~~~~~~~~~~~~
|
|
||||||
|
|
||||||
Verify operation of the Resource Classes for OpenStack 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 resource classes for openstack service list
|
|
|
@ -1,7 +0,0 @@
|
||||||
========
|
|
||||||
Usage
|
|
||||||
========
|
|
||||||
|
|
||||||
To use os-resource-classes in a project::
|
|
||||||
|
|
||||||
import os_resource_classes
|
|
|
@ -1 +0,0 @@
|
||||||
.. include:: ../../README.rst
|
|
|
@ -1,5 +0,0 @@
|
||||||
==========
|
|
||||||
References
|
|
||||||
==========
|
|
||||||
|
|
||||||
References of os-resource-classes.
|
|
|
@ -1,5 +1,12 @@
|
||||||
===========
|
|
||||||
Users guide
|
|
||||||
===========
|
|
||||||
|
|
||||||
Users guide of os-resource-classes.
|
=====
|
||||||
|
Usage
|
||||||
|
=====
|
||||||
|
|
||||||
|
To use ``os-resource-classes`` in a project:
|
||||||
|
|
||||||
|
.. code-block:: python
|
||||||
|
|
||||||
|
import os_resource_classes as orc
|
||||||
|
|
||||||
|
vcpu = orc.VPCU
|
||||||
|
|
Loading…
Reference in New Issue