--- # Include: includes/sops_credentials.yaml # Description: Get sops secure encrypted credentials # Author: Mauro Rosero P. # Email: mauro@rosero.one (mauro.rosero@gmail.com) # Organization: ROSERO ONE # Created: Ene 04, 2025 12:00:00 # Updated: 2025-01-05 00:00:00 - name: Get if credential access exists ansible.builtin.stat: path: "{{ sops_file }}" register: credentials_access connection: local become: no - name: Check if credentials access exists ansible.builtin.assert: that: - credentials_access.stat.exists fail_msg: "{{ messages.console.error.no_credentials }}" quiet: true - name: Get sops credentials access vars set_fact: sops_vars: "{{ lookup('community.sops.sops', sops_file, input_type='yaml', output_type='yaml') | from_yaml }}"