collect traefik access logs
don't collect forgejo access logs
This commit is contained in:
parent
43145f8148
commit
c4ecfa437d
3 changed files with 14 additions and 5 deletions
|
@ -129,14 +129,15 @@
|
|||
{% if 'swarm' in group_names %}
|
||||
[FILTER]
|
||||
Name parser
|
||||
Match docker.forgejo_forgejo.**
|
||||
Match docker.traefik_traefik.**
|
||||
Key_Name log
|
||||
Parser combinedlog
|
||||
Parser traefiklog
|
||||
|
||||
[FILTER]
|
||||
Name grep
|
||||
Match docker.forgejo_forgejo.**
|
||||
Regex host .*
|
||||
Name rewrite_tag
|
||||
Match docker.traefik_traefik.**
|
||||
Rule $host .* access.traefik false
|
||||
Emitter_Name traefik_access_emitter
|
||||
{% endif %}
|
||||
|
||||
[FILTER]
|
||||
|
|
|
@ -18,3 +18,11 @@
|
|||
Types host:string ident:string authuser:string request:string status:integer size:integer referer:string useragent:string
|
||||
Time_Key date
|
||||
Time_Format %d/%b/%Y:%H:%M:%S %z
|
||||
|
||||
[PARSER]
|
||||
Name traefiklog
|
||||
Format regex
|
||||
Regex ^(?<host>\S+) (?<ident>\S+) (?<authuser>\S+) \[(?<date>[^\]]+)\] "(?<request>\S+ .+ HTTP\/\d\.\d)" (?<status>\S+) (?<size>\S+) "(?<referer>[^"]*)" "(?<useragent>[^"]*)" (?<requests>\d+) "(?<router>\S+)" "(?<serverurl>\S+)" (?<duration>\d+)ms
|
||||
Types host:string ident:string authuser:string request:string status:integer size:integer referer:string useragent:string requests:integer router:string serverurl:string duration:integer
|
||||
Time_Key date
|
||||
Time_Format %d/%b/%Y:%H:%M:%S %z
|
||||
|
|
Reference in a new issue