Ansible DevTools Intro

2021-10

About me

  • Name: Sorin Sbarnea
  • Employer: Red Hat (since 2016)
  • 10+ years of Python, CI/CD experience
  • Maintainer of molecule and ansible-lint during the last 3 years.
  • Joined Ansible DevTools in September 2021

DevTools Charter and Mission

Tooling, guidelines, and procedures that aid in the creation, testing, and standardization of production grade Ansible content and plugins

Bit of background

  • Ansible DevTools team was created in 2021
  • 6 engineers
  • We aim to include our tools into AAP

Tools we own

  • ansible-lint
  • molecule
  • ansible extension for vscode
  • ansible-navigator
  • ansible-test (soon)

I am new, what should I use?

testing-pyramid

Pain-saving tips

  • Layout your code using recommended collection layout
    • ..even when you do not plan to package it
  • Realise testing is an on-going activity
    • It is never “complete”
  • Start from bottom (linter)
  • If you write modules, use ansible-test

Ansible vscode extension

  • smart auto-completion
  • ansible-lint integration
  • easy encryption/decryption for vault secrets
  • documentation references (hover)
  • multiplatform (Windows via WSL)

Syntax highlight

syntax

Live validation

validation

Ansible-lint integration

ansible-lint

Smart auto-completion

smart-auto-completion

Documentation reference

doc-reference

Jump to module code

jump-to-module

External resources

🤗

That’s it! Any Questions?

  • #ansible-devtools channel on matrix/libera
  • Use Github discussion forums on each of those projects

Presentation source is available at sbarnea/slides