simplify logging

This commit is contained in:
Greg T. Wallace 2024-02-03 11:38:31 -05:00
parent 2c4e3df0a5
commit 201aedce1c
8 changed files with 36 additions and 93 deletions

View file

@ -67,8 +67,8 @@ func (app *app) cmdInstall(cmdCtx context.Context, args []string) error {
// log fingerprint for debugging
actualHashB64 := base64.RawStdEncoding.EncodeToString(actualHash)
actualHashHex := hex.EncodeToString(actualHash)
app.logger.Debugf("ssh: remote server key fingerprint (b64): %s", actualHashB64)
app.logger.Debugf("ssh: remote server key fingerprint (hex): %s", actualHashHex)
app.debugLogger.Printf("ssh: remote server key fingerprint (b64): %s", actualHashB64)
app.debugLogger.Printf("ssh: remote server key fingerprint (hex): %s", actualHashHex)
// allow base64 format
if actualHashB64 == *app.config.install.fingerprint {
@ -120,7 +120,7 @@ func (app *app) cmdInstall(cmdCtx context.Context, args []string) error {
}
// done
app.logger.Infof("install: apc p15 file installed on %s", *app.config.install.hostAndPort)
app.stdLogger.Printf("install: apc p15 file installed on %s", *app.config.install.hostAndPort)
return nil
}