From e4cba7d36a49353febfefcb25d2d820bc89e9d1b Mon Sep 17 00:00:00 2001 From: Stefan Becker Date: Sat, 13 Jul 2019 18:22:41 +0300 Subject: create: improve parser for --healthcheck-command Fix Docker CLI compatibility issue: the "--healthcheck-command" option value should not be split but instead be passed as single string to "CMD-SHELL", i.e. "/bin/sh -c ". On the other hand implement the same extension as is already available for "--entrypoint", i.e. allow the option value to be a JSON array of strings. This will make life easier for tools like podman-compose. Updated "--healthcheck-command" option values in tests accordingly. Continuation of #3455 & #3507 Signed-off-by: Stefan Becker --- docs/podman-create.1.md | 5 ++++- docs/podman-run.1.md | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) (limited to 'docs') diff --git a/docs/podman-create.1.md b/docs/podman-create.1.md index 87e18dbb9..ea01a346c 100644 --- a/docs/podman-create.1.md +++ b/docs/podman-create.1.md @@ -272,12 +272,15 @@ The following example maps uids 0-2000 in the container to the uids 30000-31999 Add additional groups to run as -**--healthcheck-command**=*command* +**--healthcheck-command**=*"command"* | *'["command", "arg1", ...]'* Set or alter a healthcheck command for a container. The command is a command to be executed inside your container that determines your container health. The command is required for other healthcheck options to be applied. A value of `none` disables existing healthchecks. +Multiple options can be passed in the form of a JSON array; otherwise, the command will be interpreted +as an argument to `/bin/sh -c`. + **--healthcheck-interval**=*interval* Set an interval for the healthchecks (a value of `disable` results in no automatic timer setup) (default "30s") diff --git a/docs/podman-run.1.md b/docs/podman-run.1.md index 95499edd6..e3dca9300 100644 --- a/docs/podman-run.1.md +++ b/docs/podman-run.1.md @@ -279,12 +279,15 @@ The example maps gids 0-2000 in the container to the gids 30000-31999 on the hos Add additional groups to run as -**--healthcheck-command**=*command* +**--healthcheck-command**=*"command"* | *'["command", "arg1", ...]'* Set or alter a healthcheck command for a container. The command is a command to be executed inside your container that determines your container health. The command is required for other healthcheck options to be applied. A value of `none` disables existing healthchecks. +Multiple options can be passed in the form of a JSON array; otherwise, the command will be interpreted +as an argument to `/bin/sh -c`. + **--healthcheck-interval**=*interval* Set an interval for the healthchecks (a value of `disable` results in no automatic timer setup) (default "30s") -- cgit v1.2.3-54-g00ecf