[test last]

This commit is contained in:
2025-11-11 19:08:31 +01:00
parent 3be7c70643
commit 0a71da03ac

View File

@@ -54,7 +54,7 @@
- name: bitwarden token session
ansible.builtin.command:
cmd: "{{ item }}"
shell: "{{ item }}"
environment:
BW_CLIENTID: "{{ bw_client_id }}"
BW_CLIENTSECRET: "{{ bw_client_secret }}"
@@ -66,15 +66,22 @@
delegate_to: localhost
register: bw_session_result
# - name: Return all secrets from a path
# ansible.builtin.debug: "{{ bw_session_result.results[-1].stdout }}"
- name: Return all secrets from a path
ansible.builtin.debug: "{{ bw_session_result }}"
- name: Set BW_SESSION as environment variable globally
ansible.builtin.set_fact:
bw_session: "{{ bw_session_result.results[-1].stdout | trim }}"
no_log: true
- name: bitwarden token session
ansible.builtin.command:
shell: bw unlock --passwordenv BW_PASSWORD --raw
environment:
BW_CLIENTID: "{{ bw_client_id }}"
BW_CLIENTSECRET: "{{ bw_client_secret }}"
BW_PASSWORD: "{{ bw_client_password }}"
delegate_to: localhost
- name: Utiliser le lookup
ansible.builtin.debug: