tripleo-container-manage: provide more debug doc

Provide a command that doesn't use playbook to debug a container, just
pure Ansible CLI.

Change-Id: Ie6c29df1ec70d97ad22f9c71c4f35a8928c8f160
This commit is contained in:
Emilien Macchi 2020-02-14 10:02:44 -05:00
parent 109201525f
commit 5a2eeacc0d
1 changed files with 16 additions and 4 deletions

View File

@ -1,9 +1,9 @@
===============================
Role - tripleo-container-manage
Role - tripleo_container_manage
===============================
.. ansibleautoplugin::
:role: tripleo_ansible/roles/tripleo-container-manage
:role: tripleo_ansible/roles/tripleo_container_manage
Usage
~~~~~
@ -75,7 +75,7 @@ This Ansible role allows to do the following tasks:
block:
- name: "Manage containers for step 1 with tripleo-ansible"
include_role:
name: tripleo-container-manage
name: tripleo_container_manage
vars:
tripleo_container_manage_systemd_order: true
tripleo_container_manage_config: "/var/lib/tripleo-config/container-startup-config/step_1"
@ -145,7 +145,7 @@ overrides the image setting in one-off.
block:
- name: "Manage HAproxy container at step 1 with tripleo-ansible"
include_role:
name: tripleo-container-manage
name: tripleo_container_manage
vars:
tripleo_container_manage_systemd_order: true
tripleo_container_manage_config_patterns: 'hashed-haproxy.json'
@ -155,6 +155,18 @@ overrides the image setting in one-off.
haproxy:
image: docker.io/tripleomaster/centos-binary-haproxy:hotfix
The same can be achieved with this command:
.. code-block:: bash
ansible -m include_role -a role=tripleo_container_manage \
-e tripleo_container_manage_systemd_order=True \
-e tripleo_container_manage_config_patterns='haproxy.json' \
-e tripleo_container_manage_config='/var/lib/tripleo-config/container-startup-config/step_1' \
-e tripleo_container_manage_config_id='tripleo_step1' \
-e tripleo_container_manage_config_overrides="{'haproxy': {'image': 'docker.io/tripleomaster/centos-binary-haproxy:hotfix'}}" \
--become --one-line localhost
If Ansible is run in check mode, no container will be removed nor created,
however at the end of the playbook a list of commands will be displayed to show
what would have been run.