Skip to content

Instantly share code, notes, and snippets.

@rexlManu
Last active April 27, 2022 16:43
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rexlManu/c48375b310d04626b8ddefa71fb56493 to your computer and use it in GitHub Desktop.
Save rexlManu/c48375b310d04626b8ddefa71fb56493 to your computer and use it in GitHub Desktop.
Install java 8 on debian 10
apt install apt-transport-https ca-certificates wget dirmngr gnupg software-properties-common -y
wget -qO - https://adoptopenjdk.jfrog.io/adoptopenjdk/api/gpg/key/public | apt-key add -
add-apt-repository --yes https://adoptopenjdk.jfrog.io/adoptopenjdk/deb/
apt update -y
apt install adoptopenjdk-8-hotspot -y
clear
java -version
@rexlManu
Copy link
Author

rexlManu commented Apr 23, 2020

» For a simply copy and paste

wget -O - git.io/JfIqV | bash

@PrincessAkira
Copy link

PrincessAkira commented Jul 12, 2020

You forgot

sudo update-alternatives --config java

@rexlManu
Copy link
Author

Yea only if u already had a java version installed, then you would need to change it with your command 👍

@NoNamePro0
Copy link

Is not

sudo apt-get install openjdk-8-hotspot

a better alternative, it's already in the default reposiotory exist.

@rexlManu
Copy link
Author

Its only in Ubuntu Repositories Inside. For debian you need to add it

@NoNamePro0
Copy link

Oh, i forgot it. I just work with Ubuntu and Raspian Distros.

@rexlManu
Copy link
Author

Yes!

@Mervus
Copy link

Mervus commented Mar 21, 2021

it installs Java11 is there a Way to get Java 8?

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