Apt-get install java debian 5




















Stack Overflow for Teams — Collaborate and share knowledge with a private group. Create a free Team What is Teams? Collectives on Stack Overflow. Learn more. Install Java runtime in Debian based docker image Ask Question. Asked 1 year, 8 months ago. Active 15 days ago. Viewed 6k times. Stefan Stefan 8 8 silver badges 16 16 bronze badges. Add a comment.

Active Oldest Votes. Saurabh Saurabh 2 2 silver badges 8 8 bronze badges. Turns out this was a network related issue, it is working now. You can configure which version is the default for use in the command line by using update-alternatives , which manages which symbolic links are used for different commands.

The output will look something like the following. In this case, all Java versions mentioned above were installed. If we press the enter key in this case, Java 9 will be kept as the default. We can, for example, press 3 for Java 8 and receive the following output:. Now Java 8 would be the default. Choose the default Java version that works best for your projects.

The update-alternatives command can also be used for other Java commands, such as the compiler javac , the documentation generator javadoc , the JAR signing tool jarsigner , and more. You can use the following command, filling in the command you want to customize.

To set this environment variable, we will first need to find out where Java is installed. You can do this by executing the same command as in the previous section:. In this file, add the following line, making sure to replace the highlighted path with your own copied path. You can now test whether the environment variable has been set by executing the following command:. You have now installed Java and know how to manage different versions of it. Where would you like to share this to?

Twitter Reddit Hacker News Facebook. Share link Tutorial share link. There is more information about Java 9 on the official JDK 9 website. There can be multiple Java installations on one server. You can configure which version is the default for use in the command line by using update-alternatives , which manages which symbolic links are used for different commands. The output will look something like the following.

In this case, this is what the output will look like with all Java versions mentioned above installed. You can now choose the number to use as a default. This can also be done for other Java commands, such as the compiler javac , the documentation generator javadoc , the JAR signing tool jarsigner , and more.

You can use the following command, filling in the command you want to customize. To set this environment variable, we will first need to find out where Java is installed. You can do this by executing the same command as in the previous section:. At the end of this file, add the following line, making sure to replace the highlighted path with your own copied path. You can now test whether the environment variable has been set by executing the following command:. You have now installed Java and know how to manage different versions of it.

Where would you like to share this to? Twitter Reddit Hacker News Facebook. Share link Tutorial share link.



0コメント

  • 1000 / 1000