Skip to content
This repository has been archived by the owner on Mar 30, 2023. It is now read-only.

Commit

Permalink
Patch oracle-java8-installer package (#182)
Browse files Browse the repository at this point in the history
* Patch java8 package to 8u172

The apt package oracle-java8-installer attempts to download Java 8u161 which
is no longer available on the Oracle site. This commit temporarily patches
the package to update the Java version to 8u172
  • Loading branch information
russcam committed Apr 18, 2018
1 parent 7761e57 commit e89baf2
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion src/scripts/elasticsearch-ubuntu-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -285,9 +285,21 @@ check_data_disk()
fi
}

# Update the oracle-java8-installer to patch download of Java 8u161 to 8u172.
# 8u161 is no longer available for download.
# TODO: Remove this once oracle-java8-installer package is updated
install_java_package()
{
apt-get -yq $@ install oracle-java8-installer
apt-get -yq $@ install oracle-java8-installer || true \
&& pushd /var/lib/dpkg/info \
&& log "[install_java_package] Update oracle-java8-installer to 8u172" \
&& sed -i 's|JAVA_VERSION=8u161|JAVA_VERSION=8u172|' oracle-java8-installer.* \
&& sed -i 's|PARTNER_URL=http://download.oracle.com/otn-pub/java/jdk/8u161-b12/2f38c3b165be4555a1fa6e98c45e0808/|PARTNER_URL=http://download.oracle.com/otn-pub/java/jdk/8u172-b11/a58eab1ec242421181065cdc37240b08/|' oracle-java8-installer.* \
&& sed -i 's|SHA256SUM_TGZ="6dbc56a0e3310b69e91bb64db63a485bd7b6a8083f08e48047276380a0e2021e"|SHA256SUM_TGZ="28a00b9400b6913563553e09e8024c286b506d8523334c93ddec6c9ec7e9d346"|' oracle-java8-installer.* \
&& sed -i 's|J_DIR=jdk1.8.0_161|J_DIR=jdk1.8.0_172|' oracle-java8-installer.* \
&& popd \
&& log "[install_java_package] Updated oracle-java8-installer" \
&& apt-get -yq $@ install oracle-java8-installer
}

# Install Oracle Java
Expand Down

0 comments on commit e89baf2

Please sign in to comment.