mirror of
https://github.com/Control-D-Inc/ctrld.git
synced 2026-02-03 22:18:39 +00:00
cmd/cli: handle ipc warning message more precisely
If the socket file does not exist, it means that "ctrld start" was never run. In this case, the warning message should not be printed to avoid needless confusion.
This commit is contained in:
committed by
Cuong Manh Le
parent
24910f1fa6
commit
7dfb77228f
@@ -227,7 +227,9 @@ func run(appCallback *AppCallback, stopCh chan struct{}) {
|
||||
consoleWriter.Out = io.MultiWriter(os.Stdout, lc)
|
||||
p.logConn = lc
|
||||
} else {
|
||||
mainLog.Load().Warn().Err(err).Msgf("unable to create log ipc connection")
|
||||
if !errors.Is(err, os.ErrNotExist) {
|
||||
mainLog.Load().Warn().Err(err).Msg("unable to create log ipc connection")
|
||||
}
|
||||
}
|
||||
} else {
|
||||
mainLog.Load().Warn().Err(err).Msgf("unable to resolve socket address: %s", sockPath)
|
||||
|
||||
Reference in New Issue
Block a user