From ce89382473f74197d2f560c990ad7518c3684682 Mon Sep 17 00:00:00 2001 From: Michael DeHaan Date: Fri, 19 Jul 2013 10:27:37 -0400 Subject: [PATCH] Legacy variable removal. --- docsite/latest/rst/glossary.rst | 5 ++--- docsite/latest/rst/playbooks.rst | 6 +++++- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/docsite/latest/rst/glossary.rst b/docsite/latest/rst/glossary.rst index 2e4748a18d..410966fbbd 100644 --- a/docsite/latest/rst/glossary.rst +++ b/docsite/latest/rst/glossary.rst @@ -172,8 +172,7 @@ Lookup Plugin A lookup plugin is a way to get data into Ansible from the outside world. These are how such things as "with_items" are implemented, which is a basic looping plugin, but there are also things like "with_file" which loads data from a file, and even things for querying environment variables, -DNS text records, or key value stores. Lookup plugins can also be accessed in templates using an all caps form, such as the contents of a file -on the local machine can be accessed like ``$FILE(/path/to/file)``. +DNS text records, or key value stores. Lookup plugins can also be accessed in templates as ``{{ lookup('file','/path/to/file') }}``. Multi-Tier ++++++++++ @@ -250,7 +249,7 @@ Local Action ++++++++++++ A local_action directive in a playbook targetting remote machines means that the given step will actually occur on local -machine, but that the variable '$ansible_hostname' can be passed in to reference the remote hostname being referred to in +machine, but that the variable '{{ ansible_hostname }}' can be passed in to reference the remote hostname being referred to in that step. This can be used to trigger, for example, an rsync operation. Loops diff --git a/docsite/latest/rst/playbooks.rst b/docsite/latest/rst/playbooks.rst index 06be929c4f..535d28ef01 100644 --- a/docsite/latest/rst/playbooks.rst +++ b/docsite/latest/rst/playbooks.rst @@ -433,7 +433,6 @@ Note that you cannot do variable substitution when including one playbook inside another. .. note:: - You can not conditionally path the location to an include file, like you can with 'vars_files'. If you find yourself needing to do this, consider how you can restructure your playbook to be more @@ -541,6 +540,11 @@ If you want to define certain tasks to happen before AND after roles are applied post_tasks: - shell: echo 'goodbye' +.. note:: +If you are using tags with tasks (described later as a means of only running part of a playbook) +be sure you also tag your pre_tasks and post_tasks and pass those along as well, especially if the pre +and post tasks are used for monitoring outage window control or load balancing. + Executing A Playbook ````````````````````