-
Notifications
You must be signed in to change notification settings - Fork 6
/
settings.py.sample
68 lines (45 loc) · 1.93 KB
/
settings.py.sample
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
#-*- coding: utf-8 -*-
# Apache2Piwik - importing data to Piwik from apache logs
#
# @link http://clearcode.cc/
# @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
##############################################
# MySQL Piwik Database configuration
DB_HOST = 'localhost'
DB_PORT = 3306
DB_USER = 'dbuser'
DB_PASSWORD = 'dbpass'
DB_DATABASE_NAME = 'piwik'
PIWIK_PREFIX = 'piwik_'
##############################################
# Apache files
# Format of Apache logs (see /etc/apache2/apache2.conf)
LOG_FORMAT = "%h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\""
# Apache logs files paths
APACHE_LOG_FILES = ['/path/to/log/file','/onother/path/to/log/file']
# True - if files from APACHE_LOG_FILES are orderded chronologically by server time, otherwise False
CHRONOLOGICAL_ORDER = False
# True - if after running script you want to run it again on data chronologically after and from the same server, otherwise False
CONTINUE = False
# If you want to ignore specific kind of apache log files, you can specify regexp here (http://docs.python.org/library/re.html)
IGNORED_LOGS = ['/admin/']
# If you want to ignore specific kind of user agents, you can specify regexp here (http://docs.python.org/library/re.html)
IGNORED_USER_AGENTS = ['bot','crawl','Bot','spider','Spider']
##############################################
# File extensions
# Ignored extentions of downloaded files by visitors
IGNORED_EXTENSIONS = ['.jpg','.gif','.jpeg','.css','.js','.png','.ico']
# Downloaded files
DOWNLOADED_EXTENSIONS = ['.zip','.pdf','.doc','.xls','.ppt','.jad','.jar','.cod','.apk']
##############################################
# Other
# Regular expretion to cut urls, the <url> group is taken only
URL_REGEXPR = '(?P<url>[^;\?]*).*?'
# Piwik configuration
ID_SITE = 1
# Maximum length of one visit, in seconds
VISIT_LENGTH = 1800
##############################################
# Life processing
LIFE = False
FREQUENCY_OF_READING = 1000