forked from wa0x6e/Fresque
-
Notifications
You must be signed in to change notification settings - Fork 0
/
fresque.ini
165 lines (135 loc) · 4.52 KB
/
fresque.ini
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
; ::::::::::::::::::::::::::::
; Fresque Configuration File ;
; ::::::::::::::::::::::::::::
;
; This is the default configuration
; file for your fresque application
;
; Most of these settings can be overriden
; through their corresponding option flag
; when running a command
[Redis]
; Hostname of your redis server
; Usually localhost or 127.0.0.1
host = localhost
; Port number of you redis server
; Default is 6379
port = 6379
; Redis Database
database = 0
; Redis namespace
; All resque related keys will be prepented with this string
namespace = resque
[Fresque]
; Absolute or relative for storing the Pid files
; A relative path will be relative to the location
; of the fresque cli.
; tmpdir = ./tmp/
; Absolute or relative path to php-resque libraries
; A relative path will be relative to the location
; of the fresque cli.
;
; Fresque is shipped with a copy of the php-resque
; library, but it you have already included one in your
; application, and wish to use it, put in its path
lib = ./vendor/kamisama/php-resque-ex
; Absolute path to the entry point of you application
; In order to execute your jobs, php-resque have to know
; about your jobs classes.
; Instead of passing each job classes to php-resque
; one by one, use an autoloader that will autoload
; your jobs classes
include = /path/to/your/application/autoloader.php
[Default]
; Default name of the queue the worker will be working one
; A worker can work on more than one queue, just separate
; the name with a commas, e.g "defaultone,defaultwo"
queue = default
; Polling frequency
; Number of seconds to sleep between each polling
interval = 5
; Number of workers to fork
; e.g putting 2 will start to workers with exactly
; the same settings
workers = 1
; User running the fresque process
; It's a system user, who must own the permissions
; to create and edit the log file and run you jobs
; Usually, it's the same user as the one running
; your php process, e.g www-data
user = www-data
; Verbose mode
; Log more debugging informations
; You can also enable verbose mode by using the --verbose
; option when starting a worker
verbose = 0
[Log]
; Path to the log file
; All phpresque activities will be
; recorded into this log
; You can use an absolute or relative path
; Relative path will be relative to the fresque bin file
filename = /path/to/fresque.log
; Following 2 options are used only if you use
; https://github.com/kamisama/php-resque-ex
; instead of php-resque. It enables more logging
; options, such as logging to a database
; Log Handler used for logging
; Refer to Monolog documentation for a list
; of available handler
; https://github.com/Seldaek/monolog#handlers
; Use the handler name without the "Handler" part
;
; eg : to use MongoDBHandler :
; handler = MongoDB
handler =
; Options used by the handler for initialization
; Options depends on the handler, refer to each
; handler documentation for valid options.
; If handler takes more than one mandatory arguments,
; separate them with a comma
;
; eg : FileRotateHandler takes only one
; mandatory arguments : the filename
; target = path/log.log
;
; eg : CubeHandler takes one url argument
; target : udp://127.0.0.1:1180
target =
; ---------------------------------------------------------
; Following settings are optionals
; and should be used if you have more than one worker,
; with different settings each.
; It lets you start a bunch of workers at once
;
; Here, you define default settings for your
; different workers.
; Calling `load` in cli will start all of them at once
[Queues]
; Here, we will define two workers : `activity` and `stats`
; Let's start by the `activity` worker
; We set the number of workers to 2, in the following format :
; QUEUENAME[PROPERTY] = VALUE
;activity[workers] = 2
;
; PROPERTY can be any of the key defined in [Default], [Redis],
; [Fresque] or [Log] sections (above)
;
; If you don't set the other properties (interval, user etc ...),
; default value will be used.
; You need to set at least one value, even if it's the
; same as the default one, because fresque will need
; the keyname to capture the queue name
; Here, we set the properties for another worker
; named `stats`
;stats[interval] = 10
;stats[workers] = 3
[Env]
; Environment variables that you want to pass to the workers
; Useful for example if you don't keep the database credentials or API keys in your source code
; Passing a key only will search for its value from the getenv() function
; MYSQL_USER =
; MYSQL_PASSWORD =
; Passing a key and a value will set the env variable to this value
; APP_ENV = dev
; That's all folks !