zuul/releasenotes/notes/zuul-message-a36f1a6adc7da31c.yaml
Tobias Henkel fcbb91582f
Encode zuul.message with base64
Zuul recently added zuul.message which needs to be protected against
interpretation by jinja in ansible. This was initially done by marking
it with the !unsafe tag. However this has the disadvantage that the
inventory is no longer parsable by standard yaml parsers without
teaching them the !unsafe tag.

There is a similar simple possibility that doesn't rely on this tag by
base64 encoding the commit message. Ansible has filters for decoding
this so it is still quite easy to deal with base64 encoded vars in
ansible via '{{ zuul.message | b64decode }}'.

Change-Id: I9628e2770dda120b269612e28bb6217036942b8e
2019-02-28 18:09:22 +01:00

9 lines
364 B
YAML

---
upgrade:
- |
Zuul recently added the job variable :var:`zuul.message`. This can contain
jinja tags which can cause problems accessing the zuul variable in the job.
Because of this the message is now base64 encoded and any job evaluating
this variable needs to be changed from ``{{ zuul.message }}`` to
``{{ zuul.message | b64decode }}``.