mirror of
https://github.com/sissbruecker/linkding.git
synced 2025-08-08 11:18:28 +02:00
Add black code formatter
This commit is contained in:
@@ -15,46 +15,41 @@ SASS_PROCESSOR_ENABLED = False
|
||||
|
||||
# Try read secret key from file
|
||||
try:
|
||||
with open(os.path.join(BASE_DIR, 'secretkey.txt')) as f:
|
||||
with open(os.path.join(BASE_DIR, "secretkey.txt")) as f:
|
||||
SECRET_KEY = f.read().strip()
|
||||
except:
|
||||
pass
|
||||
|
||||
# Set ALLOWED_HOSTS
|
||||
# By default look in the HOST_NAME environment variable, if that is not set then allow all hosts
|
||||
host_name = os.environ.get('HOST_NAME')
|
||||
host_name = os.environ.get("HOST_NAME")
|
||||
if host_name:
|
||||
ALLOWED_HOSTS = [host_name]
|
||||
else:
|
||||
ALLOWED_HOSTS = ['*']
|
||||
ALLOWED_HOSTS = ["*"]
|
||||
|
||||
# Logging
|
||||
LOGGING = {
|
||||
'version': 1,
|
||||
'disable_existing_loggers': False,
|
||||
'formatters': {
|
||||
'simple': {
|
||||
'format': '{asctime} {levelname} {message}',
|
||||
'style': '{',
|
||||
"version": 1,
|
||||
"disable_existing_loggers": False,
|
||||
"formatters": {
|
||||
"simple": {
|
||||
"format": "{asctime} {levelname} {message}",
|
||||
"style": "{",
|
||||
},
|
||||
},
|
||||
'handlers': {
|
||||
'console': {
|
||||
'class': 'logging.StreamHandler',
|
||||
'formatter': 'simple'
|
||||
"handlers": {"console": {"class": "logging.StreamHandler", "formatter": "simple"}},
|
||||
"root": {
|
||||
"handlers": ["console"],
|
||||
"level": "WARN",
|
||||
},
|
||||
"loggers": {
|
||||
"bookmarks": {
|
||||
"level": "INFO",
|
||||
"handlers": ["console"],
|
||||
"propagate": False,
|
||||
}
|
||||
},
|
||||
'root': {
|
||||
'handlers': ['console'],
|
||||
'level': 'WARN',
|
||||
},
|
||||
'loggers': {
|
||||
'bookmarks': {
|
||||
'level': 'INFO',
|
||||
'handlers': ['console'],
|
||||
'propagate': False,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
# Import custom settings
|
||||
|
Reference in New Issue
Block a user