From 7852eef5a6d0eefc5914f178549f6845857a5c49 Mon Sep 17 00:00:00 2001 From: LUXEY Adrien Date: Tue, 23 Mar 2021 17:00:27 +0100 Subject: WIP: improving Ansible config while I install my HammerHead - added files... --- os/config/roles/common/tasks/hashicorp.yml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 os/config/roles/common/tasks/hashicorp.yml (limited to 'os/config/roles/common/tasks/hashicorp.yml') diff --git a/os/config/roles/common/tasks/hashicorp.yml b/os/config/roles/common/tasks/hashicorp.yml new file mode 100644 index 0000000..9cf647b --- /dev/null +++ b/os/config/roles/common/tasks/hashicorp.yml @@ -0,0 +1,24 @@ +- name: "Add Hashicorps's official GPG key to apt" + ansible.builtin.apt_key: + url: https://apt.releases.hashicorp.com/gpg + state: present + +- name: "Add Hashicorp's repository to APT sources list" + ansible.builtin.apt_repository: + repo: "deb [arch={{ architecture_map[ansible_architecture] }}] https://apt.releases.hashicorp.com {{ ansible_distribution_release }} main" + state: present + vars: + architecture_map: + "x86_64": "amd64" + "aarch64": "arm64" + "aarch": "arm64" + "armhf": "armhf" + "armv7l": "armhf" + +- name: "Install Nomad & Consul" + ansible.builtin.apt: + state: present + update_cache: yes + name: + - nomad + - consul \ No newline at end of file -- cgit v1.2.3