From 40e79ffdbb5631d7f40fcfae468499cde8364c5a Mon Sep 17 00:00:00 2001 From: Clark Boylan Date: Wed, 21 Oct 2015 15:49:10 -0700 Subject: [PATCH] Use file resource to manage build copy We had a complicated series of execs to build and copy files into the docroot. Unfortunately these haven't worked as expected but we can simplify the puppet by using a file resource to manage the copy of the build for us. Change-Id: I55c521bc7b5f24e46932c11cece4376e55f50767 --- manifests/site.pp | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/manifests/site.pp b/manifests/site.pp index 7d7941e..29ccd25 100644 --- a/manifests/site.pp +++ b/manifests/site.pp @@ -24,18 +24,15 @@ define openstack_health::site( api_endpoint => $api_endpoint } - exec {'move-static-files': - command => "mv ${openstack_health::source_dir}/build ${httproot}", - path => ['/usr/local/bin/', '/usr/bin/', '/bin/'], - subscribe => Exec['build-static-files'], - refreshonly => true, - } - file {$httproot: ensure => directory, owner => 'openstack_health', group => 'openstack_health', - mode => '0755', - require => Exec['move-static-files'] + mode => '0644', + recurse => true, + purge => true, + force => true, + source => "${openstack_health::source_dir}/build", + require => Exec['build-static-files'] } }