Skip to content

Instantly share code, notes, and snippets.

@ny83427
Created February 25, 2020 23:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ny83427/fb2f15304dbc10dbfc3d4d03a908b8a2 to your computer and use it in GitHub Desktop.
Save ny83427/fb2f15304dbc10dbfc3d4d03a908b8a2 to your computer and use it in GitHub Desktop.
install-oracle-jdk13-ubuntu
# auto accept oracle license agreement
echo oracle-java13-installer shared/accepted-oracle-license-v1-2 select true | sudo /usr/bin/debconf-set-selections
# install oracle jdk13 and set environment variables
sudo add-apt-repository ppa:linuxuprising/java -y
sudo apt-get update
sudo apt-get install oracle-java13-installer -yq
sudo apt-get install oracle-java13-set-default -yq
# set JAVA_HOME variable and link jdk13 to default location also
sudo ln -s /usr/lib/jvm/java-13-oracle /usr/lib/jvm/default-java
export JAVA_HOME=/usr/lib/jvm/java-13-oracle
export PATH=$PATH:$JAVA_HOME/bin
java -version
sudo apt autoremove -yq
@ny83427
Copy link
Author

ny83427 commented Mar 12, 2020

# Install JDK13.0.2
ssh -i id_rsa_gce Admin@35.192.74.18 "cd /home/Admin && wget https://gist.githubusercontent.com/ny83427/fb2f15304dbc10dbfc3d4d03a908b8a2/raw/3b913a219a0b6bd0c828c76ae9babe100308268c/inst-oracle-jdk13-ubuntu.sh && chmod +x inst-oracle-jdk13-ubuntu.sh && ./inst-oracle-jdk13-ubuntu.sh"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment