pass extra file to child process as status handler

When stdout/stderr is closed prematurely, the proxy's writes to stdout/stderr
(i.e. `log.Errorf/log.Printf`) will returns with EPIPE error, and go runtime
will terminate the proxy when stdout/stderr writes trigger 10 EPIPE errors.

instead of using stdout/stderr as the status handler, we pass an extra file to
the child process and write `0\n` or `1\nerror message` to it and close it
after. This allow the child process to handle stdout/stderr as normal.

Docker-DCO-1.1-Signed-off-by: Daniel, Dao Quang Minh <dqminh89@gmail.com> (github: dqminh)
Restore volume refs after daemon restart

Volume refs were not being restored on daemon restart.
This made it possible to remove a volume being used by other containers
after a daemon restart.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Fixes re-creating volume on (re)start

When a container is restarted all the volume configs are parsed again.
Even if the volume was already handled in a previous start it was still
calling "FindOrCreateVolume" on the volume repo causing a new volume to
be created.

This wasn't being detected because as part of the mount initialization
it checks to see if the the _mount_ was already initialized, but this
happens after the parsing of the configs.
So a check is added during parsing to skip a volume which was already
created for that container.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Merge pull request #8472 from cpuguy83/fix_volume_refs_on_daemon_restore

Restore volume refs after daemon restart
Merge pull request #8475 from cpuguy83/fix_create_phantom_volumes_on_container_restart

Fixes re-creating volume on (re)start
Merge pull request #8450 from dqminh/fix-proxy-exit

dont close proxy's stdout/stderr prematurely
Deprecating ResolveRepositoryName

Passing RepositoryInfo to ResolveAuthConfig, pullRepository, and pushRepository

Moving --registry-mirror configuration to registry config

Created resolve_repository job

Repo names with 'index.docker.io' or 'docker.io' are now synonymous with omitting an index name.

Adding test for RepositoryInfo

Adding tests for opts.StringSetOpts and registry.ValidateMirror

Signed-off-by: Don Kjer <don.kjer@gmail.com>
gofmt changes

Signed-off-by: Don Kjer <don.kjer@gmail.com>
Fixing search term use of repoInfo

Signed-off-by: Don Kjer <don.kjer@gmail.com>
Adding integration tests for registry mirror configuration

Signed-off-by: Don Kjer <don.kjer@gmail.com>