You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
655 B

  1. ---
  2. - name: shared/auth_backend | Test if the auth backend exists
  3. uri:
  4. url: "{{ vault_leader_url }}/v1/sys/auth/{{ auth_backend_path }}/tune"
  5. headers: "{{ vault_headers }}"
  6. validate_certs: false
  7. ignore_errors: true
  8. register: vault_auth_backend_check
  9. - name: shared/auth_backend | Add the cert auth backend if needed
  10. uri:
  11. url: "{{ vault_leader_url }}/v1/sys/auth/{{ auth_backend_path }}"
  12. headers: "{{ vault_headers }}"
  13. method: POST
  14. body_format: json
  15. body:
  16. description: "{{ auth_backend_description|d('') }}"
  17. type: "{{ auth_backend_type }}"
  18. status_code: 204
  19. when: vault_auth_backend_check|failed