add forgejo access logs and geo ip enrichment
This commit is contained in:
parent
59db3b2fb7
commit
44e3bd6729
3 changed files with 20 additions and 1 deletions
|
@ -122,7 +122,7 @@ services:
|
||||||
- BAUTH_PASS=test
|
- BAUTH_PASS=test
|
||||||
|
|
||||||
fluentd:
|
fluentd:
|
||||||
image: git.kun.is/pim/fluentd:1.0.2
|
image: git.kun.is/pim/fluentd:1.0.3
|
||||||
depends_on:
|
depends_on:
|
||||||
- elasticsearch
|
- elasticsearch
|
||||||
ports:
|
ports:
|
||||||
|
|
|
@ -25,3 +25,11 @@ datasources:
|
||||||
jsonData:
|
jsonData:
|
||||||
index: 'fluentd.diskfree-*'
|
index: 'fluentd.diskfree-*'
|
||||||
timeField: '@timestamp'
|
timeField: '@timestamp'
|
||||||
|
|
||||||
|
- name: forgejo_access
|
||||||
|
type: elasticsearch
|
||||||
|
access: proxy
|
||||||
|
url: http://maestro.dmz:{{ elasticsearch_port }}
|
||||||
|
jsonData:
|
||||||
|
index: 'fluentd.docker.forgejo_forgejo.**'
|
||||||
|
timeField: '@timestamp'
|
||||||
|
|
|
@ -6,6 +6,17 @@
|
||||||
port {{ fluent_forward_port }}
|
port {{ fluent_forward_port }}
|
||||||
</source>
|
</source>
|
||||||
|
|
||||||
|
<filter docker.forgejo_forgejo.**>
|
||||||
|
@type geoip
|
||||||
|
geoip_lookup_keys host
|
||||||
|
backend_library geoip2_c
|
||||||
|
<record>
|
||||||
|
latitude ${location.latitude["host"]}
|
||||||
|
longitude ${location.longitude["host"]}
|
||||||
|
</record>
|
||||||
|
skip_adding_null_record true
|
||||||
|
</filter>
|
||||||
|
|
||||||
<match cpu memory diskfree docker.forgejo_forgejo.**>
|
<match cpu memory diskfree docker.forgejo_forgejo.**>
|
||||||
@type elasticsearch
|
@type elasticsearch
|
||||||
host maestro.dmz
|
host maestro.dmz
|
||||||
|
|
Reference in a new issue