---

- block:
    - name: Detect installed version
      shell: /usr/local/bin/vault version | perl -pe 's/Vault v(\d+(\.\d+)*)\s.*/$1/'
      changed_when: False
      register: vault_current_version
    - set_fact:
        vault_current_version: "{{ vault_current_version.stdout }}"
  tags: vault

