You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This works fine if the container is run as-is or by an orchestrator that doesn't attempt to override the arguments.
However, take an example where a user attempts to remove HTTPS usage from the default URL via Kubernetes deployment by using the args property on the container spec:
Which is going to fail for two reasons: the original https://+:52323 will fail to bind because a certificate was not configured and the second metricsUrls value fails to bind because 52325 is already in use. It's not obvious why these would fail given that the user attempted to override the parameters of the container.
The root of the issue is how Kubernetes overrides the startup values for Docker and how the Dockerfile has described those values:
Kubernetes' command property will override Docker's ENTRYPOINT statement
Kubernetes' args property will override Docker's CMD statement
Thus, to truly override the command line arguments, users need to specify command in their Kubernetes deployments:
Problem
Currently, the Dockerfile describes the startup of the container as follows:
This works fine if the container is run as-is or by an orchestrator that doesn't attempt to override the arguments.
However, take an example where a user attempts to remove HTTPS usage from the default URL via Kubernetes deployment by using the
args
property on the container spec:What actually happens is that the following is executed when starting the container:
Which is going to fail for two reasons: the original
https://+:52323
will fail to bind because a certificate was not configured and the second metricsUrls value fails to bind because 52325 is already in use. It's not obvious why these would fail given that the user attempted to override the parameters of the container.The root of the issue is how Kubernetes overrides the startup values for Docker and how the Dockerfile has described those values:
command
property will override Docker'sENTRYPOINT
statementargs
property will override Docker'sCMD
statementThus, to truly override the command line arguments, users need to specify
command
in their Kubernetes deployments:Proposal
It might be beneficial to change the Dockerfile to split the arguments from the entrypoint so that they are more easily overridable:
This allows users to override the arguments to the tool. Thus, if a user specifies the following in a Kubernetes deployment:
then the effective execution within the container is:
The text was updated successfully, but these errors were encountered: