From bbb0ed2f0041844dc4abfddef2d1fe2f25340249 Mon Sep 17 00:00:00 2001 From: Daniel Piddock <30546489+dpiddock@users.noreply.github.com> Date: Fri, 27 Jan 2023 16:17:45 +0100 Subject: [PATCH] Fix docker-entrypoint when called with atlantis (#3060) Prior to v0.22.0 the container could be run with the command `atlantis server`. However this was broken by #2770: ``` Error: unknown command "atlantis" for "atlantis" ``` This PR reverts to previous functionality and matches the comment. Following calls all work again: ```sh docker run atlantis server docker run atlantis --help docker run atlantis atlantis server docker run atlantis atlantis --help ``` --- docker-entrypoint.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-entrypoint.sh b/docker-entrypoint.sh index 3d1e29656..dd4e15e7b 100755 --- a/docker-entrypoint.sh +++ b/docker-entrypoint.sh @@ -5,7 +5,7 @@ set -e # If the user is trying to run atlantis directly with some arguments, then # pass them to atlantis. -if [ "$(echo "${1}" | cut -c1)" ]; then +if [ "$(echo "${1}" | cut -c1)" = "-" ]; then set -- atlantis "$@" fi