setting.py 1.29 KB
Newer Older
wanli's avatar
wanli committed
1 2 3 4 5 6 7 8 9 10 11 12 13
#!/usr/bin/env python
# -*- coding: utf_8 -*-

import os
import configparser

conf = configparser.ConfigParser()
conf.read(os.path.join(os.getcwd(), "config.ini"))

config = dict(
    NAME='evm_store',
    DEBUG=True,
    HOST="0.0.0.0",
wanliofficial's avatar
wanliofficial committed
14
    PORT=5000,
wanli's avatar
wanli committed
15 16 17 18 19
    SECRET_KEY='secret_key_EhuqUkwV',
    LOGIN_DISABLED=False,
    BACKUP_DIR=conf.get('application', 'backup_dir'),
    NETDISC=conf.get('uploads', 'netdisc'),
    DATABASE=conf.get('database', 'filename'),
wanliofficial's avatar
wanliofficial committed
20
    DATABASE_FILE=conf.get('scheduler', 'db'),
wanli's avatar
wanli committed
21 22 23 24 25
    PONY={
        'provider': conf.get('database', 'provider'),
        'filename': "../{}".format(conf.get('database', 'filename')),
        'create_db': True,
    },
wanli's avatar
wanli committed
26
    TABLE_PREFIX='evm_store_',
wanli's avatar
wanli committed
27
    MD5_SALT="EhuqUkwV",
wanli's avatar
wanli committed
28
    UPLOAD_PATH=os.getcwd(),
wanli's avatar
wanli committed
29 30 31 32 33 34 35 36 37 38 39 40 41
    UPLOAD_DIR=conf.get('uploads', 'upload_dir'),
    TEMPLATE_PATH=os.path.join(os.getcwd(), "static"),
    STATIC_PATH=os.path.join(os.getcwd(), "static"),
    LOGO=r'''
               ______                               _____              
___      _________  /_     ________________________ __  /______________
__ | /| / /  _ \_  __ \    _  ___/_  ___/  _ \  __ `/  __/  __ \_  ___/
__ |/ |/ //  __/  /_/ /    / /__ _  /   /  __/ /_/ // /_ / /_/ /  /    
____/|__/ \___//_.___/     \___/ /_/    \___/\__,_/ \__/ \____//_/   

Power by EVM Team
    '''
)