Skip to content

Commit

Permalink
Move logging to stderr
Browse files Browse the repository at this point in the history
  • Loading branch information
marcofranssen committed Feb 21, 2022
1 parent 1ae8ad7 commit b687dba
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cmd/spiffe-vault/cli/auth.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import (
"context"
"flag"
"fmt"
"os"
"time"

"github.com/peterbourgon/ff/v3/ffcli"
Expand Down Expand Up @@ -49,9 +50,8 @@ func Auth() *ffcli.Command {
if err != nil {
return err
}

fmt.Println("# Export following environment variable to authenticate to Hashicorp Vault")
fmt.Printf("export VAULT_TOKEN=%s\n", c.Token())
fmt.Fprintln(os.Stderr, "# Export following environment variable to authenticate to Hashicorp Vault")
fmt.Fprintf(os.Stdout, "export VAULT_TOKEN=%s\n", c.Token())

return nil
},
Expand Down

0 comments on commit b687dba

Please sign in to comment.