Skip to content

Commit

Permalink
Update hashibox.pkr.hcl
Browse files Browse the repository at this point in the history
Baked Consul and Nomad TLS CA certs and directory permissions
  • Loading branch information
amitchahalgits authored Jun 4, 2024
1 parent bc07d1e commit 044f0da
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion packer/hashibox.pkr.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,11 @@ build {

# Provision Nomad and Consul CA's that can be later used for agent cert provisioning.
"sudo mkdir /etc/consul.d/certs && cd /etc/consul.d/certs ; sudo consul tls ca create",
"sudo mkdir /etc/nomad.d/certs && cd /etc/nomad.d/certs ; sudo consul tls ca create",
"sudo mkdir /etc/nomad.d/certs && cd /etc/nomad.d/certs ; sudo nomad tls ca create",

# Set permissions for the certs directory
"sudo chown consul:consul /etc/consul.d/certs",
"sudo chown nomad:nomad /etc/nomad.d/certs"

# Enabling of the services is the responsibility of the instance provisioning scripts.
"sudo systemctl disable docker consul nomad"
Expand Down

0 comments on commit 044f0da

Please sign in to comment.