From 8b88132d25769d03e5061afc223959dece73fc7d 2015-05-05 00:21:50 From: Branko Majic Date: 2015-05-05 00:21:50 Subject: [PATCH] MAR-13: Update docs for testsite. No need to run bootstrap.yml with -k option (we use public key at this point). Optimimsed the bootstrap process a bit to be faster/easier. --- diff --git a/docs/testsite.rst b/docs/testsite.rst index 744214bb8e342b0a8bf4258075657e6d6865b960..c5769fb660682c4bfce6a9867bc261f2d6b11ce8 100644 --- a/docs/testsite.rst +++ b/docs/testsite.rst @@ -17,14 +17,14 @@ playbook runs. A number of playbooks is provided out of the box: -bootstrap.yml (for bootstrapping a new node) - This playbook can be used for bootstrapping a new node. This playbook expects - that a server name is passed via extra variables in CLI. The server name has - to be included in the hosts file, of course. For example: +bootstrap.yml (for bootstrapping fresh nodes) + This playbook can be used for bootstrapping fresh nodes. By default, the + entire test site will be included in the bootstrap. If you wish to limit + bootstrap to a single server, just run the playbook with (for example): .. code-block:: shell - ansible-playbook -e server=ldap.example.com playbooks/bootstrap.yml + ansible-playbook -l ldap.example.com playbooks/bootstrap.yml ldap.yml This playbook sets-up the LDAP servers. It is included in ``site.yml``. @@ -70,12 +70,12 @@ In order to deploy the test site, the following steps would normally be taken: 5. Install all servers using the generated preseed files. -6. Invoke the ``bootstrap.yml`` playbook for every server, one by one. For - example: +6. Invoke the ``bootstrap.yml`` playbook in order to set-up some basic + environment for Ansible runs on all servers: .. code-block:: shell - ansible-playbook -k -e server=ldap.example.com playbooks/bootstrap.yml + ansible-playbook playbooks/bootstrap.yml 7. Finally, apply configuration on all servers: diff --git a/testsite/hosts b/testsite/hosts index ea4dbec05230fb641781430ddb939505318155f3..96498d63446caad6c5f4ab0679b4ccd5af5d126e 100644 --- a/testsite/hosts +++ b/testsite/hosts @@ -8,4 +8,9 @@ ldap.example.com xmpp.example.com [mail] -mail.example.com \ No newline at end of file +mail.example.com + +[testsite:children] +ldap +xmpp +mail \ No newline at end of file diff --git a/testsite/playbooks/bootstrap.yml b/testsite/playbooks/bootstrap.yml index 10e3b62ada0690ee8622912c441500c565f6124f..97154f39ece672e3319027e7180db65d38801601 100644 --- a/testsite/playbooks/bootstrap.yml +++ b/testsite/playbooks/bootstrap.yml @@ -1,6 +1,6 @@ --- -- hosts: "{{ server }}" +- hosts: testsite remote_user: root roles: - bootstrap \ No newline at end of file