From 3fdc59b1d915b681fa006ab28e1bddec4796981d Mon Sep 17 00:00:00 2001 From: Neil Lalonde Date: Mon, 4 Mar 2013 16:06:46 -0500 Subject: [PATCH] Raise an error in production env if host_names is using production.localhost --- config/initializers/verify_config.rb | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 config/initializers/verify_config.rb diff --git a/config/initializers/verify_config.rb b/config/initializers/verify_config.rb new file mode 100644 index 00000000000..231b4de4296 --- /dev/null +++ b/config/initializers/verify_config.rb @@ -0,0 +1,15 @@ +# Check that the app is configured correctly. Raise some helpful errors if something is wrong. + +if Rails.env.production? and ['localhost', 'production.localhost'].include?(Discourse.current_hostname) + puts <