summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsgpinkus <sgpinkus@gmail.com>2021-03-25 21:05:50 +0100
committerGitHub <noreply@github.com>2021-03-25 21:05:50 +0100
commit2abb2d3f17193a59d71c0a03ae1374a709f2db39 (patch)
tree237123eb242b9e8f192e5f4cd4de93805d43c11c
parentAdded prerequisites to install for CentOS (#73993) (diff)
downloadansible-2abb2d3f17193a59d71c0a03ae1374a709f2db39.tar.xz
ansible-2abb2d3f17193a59d71c0a03ae1374a709f2db39.zip
Update playbooks_variables.rst. To say you can define variables within a playbook is somewhat misleading. Variables are defined within plays and are only visible within the play they are defined in *not* the entire playbook. There is no way to define vars to have strictly playbook scope. (#73986)
+label: docsite_pr
-rw-r--r--docs/docsite/rst/user_guide/playbooks_variables.rst8
1 files changed, 4 insertions, 4 deletions
diff --git a/docs/docsite/rst/user_guide/playbooks_variables.rst b/docs/docsite/rst/user_guide/playbooks_variables.rst
index 75acc56ccc..086043b629 100644
--- a/docs/docsite/rst/user_guide/playbooks_variables.rst
+++ b/docs/docsite/rst/user_guide/playbooks_variables.rst
@@ -206,16 +206,16 @@ You can define different variables for each individual host, or set shared varia
.. _playbook_variables:
-Defining variables in a playbook
---------------------------------
+Defining variables in a play
+----------------------------
-You can define variables directly in a playbook::
+You can define variables directly in a playbook play::
- hosts: webservers
vars:
http_port: 80
-When you define variables in a playbook, they are visible to anyone who runs that playbook. This is especially useful if you share playbooks widely.
+When you define variables in a play, they are only visible to tasks executed in that play.
.. _included_variables:
.. _variable_file_separation_details: