File tree Expand file tree Collapse file tree 3 files changed +11
-7
lines changed Expand file tree Collapse file tree 3 files changed +11
-7
lines changed Original file line number Diff line number Diff line change @@ -81,10 +81,12 @@ func initEcho() {
81
81
uri = re .ReplaceAllString (v .URI , `apikey=**REDACTED**` )
82
82
}
83
83
84
- logger .Info ().
85
- Str ("URI" , uri ).
86
- Int ("status" , v .Status ).
87
- Msg ("request" )
84
+ if configuration .Api .StatusLogEnabled || ! strings .Contains (v .URI , "/status" ) {
85
+ logger .Info ().
86
+ Str ("URI" , uri ).
87
+ Int ("status" , v .Status ).
88
+ Msg ("request" )
89
+ }
88
90
89
91
return nil
90
92
},
Original file line number Diff line number Diff line change 3
3
ttl : 300
4
4
api :
5
5
port : 9595
6
- hideApiKeyInLogs : true
6
+ hideApiKeyInLogs : true
7
+ enableStatusLog : false
Original file line number Diff line number Diff line change @@ -16,8 +16,9 @@ type Config struct {
16
16
} `yaml:"gandi"`
17
17
18
18
Api struct {
19
- Port string `yaml:"port"`
20
- ApiKeyHidden bool `yaml:"hideApiKeyInLogs"`
19
+ Port string `yaml:"port"`
20
+ ApiKeyHidden bool `yaml:"hideApiKeyInLogs"`
21
+ StatusLogEnabled bool `yaml:"enableStatusLog"`
21
22
} `yaml:"api"`
22
23
}
23
24
You can’t perform that action at this time.
0 commit comments