Statistics
| Branch: | Tag: | Revision:

root / pithos / settings.py.dist @ 59d6bd1e

History | View | Annotate | Download (3.6 kB)

1 c7e0bbe2 Antony Chazapis
# Django settings for pithos project.
2 c7e0bbe2 Antony Chazapis
import os
3 c7e0bbe2 Antony Chazapis
4 c7e0bbe2 Antony Chazapis
PROJECT_PATH = os.path.dirname(os.path.abspath(__file__)) + '/'
5 c7e0bbe2 Antony Chazapis
6 c7e0bbe2 Antony Chazapis
DEBUG = True
7 c7e0bbe2 Antony Chazapis
TEMPLATE_DEBUG = DEBUG
8 c7e0bbe2 Antony Chazapis
9 c7e0bbe2 Antony Chazapis
# A quick-n-dirty way to know if we're running unit tests
10 c7e0bbe2 Antony Chazapis
import sys
11 c7e0bbe2 Antony Chazapis
TEST = False
12 c7e0bbe2 Antony Chazapis
if len(sys.argv) >= 2:
13 c7e0bbe2 Antony Chazapis
    if os.path.basename(sys.argv[0]) == 'manage.py' and \
14 c7e0bbe2 Antony Chazapis
        (sys.argv[1] == 'test' or sys.argv[1] == 'hudson'):
15 c7e0bbe2 Antony Chazapis
            TEST = True
16 c7e0bbe2 Antony Chazapis
17 c7e0bbe2 Antony Chazapis
ADMINS = (
18 c7e0bbe2 Antony Chazapis
    # ('Your Name', 'your_email@domain.com'),
19 c7e0bbe2 Antony Chazapis
)
20 c7e0bbe2 Antony Chazapis
21 c7e0bbe2 Antony Chazapis
MANAGERS = ADMINS
22 c7e0bbe2 Antony Chazapis
23 c7e0bbe2 Antony Chazapis
DATABASES = {
24 c7e0bbe2 Antony Chazapis
    'default': {
25 c7e0bbe2 Antony Chazapis
        'ENGINE': 'sqlite3', # Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
26 c7e0bbe2 Antony Chazapis
        'NAME': PROJECT_PATH + 'pithos.db',		# Or path to database file if using sqlite3.
27 c7e0bbe2 Antony Chazapis
        'USER': '',                      # Not used with sqlite3.
28 c7e0bbe2 Antony Chazapis
        'PASSWORD': '',                  # Not used with sqlite3.
29 c7e0bbe2 Antony Chazapis
        'HOST': '',                      # Set to empty string for localhost. Not used with sqlite3.
30 c7e0bbe2 Antony Chazapis
        'PORT': '',                      # Set to empty string for default. Not used with sqlite3.
31 c7e0bbe2 Antony Chazapis
    }
32 c7e0bbe2 Antony Chazapis
}
33 c7e0bbe2 Antony Chazapis
34 c7e0bbe2 Antony Chazapis
# Local time zone for this installation. Choices can be found here:
35 c7e0bbe2 Antony Chazapis
# http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
36 c7e0bbe2 Antony Chazapis
# although not all choices may be available on all operating systems.
37 c7e0bbe2 Antony Chazapis
# On Unix systems, a value of None will cause Django to use the same
38 c7e0bbe2 Antony Chazapis
# timezone as the operating system.
39 c7e0bbe2 Antony Chazapis
# If running in a Windows environment this must be set to the same as your
40 c7e0bbe2 Antony Chazapis
# system time zone.
41 c7e0bbe2 Antony Chazapis
TIME_ZONE = 'UTC'
42 c7e0bbe2 Antony Chazapis
43 c7e0bbe2 Antony Chazapis
# Language code for this installation. All choices can be found here:
44 c7e0bbe2 Antony Chazapis
# http://www.i18nguy.com/unicode/language-identifiers.html
45 c7e0bbe2 Antony Chazapis
LANGUAGE_CODE = 'en-us'
46 c7e0bbe2 Antony Chazapis
47 c7e0bbe2 Antony Chazapis
SITE_ID = 1
48 c7e0bbe2 Antony Chazapis
49 c7e0bbe2 Antony Chazapis
# If you set this to False, Django will make some optimizations so as not
50 c7e0bbe2 Antony Chazapis
# to load the internationalization machinery.
51 c7e0bbe2 Antony Chazapis
USE_I18N = True
52 c7e0bbe2 Antony Chazapis
53 c7e0bbe2 Antony Chazapis
# If you set this to False, Django will not format dates, numbers and
54 c7e0bbe2 Antony Chazapis
# calendars according to the current locale
55 c7e0bbe2 Antony Chazapis
USE_L10N = True
56 c7e0bbe2 Antony Chazapis
57 c7e0bbe2 Antony Chazapis
# Absolute filesystem path to the directory that will hold user-uploaded files.
58 c7e0bbe2 Antony Chazapis
# Example: "/home/media/media.lawrence.com/"
59 c7e0bbe2 Antony Chazapis
MEDIA_ROOT = ''
60 c7e0bbe2 Antony Chazapis
61 c7e0bbe2 Antony Chazapis
# URL that handles the media served from MEDIA_ROOT. Make sure to use a
62 c7e0bbe2 Antony Chazapis
# trailing slash if there is a path component (optional in other cases).
63 c7e0bbe2 Antony Chazapis
# Examples: "http://media.lawrence.com", "http://example.com/media/"
64 c7e0bbe2 Antony Chazapis
MEDIA_URL = ''
65 c7e0bbe2 Antony Chazapis
66 c7e0bbe2 Antony Chazapis
# URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a
67 c7e0bbe2 Antony Chazapis
# trailing slash.
68 c7e0bbe2 Antony Chazapis
# Examples: "http://foo.com/media/", "/media/".
69 c7e0bbe2 Antony Chazapis
ADMIN_MEDIA_PREFIX = '/media/'
70 c7e0bbe2 Antony Chazapis
71 c7e0bbe2 Antony Chazapis
# Make this unique, and don't share it with anybody.
72 c7e0bbe2 Antony Chazapis
SECRET_KEY = '$j0cdrfm*0sc2j+e@@2f-&3-_@2=^!z#+b-8o4_i10@2%ev7si'
73 c7e0bbe2 Antony Chazapis
74 c7e0bbe2 Antony Chazapis
# List of callables that know how to import templates from various sources.
75 c7e0bbe2 Antony Chazapis
TEMPLATE_LOADERS = (
76 c7e0bbe2 Antony Chazapis
    'django.template.loaders.filesystem.Loader',
77 c7e0bbe2 Antony Chazapis
    'django.template.loaders.app_directories.Loader',
78 c7e0bbe2 Antony Chazapis
#     'django.template.loaders.eggs.Loader',
79 c7e0bbe2 Antony Chazapis
)
80 c7e0bbe2 Antony Chazapis
81 c7e0bbe2 Antony Chazapis
MIDDLEWARE_CLASSES = (
82 c7e0bbe2 Antony Chazapis
    'django.middleware.common.CommonMiddleware',
83 c7e0bbe2 Antony Chazapis
    'django.contrib.sessions.middleware.SessionMiddleware',
84 c7e0bbe2 Antony Chazapis
    'django.middleware.csrf.CsrfViewMiddleware',
85 c7e0bbe2 Antony Chazapis
    'django.contrib.auth.middleware.AuthenticationMiddleware',
86 c7e0bbe2 Antony Chazapis
    'django.contrib.messages.middleware.MessageMiddleware',
87 c7e0bbe2 Antony Chazapis
)
88 c7e0bbe2 Antony Chazapis
89 c7e0bbe2 Antony Chazapis
ROOT_URLCONF = 'pithos.urls'
90 c7e0bbe2 Antony Chazapis
91 c7e0bbe2 Antony Chazapis
TEMPLATE_DIRS = (
92 c7e0bbe2 Antony Chazapis
    # Put strings here, like "/home/html/django_templates" or "C:/www/django/templates".
93 c7e0bbe2 Antony Chazapis
    # Always use forward slashes, even on Windows.
94 c7e0bbe2 Antony Chazapis
    # Don't forget to use absolute paths, not relative paths.
95 c7e0bbe2 Antony Chazapis
)
96 c7e0bbe2 Antony Chazapis
97 c7e0bbe2 Antony Chazapis
INSTALLED_APPS = (
98 c7e0bbe2 Antony Chazapis
    'django.contrib.auth',
99 c7e0bbe2 Antony Chazapis
    'django.contrib.contenttypes',
100 c7e0bbe2 Antony Chazapis
    'django.contrib.sessions',
101 c7e0bbe2 Antony Chazapis
    'django.contrib.sites',
102 c7e0bbe2 Antony Chazapis
    'django.contrib.messages',
103 08184449 Antony Chazapis
#    'django.contrib.admin',
104 08184449 Antony Chazapis
#    'django.contrib.admindocs',
105 c7e0bbe2 Antony Chazapis
    'api'
106 c7e0bbe2 Antony Chazapis
)