From 4598483d0f7faf357c443e12816a45cd0f975e50 Mon Sep 17 00:00:00 2001 From: Nick Walker Date: Mon, 26 Oct 2015 15:50:22 -0700 Subject: [PATCH] Fix the update-classes script and set appropriate perms on it --- site/profile/files/puppetmaster/update-classes.sh | 2 +- site/profile/manifests/puppetmaster.pp | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/site/profile/files/puppetmaster/update-classes.sh b/site/profile/files/puppetmaster/update-classes.sh index dea10a9..fc33026 100644 --- a/site/profile/files/puppetmaster/update-classes.sh +++ b/site/profile/files/puppetmaster/update-classes.sh @@ -6,6 +6,6 @@ CERT=$(puppet master --confdir ${CONFDIR} --configprint hostcert) CACERT=$(puppet master --confdir ${CONFDIR} --configprint localcacert) PRVKEY=$(puppet master --confdir ${CONFDIR} --configprint hostprivkey) OPTIONS="--cert ${CERT} --cacert ${CACERT} --key ${PRVKEY}" -CONSOLE=$(awk '/server =/{print $NF}' ${CONFDIR}/console.conf) +CONSOLE=$(awk '/server: /{print $NF}' ${CONFDIR}/classifier.yaml) curl -k -X POST ${OPTIONS} "https://${CONSOLE}:4433/classifier-api/v1/update-classes" diff --git a/site/profile/manifests/puppetmaster.pp b/site/profile/manifests/puppetmaster.pp index ec85155..193f0ca 100644 --- a/site/profile/manifests/puppetmaster.pp +++ b/site/profile/manifests/puppetmaster.pp @@ -53,6 +53,7 @@ class profile::puppetmaster { file { '/usr/local/bin/update-classes.sh' : ensure => file, source => 'puppet:///modules/profile/puppetmaster/update-classes.sh', + mode => '755', } #https://docs.puppetlabs.com/puppet/latest/reference/config_file_environment.html#environmenttimeout