aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ansible/README.md42
-rw-r--r--ansible/inventory/all-in-one8
-rw-r--r--ansible/inventory/multinode14
-rw-r--r--ansible/roles/database/tasks/main.yml3
-rw-r--r--ansible/roles/message-broker/tasks/main.yml3
-rw-r--r--ansible/site.yml10
6 files changed, 80 insertions, 0 deletions
diff --git a/ansible/README.md b/ansible/README.md
new file mode 100644
index 000000000..d1734ea30
--- /dev/null
+++ b/ansible/README.md
@@ -0,0 +1,42 @@
+Koalla - Kolla with ansible!
+============================
+
+Koalla extends the Kolla project past [TripleO][] into its own bonified
+deployment system using [Ansible][] and [docker-compose][].
+
+[TripleO]: https://wiki.openstack.org/wiki/TripleO
+[Ansible]: https://docs.ansible.com
+[docker-compose]: http://docs.docker.com/compose
+
+
+Getting Started
+===============
+
+To run the ansible playbooks, you must specify an inventory file which tracks
+all of the available nodes in your environment. With this inventory file
+ansible will log into each node via ssh (configurable) and run tasks. Ansible
+does not require password less logins via ssh, however it is highly recommended
+to setup ssh-keys. More information on the ansible inventory file can be found
+[here][].
+
+[here]: https://docs.ansible.com/intro_inventory.html
+
+
+Deploying
+=========
+
+For AIO deploys, you can run the following commands. These will setup all of
+the containers on your localhost.
+
+```
+$ cd ./kolla/ansible
+$ ansible-playbook -i inventory/all-in-one site.yml
+```
+
+
+Further Reading
+===============
+
+Ansible playbook documentation can be found [here][].
+
+[here]: http://docs.ansible.com/playbooks.html
diff --git a/ansible/inventory/all-in-one b/ansible/inventory/all-in-one
new file mode 100644
index 000000000..246ce4e92
--- /dev/null
+++ b/ansible/inventory/all-in-one
@@ -0,0 +1,8 @@
+[support]
+localhost ansible_connection=local
+
+[database:children]
+support
+
+[message-broker:children]
+support
diff --git a/ansible/inventory/multinode b/ansible/inventory/multinode
new file mode 100644
index 000000000..a14fc6726
--- /dev/null
+++ b/ansible/inventory/multinode
@@ -0,0 +1,14 @@
+[support]
+# These hostname must be resolvable from your deployment host
+support01 ansible_ssh_user=sam
+support02 ansible_ssh_user=sam
+support03 ansible_ssh_user=sam
+
+# The above can also be specified as follows:
+#support[01:03] ansible_ssh_user=sam
+
+[database:children]
+support
+
+[message-broker:children]
+support
diff --git a/ansible/roles/database/tasks/main.yml b/ansible/roles/database/tasks/main.yml
new file mode 100644
index 000000000..c624649c2
--- /dev/null
+++ b/ansible/roles/database/tasks/main.yml
@@ -0,0 +1,3 @@
+---
+- name: Bringing up mariadb service(s)
+ command: docker-compose -f /root/kolla/compose/mariadb.yml up -d
diff --git a/ansible/roles/message-broker/tasks/main.yml b/ansible/roles/message-broker/tasks/main.yml
new file mode 100644
index 000000000..bec1f11d8
--- /dev/null
+++ b/ansible/roles/message-broker/tasks/main.yml
@@ -0,0 +1,3 @@
+---
+- name: Bringing up rabbitmq service(s)
+ command: docker-compose -f /root/kolla/compose/rabbitmq.yml up -d
diff --git a/ansible/site.yml b/ansible/site.yml
new file mode 100644
index 000000000..feccbb0b3
--- /dev/null
+++ b/ansible/site.yml
@@ -0,0 +1,10 @@
+---
+- hosts: database
+ roles:
+ - database
+ tags: database
+
+- hosts: message-broker
+ roles:
+ - message-broker
+ tags: message-broker