Skip to content
Ansible playbook with Hashicorp Vault and Vagrant
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
cert
roles/user_management
.gitignore
README.md
Vagrantfile
inventory
site.yml

README.md

Overview

Playbook example for getting remote host credentials from hashicorp vault

Workspace Parts

Hashicorp Vault

Assume the vault already up and running on https://127.0.0.1:8200

Vagrantfile

Two remote hosts with IP Address 172.20.20.100 and 172.20.20.101

Ansible Playbook

The playbook will retrieve credentials from vault the create user in remote machines. We will user TLS mechanism to connect to vault.

Important note

Because this playbook using username and password to connect to machine, instead of ssh-copy-id mechanism, we need to install sshpass first.

Additional variables to be exported for make this playbook run, due to self-signed certificate and sshpass:

   export ANSIBLE_HOST_KEY_CHECKING=False
   export VAULT_SKIP_VERIFY=true
You can’t perform that action at this time.