Skip to content

Instantly share code, notes, and snippets.

@alces
Created May 30, 2017 10:45
Show Gist options
  • Save alces/a8baae143f09a22fc2467b6db34536cf to your computer and use it in GitHub Desktop.
Save alces/a8baae143f09a22fc2467b6db34536cf to your computer and use it in GitHub Desktop.
Genereta an idempotent, pretty obscure string (can be used as a database password, etc.)
- connection: local
hosts: localhost
tasks:
- debug:
msg: "{{ ('secretword' | password_hash('sha256', 'salt_string')).split('$')[-1][:16] }}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment