From 885907310f2e245059d2517a1c0473c265182cdf Mon Sep 17 00:00:00 2001 From: Kazuhiro MUSASHI Date: Sat, 6 Apr 2024 16:40:01 +0900 Subject: [PATCH] Deploy `/etc/nomad.d/client.hcl`. --- cookbooks/nomad/setup.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cookbooks/nomad/setup.rb b/cookbooks/nomad/setup.rb index 3a26a5f..100a9b3 100644 --- a/cookbooks/nomad/setup.rb +++ b/cookbooks/nomad/setup.rb @@ -38,11 +38,13 @@ end if node['nomad']['client'] %w( /etc/nomad.d/client.hcl ).each do |conf| - remote_file conf do + template conf do owner 'nomad' group 'nomad' mode '664' + variables(consul-token: node['nomad']['consul-token']) + notifies :restart, 'service[nomad]' end end