Skip to content
This repository has been archived by the owner on Aug 30, 2024. It is now read-only.

entrypoint validation fails for the Shell form ENTRYPOINT #12572

Open
ryh-cc opened this issue Jan 17, 2022 · 0 comments
Open

entrypoint validation fails for the Shell form ENTRYPOINT #12572

ryh-cc opened this issue Jan 17, 2022 · 0 comments

Comments

@ryh-cc
Copy link

ryh-cc commented Jan 17, 2022

Context: I need to use the shell form ENTRYPOINT to be able to do variable substitution e.g.
ENTRYPOINT exec java -javaagent:dd-java-agent.jar ${JAVA_OPTS} -jar /app.jar.

It seems that container-structure-test does not support the shell form, as it fails when I run an entrypoint validation like so:

  entrypoint: ["/bin/sh", "-c", "exec", "java", "-javaagent:dd-java-agent.jar", "${JAVA_OPTS}", "-jar", "/app.jar"]

(I've also tried substituting JAVA_OPTS with a literal value)
and the test fails with the following error:

Error

=== RUN: Metadata Test
--- FAIL
duration: 0s
Error: Image entrypoint [/bin/sh -c exec java -javaagent:dd-java-agent.jar ${JAVA_OPTS} -jar /app.jar] does not match expected entrypoint: [/bin/sh -c exec java -javaagent:dd-java-agent.jar ${JAVA_OPTS} -jar /app.jar]

Will this be supported and/or is there a workaround for this?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant