Skip to content

Commit 4dcb120

Browse files
Dr.SnowbirdDr.Snowbird
authored andcommitted
update to JDK 1.8.201
1 parent e5f0e20 commit 4dcb120

17 files changed

+1068
-148
lines changed

Dockerfile

Lines changed: 103 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,56 +1,70 @@
1-
# ref: https://github.com/dockerfile/java/tree/master/oracle-java8
21

3-
# use the latest LTS Ubuntu
42
FROM ubuntu:bionic
53

64
75

86
ENV DEBIAN_FRONTEND noninteractive
97

8+
########################################
109
##### update ubuntu and Install Python 3
11-
RUN apt-get update \
12-
&& apt-get install -y apt-utils automake pkg-config libpcre3-dev zlib1g-dev liblzma-dev \
13-
&& apt-get install -y curl net-tools build-essential software-properties-common libsqlite3-dev sqlite3 bzip2 libbz2-dev git wget unzip vim python3-pip python3-setuptools python3-dev python3-numpy python3-scipy python3-pandas python3-matplotlib \
14-
&& apt-get clean \
15-
&& rm -rf /var/lib/apt/lists/*
10+
########################################
11+
RUN apt-get update && \
12+
apt-get install -y apt-utils automake pkg-config libpcre3-dev zlib1g-dev liblzma-dev && \
13+
apt-get install -y curl net-tools build-essential software-properties-common libsqlite3-dev sqlite3 bzip2 libbz2-dev git wget unzip vim python3-pip python3-setuptools python3-dev python3-numpy python3-scipy python3-pandas python3-matplotlib && \
14+
apt-get install -y git xz-utils && \
15+
apt-get clean && \
16+
rm -rf /var/lib/apt/lists/*
1617

18+
ENV INSTALL_DIR=${INSTALL_DIR:-/usr}
19+
20+
###################################
1721
#### Install Java 8
22+
###################################
1823
#### ---------------------------------------------------------------
1924
#### ---- Change below when upgrading version ----
2025
#### ---------------------------------------------------------------
26+
## https://download.oracle.com/otn-pub/java/jdk/8u201-b09/42970487e3af4f5aa5bca3f542482c60/jdk-8u201-linux-x64.tar.gz
2127
ARG JAVA_MAJOR_VERSION=${JAVA_MAJOR_VERSION:-8}
22-
ARG JAVA_UPDATE_VERSION=${JAVA_UPDATE_VERSION:-181}
23-
ARG JAVA_BUILD_NUMBER=${JAVA_BUILD_NUMBER:-13}
24-
ARG JAVA_DOWNLOAD_TOKEN=${JAVA_DOWNLOAD_TOKEN:-96a7b8442fe848ef90c96a2fad6ed6d1}
25-
## http://download.oracle.com/otn-pub/java/jdk/8u181-b13/96a7b8442fe848ef90c96a2fad6ed6d1/jdk-8u181-linux-x64.tar.gz
26-
## http://download.oracle.com/otn-pub/java/jdk/8u172-b11/a58eab1ec242421181065cdc37240b08/jdk-8u172-linux-x64.tar.gz
28+
ARG JAVA_UPDATE_VERSION=${JAVA_UPDATE_VERSION:-201}
29+
ARG JAVA_BUILD_NUMBER=${JAVA_BUILD_NUMBER:-09}
30+
ARG JAVA_DOWNLOAD_TOKEN=${JAVA_DOWNLOAD_TOKEN:-42970487e3af4f5aa5bca3f542482c60}
2731

2832
#### ---------------------------------------------------------------
2933
#### ---- Don't change below unless you know what you are doing ----
3034
#### ---------------------------------------------------------------
3135
ARG UPDATE_VERSION=${JAVA_MAJOR_VERSION}u${JAVA_UPDATE_VERSION}
3236
ARG BUILD_VERSION=b${JAVA_BUILD_NUMBER}
3337

34-
ENV JAVA_HOME /usr/jdk1.${JAVA_MAJOR_VERSION}.0_${JAVA_UPDATE_VERSION}
35-
ENV PATH $PATH:$JAVA_HOME/bin
36-
ENV INSTALL_DIR /usr
38+
ENV JAVA_HOME_ACTUAL=${INSTALL_DIR}/jdk1.${JAVA_MAJOR_VERSION}.0_${JAVA_UPDATE_VERSION}
39+
ENV JAVA_HOME=${INSTALL_DIR}/java
40+
41+
ENV PATH=$PATH:${JAVA_HOME}/bin
42+
43+
WORKDIR ${INSTALL_DIR}
3744

3845
RUN curl -sL --retry 3 --insecure \
3946
--header "Cookie: oraclelicense=accept-securebackup-cookie;" \
4047
"http://download.oracle.com/otn-pub/java/jdk/${UPDATE_VERSION}-${BUILD_VERSION}/${JAVA_DOWNLOAD_TOKEN}/jdk-${UPDATE_VERSION}-linux-x64.tar.gz" \
4148
| gunzip \
42-
| tar x -C $INSTALL_DIR/ \
43-
&& ln -s $JAVA_HOME $INSTALL_DIR/java \
44-
&& rm -rf $JAVA_HOME/man
49+
| tar x -C ${INSTALL_DIR}/ \
50+
&& rm -rf jdk-${UPDATE_VERSION}-linux-x64.tar.gz # ${JAVA_HOME_ACTUAL}/man
51+
52+
############################
53+
#### --- JAVA_HOME --- #####
54+
############################
55+
ENV JAVA_HOME=$INSTALL_DIR/java
4556

57+
###################################
4658
#### Install Maven 3
47-
ENV MAVEN_VERSION 3.5.3
48-
ENV MAVEN_HOME /usr/apache-maven-$MAVEN_VERSION
49-
ENV PATH $PATH:$MAVEN_HOME/bin
50-
RUN curl -sL http://archive.apache.org/dist/maven/maven-3/$MAVEN_VERSION/binaries/apache-maven-$MAVEN_VERSION-bin.tar.gz \
59+
###################################ENV MAVEN_VERSION 3.5.3
60+
ARG MAVEN_VERSION=${MAVEN_VERSION:-3.6.0}
61+
ENV MAVEN_VERSION=${MAVEN_VERSION}
62+
ENV MAVEN_HOME=/usr/apache-maven-${MAVEN_VERSION}
63+
ENV PATH=${PATH}:${MAVEN_HOME}/bin
64+
RUN curl -sL http://archive.apache.org/dist/maven/maven-3/${MAVEN_VERSION}/binaries/apache-maven-${MAVEN_VERSION}-bin.tar.gz \
5165
| gunzip \
5266
| tar x -C /usr/ \
53-
&& ln -s $MAVEN_HOME /usr/maven
67+
&& ln -s ${MAVEN_HOME} /usr/maven
5468

5569
###################################
5670
#### ---- Pip install packages ----
@@ -61,9 +75,22 @@ COPY requirements.txt ./
6175
## Don't upgrade pip to 10.0.x version -- it's broken!
6276
## Staying with version 8 to avoid the problem
6377
## ---------------------------------------------------
64-
## RUN pip3 install --upgrade pip \
65-
## && pip3 install -r ./requirements.txt
66-
RUN pip3 install -r ./requirements.txt
78+
79+
RUN pip3 install --upgrade pip
80+
RUN pip3 install -r ./requirements.txt
81+
82+
## VERSIONS ##
83+
ENV PATH=${PATH}:${JAVA_HOME}/bin
84+
85+
RUN ln -s ${JAVA_HOME_ACTUAL} ${JAVA_HOME} && \
86+
ls -al ${INSTALL_DIR} && \
87+
echo "JAVA_HOME=$JAVA_HOME" && \
88+
echo "PATH=${PATH}" && export JAVA_HOME=${JAVA_HOME} && export PATH=$PATH && \
89+
java -version && \
90+
mvn --version && \
91+
python -V && \
92+
python3 -V && \
93+
pip3 --version
6794

6895
## VERSIONS ##
6996
RUN echo "JAVA_HOME=$JAVA_HOME" && \
@@ -73,9 +100,56 @@ RUN echo "JAVA_HOME=$JAVA_HOME" && \
73100
python3 -V && \
74101
pip3 --version
75102

76-
#### define working directory.
77-
RUN mkdir -p /data
78-
COPY . /data
103+
###################################
104+
#### ---- Install Gradle ---- #####
105+
###################################
106+
ARG GRADLE_INSTALL_BASE=${GRADLE_INSTALL_BASE:-/opt/gradle}
107+
ARG GRADLE_VERSION=${GRADLE_VERSION:-5.1.1}
108+
109+
ARG GRADLE_HOME=${GRADLE_INSTALL_BASE}/gradle-${GRADLE_VERSION}
110+
ENV GRADLE_HOME=${GRADLE_HOME}
111+
ARG GRADLE_PACKAGE=gradle-${GRADLE_VERSION}-bin.zip
112+
ARG GRADLE_PACKAGE_URL=https://services.gradle.org/distributions/${GRADLE_PACKAGE}
113+
# https://services.gradle.org/distributions/gradle-5.1.1-bin.zip
114+
RUN mkdir -p ${GRADLE_INSTALL_BASE} && \
115+
cd ${GRADLE_INSTALL_BASE} && \
116+
wget -c ${GRADLE_PACKAGE_URL} && \
117+
unzip -d ${GRADLE_INSTALL_BASE} ${GRADLE_PACKAGE} && \
118+
ls -al ${GRADLE_HOME} && \
119+
ln -s ${GRADLE_HOME}/bin/gradle /usr/bin/gradle && \
120+
${GRADLE_HOME}/bin/gradle -v && \
121+
rm -f ${GRADLE_PACKAGE}
122+
123+
######################################
124+
#### ---- NodeJS from Ubuntu ---- ####
125+
######################################
126+
#RUN apt-get update -y && \
127+
# apt-get install -y git xz-utils && \
128+
# apt-get install -y nodejs npm && \
129+
# npm --version && \
130+
# apt-get install -y gcc g++ make
131+
132+
#########################################
133+
#### ---- Node from NODESOURCES ---- ####
134+
#########################################
135+
# Ref: https://github.com/nodesource/distributions
136+
ARG NODE_VERSION=${NODE_VERSION:-11}
137+
ENV NODE_VERSION=${NODE_VERSION}
138+
RUN apt-get update -y && \
139+
apt-get install -y sudo curl git xz-utils && \
140+
curl -sL https://deb.nodesource.com/setup_${NODE_VERSION}.x | bash - && \
141+
apt-get install -y gcc g++ make && \
142+
apt-get install -y nodejs && \
143+
node -v && npm --version
144+
145+
###################################
146+
#### define working directory. ####
147+
###################################
148+
RUN mkdir -p /data
149+
150+
COPY ./printVersions.sh ./
151+
COPY ./examples /data/examples
152+
COPY ./docker-entrypoint.sh /
79153

80154
VOLUME "/data"
81155

README.md

Lines changed: 63 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
1-
# Ubuntu LTS (bionic) 18.04 + Java 8 (1.8.0_181) JDK + Maven 3.5 + Python 2.7.12/3.5.2 + PIP3 8.1.1
1+
# Ubuntu 18.04.1 LTS (Bionic Beaver) + Java 8 (1.8.0_201) + Maven 3.6 + Python 2.7/3.6 + PIP3 19 + Node 11 + NPM 6
22

33
[![](https://images.microbadger.com/badges/image/openkbs/ubuntu-bionic-ubuntu-bionic-jdk-mvn-py3.svg)](https://microbadger.com/images/openkbs/ubuntu-bionic-ubuntu-bionic-jdk-mvn-py3 "Get your own image badge on microbadger.com") [![](https://images.microbadger.com/badges/version/openkbs/ubuntu-bionic-ubuntu-bionic-jdk-mvn-py3.svg)](https://microbadger.com/images/openkbs/ubuntu-bionic-ubuntu-bionic-jdk-mvn-py3 "Get your own version badge on microbadger.com")
44

55
# Components:
66
* Ubuntu LTS 18.04, bionic-20180724.1, bionic, latest
7-
* java version "1.8.0_181"
8-
Java(TM) SE Runtime Environment (build 1.8.0_181-b13)
9-
Java HotSpot(TM) 64-Bit Server VM (build 25.181-b13, mixed mode)
10-
* Apache Maven 3.5.3
11-
* Python 3.5.2
7+
* java version "1.8.0_201"
8+
Java(TM) SE Runtime Environment (build 1.8.0_201-b09)
9+
Java HotSpot(TM) 64-Bit Server VM (build 25.201-b09, mixed mode)
10+
* Apache Maven 3.6
11+
* Python 3.6
12+
* Node 11 + NPM 6
1213
* Other tools: git wget unzip vim python python-setuptools python-dev python-numpy
1314

1415
## Pull the image from Docker Repository
@@ -136,28 +137,62 @@ For example, try the following Docker-based IDEs:
136137

137138
# Versions
138139
```
139-
Linux f1c21daeac32 4.15.0-29-generic #31~16.04.1-Ubuntu SMP Wed Jul 18 08:54:04 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
140-
No LSB modules are available.
141-
Distributor ID: Ubuntu
142-
Description: Ubuntu 18.04.1 LTS
143-
Release: 18.04
144-
Codename: bionic
145-
146-
JAVA_HOME=/usr/jdk1.8.0_181
147-
java version "1.8.0_181"
148-
Java(TM) SE Runtime Environment (build 1.8.0_181-b13)
149-
Java HotSpot(TM) 64-Bit Server VM (build 25.181-b13, mixed mode)
150-
151-
Apache Maven 3.5.3 (3383c37e1f9e9b3bc3df5050c29c8aff9f295297; 2018-02-24T19:49:05Z)
152-
Maven home: /usr/apache-maven-3.5.3
153-
Java version: 1.8.0_181, vendor: Oracle Corporation
154-
Java home: /usr/jdk1.8.0_181/jre
140+
root@2279085c3b8d:/data# /usr/printVersions.sh
141+
+ echo JAVA_HOME=/usr/java
142+
JAVA_HOME=/usr/java
143+
+ java -version
144+
java version "1.8.0_201"
145+
Java(TM) SE Runtime Environment (build 1.8.0_201-b09)
146+
Java HotSpot(TM) 64-Bit Server VM (build 25.201-b09, mixed mode)
147+
+ mvn --version
148+
Apache Maven 3.6.0 (97c98ec64a1fdfee7767ce5ffb20918da4f719f3; 2018-10-24T18:41:47Z)
149+
Maven home: /usr/apache-maven-3.6.0
150+
Java version: 1.8.0_201, vendor: Oracle Corporation, runtime: /usr/jdk1.8.0_201/jre
155151
Default locale: en_US, platform encoding: ANSI_X3.4-1968
156-
OS name: "linux", version: "4.15.0-29-generic", arch: "amd64", family: "unix"
157-
152+
OS name: "linux", version: "4.15.0-43-generic", arch: "amd64", family: "unix"
153+
+ python -V
158154
Python 2.7.15rc1
159-
160-
Python 3.6.5
161-
162-
pip 9.0.1 from /usr/lib/python3/dist-packages (python 3.6)
155+
+ python3 -V
156+
Python 3.6.7
157+
+ pip --version
158+
pip 19.0.1 from /usr/local/lib/python3.6/dist-packages/pip (python 3.6)
159+
+ pip3 --version
160+
pip 19.0.1 from /usr/local/lib/python3.6/dist-packages/pip (python 3.6)
161+
+ gradle --version
162+
163+
------------------------------------------------------------
164+
Gradle 5.1.1
165+
------------------------------------------------------------
166+
167+
Build time: 2019-01-10 23:05:02 UTC
168+
Revision: 3c9abb645fb83932c44e8610642393ad62116807
169+
170+
Kotlin DSL: 1.1.1
171+
Kotlin: 1.3.11
172+
Groovy: 2.5.4
173+
Ant: Apache Ant(TM) version 1.9.13 compiled on July 10 2018
174+
JVM: 1.8.0_201 (Oracle Corporation 25.201-b09)
175+
OS: Linux 4.15.0-43-generic amd64
176+
177+
+ npm -v
178+
6.5.0
179+
+ node -v
180+
v11.9.0
181+
+ cat /etc/lsb-release /etc/os-release
182+
DISTRIB_ID=Ubuntu
183+
DISTRIB_RELEASE=18.04
184+
DISTRIB_CODENAME=bionic
185+
DISTRIB_DESCRIPTION="Ubuntu 18.04.1 LTS"
186+
NAME="Ubuntu"
187+
VERSION="18.04.1 LTS (Bionic Beaver)"
188+
ID=ubuntu
189+
ID_LIKE=debian
190+
PRETTY_NAME="Ubuntu 18.04.1 LTS"
191+
VERSION_ID="18.04"
192+
HOME_URL="https://www.ubuntu.com/"
193+
SUPPORT_URL="https://help.ubuntu.com/"
194+
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
195+
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
196+
VERSION_CODENAME=bionic
197+
UBUNTU_CODENAME=bionic
163198
```

0 commit comments

Comments
 (0)