GithubHelp home page GithubHelp logo

rpardini / adoptium-deb-installer Goto Github PK

View Code? Open in Web Editor NEW
58.0 11.0 3.0 5.66 MB

Creates Ubuntu/Debian installer packages for Eclipse Adoptium using their API. Important: these are NOT official packages. JDK 8, 11, 17, 18 and 19, all multiarch, in both JRE and JDK flavors.

Shell 49.94% JavaScript 49.47% Makefile 0.59%
launchpad ubuntu debian java jdk jre hotspot adoptium apt ppa webupd8

adoptium-deb-installer's Introduction

Debian/Ubuntu installer packages for Eclipse Adoptium

This uses the Eclipse Adoptium API to produce Ubuntu/Debian packages which download and install Eclipse Adoptium from their official releases.

  • Ubuntu: ppa:rpardini/adoptium-installers or see instructions below.
  • Debian: there's an APT repo hosted at GitHub Pages, see below for instructions.
  • The Debian instructions also work for Ubuntu if you'd rather avoid PPA's.

Use these packages at your own risk. These are NOT official packages.

For Ubuntu:

[[ ! -f /usr/bin/add-apt-repository ]] && sudo apt-get -y install software-properties-common # Make sure 'add-apt-repository' is available
sudo add-apt-repository --yes ppa:rpardini/adoptium-installers
sudo apt-get install adoptium-17-installer # or 8, 11, etc; also adoptium-17-jdk-hotspot-installer-set-default

For Debian:

sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys A1EAC8B7 # add the builder key
echo 'deb https://rpardini.github.io/adoptium-deb-installer stable main' > /etc/apt/sources.list.d/rpardini-adoptium.list # add the package repo to sources 
sudo apt-get update # update from sources
sudo apt-get install adoptium-17-installer # or 8, 11, etc; also adoptium-17-jdk-hotspot-installer-set-default

For developers/builders

This repo produces source packages which are then uploaded to Launchpad, where they're built and hosted. The final packages produced are essentially just downloader scripts, and try to handle proxy usage, SHA256 verification, update-alternatives and update-java-alternatives as per java-common standards.

A huge amount of the actual installer scripting was stolen from Alin Andrei's webupd8 oracle-java8-installer -- all the update-alternatives, manpages, etc stuff is clearly in need of work. The proxy handling also needs to be confirmed; a few of his provisions like using a custom wgetrc was kept, but a lot of cosmetic stuff like icons were removed.

Due to the way Launchpad works, a big part of this is calculating a single set/version from many possible JDK builds for different architectures. It seems common that aarch64 and/or s390x archs have different Eclipse Adoptium builds than other architectures, at least for Java 8 and Java 11. Update: Adoptium does not suffer so much from those.

For this reason (and also cause I'm a bit of a codegen freak) I implemented a Node.js script that consumes Eclipse Adoptium's releases API and process sets of templates to produce final source packages.

Also due to Launchpad's requirements, I build a lot of (otherwise identical) source packages for different distributions/series (trusty, xenial, bionic, etc); please instruct me how to avoid this if you know.

Credits

  • Of course, Eclipse Adoptium for all of the actual amazing work, and for the API.
  • Alin Andrei/webupd8 for the original oracle-jdk8-installer from which I started this work
  • Launchpad for actually building on many architectures and hosting the whole thing for Ubuntu
  • GitHub for repo, Github Actions, and hosting the Debian repo with GitHub Pages. Please don't ban me.

adoptium-deb-installer's People

Contributors

cruwe avatar rpardini avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

adoptium-deb-installer's Issues

Installer-based method makes apt-mirror useless

I don't know whether this is observed all over the world, but where I live, the download rates for the adoptopenjdk files from GitHub/Amazon AWS now consistently seem to be in the two-digit kB/s range, and for anyone with more than one machine needing the same packages I guess it would usually be a good idea to set up one machine acting as an apt-mirror for this PPA. But with the installer-based update method, the apt-mirror would only mirror the installer, and so even if every machine would use the mirrored PPA, it still would trigger the complete JDK download from GitHub/Amazon AWS again, and nothing would be gained.

Until there hopefully will be a solution for the slow downloads as such at some point in time, I'd like to at least minimize the impact... Is there perhaps a not-too-complex solution I just haven't thought about?

Eoan support

The launchpad site suggests that the latest Ubuntu version that is supported is Disco (19.04), but 19.10 is already out and for me using it it says there is no Release file (-> no support yet for Eoan).

Can I use the Disco ppa for my Eoan (19.10) installation or is it not compatible?

Can't install adoptopenjdk-8 -jre-openj9-installer

Original email received:

Good afternoon Ricardo Pardini

First of all I appreciate all the effort you put into creating this ppa
to easily install openjdk with openj9.

By this means I want to report a bug in the installer of adoptopenjdk-8
-jre-openj9-installer.

The process is corrupted with the following error:

Could not find 'jdk8u202-b08_openj9-0.12.1' or 'jdk8u202-b08' or
'jdk8u202-b08_openj9-0.12.1-jre' after unpacking.
This is an installer bug, please report:
find: warning: you have specified the -maxdepth option after a non-
option argument -type, but options are not positional (-maxdepth affects
tests specified before as well as those specified after it). Please
specify options before other arguments.

 -> expected './jdk8u202-b08_openj9-0.12.1' or './jdk8u202-b08' or
'./jdk8u202-b08_openj9-0.12.1-jre' but got './jdk8u202-b08-jre'.

AdoptOpenJDK JRE 8 with OpenJ9 is NOT installed: .tar.gz does not
contain expected dir
dpkg: error while cleaning up:
 installed adoptopenjdk-8-jre-openj9-installer package post-installation
script subprocess returned error exit status 1
Errors were encountered while processing:
 adoptopenjdk-8-jre-openj9-installer

When reviewing the contents of the file OpenJDK8U-
jre_x64_linux_openj9_8u202b08_openj9-0.12.1.tar.gz, the problem occurs
because the folder is called jdk8u202-b08-jre and in the bash postinst
the variable J_DIR_INSIDE_TAR_GZ_SHORT points to "jdk8u202-b08".

JDK11 upgrade?

I've currently using the repo for a while, and everytime I deploy jdk11-hotspot-installer, i'm on 11.0.8+10 version. The last one on AdoptOpenJDK is 11.0.10+9. Is it normal or am I missing something ?

Same, is there a command or a way to make an autoupgrade of the actual JDK installed on the host ?

OS: Debian 8.11

Thanks!

Java 13

Java 13 is out for some time. If possible, can this be added to the repository, as well?
And maybe the older non-LTS-versions (9, 10, 12) aren't that interesting anymore.

Debian i386 support

apt-get update:

N: Skipping acquire of configured file 'main/binary-i386/Packages' as repository 'https://rpardini.github.io/adoptopenjdk-deb-installer stable InRelease' doesn't support architecture 'i386'

OpenJ9 deb installers based on IBM/Semeru

Hi. After AdoptOpenJDK has transformed in Adoptium they've stopped to provide OpenJ9 builds and recommends to use IBM/Semeru builds. But IBM/Semeru has only .tar.gz and .rpm builds and no .debs.
So, I think a lot of people really could have a use for ppa repository with new OpenJ9 deb packages.

Use `sudo tee` to add source on Debian

Using sudo tee instead of output redirect will let you to run the whole sequence of actions as an unprivileged user (with sudo, naturally). I.e. instead of

echo 'deb https://rpardini.github.io/adoptopenjdk-deb-installer stable main' > /etc/apt/sources.list.d/rpardini-aoj.list 

use

echo 'deb https://rpardini.github.io/adoptopenjdk-deb-installer stable main' | sudo tee /etc/apt/sources.list.d/rpardini-aoj.list 

sha256sum mismatch OpenJDK8U-jre_x64_linux_hotspot_8u212b03.tar.gz

Hi,
This happened during upgrade.

 adoptopenjdk-8-jre-hotspot-installer
E: Sub-process /usr/bin/dpkg returned an error code (1)
Se pregătește adoptopenjdk-8-jre-hotspot-installer (201904201617~8u212b03+aarch64~8u191b12) ...
Installing for arch 'amd64'...
Installing from local file /var/cache/adoptopenjdk-8-jre-hotspot-installer/OpenJDK8U-jre_x64_linux_hotspot_8u212b03.tar.gz
Checking SHA256 checksum: 
AdoptOpenJDK JRE 8 with Hotspot is NOT installed: sha256sum mismatch OpenJDK8U-jre_x64_linux_hotspot_8u212b03.tar.gz
dpkg: error processing package adoptopenjdk-8-jre-hotspot-installer (--configure):
 installed adoptopenjdk-8-jre-hotspot-installer package post-installation script subprocess returned error exit status 1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.