[DOCS] Move example playbook to separate file

Change-Id: I104ee25bd12f25eb3c88f1e1cb6860058e2154e4
This commit is contained in:
Robb Romans 2016-08-11 20:58:53 -05:00
parent 115f7be8af
commit faf032a896
3 changed files with 68 additions and 66 deletions

View File

@ -1,67 +1,5 @@
========================
OpenStack-Ansible Magnum
########################
========================
Ansible role that installs and configures OpenStack Magnum. Magnum is
installed behind the Apache webserver listening on port 9511 by default.
.. literalinclude:: ../../defaults/main.yml
:language: yaml
:start-after: under the License.
Required Variables
==================
This list is not exhaustive at present. See role internals for further
details.
.. code-block:: yaml
# Magnum TCP listening port
magnum_service_port: 9511
# Magnum service protocol http or https
magnum_service_proto: http
# Magnum Galera address of internal load balancer
magnum_galera_address: "{{ internal_lb_vip_address }}"
# Magnum Galera database name
magnum_galera_database_name: magnum_service
# Magnum Galera username
magnum_galera_user: magnum
# Magnum rabbit userid
magnum_rabbitmq_userid: magnum
# Magnum rabbit vhost
magnum_rabbitmq_vhost: /magnum
Example Playbook
================
.. code-block:: yaml
- name: Install magnum server
hosts: magnum_all
user: root
roles:
- { role: "os_magnum", tags: [ "os-magnum" ] }
vars:
magnum_galera_address: "{{ internal_lb_vip_address }}"
magnum_galera_database_name: magnum_service
magnum_galera_user: magnum
magnum_rabbitmq_userid: magnum
magnum_rabbitmq_vhost: /magnum
ansible_hostname: "{{ container_name }}"
is_metal: "{{ properties.is_metal|default(false) }}"
Tags
====
This role supports two tags: ``magnum-install`` and ``magnum-config``.
The ``magnum-install`` tag can be used to install and upgrade.
The ``magnum-config`` tag can be used to maintain configuration of the
service.
Ansible role that installs and configures OpenStack Magnum.

View File

@ -1 +1,52 @@
.. include:: ../../README.rst
========================
OpenStack-Ansible Magnum
========================
Ansible role that installs and configures OpenStack Magnum. Magnum is
installed behind the Apache webserver listening on port 9511 by default.
.. literalinclude:: ../../defaults/main.yml
:language: yaml
:start-after: under the License.
Required variables
~~~~~~~~~~~~~~~~~~
This list is not exhaustive. See role internals for further details.
.. code-block:: yaml
# Magnum TCP listening port
magnum_service_port: 9511
# Magnum service protocol http or https
magnum_service_proto: http
# Magnum Galera address of internal load balancer
magnum_galera_address: "{{ internal_lb_vip_address }}"
# Magnum Galera database name
magnum_galera_database_name: magnum_service
# Magnum Galera username
magnum_galera_user: magnum
# Magnum rabbit userid
magnum_rabbitmq_userid: magnum
# Magnum rabbit vhost
magnum_rabbitmq_vhost: /magnum
Example playbook
~~~~~~~~~~~~~~~~
.. literalinclude:: ../../examples/playbook.yml
:language: yaml
Tags
~~~~
This role supports two tags: ``magnum-install`` and ``magnum-config``.
The ``magnum-install`` tag can be used to install and upgrade. The
``magnum-config`` tag can be used to maintain configuration of the
service.

13
examples/playbook.yml Normal file
View File

@ -0,0 +1,13 @@
- name: Install Magnum server
hosts: magnum_all
user: root
roles:
- { role: "os_magnum", tags: [ "os-magnum" ] }
vars:
magnum_galera_address: "{{ internal_lb_vip_address }}"
magnum_galera_database_name: magnum_service
magnum_galera_user: magnum
magnum_rabbitmq_userid: magnum
magnum_rabbitmq_vhost: /magnum
ansible_hostname: "{{ container_name }}"
is_metal: "{{ properties.is_metal|default(false) }}"