While researching another article I discovered that it’s now possible to change the restart policy for a container without stopping, deleting and re-running it. Apparently this has also been possible for quite a long time, since Docker 1.11 was released in April 2016.
The docker update command allows you to change the configuration of a container in several ways. To change the restart policy use the ––restart command line option:
$ docker update --restart=always CONTAINER
There is a rather unhealthy obsession, in my opinion, in the Docker community about developing the smallest possible container size. Obviously you don’t want your container to contain hundreds of megabytes of useless junk, but perhaps we have passed the point of diminishing returns. It turns out that it is less expensive to have files in your base image that aren’t used than it is to have duplicated files in higher layers.
Continue reading “Do Docker Users Have a Container Size Fetish?”
If you were lucky enough to go to DockerCon 2017 (I wasn’t) you might have seen the announcement of Moby and LinuxKit, Docker’s new framework for assembling specialised container systems. Traditionally a bare metal or virtual machine that runs Docker has run a “full service” distribution like Debian, Ubuntu or RedHat Linux. Docker and containerized applications are then installed and run on that server. LinuxKit gives us a quick and easy way of building an OS for the host machine that’s customised to run containers and not a lot else.
Continue reading “LinuxKit – the software-defined OS”
I remember the first time that I discovered command line completion for my shell way back in the early 90’s. Up until then, you needed to remember the filename you wanted to use for any command and type the full name out in its entirety. This could be a frustrating and error-prone process even if you were a good typist. From then on being able to hit TAB and get the right filename was just pure bliss!
Depending on your situation, command line completion for Docker client may already be working and you might not realise it! Read on for details. Continue reading “Docker Command Line Completion”