Remove Info.Print in favour of Log.Info
This commit is contained in:
1 parent
013380c7e7
commit
a5ddb63fca
22 files changed
+60
-61
No files matched your search
@@ -36,7 +36,7 @@ func NewClient(apiPath string) (*Client, error) {
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
Info.Printf("[docker] Using Docker API on %s: %v", apiPath, env)
|
||||
Log.Infof("[docker] Using Docker API on %s: %v", apiPath, env)
|
||||
return client, nil
|
||||
}
|
||||
|
||||
|
||||
+4
-6
@@ -38,21 +38,19 @@ var (
|
||||
)
|
||||
|
||||
var (
|
||||
Log *logrus.Logger
|
||||
Info *logrus.Logger
|
||||
Log *logrus.Logger
|
||||
)
|
||||
|
||||
func InitLogging(level logrus.Level) {
|
||||
if Info == nil {
|
||||
Info = &logrus.Logger{
|
||||
if Log == nil {
|
||||
Log = &logrus.Logger{
|
||||
Out: os.Stderr,
|
||||
Formatter: standardTextFormatter,
|
||||
Hooks: make(logrus.LevelHooks),
|
||||
Level: level,
|
||||
}
|
||||
Log = Info
|
||||
}
|
||||
Info.Level = level
|
||||
Log.Level = level
|
||||
}
|
||||
|
||||
func InitDefaultLogging(debug bool) {
|
||||
|
||||
@@ -11,7 +11,7 @@ import (
|
||||
// Ensure we can add new calls while forwarding the clock
|
||||
func TestSchedCallsBasic(t *testing.T) {
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestSchedCallsBasic starting")
|
||||
Log.Infoln("TestSchedCallsBasic starting")
|
||||
|
||||
const testSecs = 1000
|
||||
clk := clock.NewMock()
|
||||
@@ -37,7 +37,7 @@ func TestSchedCallsBasic(t *testing.T) {
|
||||
// Ensure we can create a 100 seconds gap in the middle of the time travel
|
||||
func TestSchedCallsGap(t *testing.T) {
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestSchedCallsGap starting")
|
||||
Log.Infoln("TestSchedCallsGap starting")
|
||||
|
||||
const testSecs = 1000
|
||||
clk := clock.NewMock()
|
||||
@@ -65,7 +65,7 @@ func TestSchedCallsGap(t *testing.T) {
|
||||
|
||||
func TestSchedCallsStop(t *testing.T) {
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestSchedCallsStop starting")
|
||||
Log.Infoln("TestSchedCallsStop starting")
|
||||
|
||||
const testSecs = 1000
|
||||
clk := clock.NewMock()
|
||||
|
||||
+3
-3
@@ -20,17 +20,17 @@ func SignalHandlerLoop(ss ...SignalReceiver) {
|
||||
for {
|
||||
switch <-sigs {
|
||||
case syscall.SIGINT:
|
||||
Info.Printf("=== received SIGINT ===\n*** exiting\n")
|
||||
Log.Infof("=== received SIGINT ===\n*** exiting\n")
|
||||
for _, subsystem := range ss {
|
||||
subsystem.Stop()
|
||||
}
|
||||
return
|
||||
case syscall.SIGQUIT:
|
||||
stacklen := runtime.Stack(buf, true)
|
||||
Info.Printf("=== received SIGQUIT ===\n*** goroutine dump...\n%s\n*** end\n", buf[:stacklen])
|
||||
Log.Infof("=== received SIGQUIT ===\n*** goroutine dump...\n%s\n*** end\n", buf[:stacklen])
|
||||
case syscall.SIGUSR1:
|
||||
for _, subsystem := range ss {
|
||||
Info.Printf("=== received SIGUSR1 ===\n*** status...\n%s\n*** end\n", subsystem.Status())
|
||||
Log.Infof("=== received SIGUSR1 ===\n*** status...\n%s\n*** end\n", subsystem.Status())
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -343,14 +343,14 @@ func TestAllocatorFuzz(t *testing.T) {
|
||||
|
||||
allocIndex := rand.Int31n(nodes)
|
||||
alloc := allocs[allocIndex]
|
||||
//common.Info.Printf("Allocate: asking allocator %d", allocIndex)
|
||||
//common.Log.Infof("Allocate: asking allocator %d", allocIndex)
|
||||
addr, err := alloc.Allocate(name, subnet, nil)
|
||||
|
||||
if err != nil {
|
||||
panic(fmt.Sprintf("Could not allocate addr"))
|
||||
}
|
||||
|
||||
//common.Info.Printf("Allocate: got address %s for name %s", addr, name)
|
||||
//common.Log.Infof("Allocate: got address %s for name %s", addr, name)
|
||||
addrStr := addr.String()
|
||||
|
||||
stateLock.Lock()
|
||||
@@ -387,7 +387,7 @@ func TestAllocatorFuzz(t *testing.T) {
|
||||
stateLock.Unlock()
|
||||
|
||||
alloc := allocs[res.alloc]
|
||||
//common.Info.Printf("Freeing %s (%s) on allocator %d", res.name, addr, res.alloc)
|
||||
//common.Log.Infof("Freeing %s (%s) on allocator %d", res.name, addr, res.alloc)
|
||||
|
||||
oldAddr, err := address.ParseIP(addr)
|
||||
if err != nil {
|
||||
@@ -412,7 +412,7 @@ func TestAllocatorFuzz(t *testing.T) {
|
||||
stateLock.Unlock()
|
||||
alloc := allocs[res.alloc]
|
||||
|
||||
//common.Info.Printf("Asking for %s (%s) on allocator %d again", res.name, addr, res.alloc)
|
||||
//common.Log.Infof("Asking for %s (%s) on allocator %d again", res.name, addr, res.alloc)
|
||||
|
||||
newAddr, _ := alloc.Allocate(res.name, subnet, nil)
|
||||
oldAddr, _ := address.ParseIP(addr)
|
||||
|
||||
+2
-2
@@ -79,7 +79,7 @@ func (alloc *Allocator) HandleHTTP(router *mux.Router, defaultSubnet address.CID
|
||||
return
|
||||
}
|
||||
if dockerCli != nil && dockerCli.IsContainerNotRunning(ident) {
|
||||
common.Info.Printf("[allocator] '%s' is not running: freeing %s", ident, addr)
|
||||
common.Log.Infof("[allocator] '%s' is not running: freeing %s", ident, addr)
|
||||
alloc.Free(ident, addr)
|
||||
return
|
||||
}
|
||||
@@ -96,7 +96,7 @@ func (alloc *Allocator) HandleHTTP(router *mux.Router, defaultSubnet address.CID
|
||||
return
|
||||
}
|
||||
if dockerCli != nil && dockerCli.IsContainerNotRunning(ident) {
|
||||
common.Info.Printf("[allocator] '%s' is not running: freeing %s", ident, newAddr)
|
||||
common.Log.Infof("[allocator] '%s' is not running: freeing %s", ident, newAddr)
|
||||
alloc.Free(ident, newAddr)
|
||||
return
|
||||
}
|
||||
|
||||
@@ -10,7 +10,7 @@ import (
|
||||
|
||||
func TestAddrs(t *testing.T) {
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestAddrs starting")
|
||||
Log.Infoln("TestAddrs starting")
|
||||
|
||||
ip, err := addrToIPv4("10.13.12.11")
|
||||
require.NoError(t, err)
|
||||
|
||||
@@ -15,7 +15,7 @@ import (
|
||||
// Check that the cache keeps its intended capacity constant
|
||||
func TestCacheLength(t *testing.T) {
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestCacheLength starting")
|
||||
Log.Infoln("TestCacheLength starting")
|
||||
|
||||
const cacheLen = 128
|
||||
|
||||
@@ -56,9 +56,9 @@ func TestCacheLength(t *testing.T) {
|
||||
// Check that the cache entries are ok
|
||||
func TestCacheEntries(t *testing.T) {
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestCacheEntries starting")
|
||||
Log.Infoln("TestCacheEntries starting")
|
||||
|
||||
Info.Println("Checking cache consistency")
|
||||
Log.Infoln("Checking cache consistency")
|
||||
|
||||
const cacheLen = 128
|
||||
clk := clock.NewMock()
|
||||
|
||||
@@ -12,7 +12,7 @@ import (
|
||||
// Check that we can prune an answer
|
||||
func TestPrune(t *testing.T) {
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestPrune starting")
|
||||
Log.Infoln("TestPrune starting")
|
||||
|
||||
questionMsg := new(dns.Msg)
|
||||
questionMsg.SetQuestion("name", dns.TypeA)
|
||||
|
||||
+6
-6
@@ -61,10 +61,10 @@ func ServeHTTP(listener net.Listener, version string, server *DNSServer, dockerC
|
||||
|
||||
domain := server.Zone.Domain()
|
||||
if !dns.IsSubDomain(domain, name) {
|
||||
Info.Printf("[http] Ignoring name %s, not in %s", name, domain)
|
||||
Log.Infof("[http] Ignoring name %s, not in %s", name, domain)
|
||||
return
|
||||
}
|
||||
Info.Printf("[http] Adding %s -> %s", name, ipStr)
|
||||
Log.Infof("[http] Adding %s -> %s", name, ipStr)
|
||||
if err := server.Zone.AddRecord(idStr, name, ip); err != nil {
|
||||
if _, ok := err.(DuplicateError); !ok {
|
||||
httpErrorAndLog(
|
||||
@@ -75,7 +75,7 @@ func ServeHTTP(listener net.Listener, version string, server *DNSServer, dockerC
|
||||
}
|
||||
|
||||
if dockerCli != nil && dockerCli.IsContainerNotRunning(idStr) {
|
||||
Info.Printf("[http] '%s' is not running: removing", idStr)
|
||||
Log.Infof("[http] '%s' is not running: removing", idStr)
|
||||
server.Zone.DeleteRecords(idStr, name, ip)
|
||||
}
|
||||
})
|
||||
@@ -95,7 +95,7 @@ func ServeHTTP(listener net.Listener, version string, server *DNSServer, dockerC
|
||||
|
||||
fqdnStr, fqdn := extractFQDN(r)
|
||||
|
||||
Info.Printf("[http] Deleting ID %s, IP %s, FQDN %s", idStr, ipStr, fqdnStr)
|
||||
Log.Infof("[http] Deleting ID %s, IP %s, FQDN %s", idStr, ipStr, fqdnStr)
|
||||
server.Zone.DeleteRecords(idStr, fqdn, ip)
|
||||
})
|
||||
|
||||
@@ -105,14 +105,14 @@ func ServeHTTP(listener net.Listener, version string, server *DNSServer, dockerC
|
||||
|
||||
fqdnStr, fqdn := extractFQDN(r)
|
||||
|
||||
Info.Printf("[http] Deleting ID %s, IP *, FQDN %s", idStr, fqdnStr)
|
||||
Log.Infof("[http] Deleting ID %s, IP *, FQDN %s", idStr, fqdnStr)
|
||||
server.Zone.DeleteRecords(idStr, fqdn, net.IP{})
|
||||
})
|
||||
|
||||
muxRouter.Methods("DELETE").Path("/name").HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
|
||||
fqdnStr, fqdn := extractFQDN(r)
|
||||
|
||||
Info.Printf("[http] Deleting ID *, IP *, FQDN %s", fqdnStr)
|
||||
Log.Infof("[http] Deleting ID *, IP *, FQDN %s", fqdnStr)
|
||||
server.Zone.DeleteRecords("", fqdn, net.IP{})
|
||||
})
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ func TestServerSimpleQuery(t *testing.T) {
|
||||
)
|
||||
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestServerSimpleQuery starting")
|
||||
Log.Infoln("TestServerSimpleQuery starting")
|
||||
|
||||
mzone := newMockedZoneWithRecords([]ZoneRecord{testRecord1, testRecord2})
|
||||
mdnsServer, err := NewMDNSServer(mzone, true, DefaultLocalTTL)
|
||||
|
||||
@@ -188,11 +188,11 @@ func NewDNSServer(config DNSServerConfig) (s *DNSServer, err error) {
|
||||
|
||||
// Start the DNS server
|
||||
func (s *DNSServer) Start() error {
|
||||
Info.Printf("[dns] Upstream server(s): %+v", s.Upstream)
|
||||
Log.Infof("[dns] Upstream server(s): %+v", s.Upstream)
|
||||
if s.cacheDisabled {
|
||||
Info.Printf("[dns] Cache: disabled")
|
||||
Log.Infof("[dns] Cache: disabled")
|
||||
} else {
|
||||
Info.Printf("[dns] Cache: %d entries", s.cache.Capacity())
|
||||
Log.Infof("[dns] Cache: %d entries", s.cache.Capacity())
|
||||
}
|
||||
|
||||
pc, err := net.ListenPacket("udp", s.ListenAddr)
|
||||
@@ -225,7 +225,7 @@ func (s *DNSServer) ActivateAndServe() {
|
||||
go func() {
|
||||
defer s.listenersWg.Done()
|
||||
|
||||
Info.Printf("[dns] Listening for DNS on %s (UDP)", s.ListenAddr)
|
||||
Log.Infof("[dns] Listening for DNS on %s (UDP)", s.ListenAddr)
|
||||
err := s.udpSrv.ActivateAndServe()
|
||||
CheckFatal(err)
|
||||
Log.Debugf("[dns] DNS UDP server exiting...")
|
||||
@@ -234,7 +234,7 @@ func (s *DNSServer) ActivateAndServe() {
|
||||
go func() {
|
||||
defer s.listenersWg.Done()
|
||||
|
||||
Info.Printf("[dns] Listening for DNS on %s (TCP)", s.ListenAddr)
|
||||
Log.Infof("[dns] Listening for DNS on %s (TCP)", s.ListenAddr)
|
||||
err := s.tcpSrv.ActivateAndServe()
|
||||
CheckFatal(err)
|
||||
Log.Debugf("[dns] DNS TCP server exiting...")
|
||||
@@ -243,7 +243,7 @@ func (s *DNSServer) ActivateAndServe() {
|
||||
// Waiting for all goroutines to finish (otherwise they die as main routine dies)
|
||||
s.listenersWg.Wait()
|
||||
|
||||
Info.Printf("[dns] Server exiting...")
|
||||
Log.Infof("[dns] Server exiting...")
|
||||
}
|
||||
|
||||
// Return status string
|
||||
@@ -284,7 +284,7 @@ func (s *DNSServer) createMux(proto dnsProtocol) *dns.ServeMux {
|
||||
}
|
||||
notUsHandler := s.notUsHandler(proto)
|
||||
notUsFallback := func(w dns.ResponseWriter, r *dns.Msg) {
|
||||
Info.Printf("[dns msgid %d] -> sending to fallback server", r.MsgHdr.Id)
|
||||
Log.Infof("[dns msgid %d] -> sending to fallback server", r.MsgHdr.Id)
|
||||
notUsHandler(w, r)
|
||||
}
|
||||
|
||||
@@ -351,8 +351,9 @@ func (s *DNSServer) localHandler(proto dnsProtocol, kind string, qtype uint16,
|
||||
}
|
||||
|
||||
if answers, err := lookup(q.Name); err != nil {
|
||||
Info.Printf("[dns msgid %d] No results for type %s query for '%s' [caching no-local]",
|
||||
Log.Infof("[dns msgid %d] No results for type %s query for '%s' [caching no-local]",
|
||||
r.MsgHdr.Id, dns.TypeToString[q.Qtype], q.Name)
|
||||
|
||||
maybeCache(nil, s.negLocalTTL, CacheNoLocalReplies)
|
||||
fallback(w, r)
|
||||
} else {
|
||||
|
||||
@@ -20,7 +20,7 @@ func TestServerDbCacheInvalidation(t *testing.T) {
|
||||
)
|
||||
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestServerDbCacheInvalidation starting")
|
||||
Log.Infoln("TestServerDbCacheInvalidation starting")
|
||||
|
||||
clk := newMockedClock()
|
||||
|
||||
@@ -178,7 +178,7 @@ func TestServerCacheExpiration(t *testing.T) {
|
||||
)
|
||||
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestServerCacheExpiration starting")
|
||||
Log.Infoln("TestServerCacheExpiration starting")
|
||||
|
||||
clk := newMockedClock()
|
||||
|
||||
@@ -266,7 +266,7 @@ func TestServerCacheRefresh(t *testing.T) {
|
||||
)
|
||||
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestServerCacheRefresh starting")
|
||||
Log.Infoln("TestServerCacheRefresh starting")
|
||||
clk := newMockedClock()
|
||||
|
||||
Log.Debugf("Creating 2 zone databases")
|
||||
|
||||
@@ -41,7 +41,7 @@ func TestUDPDNSServer(t *testing.T) {
|
||||
testCIDR1 := testAddr1 + "/24"
|
||||
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestUDPDNSServer starting")
|
||||
Log.Infoln("TestUDPDNSServer starting")
|
||||
|
||||
zone, err := NewZoneDb(ZoneConfig{})
|
||||
require.NoError(t, err)
|
||||
@@ -138,7 +138,7 @@ func TestTCPDNSServer(t *testing.T) {
|
||||
)
|
||||
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestTCPDNSServer starting")
|
||||
Log.Infoln("TestTCPDNSServer starting")
|
||||
|
||||
zone, err := NewZoneDb(ZoneConfig{})
|
||||
require.NoError(t, err)
|
||||
|
||||
+3
-3
@@ -506,9 +506,9 @@ func NewZoneDb(config ZoneConfig) (zone *ZoneDb, err error) {
|
||||
// Start the zone database
|
||||
func (zone *ZoneDb) Start() (err error) {
|
||||
if zone.iface != nil {
|
||||
Info.Printf("[zonedb] Using mDNS on %+v", zone.iface)
|
||||
Log.Infof("[zonedb] Using mDNS on %+v", zone.iface)
|
||||
} else {
|
||||
Info.Printf("[zonedb] Using mDNS on all interfaces")
|
||||
Log.Infof("[zonedb] Using mDNS on all interfaces")
|
||||
}
|
||||
|
||||
if err = zone.mdnsCli.Start(zone.iface); err != nil {
|
||||
@@ -638,7 +638,7 @@ func (zone *ZoneDb) String() string {
|
||||
|
||||
// Notify that a container has died
|
||||
func (zone *ZoneDb) ContainerDied(ident string) error {
|
||||
Info.Printf("[zonedb] Container %s down. Removing records", ident)
|
||||
Log.Infof("[zonedb] Container %s down. Removing records", ident)
|
||||
zone.DeleteRecords(ident, "", net.IP{})
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -24,7 +24,7 @@ func TestZoneRefresh(t *testing.T) {
|
||||
)
|
||||
|
||||
InitDefaultLogging(testing.Verbose())
|
||||
Info.Println("TestZoneRefresh starting")
|
||||
Log.Infoln("TestZoneRefresh starting")
|
||||
|
||||
clk := newMockedClock()
|
||||
|
||||
|
||||
@@ -71,17 +71,17 @@ func main() {
|
||||
}
|
||||
|
||||
InitDefaultLogging(debug)
|
||||
Info.Printf("[main] WeaveDNS version %s\n", version) // first thing in log: the version
|
||||
Log.Infof("[main] WeaveDNS version %s\n", version) // first thing in log: the version
|
||||
|
||||
var iface *net.Interface
|
||||
if ifaceName != "" {
|
||||
var err error
|
||||
Info.Println("[main] Waiting for mDNS interface", ifaceName, "to come up")
|
||||
Log.Infoln("[main] Waiting for mDNS interface", ifaceName, "to come up")
|
||||
iface, err = weavenet.EnsureInterface(ifaceName, wait)
|
||||
if err != nil {
|
||||
Log.Fatal(err)
|
||||
} else {
|
||||
Info.Println("[main] Interface", ifaceName, "is up")
|
||||
Log.Infoln("[main] Interface", ifaceName, "is up")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -89,12 +89,12 @@ func main() {
|
||||
if httpIfaceName == "" {
|
||||
httpIP = "0.0.0.0"
|
||||
} else {
|
||||
Info.Println("[main] Waiting for HTTP interface", httpIfaceName, "to come up")
|
||||
Log.Infoln("[main] Waiting for HTTP interface", httpIfaceName, "to come up")
|
||||
httpIface, err := weavenet.EnsureInterface(httpIfaceName, wait)
|
||||
if err != nil {
|
||||
Log.Fatal(err)
|
||||
}
|
||||
Info.Println("[main] Interface", httpIfaceName, "is up")
|
||||
Log.Infoln("[main] Interface", httpIfaceName, "is up")
|
||||
|
||||
addrs, err := httpIface.Addrs()
|
||||
if err != nil {
|
||||
@@ -173,7 +173,7 @@ func main() {
|
||||
if err != nil {
|
||||
Log.Fatal("[main] Unable to create http listener: ", err)
|
||||
}
|
||||
Info.Println("[main] HTTP API listening on", httpAddr)
|
||||
Log.Infoln("[main] HTTP API listening on", httpAddr)
|
||||
|
||||
go SignalHandlerLoop(srv)
|
||||
go weavedns.ServeHTTP(httpListener, version, srv, dockerCli)
|
||||
|
||||
@@ -50,8 +50,8 @@ func main() {
|
||||
InitDefaultLogging(true)
|
||||
}
|
||||
|
||||
Info.Println("weave proxy", version)
|
||||
Info.Println("Command line arguments:", strings.Join(os.Args[1:], " "))
|
||||
Log.Infoln("weave proxy", version)
|
||||
Log.Infoln("Command line arguments:", strings.Join(os.Args[1:], " "))
|
||||
|
||||
p, err := proxy.NewProxy(c)
|
||||
if err != nil {
|
||||
|
||||
@@ -45,7 +45,7 @@ func (i *createContainerInterceptor) InterceptRequest(r *http.Request) error {
|
||||
}
|
||||
|
||||
if cidrs, ok := i.proxy.weaveCIDRsFromConfig(container.Config); ok {
|
||||
Info.Printf("Creating container with WEAVE_CIDR \"%s\"", strings.Join(cidrs, " "))
|
||||
Log.Infof("Creating container with WEAVE_CIDR \"%s\"", strings.Join(cidrs, " "))
|
||||
if container.HostConfig == nil {
|
||||
container.HostConfig = &docker.HostConfig{}
|
||||
}
|
||||
|
||||
@@ -30,7 +30,7 @@ func (i *createExecInterceptor) InterceptRequest(r *http.Request) error {
|
||||
}
|
||||
|
||||
if cidrs, ok := i.proxy.weaveCIDRsFromConfig(container.Config); ok {
|
||||
Info.Printf("Exec in container %s with WEAVE_CIDR \"%s\"", container.ID, strings.Join(cidrs, " "))
|
||||
Log.Infof("Exec in container %s with WEAVE_CIDR \"%s\"", container.ID, strings.Join(cidrs, " "))
|
||||
cmd := append(weaveWaitEntrypoint, "-s")
|
||||
options.Cmd = append(cmd, options.Cmd...)
|
||||
}
|
||||
|
||||
+2
-2
@@ -72,7 +72,7 @@ func (proxy *Proxy) Dial() (net.Conn, error) {
|
||||
}
|
||||
|
||||
func (proxy *Proxy) ServeHTTP(w http.ResponseWriter, r *http.Request) {
|
||||
Info.Printf("%s %s", r.Method, r.URL)
|
||||
Log.Infof("%s %s", r.Method, r.URL)
|
||||
path := r.URL.Path
|
||||
var i interceptor
|
||||
switch {
|
||||
@@ -101,7 +101,7 @@ func (proxy *Proxy) ListenAndServe() {
|
||||
}
|
||||
|
||||
for _, addr := range addrs {
|
||||
Info.Println("proxy listening on", addr)
|
||||
Log.Infoln("proxy listening on", addr)
|
||||
}
|
||||
|
||||
errs := make(chan error)
|
||||
|
||||
@@ -26,7 +26,7 @@ func (i *startContainerInterceptor) InterceptResponse(r *http.Response) error {
|
||||
Log.Debug("No Weave CIDR, ignoring")
|
||||
return nil
|
||||
}
|
||||
Info.Printf("Attaching container %s with WEAVE_CIDR \"%s\" to weave network", container.ID, strings.Join(cidrs, " "))
|
||||
Log.Infof("Attaching container %s with WEAVE_CIDR \"%s\" to weave network", container.ID, strings.Join(cidrs, " "))
|
||||
args := []string{"attach"}
|
||||
args = append(args, cidrs...)
|
||||
args = append(args, "--or-die", container.ID)
|
||||
|
||||
Reference in new issue
Block a user