Detect Docker robustly
"&> /dev/null" works as a redirection from stdout/stderr to /dev/null
in Bash but not in POSIX shell (considered as an asynchronous execution
and the result of the "command" command cannot be retrieved).
As a result, it always assumes that Docker always exists.
This commit makes the redirection robust and portable (makes it possible
to detect "no Docker" condition correctly).
Signed-off-by:
Tsukasa OI <research_trasio@irq.a4lg.com>
parent
b65e07cb
Please register or sign in to comment