Last active
October 29, 2019 14:32
-
-
Save hoangdh/feb9f5d96eb72150e04ba61cb4d543fa to your computer and use it in GitHub Desktop.
Install JAVA on Ubuntu in 2 minutes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
apt-get update | |
apt-get install openjdk-8-jdk -y | |
echo "JAVA_HOME=$(which java)" | tee -a /etc/environment | |
source /etc/environment | |
echo "\$JAVA_HOME: $JAVA_HOME" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
How to install?
RUN it and Enjoy!