# Copyright 2011, Dell 
# 
# Licensed under the Apache License, Version 2.0 (the "License"); 
# you may not use this file except in compliance with the License. 
# You may obtain a copy of the License at 
# 
#  http://www.apache.org/licenses/LICENSE-2.0 
# 
# Unless required by applicable law or agreed to in writing, software 
# distributed under the License is distributed on an "AS IS" BASIS, 
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
# See the License for the specific language governing permissions and 
# limitations under the License. 
# 
# Author: RobHirschfeld 
# 

# Settings specified here will take precedence over those in config/environment.rb

# The production environment is meant for finished, "live" apps.
# Code is not reloaded between requests
Crowbar::Application.configure do
  config.cache_classes = true
  # Full error reports are disabled and caching is turned on
  #config.action_controller.consider_all_requests_local = false
  config.action_controller.perform_caching             = true
  config.action_view.cache_template_loading            = true
  config.active_support.deprecation = :notify

  # Disable request forgery protection in test environment
  config.action_controller.allow_forgery_protection    = true

  # See everything in the log (default is :info)
  # config.log_level = :debug

  # Use a different logger for distributed setups
  require 'syslogger'
  config.logger = Syslogger.new("crowbar_app", Syslog::LOG_PID, Syslog::LOG_LOCAL0)
  config.logger.level = Logger::DEBUG
  config.log_level = :debug

  # Use a different cache store in production
  # config.cache_store = :mem_cache_store

  # Enable serving of images, stylesheets, and javascripts from an asset server
  # config.action_controller.asset_host = "http://assets.example.com"

  # Disable delivery errors, bad email addresses will be ignored
  # config.action_mailer.raise_delivery_errors = false

  # Enable threaded mode
  config.threadsafe! unless $rails_rake_task

  # Legacy vars, should not be needed on Crowbar 2.0
  #DISABLE_CHEF=false
  #CHEF_CLIENT_KEY = "/opt/dell/crowbar_framework/config/client.pem"
  #CHEF_NODE_NAME ="crowbar" 
  #CHEF_SERVER_URL = "http://192.168.124.10:4000"
  CROWBAR_VERSION = "v2.0-dev"
 end 
