[global]
# This is where all of your settings go for your production environment.
# You'll copy this file over to your production server and provide it
# as a command-line option to your start script.
# Settings that are the same for both development and production
# (such as template engine, encodings, etc.) all go in
# ${package}/config/app.cfg

# DATABASE

#if $sqlalchemy == "True"
# driver://username:password@host:port/database

# pick the form for your database
# sqlalchemy.dburi = 'postgres://username@hostname/databasename'
# sqlalchemy.dburi = 'mysql://username:password@hostname:port/databasename'
# sqlalchemy.dburi = 'sqlite:///relative/path/to/database/file'
# sqlalchemy.dburi = 'sqlite:////absolute/path/to/database/file'

# If you have sqlite, here's a simple default to get you started
# in development
sqlalchemy.dburi = 'sqlite:///%(current_dir_uri)s/devdata.sqlite'

# for Windows users, SQLAlchemy URIs for SQlite look like:
# sqlobject.dburi = 'sqlite:///drive_letter:/path/to/file'
#else
# pick the form for your database
# sqlobject.dburi = 'postgres://username@hostname/databasename'
# sqlobject.dburi = 'mysql://username:password@hostname:port/databasename'
# sqlobject.dburi = 'sqlite:///file_name_and_path'

# If you have sqlite, here's a simple default to get you started
# in development
sqlobject.dburi = 'sqlite:///%(current_dir_uri)s/devdata.sqlite'

# if you are using a database or table type without transactions
# (MySQL default, for example), you should turn off transactions
# by prepending notrans_ on the uri
# sqlobject.dburi = 'notrans_mysql://username:password@hostname:port/databasename'

# for Windows users, SQLObject URIs for SQlite look like:
# sqlobject.dburi = 'sqlite:///drive_letter|/path/to/file'
#end if

# SERVER

# Set the production environment
environment = 'production'

# No Auto-Reload after code modification
engine.autoreload.on = False

# Sets the number of threads the server uses
# server.thread_pool = 1

# if this is part of a larger site, you can set the path
# to the TurboGears instance here
# server.webpath = ''

# Set to True if you are deploying your App behind a proxy
# e.g. Apache using mod_proxy
tools.proxy.on = True
# Set if your proxy adds the X-Forwarded-Host header
tools.proxy.local = 'X-Forwarded-Host'
# If your proxy does not add the X-Forwarded-Host header, set
# tools.proxy.local = '' and the following to the *public* host url
# tools.proxy.base = 'http://www.example.com'

# Set to True if you'd like to abort execution if a controller gets an
# unexpected parameter. False by default
# tg.strict_parameters = False

# LOGGING

# CherryPy 3 logging settings. See http://www.cherrypy.org/wiki/Logging
# Set this to True to have both "error" and "access" messages printed to stdout.
# Set to False because we set our own 'cherrypy.access' logger below.
log.screen = False
# Set this to an absolute filename where you want "access" messages written.
# log.access_file = None
# Set this to an absolute filename where you want "error" messages written.
# log.error_file = None

# Logging configuration generally follows the style of the standard
# Python logging module configuration. Note that when specifying
# log format messages, you need to use *() for formatting variables.
# Deployment independent log configuration is in ${package}/config/log.cfg

[logging]

[[handlers]]

[[[access_out]]]
# set the filename as the first argument below
args="('server.log',)"
class='FileHandler'
level='INFO'
formatter='message_only'

[[loggers]]

[[[allerror]]]
level='ERROR'
handlers=['error_out']

[[[${package}]]]
level='ERROR'
qualname='${package}'
handlers=['error_out']
propagate=0

[[[access]]]
level='INFO'
qualname='cherrypy.access'
handlers=['access_out']
propagate=0

[[[error]]]
level='ERROR'
qualname='cherrypy.error'
handlers=['error_out']
propagate=0
