Prettify docs-update.py

Remove commented code, use format for string concatenation, split long lines, fix how-to-run instructions
Signed-off-by: Davide Ceretti <dav.ceretti@gmail.com>
Add ENV variables support to WORKDIR build command

Docker-DCO-1.1-Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com> (github: unclejack)
Docker-DCO-1.1-Signed-off-by: Adrien Folie <folie.adrien@gmail.com> (github: folieadrien)

Conflicts:
	builder/builder.go
		This file has been deleted.
Multiple fixes to the cli.md document.

*. Fixed headings so the side menu will now be consistent. Some sections
had H3s that were displaying and others did not leaving the left menu
very mismatched.

* Fixed several spelling errors.

* Re-formatted several long lines and badly laid out paragraphs.

* Fixed several double backticks.

* Added backticks to several outputs and variables.

* Removed two issues that are no longer valid.

* Removed several double spaces and extra lines.

Docker-DCO-1.1-Signed-off-by: James Turnbull <james@lovedthanlost.net> (github: jamtur01)
Fix TestBuildCacheADD to check cache in out, not in id

Signed-off-by: Alexandr Morozov <lk4d4@docker.com>
Merge pull request #8416 from LK4D4/fix_build_cache_test

Fix TestBuildCacheADD to check cache in out, not in id
integcli: lint fixes

Docker-DCO-1.1-Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com> (github: unclejack)
Merge pull request #8409 from unclejack/integcli_lint

integcli: lint fixes
google: fix typo

Docker-DCO-1.1-Signed-off-by: Johan Euphrosine <proppy@google.com> (github: proppy)
Container#AllocateNetwork: Simplify error handling.

The defer logic was a little tricky and was hiding one bug: `err` was
being redefined (with `:=`) and thus it escaped the defer error checking
logic.

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
Add test for ignoring invalid dockerfile instructions

Signed-off-by: Tibor Vass <teabee89@gmail.com>
Merge pull request #8426 from proppy/patch-12

google: fix typo
ignore invalid Dockerfile instructions and do not consider "docker-version" a Dockerfile instruction

Signed-off-by: Tibor Vass <teabee89@gmail.com>
Merge pull request #8341 from unclejack/add_workdir_test

add test for workdir env vars and add docs
Merge pull request #8304 from davide-ceretti/chore/prettify-docs-update.py

Prettify docs-update.py
Merge pull request #8382 from jamtur01/cli

Multiple fixes to the cli.md document.
back from camping, and making fred the docs 'guy in charge'

Docker-DCO-1.1-Signed-off-by: Sven Dowideit <SvenDowideit@docker.com> (github: SvenDowideit)
Increase the tag length limit from 30 to 128

Signed-off-by: Burke Libbey <burke.libbey@shopify.com>
Fix system socket/service unit files

Two problems how they are today:

In the current systemd unit files it is impossible to have the
docker.service started at system boot.  Instead enableing docker.service
will actually enable docker.socket.  This is a problem, as that means
any container with --restart=always will not launch on reboot.  And of
course as soon as you log in and type docker ps, docker.service will be
launched and now your images are running.  Talk about a PITA to debug!
The fix is to just install docker.service when people ask docker.service
to be enabled.  If an admin wants to enable docker.socket instead, that
is fine and will work just as it does today.

The second problem is a common docker devel workflow, although not
something normal admins would hit.  In this case consider a dev doing
the following:

systemctl stop docker.service

docker -d
[run commands]
[^C]

systemctl start docker.service

Running docker -d (without -F fd://) will clean up the
/var/run/docker.sock when it exits.  Remember, you just ran the docker
daemon not telling it about socket actviation, so cleaning up its socket
makes sense!  The new docker, started by systemd will expect socket
activation, but the last one cleaned up the docker.sock.  So things are
just broken.  You can, today, work around this by restarting
docker.socket.  This fixes it by telling docker.socket that it is
PartOf=docker.service.  So when docker.service is
started/stopped/restarted docker.socket will also be
started/stopped/restarted.  So the above semi-common devel workflow will
be fine.  When docker.service is stopped, so is docker.socket,   docker
-d (without -F fd://) will create and delete /var/run/docker.sock.
Starting docker.service again will restart docker.socket, which will
create the file an all is happy in the word.

Signed-off-by: Eric Paris <eparis@redhat.com>
Check /etc/resolv.conf every time for 127.* content

Currently if you start the docker -d on a system with 127.0.0.1 in /etc/resolv.conf
It will set the default dns to 8.8.8.8 8.8.4.4 permanently.

This causes a problem at boot on Fedora machines where NetworkManager has not
populated /etc/resolv.conf before docker gets started.

This fix checks /etc/resolv.conf on every docker run. And only populates
daemon.config.Dns  if the user specified it on the command line.

Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
Merge pull request #8434 from tiborvass/ignore_invalid_Dockerfile_instructions

Ignore unknown dockerfile instructions