trove/install-guide/source/common_prerequisites.txt
Andreas Jaeger 696d80d4a8 Add Install Guide
This adds trove-specific contents of the OpenStack Installation Guide
in the trove repo per [1]. A separate change will remove the heat
contents from the OpenStack Installation Guide for Newton per [2].

This is a verbatim import from the content in openstack-manuals with
minimal changes to get content building.

Also adds tox.ini environment for install-guide and adds
openstackdocs-theme to test-requirements.txt.

From lmichaels -- added a statement to the next-steps doc.

[1]
http://specs.openstack.org/openstack/docs-specs/specs/newton/project-specific-installguides.html
[2]
http://specs.openstack.org/openstack/docs-specs/specs/newton/installguide.html
[3] https://review.openstack.org/#/c/314229/

Partially-Implements: blueprint projectspecificinstallguides
Change-Id: Idf8cb90536fd4b4d9a2d0695ef30f498b1283410
2016-06-16 15:48:29 -07:00

138 lines
5.6 KiB
Plaintext

Prerequisites
-------------
Before you install and configure the Database 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 ``trove`` database:
.. code-block:: console
CREATE DATABASE trove;
* Grant proper access to the ``trove`` database:
.. code-block:: console
GRANT ALL PRIVILEGES ON trove.* TO 'trove'@'localhost' \
IDENTIFIED BY 'TROVE_DBPASS';
GRANT ALL PRIVILEGES ON trove.* TO 'trove'@'%' \
IDENTIFIED BY 'TROVE_DBPASS';
Replace ``TROVE_DBPASS`` with a suitable password.
* Exit the database access client.
#. 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 ``trove`` user:
.. code-block:: console
$ openstack user create --domain default --password-prompt trove
User Password:
Repeat User Password:
+-----------+-----------------------------------+
| Field | Value |
+-----------+-----------------------------------+
| domain_id | default |
| enabled | True |
| id | ca2e175b851943349be29a328cc5e360 |
| name | trove |
+-----------+-----------------------------------+
* Add the ``admin`` role to the ``trove`` user:
.. code-block:: console
$ openstack role add --project service --user trove admin
.. note::
This command provides no output.
* Create the ``trove`` service entity:
.. code-block:: console
$ openstack service create --name trove \
--description "Database" database
+-------------+-----------------------------------+
| Field | Value |
+-------------+-----------------------------------+
| description | Database |
| enabled | True |
| id | 727841c6f5df4773baa4e8a5ae7d72eb |
| name | trove |
| type | database |
+-------------+-----------------------------------+
#. Create the Database service API endpoints:
.. code-block:: console
$ openstack endpoint create --region RegionOne \
database public http://controller:8779/v1.0/%\(tenant_id\)s
+--------------+----------------------------------------------+
| Field | Value |
+--------------+----------------------------------------------+
| enabled | True |
| id | 3f4dab34624e4be7b000265f25049609 |
| interface | public |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 727841c6f5df4773baa4e8a5ae7d72eb |
| service_name | trove |
| service_type | database |
| url | http://controller:8779/v1.0/%\(tenant_id\)s |
+--------------+----------------------------------------------+
$ openstack endpoint create --region RegionOne \
database internal http://controller:8779/v1.0/%\(tenant_id\)s
+--------------+----------------------------------------------+
| Field | Value |
+--------------+----------------------------------------------+
| enabled | True |
| id | 9489f78e958e45cc85570fec7e836d98 |
| interface | internal |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 727841c6f5df4773baa4e8a5ae7d72eb |
| service_name | trove |
| service_type | database |
| url | http://controller:8779/v1.0/%\(tenant_id\)s |
+--------------+----------------------------------------------+
$ openstack endpoint create --region RegionOne \
database admin http://controller:8779/v1.0/%\(tenant_id\)s
+--------------+----------------------------------------------+
| Field | Value |
+--------------+----------------------------------------------+
| enabled | True |
| id | 76091559514b40c6b7b38dde790efe99 |
| interface | admin |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 727841c6f5df4773baa4e8a5ae7d72eb |
| service_name | trove |
| service_type | database |
| url | http://controller:8779/v1.0/%\(tenant_id\)s |
+--------------+----------------------------------------------+