-
Notifications
You must be signed in to change notification settings - Fork 71
/
thumbor.conf
38 lines (28 loc) · 1.03 KB
/
thumbor.conf
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
import os
STORAGE = "thumbor.storages.mixed_storage"
MIXED_STORAGE_FILE_STORAGE = "thumbor.storages.no_storage"
MIXED_STORAGE_CRYPTO_STORAGE = "thumbor.storages.no_storage"
MIXED_STORAGE_DETECTOR_STORAGE = "thumbor.storages.no_storage"
DETECTORS = []
FILTERS = [
'thumbor.filters.brightness',
'thumbor.filters.contrast',
'thumbor.filters.rgb',
'thumbor.filters.round_corner',
'thumbor.filters.quality',
'thumbor.filters.noise',
'thumbor.filters.watermark',
]
# Use optimizers to make pictures smaller
OPTIMIZERS = [
'thumbor.optimizers.jpegtran'
]
# Running insecure Thumbor instance is dangerous, you'd better to set a key
SECURITY_KEY = os.environ.get('THUMBOR_SECURITY_KEY', 'thumbor')
# If SECURITY_KEY is set, force unsafe url disabled
ALLOW_UNSAFE_URL = not SECURITY_KEY or SECURITY_KEY is 'thumbor'
HTTP_LOADER_FORWARD_USER_AGENT = True
# WebP can reduce traffic in most cases
AUTO_WEBP = True
# Executable path for jpegtran, usually command name is enough if it's in $PATH
JPEGTRAN_PATH = 'jpegtran'