Created
October 11, 2022 19:49
-
-
Save konstruktoid/961599dd311fae3ae07947655d0bdaaf to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
- hosts: localhost | |
tasks: | |
- name: 8 character random string | |
ansible.builtin.set_fact: | |
generated_password: "{{ lookup('community.general.random_string', min_lower=1, min_upper=1, min_special=1, min_numeric=1) }}" | |
register: password | |
- name: print registered password | |
debug: | |
msg: "{{ password }}" | |
- name: print password fact | |
debug: | |
msg: "{{ generated_password }}" | |
... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment