3. Elsevier
"Elsevier is an information solutions company with roots in publishing scientific, medical, and technical literature"
Publisher of scientific, medical and technical literature
ScienceDirect.com, part of Elsevier
AWS, Ansible, Packer
Python / BASH + GoCD for operations/automation
Microservice architecutre (mostly Java)
Know any/all of above? We're hiring!
4. Debugging Ansible modules
Ansible makes debugging somewhat problematic, expects valid json for
any output.
print('x has value: {0}').format(x) won't ever make it to the console.
So how do we check the state of a variable, e.g. when looping over a list?
26. Use 'q'
"Quick-and-dirty debugging output for tired programmers"
Install it with pip install q( )
Output is sent to $TMPDIR/q
Use for normal output (replace 'print' with 'q')
Use as a decorator (@q)
https://pypi.python.org/pypi/q
30. check out the temporary directory:
Mooaaarr debugging!
tell ansible to not clean-up after itself:
$exportANSIBLE_KEEP_REMOTE_FILES=1
$play-Mmodules/-iinventorymyplay_describe.yml-vvv
(in our case locally as we dont run against remote hosts)
$cd ~/.ansible/tmp/ansible-tmp-1434809169.56-151563844546363
$ls-l
-rw-r--r-- 1ale staff 7265520Jun15:06ec2_describe