til

Today I Learned: collection of notes, tips and tricks and stuff I learn from day to day working with computers and technology as an open source contributor and product manager

View project on GitHub

Customize your docker ps output

docker ps is nifty, you can even customize the outout to suit your needs.

My customization gives me the following output (squashed for readability):

$ docker ps

NAMES     CONTAINER ID  IMAGE       STATUS      NETWORKS  PORTS
registry  81bbacaeb8b9  registry:2  Up 2 weeks  bridge    0.0.0.0:5000->5000/tcp

The output is defined in: $HOME/.docker/config.json, like so:

{
    "psFormat": "table \\t\\t\\t\\t\\t",
}

You can also specify this on the fly:

$ docker ps --format ""

Please see the documentation for more information.

References