Skip to content

Commit 14564f9

Browse files
committed
nit: remove double validation on folder when register flag
Signed-off-by: SamYuan1990 <[email protected]>
1 parent 63fc7f6 commit 14564f9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

config/config.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -237,8 +237,8 @@ func RegisterFlags(app *kingpin.Application) ConfigUpdaterFn {
237237
logLevel := app.Flag(LogLevelFlag, "Logging level: debug, info, warn, error").Default("info").Enum("debug", "info", "warn", "error")
238238
logFormat := app.Flag(LogFormatFlag, "Logging format: text or json").Default("text").Enum("text", "json")
239239
// host
240-
hostSysFS := app.Flag(HostSysFSFlag, "Host sysfs path").Default("/sys").ExistingDir()
241-
hostProcFS := app.Flag(HostProcFSFlag, "Host procfs path").Default("/proc").ExistingDir()
240+
hostSysFS := app.Flag(HostSysFSFlag, "Host sysfs path").Default("/sys").String()
241+
hostProcFS := app.Flag(HostProcFSFlag, "Host procfs path").Default("/proc").String()
242242

243243
// monitor
244244
monitorInterval := app.Flag(MonitorIntervalFlag,

0 commit comments

Comments
 (0)