Set default timezone to where our lab is located
[htsworkflow.git] / htsworkflow / settings.py
1 """
2 Django settings for wsgiexample project.
3
4 For more information on this file, see
5 https://docs.djangoproject.com/en/1.6/topics/settings/
6
7 For the full list of settings and their values, see
8 https://docs.djangoproject.com/en/1.6/ref/settings/
9 """
10
11 # Build paths inside the project like this: os.path.join(BASE_DIR, ...)
12 import os
13 BASE_DIR = os.path.dirname(os.path.dirname(__file__))
14
15
16 # Quick-start development settings - unsuitable for production
17 # See https://docs.djangoproject.com/en/1.6/howto/deployment/checklist/
18
19 # SECURITY WARNING: keep the secret key used in production secret!
20 SECRET_KEY = 'c=5&609$7)bm_u+3$2bi=ida$*a)c1(cp_0siua7uyww!1qfg_'
21
22 DEFAULT_API_KEY = 'n7HsXGHIi0vp9j5u4TIRJyqAlXYc4wrH'
23
24 # SECURITY WARNING: don't run with debug turned on in production!
25 # Override in settings_local
26 DEBUG = True
27
28 TEMPLATE_DEBUG = True
29
30 ALLOWED_HOSTS = ['jumpgate.caltech.edu']
31
32 # Application definition
33 AUTHENTICATION_BACKENDS = (
34   'htsworkflow.frontend.samples.auth_backend.HTSUserModelBackend', )
35 CUSTOM_USER_MODEL = 'samples.HTSUser'
36
37 INSTALLED_APPS = (
38     'django.contrib.admin',
39     'django.contrib.auth',
40     'django.contrib.contenttypes',
41     'django.contrib.sessions',
42     'django.contrib.messages',
43     'django.contrib.staticfiles',
44     'django.contrib.humanize',
45
46     'htsworkflow.frontend.eland_config',
47     'htsworkflow.frontend.samples',
48     'htsworkflow.frontend.experiments',
49     'htsworkflow.frontend.inventory',
50     'htsworkflow.frontend.bcmagic',
51     'htsworkflow.frontend.labels',
52 )
53
54 MIDDLEWARE_CLASSES = (
55     'django.contrib.sessions.middleware.SessionMiddleware',
56     'django.middleware.common.CommonMiddleware',
57     'django.middleware.csrf.CsrfViewMiddleware',
58     'django.contrib.auth.middleware.AuthenticationMiddleware',
59     'django.contrib.messages.middleware.MessageMiddleware',
60     'django.middleware.clickjacking.XFrameOptionsMiddleware',
61 )
62
63 TEMPLATE_DIRS = (
64     os.path.join(BASE_DIR, 'htsworkflow', 'frontend', 'templates'),
65     os.path.join(BASE_DIR, 'htsworkflow', 'templates'),
66 )
67
68 ROOT_URLCONF = 'htsworkflow.frontend.urls'
69
70 WSGI_APPLICATION = 'wsgi.application'
71
72 # Database
73 # https://docs.djangoproject.com/en/1.6/ref/settings/#databases
74
75 DATABASES = {
76     'default': {
77         'ENGINE': 'django.db.backends.sqlite3',
78         'NAME': os.path.join(BASE_DIR, 'fctracker.db'),
79     }
80 }
81
82 EMAIL_HOST = 'localhost'
83
84 # Internationalization
85 # https://docs.djangoproject.com/en/1.6/topics/i18n/
86
87 LANGUAGE_CODE = 'en-us'
88
89 TIME_ZONE = 'UTC'
90
91 USE_I18N = True
92
93 USE_L10N = True
94
95 USE_TZ = True
96
97 TIME_ZONE='America/Los_Angeles'
98
99 # Static files (CSS, JavaScript, Images)
100 # https://docs.djangoproject.com/en/1.6/howto/static-files/
101 STATIC_URL = '/static/'
102
103
104 #####
105 # Application specific settings
106 # Update this in settings_local to point to your flowcell result directory
107 RESULT_HOME_DIR = os.path.join(BASE_DIR, 'test', 'results')
108
109 # configure who is sending email and who should get BCCs of announcments
110 NOTIFICATION_SENDER = "noreply@example.com"
111 NOTIFICATION_BCC=[]
112
113 try:
114     # allow local customizations
115     from settings_local import *
116 except ImportError as e:
117     pass