Skip to content

Commit

Permalink
feat(model-server)!: Use ENTRYPOINT instead of CMD in the provided Do…
Browse files Browse the repository at this point in the history
…cker image

> You can use the exec form of ENTRYPOINT to set fairly stable default commands and arguments and then use either form of CMD to set additional defaults that are more likely to be changed.
See. https://docs.docker.com/engine/reference/builder/#exec-form-entrypoint-example

Using a ENTRYPOINT in model-server docker container makes passing arguments easier.
For example,
`docker run --rm -p 28101:28101 -it modelix/model-server ./run-model-server.sh -inmemory`
would be simplified to
`docker run --rm -p 28101:28101 -it modelix/model-server -inmemory`

This is a breaking change, because the previous ENTRYPOINT was the default `ENTRYPOINT ["/bin/sh", "-c"]`.
  • Loading branch information
odzhychko committed Jan 3, 2024
1 parent 3d41891 commit 9b1929e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion model-server/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ EXPOSE 28101
COPY run-model-server.sh /usr/modelix-model/
COPY build/dependency-libs/ /usr/modelix-model/model-server/build/libs/
COPY build/libs/ /usr/modelix-model/model-server/build/libs/
CMD ["./run-model-server.sh"]
ENTRYPOINT ["./run-model-server.sh"]

0 comments on commit 9b1929e

Please sign in to comment.