Provide nomad.Config with a default LogOutput of os.StdErr

This commit is contained in:
Sean Chittenden
2016-06-17 06:44:10 -07:00
parent bcf0929c95
commit 451c685f1c
4 changed files with 6 additions and 17 deletions

View File

@@ -5,7 +5,6 @@ import (
"io"
"log"
"net"
"os"
"path/filepath"
"runtime"
"strconv"
@@ -61,11 +60,6 @@ type Agent struct {
// NewAgent is used to create a new agent with the given configuration
func NewAgent(config *Config, logOutput io.Writer) (*Agent, error) {
// Ensure we have a log sink
if logOutput == nil {
logOutput = os.Stderr
}
a := &Agent{
config: config,
logger: log.New(logOutput, "", log.LstdFlags),