-
Notifications
You must be signed in to change notification settings - Fork 81
/
Copy pathgopa.yml
294 lines (275 loc) · 6.48 KB
/
gopa.yml
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
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
path.data: data
path.logs: log
cookie_secret: YOUR-GOPA-SECRET
allow_multi_instance: true
max_num_of_instances: 1
logging.level: debug
elasticsearch:
- name: default
enabled: true
endpoint: http://localhost:9200
index_prefix: gopa-
basic_auth:
username: elastic
password: WYOWoQq28mp07fDoPIvc
pipelines:
- name: url_fetch_flow
start:
joint: init_task
enabled: true
process:
- joint: url_normalization
enabled: true
parameters:
follow_all_domain: false
follow_sub_domain: true
max_filename_length: 1000
- joint: ignore_timeout
parameters:
ignore_timeout_after_count: 500
enabled: true
- joint: chrome_fetch
enabled: true
parameters:
chrome_host: http://127.0.0.1:9223
save_screenshot: true
compress_enabled: true
timeout_in_seconds: 60
screenshot_quality: 50
- joint: fetch
enabled: false
parameters:
timeout_in_seconds: 100
- joint: parse
enabled: true
parameters:
dispatch_links: true
save_images: true
max_depth: 2
max_breadth: 1
- joint: extract
enabled: false
parameters:
html_block:
your_tag_name1: ".tag_class"
your_tag_name2: "#tag_id"
- joint: html2text
parameters:
remove_nonscript: true
merge_whitespace: false
enabled: true
- joint: hash
enabled: true
- joint: content_deduplication
enabled: true
- joint: update_check_time
enabled: true
parameters:
decelerate_steps: "72h,168h,360h,720h"
accelerate_steps: "360h,120h,72h"
- joint: lang_detect
enabled: true
- joint : save_snapshot_fs
enabled: false
- joint : save_snapshot_db
enabled: true
parameters:
compress_enabled: true
bucket: "Snapshot"
max_revision: 5
- joint: index
enabled: true
end:
joint: save_task
enabled: true
keep_404: false
keep_redirected: false
- name: url_filter_flow
start:
joint: init_task
enabled: true
process:
- joint: url_normalization
enabled: true
parameters:
follow_all_domain: false
follow_sub_domain: true
max_filename_length: 1000
- joint: url_filter
enabled: true
parameters:
url_match_rule:
must_not:
prefix:
- "mailto:"
- "data:image/"
- "#"
- "javascript:"
contain:
- "crond/run"
- "login"
- "logout"
- "/account/"
- "/blob/"
- "/tree/"
- "/commit/"
- "/compare/"
- "/releases"
suffix: []
must:
prefix: []
contain: ["elastic"]
suffix: []
should:
prefix: ["https://stackoverflow.com/questions/tagged/elasticsearch","/questions/tagged/elasticsearch"]
contain: ["https://stackoverflow.com/questions/","/issues","elastic.co","elasticsearch.cn","elastic"]
suffix: []
host_match_rule:
must:
prefix: []
contain: []
suffix: []
should:
prefix: []
contain: []
suffix: []
must_not:
prefix: []
contain: ["elasticsearch-ci","github.com"]
suffix: []
file_match_rule:
must:
prefix: []
contain: []
suffix: []
should:
prefix: []
contain: []
suffix: []
must_not:
prefix: []
contain: []
suffix: []
file_ext_match_rule:
should:
prefix: []
contain: []
suffix: []
must:
prefix: []
contain: []
suffix: []
must_not:
contain: [zip, exe, jar, js, css, rar, gz, zip, bmp, jpeg, gif, svg, png, jpg, apk]
prefix: []
suffix: []
- joint: filter_check
enabled: true
parameters:
filter_key: check_filter
- joint: task_deduplication
enabled: true
end:
joint: save_task
enabled: true
parameters:
is_create: true
api:
enabled: true
auth:
basic_auth:
users: users.txt
roles: roles.txt
network:
binding: 0.0.0.0:8000
tls:
enabled: true
skip_insecure_verify: true
cluster:
enabled: true
name: gopa
minimum_nodes: 1
seeds:
- 127.0.0.1:10000
broadcast:
binding: 224.3.2.2:9876
rpc:
network:
binding: 0.0.0.0:10000
tls:
enabled: true
skip_insecure_verify: true
modules:
- name: pipeline
enabled: true
runners:
- name: checker
enabled: true
input_queue: check
pipeline_id: url_filter_flow
max_go_routine: 5
threshold_in_ms: 0
timeout_in_ms: 5000
default_config:
- name: fetch
enabled: true
input_queue: fetch
pipeline_id: url_fetch_flow
max_go_routine: 10
threshold_in_ms: 0
timeout_in_ms: 30000
default_config:
- name: web
enabled: true
tls:
enabled: false
skip_insecure_verify: true
network:
binding: 127.0.0.1:9000
auth:
enabled: false
oauth_provider: github
oauth_authorize_url: https://github.com/login/oauth/authorize
oauth_token_url: https://github.com/login/oauth/access_token
client_id: 1ebc947823769bbe0532
client_secret: 13c04410a7e41bb76329929ca0ad8995afc8b887
authorized_admin:
- medcl
- name: filter
enabled: true
- name: queue
enabled: true
- name: boltdb
enabled: false
- name: index
enabled: true
ui:
enabled: true
site_name: Elastic Intelligence Agency
logo: https://static-www.elastic.co/v3/assets/bltefdd0b53724fa2ce/blt280217a63b82a734/5bbdaacf63ed239936a7dd56/elastic-logo.svg
favicon: https://www.elastic.co/favicon.ico
elasticsearch: default
- name: elastic
enabled: true
indexer_enabled: true
store_enabled: true
orm_enabled: true
elasticsearch: default
- name: stats
enabled: true
- name: boltdb
enabled: false
plugins:
- name: chrome
enabled: true
command: "/Applications/Google Chrome.app/Contents/MacOS/Google Chrome"
# command: "/usr/bin/google-chrome"
debug_port: 9223
- name: dispatch
enabled: true
failed_retry: false
new_task: true
update_task: false
max_concurrent_fetch_tasks: 50
fetch_size: 10
get_host_config_by_url: false