root / snf-pithos-app / pithos / api / settings.py @ 93127325
History | View | Annotate | Download (2.2 kB)
1 |
#coding=utf8
|
---|---|
2 |
from django.conf import settings |
3 |
|
4 |
# Set local users, or a remote host. To disable local users set them to None.
|
5 |
sample_users = { |
6 |
'0000': {'userid': '0', 'email': ['test'], 'name': 'test', 'auth_token': '0000'}, |
7 |
'0001': {'userid': '1', 'email': ['verigak'], 'name': 'verigak', 'auth_token': '0001'}, |
8 |
'0002': {'userid': '2', 'email': ['chazapis'], 'name': 'chazapis', 'auth_token': '0002'}, |
9 |
'0003': {'userid': '3', 'email': ['gtsouk'], 'name': 'gtsouk', 'auth_token': '0003'}, |
10 |
'0004': {'userid': '4', 'email': ['papagian'], 'name': 'papagian', 'auth_token': '0004'}, |
11 |
'0005': {'userid': '5', 'email': ['louridas'], 'name': 'louridas', 'auth_token': '0005'}, |
12 |
'0006': {'userid': '6', 'email': ['chstath'], 'name': 'chstath', 'auth_token': '0006'}, |
13 |
'0007': {'userid': '7', 'email': ['pkanavos'], 'name': 'pkanavos', 'auth_token': '0007'}, |
14 |
'0008': {'userid': '8', 'email': ['mvasilak'], 'name': 'mvasilak', 'auth_token': '0008'}, |
15 |
'0009': {'userid': '9', 'email': ['διογένης'], 'name': 'διογένης', 'auth_token': '0009'} |
16 |
} |
17 |
|
18 |
AUTHENTICATION_URL = getattr(settings, 'PITHOS_AUTHENTICATION_URL', 'http://127.0.0.1:8000/im/authenticate') |
19 |
AUTHENTICATION_USERS = getattr(settings, 'PITHOS_AUTHENTICATION_USERS', sample_users) |
20 |
|
21 |
COOKIE_NAME = getattr(settings, 'ASTAKOS_COOKIE_NAME', '_pithos2_a') |
22 |
|
23 |
# SQLAlchemy (choose SQLite/MySQL/PostgreSQL).
|
24 |
BACKEND_DB_MODULE = getattr(settings, 'PITHOS_BACKEND_DB_MODULE', 'pithos.backends.lib.sqlalchemy') |
25 |
BACKEND_DB_CONNECTION = getattr(settings, 'PITHOS_BACKEND_DB_CONNECTION', 'sqlite:////tmp/pithos-backend.db') |
26 |
|
27 |
# Block storage.
|
28 |
BACKEND_BLOCK_MODULE = getattr(settings, 'PITHOS_BACKEND_BLOCK_MODULE', 'pithos.backends.lib.hashfiler') |
29 |
BACKEND_BLOCK_PATH = getattr(settings, 'PITHOS_BACKEND_BLOCK_PATH', '/tmp/pithos-data/') |
30 |
|
31 |
# Queue for billing.
|
32 |
BACKEND_QUEUE_MODULE = getattr(settings, 'PITHOS_BACKEND_QUEUE_MODULE', None) # Example: 'pithos.backends.lib.rabbitmq' |
33 |
BACKEND_QUEUE_CONNECTION = getattr(settings, 'PITHOS_BACKEND_QUEUE_CONNECTION', None) # Example: 'rabbitmq://guest:guest@localhost:5672/pithos' |
34 |
|
35 |
# Default setting for new accounts.
|
36 |
BACKEND_QUOTA = getattr(settings, 'PITHOS_BACKEND_QUOTA', 50 * 1024 * 1024 * 1024) |
37 |
BACKEND_VERSIONING = getattr(settings, 'PITHOS_BACKEND_VERSIONING', 'auto') |
38 |
|