Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Is there a way to tell shell commands are available in a docker image?

I’m using the node docker images as a container for my build pipelines.

An issue I frequently run into is that a binary that I expect to exist, doesn’t and I have to wait for it fail in the build pipeline. The zip command is one such example.

I can run the docker image on my local machine and ssh in to test commands.

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

Is there a way to summarise what commands are available for a given image?

>Solution :

Is there a way to summarise what commands are available for a given image?

You could look at the contents of /bin:

$ docker run --rm -it --entrypoint=ls node /bin

or /usr/local/bin:

$ docker run --rm -it --entrypoint=ls node /usr/local/bin

etc…

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading