hashipi

Raspberry Pi Test Cluster for HashiCorp Vault, Nomad and Consul
git clone https://git.in0rdr.ch/hashipi.git
Log | Files | Refs | README

commit 2df33ae76129ad52b5bdd7db13e75be7a058c1a5
parent f58812e1529eefccc8e4fb8c36f8d191799b3659
Author: Andreas Gruhler <andreas.gruhler@adfinis.com>
Date:   Sat,  8 Jun 2024 17:37:29 +0200

feat: replace host json with hcl

Diffstat:
M.gitignore | 2+-
MREADME.md | 2+-
Dhosts/pi0.json | 7-------
Ahosts/pi0.pkrvars.hcl | 5+++++
Dhosts/pi1.json | 7-------
Ahosts/pi1.pkrvars.hcl | 5+++++
Dhosts/pi2.json | 7-------
Ahosts/pi2.pkrvars.hcl | 5+++++
Dhosts/pi3.json | 7-------
Ahosts/pi3.pkrvars.hcl | 5+++++
Dhosts/pi4.json | 7-------
Ahosts/pi4.pkrvars.hcl | 5+++++
12 files changed, 27 insertions(+), 37 deletions(-)

diff --git a/.gitignore b/.gitignore @@ -1,2 +1,2 @@ **.swp -**.pkrvars.hcl +**auto.pkrvars.hcl diff --git a/README.md b/README.md @@ -154,7 +154,7 @@ interpreter /usr/bin/qemu-aarch64-static Don't forget to create a new set of [Consul TLS certificates](#Consul) before each run. Run packer with a value file to build an image for one host: ```bash -./consul-tls.sh && sudo /usr/bin/packer build -var-file=variables.auto.pkrvars.hcl -var-file=hosts/pi0.json hashi-pi.pkr.hcl +./consul-tls.sh && sudo /usr/bin/packer build -var-file=variables.auto.pkrvars.hcl -var-file=hosts/pi0.pkrvars.hcl hashi-pi.pkr.hcl ``` The `variable.auto.pkrvars.hcl` contains all sensitive packer variables. diff --git a/hosts/pi0.json b/hosts/pi0.json @@ -1,7 +0,0 @@ -{ - "hostname": "pi0", - "img_name": "HashiPi-pi0.img", - "consul_server": "true", - "nomad_server": "true", - "nomad_client": "true" -} diff --git a/hosts/pi0.pkrvars.hcl b/hosts/pi0.pkrvars.hcl @@ -0,0 +1,5 @@ +hostname = "pi0" +img_name = "HashiPi-pi0.img" +consul_server = true +nomad_server = true +nomad_client = true diff --git a/hosts/pi1.json b/hosts/pi1.json @@ -1,7 +0,0 @@ -{ - "hostname": "pi1", - "img_name": "HashiPi-pi1.img", - "consul_server": "false", - "nomad_server": "false", - "nomad_client": "true" -} diff --git a/hosts/pi1.pkrvars.hcl b/hosts/pi1.pkrvars.hcl @@ -0,0 +1,5 @@ +hostname = "pi1" +img_name = "HashiPi-pi1.img" +consul_server = false +nomad_server = false +nomad_client = true diff --git a/hosts/pi2.json b/hosts/pi2.json @@ -1,7 +0,0 @@ -{ - "hostname": "pi2", - "img_name": "HashiPi-pi2.img", - "consul_server": "true", - "nomad_server": "true", - "nomad_client": "true" -} diff --git a/hosts/pi2.pkrvars.hcl b/hosts/pi2.pkrvars.hcl @@ -0,0 +1,5 @@ +hostname = "pi2" +img_name = "HashiPi-pi2.img" +consul_server = true +nomad_server = true +nomad_client = true diff --git a/hosts/pi3.json b/hosts/pi3.json @@ -1,7 +0,0 @@ -{ - "hostname": "pi3", - "img_name": "HashiPi-pi3.img", - "consul_server": "false", - "nomad_server": "false", - "nomad_client": "true" -} diff --git a/hosts/pi3.pkrvars.hcl b/hosts/pi3.pkrvars.hcl @@ -0,0 +1,5 @@ +hostname = "pi3" +img_name = "HashiPi-pi3.img" +consul_server = false +nomad_server = false +nomad_client = true diff --git a/hosts/pi4.json b/hosts/pi4.json @@ -1,7 +0,0 @@ -{ - "hostname": "pi4", - "img_name": "HashiPi-pi4.img", - "consul_server": "true", - "nomad_server": "true", - "nomad_client": "true" -} diff --git a/hosts/pi4.pkrvars.hcl b/hosts/pi4.pkrvars.hcl @@ -0,0 +1,5 @@ +hostname = "pi4" +img_name = "HashiPi-pi4.img" +consul_server = true +nomad_server = true +nomad_client = true