-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsettings.py
237 lines (215 loc) · 5.75 KB
/
settings.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Copyright 2007 - 2011 TUBITAK/BILGEM
# Licensed under the GNU General Public License, version 3.
# See the file http://www.gnu.org/copyleft/gpl.txt.
from os import path
ADMINS = ()
MANAGERS = ADMINS
# Site configuration
SITE_NAME = 'Özgürlük için...'
SITE_DESC = 'Pardus için bir numaralı bilgi kaynağı'
DEBUG = True
TESTING = True
TEMPLATE_DEBUG = DEBUG
WEB_URL = 'http://localhost:8000'
DOCUMENT_ROOT = path.abspath(path.dirname(__file__))
DATABASES = {
"default": {
"ENGINE": "django.db.backends.mysql",
"NAME": "oi",
"USER": "root",
"PASSWORD": "root",
"HOST": "/var/run/mysqld/mysqld.sock",
"PORT": "",
}
}
# Email
DEFAULT_FROM_EMAIL = '[email protected]'
#EMAIL_USE_TLS = True
# Pagination
USER_PER_PAGE = 10
PACKAGE_PER_PAGE = 10
FS_PER_PAGE = 10
HOWTO_PER_PAGE = 10
WORKSHOP_PER_PAGE = 10
GAME_PER_PAGE = 10
NEWS_PER_PAGE = 10
TAG_PER_PAGE = 10
SEMINAR_PER_PAGE = 10
# News in homepage
NEWS_IN_HOMEPAGE = 5
PACKAGES_IN_HOMEPAGE = 2
GAMES_IN_HOMEPAGE = 2
FS_IN_HOMEPAGE = 2
HOWTOS_IN_HOMEPAGE = 2
# For extending User class
AUTH_PROFILE_MODULE = 'profile.Profile'
# Login stuff, we use different urls for authentication.
LOGIN_URL = '/kullanici/giris/'
LOGIN_REDIRECT_URL = '/kullanici/sayfam'
LOGOUT_URL = '/kullanici/cikis/'
PROFILE_EDIT_URL = '/kullanici/duzenle/'
# Feedjack Settings for resizing images
FEEDJACK_RESIZE_IMAGE = True
FEEDJACK_MAX_IMAGE_Y = False
FEEDJACK_MAX_IMAGE_X = 610
FEEDJACK_UPLOAD_DIR = "%s/media/feedjack" % DOCUMENT_ROOT
FEEDJACK_UPLOAD_URL = "%s/media/feedjack" % WEB_URL
TIME_ZONE = 'Europe/Istanbul'
LANGUAGE_CODE = 'tr'
SITE_ID = 1
MEDIA_ROOT = '%s/media/' % DOCUMENT_ROOT
MEDIA_URL = '%s/media/' % WEB_URL
ADMIN_MEDIA_PREFIX = '/media/admin/'
WEBALIZER_DIR = ''
#SECRET_KEY = 'GENERATE YOUR OWN SECRET KEY'
TEMPLATE_LOADERS = (
'django.template.loaders.filesystem.load_template_source',
'django.template.loaders.app_directories.load_template_source',
)
TEMPLATE_CONTEXT_PROCESSORS = (
'oi.context_processors.testing',
'django.core.context_processors.auth',
'django.core.context_processors.request',
'grappelli.context_processors.admin_template_path',
)
MIDDLEWARE_CLASSES = (
'django.middleware.common.CommonMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.contrib.csrf.middleware.CsrfMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.middleware.doc.XViewMiddleware',
'oi.flatpages.middleware.FlatpageFallbackMiddleware',
'oi.middleware.threadlocals.ThreadLocals',
# 'oi.middleware.debug.DebugFooter',
'oi.middleware.ban.BanWare',
)
ROOT_URLCONF = 'oi.urls'
TEMPLATE_DIRS = (
'%s/templates' % DOCUMENT_ROOT,
'%s/shop/templates' % DOCUMENT_ROOT,
)
INSTALLED_APPS = (
'grappelli',
'filebrowser',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.admin',
'django.contrib.sites',
'django.contrib.humanize',
'django.contrib.sitemaps',
'django_evolution',
'oi.flatpages',
'oi.st',
'oi.upload',
'oi.bug',
'oi.feedjack',
'oi.seminar',
'oi.profile',
'oi.forum',
'oi.tema',
'oi.petition',
'oi.poll',
# shop apps
'oi.shop.shopprofile',
'oi.shop.product',
'oi.shop.cart',
'oi.beyin2',
'oi.ezine',
'oi.webalizer',
'oi.editor',
'oi.paste',
'oi.shipit',
'oi.piyango',
'oi.podcast',
)
CITY_LIST = (
('adana','Adana'),
('adiyaman','Adıyaman'),
('afyon','Afyon'),
('agri','Ağrı'),
('aksaray','Aksaray'),
('amasya','Amasya'),
('ankara','Ankara'),
('antalya','Antalya'),
('ardahan','Ardahan'),
('artvin','Artvin'),
('aydin','Aydın'),
('balikesir','Balikesir'),
('bartin','Bartın'),
('batman','Batman'),
('bayburt','Bayburt'),
('bilecik','Bilecik'),
('bingol','Bingöl'),
('bitlis','Bitlis'),
('bolu','Bolu'),
('burdur','Burdur'),
('bursa','Bursa'),
('canakkale','Çanakkale'),
('cankiri','Çankırı'),
('corum','Çorum'),
('denizli','Denizli'),
('diyarbakir','Diyarbakır'),
('duzce','Düzce'),
('edirne','Edirne'),
('elazig','Elazığ'),
('erzincan','Erzincan'),
('erzurum','Erzurum'),
('eskisehir','Eskişehir'),
('gaziantep','Gaziantep'),
('giresun','Giresun'),
('gumushane','Gümüşhane'),
('hakkari','Hakkari'),
('hatay','Hatay'),
('igdir','Iğdır'),
('isparta','Isparta'),
('istanbul_anadolu','İstanbul (Anadolu)'),
('istanbul_avrupa','İstanbul (Avrupa)'),
('izmir','İzmir'),
('kahramanmaras','KahramanMaraş'),
('karabuk', 'Karabük'),
('karaman','Karaman'),
('kars','Kars'),
('kastamonu','Kastamonu'),
('kayseri','Kayseri'),
('kilis', 'Kilis'),
('kirikkale','Kırıkkale'),
('kirklareli','Kırklareli'),
('kirsehir','Kırşehir'),
('kocaeli','Kocaeli'),
('konya','Konya'),
('kutahya','Kütahya'),
('malatya','Malatya'),
('manisa','Manisa'),
('mardin','Mardin'),
('mersin','Mersin'),
('mugla','Muğla'),
('mus','Muş'),
('nevsehir','Nevşehir'),
('nigde','Niğde'),
('ordu','Ordu'),
('osmaniye', 'Osmaniye'),
('rize','Rize'),
('sakarya','Sakarya'),
('samsun','Samsun'),
('siirt','Siirt'),
('sinop','Sinop'),
('sirnak','Şırnak'),
('sivas','Sivas'),
('tekirdag','Tekirdag'),
('tokat','Tokat'),
('trabzon','Trabzon'),
('tunceli','Tunceli'),
('urfa','Urfa'),
('usak','Uşak'),
('van','Van'),
('yalova', 'Yalova'),
('yozgat','Yozgat'),
('zonguldak','Zonguldak'),
('zzyurtdisi', 'Yurtdışı'),
)
GRAPPELLI_ADMIN_TITLE = "Özgürlükİçin"
FILEBROWSER_DIRECTORY = "uploads/"