[test last]

This commit is contained in:
2025-11-11 17:13:28 +01:00
parent ac5304fa0e
commit 2a6b992c96

View File

@@ -61,8 +61,6 @@
mode: '0755' mode: '0755'
remote_src: yes remote_src: yes
delegate_to: localhost delegate_to: localhost
when: bw_check.rc != 0
- name: bitwarden token session - name: bitwarden token session
ansible.builtin.command: ansible.builtin.command:
@@ -74,7 +72,23 @@
- bw config server {{ vaultwarden_url }} - bw config server {{ vaultwarden_url }}
- bw login --apikey - bw login --apikey
- bw unlock {{ bw_client_password }} --raw - bw unlock {{ bw_client_password }} --raw
delegate_to: localhost
register: bw_session_result register: bw_session_result
when: bw_check.rc != 0
# - name: bitwarden token session
# ansible.builtin.command:
# cmd: "{{ item }}"
# environment:
# BW_CLIENTID: "{{ bw_client_id }}"
# BW_CLIENTSECRET: "{{ bw_client_secret }}"
# loop:
# - bw config server {{ vaultwarden_url }}
# - bw login --apikey
# - bw unlock {{ bw_client_password }} --raw
# delegate_to: localhost
# register: bw_session_result
- debug: - debug:
@@ -87,9 +101,9 @@
environment: environment:
BW_SESSION: "{{ bw_session_result.results[-1].stdout }}" BW_SESSION: "{{ bw_session_result.results[-1].stdout }}"
- name: logout # - name: logout
ansible.builtin.command: # ansible.builtin.command:
cmd: bw logout # cmd: bw logout
# - name: Return all secrets from a path # - name: Return all secrets from a path
# delegate_to: localhost # delegate_to: localhost