templates/torquebox/config/rubber/role/app/torquebox-apache-vhost.conf in rubber-2.12.2 vs templates/torquebox/config/rubber/role/app/torquebox-apache-vhost.conf in rubber-2.13.0

- old
+ new

@@ -1,7 +1,12 @@ <% + is_old_ubuntu = %w[10.04 12.04].include?(rubber_instance.os_version) + + # Apache 2.2 requires no extension while Apache 2.4 requires the '.conf' extension. @path = "/etc/apache2/sites-available/#{rubber_env.app_name}-torquebox" + @path << '.conf' unless is_old_ubuntu + @post = "a2enmod rewrite && a2enmod ssl && a2enmod expires && a2enmod xsendfile && a2ensite #{rubber_env.app_name}-torquebox" sidekiq_gem_path = if rubber_instances.for_role('sidekiq').any? require 'sidekiq' `find /mnt/#{rubber_env.app_name}-#{RUBBER_ENV}/shared/bundle -name sidekiq-#{Sidekiq::VERSION}`.strip @@ -16,9 +21,16 @@ ServerName <%= rubber_env.domain %> <%- if rubber_env.web_aliases -%> ServerAlias <%= rubber_env.web_aliases.join(" ") %> <%- end -%> DocumentRoot <%= Rubber.root + "/public" %> + + <%- unless is_old_ubuntu %> + <Directory <%= Rubber.root + "/public" %>> + Options FollowSymLinks + Require all granted + </Directory> + <% end %> ErrorDocument 404 /404.html ErrorDocument 500 /500.html SetEnvIf User-Agent "^(.*MSIE.*)|(.*AppleWebKit.*)$" nokeepalive