~/talk

Extending and embedding Ansible with Python

Talkat EuroPython 2015 · 2015-07-20..07-26· [python, devops-and-delivery]
links:none on file
slides:none on file

Shows concrete Python usage: Embedding Ansible with the Python API to run modules and playbooks (demo creates a user and installs packages on localhost), a small Flask REST wrapper to fetch facts, and creating modules with a real tiger issue module submitted to ansible extras that can create and delete issues. Adds dynamic inventory scripts (shelf file example) and several plugins (callback that fires notify send, filter with Caesar rotation). All demos run and produce the claimed effects.

AI-written summary · about

  1. 0:00Intro
  2. 1:24WHAT ANSIBLE IS
  3. 2:29ARCHITECTURE OVERVIEW
  4. 3:11HOST FILE (INVENTORY)
  5. 3:38AD HOC COMMANDS
  6. 4:10HELLO WORLD!: PING
  7. 4:47PLAYBOOKS
  8. 5:51A PLAYBOOK TO DEPLOY NGINX
  9. 7:30EMBEDDING?
  10. 9:29ABOUT FACTS
  11. 9:59EXAMPLE: FLASK FACTER
  12. 12:22EXAMPLE: INSTALLER
  13. 14:26EXTENDING?
  14. 14:57AN ANSIBLE MODULE ..
  15. 15:32STRUCTURE OF THE MODULE
  16. 16:23DOCUMENTATION AND EXAMPLES
  17. 17:13THE PYTHONIC PART
  18. 18:04THE MAIN() FUNCTION
  19. 19:12BOILERPLATE CODE
  20. 19:55MODULE CREATION TIPS
  21. 20:21MODULE EXAMPLE: TAIGA_ISSUE
  22. 24:12DYNAMIC INVENTORY SCRIPTS
  23. 24:33EXAMPLE: SHELVE_INVENTORY
  24. 25:48CALLBACK PLUGINS
  25. 27:57LOOKUP PLUGINS
  26. 28:14LOOKUP PLUGIN BASICS
  27. 29:38FILTER PLUGINS
  28. 30:00FILTER PLUGIN BASICS
  29. 30:14EXAMPLE: ROT13
  30. 30:51ACTION PLUGINS
  31. 31:24VARS PLUGINS
  32. 31:40VARS PLUGIN TEMPLATE CODE
  33. 31:50CACHE PLUGINS
  34. 32:19CACHE PLUGIN TEMPLATE CODE
  35. 34:03REFERENCES
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.