from small one page howto to huge articles all in one place

search text in:




Other .linuxhowtos.org sites:gentoo.linuxhowtos.org



Last additions:
using iotop to find disk usage hogs

using iotop to find disk usage hogs

words:

887

views:

210172

userrating:


May 25th. 2007:
Words

486

Views

259147

why adblockers are bad


Workaround and fixes for the current Core Dump Handling vulnerability affected kernels

Workaround and fixes for the current Core Dump Handling vulnerability affected kernels

words:

161

views:

150507

userrating:


April, 26th. 2006:

Druckversion
You are here: manpages





CONFIG.JSON

Section: Docker User Manuals (5)
Updated: JANUARY 2016
Index Return to Main Contents

 

NAME

HOME/.docker/config.json - Default Docker configuration file

 

INTRODUCTION

By default, the Docker command line stores its configuration files in a directory called .docker within your $HOME directory. Docker manages most of the files in the configuration directory and you should not modify them. However, you can modify the config.json file to control certain aspects of how the docker command behaves.

Currently, you can modify the docker command behavior using environment variables or comman-line options. You can also use options within config.json to modify some of the same behavior. When using these mechanisms, you must keep in mind the order of precedence among them. Command line options override environment variables and environment variables override properties you specify in a config.json file.

The config.json file stores a JSON encoding of several properties:

*
The HttpHeaders property specifies a set of headers to include in all messages sent from the Docker client to the daemon. Docker does not try to interpret or understand these header; it simply puts them into the messages. Docker does not allow these headers to change any headers it sets for itself.
*
The psFormat property specifies the default format for docker ps output. When the -format flag is not provided with the docker ps command, Docker's client uses this property. If this property is not set, the client falls back to the default table format. For a list of supported formatting directives, see docke-ps(1).
*
The detachKeys property specifies the default key sequence which detaches the container. When the -detac-keys flag is not provide with the docker attach, docker exec, docker run or docker start, Docker's client uses this property. If this property is not set, the client falls back to the default sequence ctr-p,ctr-q.
*
The imagesFormat property specifies the default format for docker images output. When the -format flag is not provided with the docker images command, Docker's client uses this property. If this property is not set, the client falls back to the default table format. For a list of supported formatting directives, see docke-images(1).

You can specify a different location for the configuration files via the DOCKER_CONFIG environment variable or the -config command line option. If both are specified, then the -config option overrides the DOCKER_CONFIG environment variable:

docker-config ~/testconfigs/ ps

This command instructs Docker to use the configuration files in the ~/testconfigs/ directory when running the ps command.

 

Examples

Following is a sample config.json file:

{
  "HttpHeaders": {
    "MyHeader": "MyValue"
  },
  "psFormat": "table {{.ID}}t{{.Image}}t{{.Command}}t{{.Labels}}",
  "imagesFormat": "table {{.ID}}t{{.Repository}}t{{.Tag}}t{{.CreatedAt}}",
  "detachKeys": "ctr-e,e" }

 

HISTORY

January 2016, created by Moxiegirl mary@docker.com [la]mailto:mary@docker.com[ra]


 

Index

NAME
INTRODUCTION
Examples
HISTORY





Support us on Content Nation
rdf newsfeed | rss newsfeed | Atom newsfeed
- Powered by LeopardCMS - Running on Gentoo -
Copyright 2004-2025 Sascha Nitsch Unternehmensberatung GmbH
Valid XHTML1.1 : Valid CSS
- Level Triple-A Conformance to Web Content Accessibility Guidelines 1.0 -
- Copyright and legal notices -
Time to create this page: 14.5 ms