cmd/dockerd: adjust error message for pidfile changes

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn 2022-10-15 18:24:29 +02:00
parent 7493debe26
commit 14da1bfe40
No known key found for this signature in database
GPG key ID: 76698F39D527CE8C

View file

@ -143,7 +143,7 @@ func (cli *DaemonCli) start(opts *daemonOptions) (err error) {
return errors.Wrap(err, "failed to create pidfile directory")
}
if err = pidfile.Write(cli.Pidfile, os.Getpid()); err != nil {
return errors.Wrap(err, "failed to start daemon")
return errors.Wrapf(err, "failed to start daemon, ensure docker is not running or delete %s", cli.Pidfile)
}
potentiallyUnderRuntimeDir = append(potentiallyUnderRuntimeDir, cli.Pidfile)
defer func() {