mvberg / ib-gateway-docker

Interactive Brokers Trading Gateway running in Docker
MIT License
224 stars 105 forks source link

Oracle-java-installer ppa is discontinued #10

Closed Python-Trading closed 5 years ago

Python-Trading commented 5 years ago

I got this mistake when I tried to build the docker image:

Package oracle-java8-installer is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'oracle-java8-installer' has no installation candidate
The command '/bin/sh -c echo oracle-java8-installer shared/accepted-oracle-license-v1-1 select true | debconf-set-selections &&   add-apt-repository -y ppa:webupd8team/java &&   apt-get update &&   apt-get install -y oracle-java8-installer &&   apt-get install -y dos2unix &&   rm -rf /var/lib/apt/lists/* &&   rm -rf /var/cache/oracle-jdk8-installer' returned a non-zero code: 100

I have found that oracle-java8-instaler ppa is discontinued, due to a recent modification of Oracle licenses. The following can be read on the webupd8 website (http://www.webupd8.org/2012/09/install-oracle-java-8-in-ubuntu-via-ppa.html):

The Oracle JDK License has changed for releases starting April 16, 2019.

The new Oracle Technology Network License Agreement for Oracle Java SE is substantially different from prior Oracle JDK licenses. The new license permits certain uses, such as personal use and development use, at no cost -- but other uses authorized under prior Oracle JDK licenses may no longer be available. Please review the terms carefully before downloading and using this product. An FAQ is available here.

Oracle Java downloads now require logging in to an Oracle account to download Java updates, like the latest Oracle Java 8u211 / Java SE 8u212. Because of this I cannot update the PPA with the latest Java (and the old links were broken by Oracle).

For this reason, THIS PPA IS DISCONTINUED (unless I find some way around this limitation).

Is it possible to find a solution to this problem?

Thank you.

mvberg commented 5 years ago

@Python-Trading

ah, yes - Oracle's new licensing is wonderful ..

seems the time is now for much needed refactoring of this Docker file - probably should extend from an OpenJDK image at this point.

i will look to check on this before week end.

cc: @krumware

krumware commented 5 years ago

Not a bad call, openjdk has a ton of image options. Here is another I have contributed to recently, for reference of a build with similar needs. https://github.com/carlossg/jenkins-swarm-slave-docker

mvberg commented 5 years ago

Unfortunately, IBController does not like "non oracle" java

https://github.com/ib-controller/ib-controller/blob/99410bd0782e1634bf7f71f198e175841e7ebb21/resources/Scripts/IBController.sh#L369-L376

This issue claims that TWS "doesn't work properly with non-oracle java"

could have been true in the past, but at this point in time i am pretty sure that the Oracle Java is built from OpenJDK sources and then sprinkled with licenses and classpath restrictions or what not.

all that said, none of this may matter, according to the user guide on IBController:

However starting with TWS 952, the TWS installers for Windows and Linux include a hidden version of Java which Interactive Brokers have used for developing and testing TWS. This version also runs IBController perfectly, and the IBController scripts ensure that it is used.

currently, it looks like it gets dropped here /opt/i4j_jres/1.8.0_152

ongoing ....