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
```
This commit is contained in:
Daniel Piddock
2023-01-27 16:17:45 +01:00
committed by GitHub
parent 9add331645
commit bbb0ed2f00

View File

@@ -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