From 36e9cf5d7de049713784ed7c7005cc2269857e63 Mon Sep 17 00:00:00 2001 From: Michael DeHaan <michael@ansibleworks.com> Date: Sun, 9 Jun 2013 21:35:51 -0400 Subject: [PATCH] Mention YAML variable quoting. --- docsite/latest/rst/YAMLSyntax.rst | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/docsite/latest/rst/YAMLSyntax.rst b/docsite/latest/rst/YAMLSyntax.rst index b8fb861cbbc..ce15390bd3d 100644 --- a/docsite/latest/rst/YAMLSyntax.rst +++ b/docsite/latest/rst/YAMLSyntax.rst @@ -95,6 +95,12 @@ You will want to quote any hash values using colons, like so: And then the colon will be preserved. +Further, Ansible uses "{{ var }}" for variables. If a value after a colon starts +with a "{", YAML will think it a dictionary, so you must quote it, like so:: + + foo: "{{ variable }}" + + .. seealso:: :doc:`playbooks`