github.com/ssdev-go/moby@v17.12.1-ce-rc2+incompatible/libcontainerd/remote_daemon_windows.go (about) 1 // +build remote_daemon 2 3 package libcontainerd 4 5 import ( 6 "os" 7 ) 8 9 const ( 10 grpcPipeName = `\\.\pipe\docker-containerd-containerd` 11 debugPipeName = `\\.\pipe\docker-containerd-debug` 12 ) 13 14 func (r *remote) setDefaults() { 15 if r.GRPC.Address == "" { 16 r.GRPC.Address = grpcPipeName 17 } 18 if r.Debug.Address == "" { 19 r.Debug.Address = debugPipeName 20 } 21 if r.Debug.Level == "" { 22 r.Debug.Level = "info" 23 } 24 if r.snapshotter == "" { 25 r.snapshotter = "naive" // TODO(mlaventure): switch to "windows" once implemented 26 } 27 } 28 29 func (r *remote) stopDaemon() { 30 p, err := os.FindProcess(r.daemonPid) 31 if err != nil { 32 r.logger.WithField("pid", r.daemonPid).Warn("could not find daemon process") 33 return 34 } 35 36 if err = p.Kill(); err != nil { 37 r.logger.WithError(err).WithField("pid", r.daemonPid).Warn("could not kill daemon process") 38 return 39 } 40 41 _, err = p.Wait() 42 if err != nil { 43 r.logger.WithError(err).WithField("pid", r.daemonPid).Warn("wait for daemon process") 44 return 45 } 46 } 47 48 func (r *remote) platformCleanup() { 49 // Nothing to do 50 }