Clean repository: organized structure and GitOps setup
- Organized root directory structure - Moved orphan files to proper locations - Updated .gitignore to ignore temporary files - Set up Gitea Runner for GitOps automation - Fixed Tailscale access issues - Added workflow for automated Nomad deployment
This commit is contained in:
36
deployment/ansible/playbooks/install/install_vault.yml
Normal file
36
deployment/ansible/playbooks/install/install_vault.yml
Normal file
@@ -0,0 +1,36 @@
|
||||
---
|
||||
# install_vault.yml
|
||||
- name: Install HashiCorp Vault
|
||||
hosts: vault_servers
|
||||
become: yes
|
||||
tasks:
|
||||
- name: Check if Vault is already installed
|
||||
command: which vault
|
||||
register: vault_check
|
||||
ignore_errors: yes
|
||||
changed_when: false
|
||||
|
||||
- name: Install Vault using apt
|
||||
apt:
|
||||
name: vault
|
||||
state: present
|
||||
update_cache: yes
|
||||
when: vault_check.rc != 0
|
||||
|
||||
- name: Create Vault data directory
|
||||
file:
|
||||
path: "{{ vault_data_dir | default('/opt/nomad/data/vault/config') }}"
|
||||
state: directory
|
||||
owner: root
|
||||
group: root
|
||||
mode: '0755'
|
||||
recurse: yes
|
||||
|
||||
- name: Verify Vault installation
|
||||
command: vault --version
|
||||
register: vault_version
|
||||
changed_when: false
|
||||
|
||||
- name: Display Vault version
|
||||
debug:
|
||||
var: vault_version.stdout
|
||||
Reference in New Issue
Block a user