Skip to content
This repository has been archived by the owner on Nov 6, 2023. It is now read-only.

Chapter 3: can't check version because container autostarts jshell #497

Open
timo-a opened this issue Apr 21, 2020 · 1 comment
Open

Chapter 3: can't check version because container autostarts jshell #497

timo-a opened this issue Apr 21, 2020 · 1 comment

Comments

@timo-a
Copy link

timo-a commented Apr 21, 2020

Chapter 3 asks to run

docker container run -it openjdk

and check the java version with java -version However for me jshell opens directly and /exitexits the whole container.

Version can be checked with System.out.println(Runtime.version())

@stridford
Copy link

Setting the entrypoint explicitly also works to access the container's shell:

docker container run -it --entrypoint=/bin/sh openjdk

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

2 participants