From 67a3bdbc835afb68c10e7fd6f8e2bfd96b64e62e Mon Sep 17 00:00:00 2001 From: Bradley Taylor Date: Tue, 10 Feb 2009 11:50:23 -0500 Subject: [PATCH] added require to file vhost --- lib/recipes/passenger_recipes.rb | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/lib/recipes/passenger_recipes.rb b/lib/recipes/passenger_recipes.rb index 07f1582..e723948 100644 --- a/lib/recipes/passenger_recipes.rb +++ b/lib/recipes/passenger_recipes.rb @@ -56,10 +56,14 @@ def passenger_site(args) conf_template_contents = File.read(conf_template) doc_root = Configuration[:prefix] + "/" + name + "/current/public" conf_content = ERB.new(conf_template_contents).result(binding) - file conf_file, { :ensure => :present, :content => conf_content, :notify => service("apache2"), :alias => "passenger_vhost" } + file conf_file, { :ensure => :present, + :content => conf_content, + :notify => service("apache2"), + :alias => "passenger_vhost", + :require => exec("enable_passenger") } exec "passenger_enable_site", { :command => "/usr/sbin/a2ensite #{name}", :creates => '/etc/apache2/sites-enabled/#{name}', - :require => [package("apache2-mpm-worker"), file("passenger_vhost")]} + :require => [package("apache2-mpm-worker"), file("passenger_vhost")] } end end \ No newline at end of file