forked from lichess-org/lila
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbase.conf
722 lines (710 loc) · 14.2 KB
/
base.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
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
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
mongodb {
uri = "mongodb://127.0.0.1:27017/lichess"
mongo-async-driver = {}
image.collection = "image"
}
net {
domain = "localhost:9663"
socket.domain = ${net.domain}
asset.domain = ${net.domain}
protocol = "http://"
base_url = ${net.protocol}${net.domain}
ip = "127.0.0.1"
email = "[email protected]"
crawlable = false
ratelimit = true
}
play {
server {
netty {
# The maximum length of the initial line. This effectively restricts the maximum length of a URL that the server will
# accept, the initial line consists of the method (3-7 characters), the URL, and the HTTP version (8 characters),
# including typical whitespace, the maximum URL length will be this number - 18.
maxInitialLineLength = 2048 # 4096
# The maximum length of the HTTP headers. The most common effect of this is a restriction in cookie length, including
# number of cookies and size of cookie values.
maxHeaderSize = 4096 # 8192
}
}
http {
session {
cookieName = "lila2"
maxAge = 365 days
}
parser.maxMemoryBuffer=1MB
}
ws {
useragent = "lichess.org"
compressionEnabled = true
timeout {
connection = 5 seconds
idle = 5 minutes
request = 5 minutes
}
}
crypto {
secret="CiebwjgIM9cHQ;I?Xk:sfqDJ;BhIe:jsL?r=?IPF[saf>s^r0]?0grUq4>q?5mP^"
}
akka.actor-system = "lila"
}
app {
scheduler {
disabled = false
debug = false
}
renderer.name = "renderer"
web_path = "public"
forcedev = false
stage = false
}
api {
token = secret
influx_event = {
endpoint = "http://monitor.lichess.ovh:8086/write?db=events"
env = "dev"
}
}
chessground {
animation {
duration = 250 ms
}
}
editor {
animation.duration = ${chessground.animation.duration}
}
accessibility {
blind {
cookie {
name = "mBzamRgfXgRBSnXB"
salt = "WWcTbz5xxaHU4d96"
max_age = 31536000 # one year
}
}
}
prismic {
api_url = "https://lichess.cdn.prismic.io/api"
}
blog {
prismic {
api_url = ${prismic.api_url}
collection = blog
}
last_post_cache.ttl = 5 minutes
}
qa {
collection {
question = qa_question
answer = qa_answer
}
}
chat {
collection {
chat = chat
timeout = chat_timeout
}
max_lines = 200
net.domain = ${net.domain}
actor.name = chat
timeout {
duration = 15 minutes
check_every = 15 seconds
}
}
puzzle {
mongodb {
uri = "mongodb://127.0.0.1:27017/lichess"
mongo-async-driver = {}
}
collection {
puzzle = puzzle
round = puzzle_round2
vote = puzzle_vote
head = puzzle_head
}
api.token = ${api.token}
selector {
puzzle_id_min = 61053 # puzzle 61052 is bad
}
animation.duration = ${chessground.animation.duration}
}
coordinate {
collection {
score = coordinate_score
}
}
event {
collection {
event = event
}
}
video {
collection {
video = video
view = video_view
}
sheet {
url = "https://spreadsheets.google.com/feeds/list/1qYU1XhvC8TlBggXEkjI481ieNGyYGmMTy97A9iboyrM/2/public/values?alt=json"
delay = 3 hour
}
youtube {
url = "https://www.googleapis.com/youtube/v3/videos"
api_key = ""
max = 50
delay = 20 minutes
}
}
search {
enabled = false
writeable = true
endpoint = "http://localhost:9673"
}
team {
collection{
team = team
member = team_member
request = team_request
}
paginator.max_per_page = 15
paginator.max_user_per_page = 24
}
teamSearch {
index = team
paginator.max_per_page = ${team.paginator.max_per_page}
actor.name = team-search
}
relation {
collection {
relation = relation
}
actor {
name = relation
notify_freq = 2 seconds
}
limit {
follow = 300
block = 500
}
}
pref {
collection.pref = pref
cache.ttl = 10 minutes
}
bookmark {
collection.bookmark = bookmark
paginator.max_per_page = ${game.paginator.max_per_page}
actor.name = bookmark
}
analyse {
socket {
uid.ttl = ${site.socket.uid.ttl}
}
collection.analysis = analysis2
collection.requester = analysis_requester
net.domain = ${net.domain}
}
geoip {
file = "data/GeoLite2-City.mmdb"
cache_ttl = 20 minutes
}
security {
collection.security = security
flood.duration = 60 seconds
firewall {
enabled=true
cookie {
enabled = false
name=fEKHA4zI74ZrZrom
}
collection.firewall = firewall
}
geoip = ${geoip}
password_reset {
secret = "???"
}
email_confirm {
enabled = false
secret = "???"
cookie = "email_confirm"
}
email_change {
secret = "???"
}
login_token {
secret = "???"
}
tor {
provider_url = "https://check.torproject.org/cgi-bin/TorBulkExitList.py?ip="${net.ip}"&port=80"
refresh_delay = 1 hour
}
disposable_email {
provider_url = "https://raw.githubusercontent.com/ornicar/disposable/publish/domains.txt"
refresh_delay = 10 minutes
}
dns_api {
url = "https://dns-api.org"
timeout = 5 seconds
}
recaptcha = ${recaptcha}
mailgun = ${mailgun}
net {
domain = ${net.domain}
base_url = ${net.base_url}
}
ipintel.email = "-"
}
oauth {
mongodb {
uri = ${mongodb.uri}
mongo-async-driver = {}
}
collection {
access_token = oauth_access_token
app = oauth_client
}
base_url = ${net.protocol}oauth.${net.domain}/
}
recaptcha {
endpoint = "https://www.google.com/recaptcha/api/siteverify"
public_key = "6LcxLTUUAAAAAFwWrEgEehMJ6VXrtVOKIifTLGoW"
private_key = ""
enabled = false
}
shutup {
collection.shutup = shutup
actor.name = shutup
}
playban {
collection.playban = playban
}
perfStat {
collection.perf_stat = "perf_stat"
}
push {
collection.device = push_device
onesignal {
url = "https://onesignal.com/api/v1/notifications"
app_id = ""
key = ""
}
}
mod {
collection {
modlog = modlog
player_assessment = player_assessment
boosting = boosting
gaming_history = mod_gaming_history
}
boosting.nb_games_to_mark = 5
boosting.ratio_games_to_mark = 0.01
actor.name = mod
}
report {
collection.report = report2
actor.name = report
score.threshold = 50
net.domain = ${net.domain}
}
i18n {
web_path.relative = ${app.web_path}/trans
net.domain = ${net.domain}
}
detectlanguage.api {
url = "http://ws.detectlanguage.com/0.2/detect"
key = ""
}
mailgun {
api {
url = ""
key = ""
}
sender = "lichess.org <[email protected]>"
reply_to = "lichess.org <[email protected]>"
}
lobby {
socket {
uid.ttl = ${site.socket.uid.ttl}
}
net.domain = ${net.domain}
broom_period = 2 seconds
resync_ids_period = 25 seconds
collection.seek = seek
collection.seek_archive = seek_archive
seek {
max_per_page = 13
max_per_user = 5
}
max_playing = ${setup.max_playing}
}
timeline {
collection {
unsub = timeline_unsub
entry = timeline_entry
}
user {
display_max = 12
actor.name = user-timeline
}
}
game {
paginator.max_per_page = 12
collection {
game = game5
crosstable = crosstable2
matchup = matchup
}
captcher {
name = captcher
duration = 15 seconds
}
net.base_url = ${net.base_url}
uci_memo.ttl = 3 minutes
png {
url = "http://boardimage.lichess.ovh:8080/board.png"
size = 1024
}
}
tv {
featured {
select = 2789 millis
}
}
streamer {
collection.streamer = "streamer"
collection.image = ${mongodb.image.collection}
paginator.max_per_page = 12
streaming {
google.api_key = ""
keyword = "lichess.org"
twitch.client_id = ""
}
}
explorer {
endpoint = "https://explorer.lichess.ovh"
internal_endpoint = "http://explorer.lichess.ovh"
tablebase = {
endpoint = "https://tablebase.lichess.ovh"
}
}
gameSearch {
index = game
paginator.max_per_page = 12
actor.name = game-search
}
round {
active.ttl = 40 seconds
uid.timeout = 10 seconds
animation.duration = ${chessground.animation.duration}
moretime = 15 seconds
player {
disconnect.timeout = 120 seconds
ragequit.timeout = 10 seconds
}
socket {
timeout = 30 seconds
}
collection {
note = game_note
history = round_history
forecast = forecast
alarm = round_alarm
}
net.domain = ${net.domain}
}
tournament {
collection {
tournament = tournament2
player = tournament_player
pairing = tournament_pairing
leaderboard = tournament_leaderboard
}
history.message.ttl = 20 seconds
uid.timeout = 7 seconds # small to avoid missed events
socket {
name = tournament-socket
timeout = 1 minute
}
api_actor.name = tournament-api
sequencer {
timeout = 10 minutes
}
pairing.delay = 3.1 seconds
created.cache.ttl = 2 seconds
leaderboard.cache.ttl = 1 hour
ranking.cache.ttl = 1 hour
net.domain = ${net.domain}
}
simul {
collection {
simul = simul
}
sequencer {
timeout = 10 minutes
}
socket {
timeout = 2 minutes
}
created.cache.ttl = 2 seconds
history.message.ttl = 20 seconds
uid.timeout = 7 seconds # small to avoid missed events
}
forum {
topic.max_per_page = 10
post.max_per_page = 10
recent {
ttl = 1 hour
nb = 20
}
collection {
categ = f_categ
topic = f_topic
post = f_post
}
public_categ_ids = [
general-chess-discussion
game-analysis
lichess-feedback
off-topic-discussion
]
}
forumSearch {
index = forum
paginator.max_per_page = 10
actor.name = forum-search
}
message {
thread.max_per_page = 30
collection.thread = m_thread
}
coach {
collection.coach = coach
collection.review = coach_review
collection.image = ${mongodb.image.collection}
}
memo {
collection {
cache = cache
config = flag
}
}
practice {
collection {
progress = practice_progress
}
}
setup {
collection {
user_config = config
anon_config = config_anon
}
max_playing = 200
}
challenge {
collection.challenge = challenge
max_per_user = 20
socket {
timeout = 1 minute
}
history.message.ttl = 30 seconds
uid.timeout = 7 seconds
max_playing = ${setup.max_playing}
}
evalCache {
collection.eval_cache = eval_cache
}
irwin {
collection.report = irwin_report
collection.request = irwin_request
}
relay {
collection.relay = relay
paginator.max_per_page = 20
}
activity {
collection.activity = activity
}
study {
collection.study = study
collection.chapter = study_chapter
socket {
timeout = 1 minute
}
sequencer {
timeout = 10 minutes
}
history.message.ttl = 20 seconds
uid.timeout = 10 seconds
net.domain = ${net.domain}
net.base_url = ${net.base_url}
paginator.max_per_page = 14
}
studySearch {
index = study
paginator.max_per_page = ${study.paginator.max_per_page}
}
site {
socket {
uid.ttl = 10 seconds
}
}
user {
paginator.max_per_page = 40
cached.nb.ttl = 10 minutes
online.ttl = 7 seconds
collection {
user = user4
note = note
trophy = trophy
ranking = ranking
}
password.bpass {
secret = "9qEYN0ThHer1KWLNekA76Q=="
}
}
history {
collection.history = history3
cached.rating_chart.ttl = 1 hour
}
fishnet {
collection {
analysis = fishnet_analysis
client = fishnet_client
}
offline_mode = true # any client can provide moves and analysis
actor.name = fishnet
analysis.nodes = 4000000
move.plies = 300
client_min_version = "1.15.10"
}
application {
global="lila.app.Global"
}
importer {
delay = 50 milliseconds
}
insight {
mongodb {
uri = "mongodb://127.0.0.1:27017/lichess-insight"
mongo-async-driver = {}
}
collection {
entry = insight
user_cache = insight_user_cache
}
}
notify {
collection.notify = notify
actor.name = notify
}
learn {
collection.progress = learn_progress
}
simulation {
enabled = false
players = 300
watchers = 200
}
slack {
incoming {
url = ""
default_channel = tavern
}
domain = ${net.domain}
}
plan {
stripe {
endpoint="https://api.stripe.com/v1"
keys {
public="pk_test_31E5TIuGtMs4ojhzMIMu8oIc"
secret="sk_test_erAQMvv5cF90WXUFlkv7Tke0"
}
}
paypal {
ipn_key=""
}
collection {
patron = plan_patron
charge = plan_charge
}
monthly_goal = 8072 # https://lichess.org/costs
}
hub {
actor {
game {
search = ${gameSearch.actor.name}
}
renderer = ${app.renderer.name}
captcher = ${game.captcher.name}
forum {
search = ${forumSearch.actor.name}
}
team.search = ${teamSearch.actor.name}
fishnet = ${fishnet.actor.name}
tournament.api = ${tournament.api_actor.name}
timeline {
user = ${timeline.user.actor.name}
}
bookmark = ${bookmark.actor.name}
relation = ${relation.actor.name}
report = ${report.actor.name}
shutup = ${shutup.actor.name}
mod = ${mod.actor.name}
chat = ${chat.actor.name}
notify = ${notify.actor.name}
}
}
dbplugin = disabled
ehcacheplugin = disabled
akka {
loggers = ["akka.event.slf4j.Slf4jLogger"]
loglevel = INFO
stdout-loglevel = INFO
log-config-on-start = off
log-dead-letters-during-shutdown = off
}
kamon {
metric {
tick-interval = 20 second
track-unmatched-entities = yes
filters {
trace {
includes = [ "**" ]
excludes = [ ]
}
}
}
influxdb {
hostname = "127.0.0.1"
port = 8086
# The maximum packet size for one POST request, set to 0 to disable batching
max-packet-size = 16384
# The protocol, either http or udp
protocol = "udp"
# The measurements will be named ${application-name}-timers and -counters
application-name = "dev"
# Allow users to override the name of the hostname reported by kamon. When changed, the hostname tag will be
# the value given here.
hostname-override = none
# For histograms, which percentiles to count
percentiles = [25.0, 50.0, 75.0, 95.0, 99.0]
# Subscription patterns used to select which metrics will be pushed to InfluxDB. Note that first, metrics
# collection for your desired entities must be activated under the kamon.metrics.filters settings.
subscriptions {
histogram = [ "**" ]
min-max-counter = [ "**" ]
gauge = [ "**" ]
counter = [ "**" ]
trace = [ "**" ]
trace-segment = [ "**" ]
akka-actor = [ "**" ]
akka-dispatcher = [ "**" ]
akka-router = [ "**" ]
system-metric = [ "**" ]
http-server = [ "**" ]
}
}
modules {
kamon-influxdb {
auto-start = no
}
}
}