0Pricing
Ansible Academy · Lesson

Encrypt a Single Variable Inline

Mix plaintext and secret vars.

Not Everything Is Secret

Sometimes one value in a file is sensitive while the rest is harmless. Encrypting the whole file feels heavy-handed. 🤔

Encrypt Just One Variable

Vault can encrypt a single value and leave the rest of the YAML readable. This keeps diffs clean and config browsable.

All lessons in this course

  1. Encrypt a File with ansible-vault create
  2. Edit, View & Rekey Vault Files
  3. Encrypt a Single Variable Inline
  4. Decrypt at Runtime with --ask-vault-pass
← Back to Ansible Academy