diff --git a/manifests/resource/vhost.pp b/manifests/resource/vhost.pp index 0f1f4d82d..3e17d581b 100644 --- a/manifests/resource/vhost.pp +++ b/manifests/resource/vhost.pp @@ -593,10 +593,11 @@ } concat { $config_file: - owner => $owner, - group => $group, - mode => $mode, - notify => Class['::nginx::service'], + owner => $owner, + group => $group, + mode => $mode, + notify => Class['::nginx::service'], + require => [File[$vhost_dir], File[$vhost_enable_dir]], } $ssl_only = ($ssl == true) and (($ssl_port + 0) == ($listen_port + 0)) @@ -704,7 +705,7 @@ ensure => $vhost_symlink_ensure, path => "${vhost_enable_dir}/${name_sanitized}.conf", target => $config_file, - require => Concat[$config_file], + require => [File[$vhost_dir], File[$vhost_enable_dir], Concat[$config_file]], notify => Class['::nginx::service'], }