Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UnixPb: Install x64 alpine bootjdks where available #2586

Merged
merged 7 commits into from
Jun 14, 2022
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions ansible/docker/Dockerfile.Alpine3
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,15 @@ RUN set -eux; \
rm -rf /ansible; apk del ansible

ENV \
JDK7_BOOT_DIR="/usr/lib/jvm/zulu8" \
JDK8_BOOT_DIR="/usr/lib/jvm/zulu8" \
JDK10_BOOT_DIR="/usr/lib/jvm/zulu11" \
JDK11_BOOT_DIR="/usr/lib/jvm/zulu11" \
JDK7_BOOT_DIR="/usr/lib/jvm/jdk8" \
JDK8_BOOT_DIR="/usr/lib/jvm/jdk8" \
JDK10_BOOT_DIR="/usr/lib/jvm/jdk-11" \
JDK11_BOOT_DIR="/usr/lib/jvm/jdk-11" \
JDK14_BOOT_DIR="/usr/lib/jvm/zulu14" \
JDK15_BOOT_DIR="/usr/lib/jvm/zulu15" \
JDK16_BOOT_DIR="/usr/lib/jvm/zulu16" \
JDK17_BOOT_DIR="/usr/lib/jvm/zulu17" \
JDK17_BOOT_DIR="/usr/lib/jvm/jdk-17" \
JDK18_BOOT_DIR="/usr/lib/jvm/zulu18" \
JDK19_BOOT_DIR="/usr/lib/jvm/zulu18" \
JDKLATEST_BOOT_DIR="/usr/lib/jvm/zulu18" \
JAVA_HOME="/usr/lib/jvm/zulu8"
JAVA_HOME="/usr/lib/jvm/jdk8"
6 changes: 3 additions & 3 deletions ansible/playbooks/AdoptOpenJDK_Unix_Playbook/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
- role: adoptopenjdk_install
jdk_version: 8
when:
- ansible_distribution != "Alpine"
- not (ansible_distribution == "Alpine" and ansible_architecture == "aarch64")
- ansible_architecture != "riscv64"
tags: build_tools
- role: adoptopenjdk_install # JDK11 Build Bootstrap
Expand All @@ -92,7 +92,7 @@
- role: adoptopenjdk_install
jdk_version: 11
when:
- ansible_distribution != "Alpine"
- not (ansible_distribution == "Alpine" and ansible_architecture == "aarch64")
- ansible_distribution != "Solaris"
- ansible_architecture != "riscv64"
tags: build_tools
Expand All @@ -113,7 +113,7 @@
- role: adoptopenjdk_install # JDK18 Build Bootstrap
jdk_version: 17
when:
- ansible_distribution != "Alpine"
- not (ansible_distribution == "Alpine" and ansible_architecture == "aarch64")
- ansible_distribution != "Solaris"
- ansible_architecture != "riscv64"
tags: build_tools
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,51 +50,6 @@
- not zulu7_installed.stat.exists
tags: build_tools

- name: Check if zulu-8 is already installed in the target location
stat: path=/usr/lib/jvm/zulu8
register: zulu8_installed
tags: build_tools
- name: Install latest zulu-8 release if not already installed
unarchive:
src: https://cdn.azul.com/zulu/bin/zulu8.58.0.13-ca-jdk8.0.312-linux_musl_x64.tar.gz
dest: /usr/lib/jvm/
remote_src: yes
when:
- not zulu8_installed.stat.exists
tags: build_tools

- name: Create symlink to point at zulu-8
file:
src: /usr/lib/jvm/zulu8.58.0.13-ca-jdk8.0.312-linux_musl_x64
dest: /usr/lib/jvm/zulu8
state: link
when:
- not zulu8_installed.stat.exists
tags: build_tools

- name: Check if zulu-11 is already installed in the target location
stat: path=/usr/lib/jvm/zulu11
register: zulu11_installed
tags: build_tools

- name: Install latest zulu-11 release if not already installed
unarchive:
src: https://cdn.azul.com/zulu/bin/zulu11.54.25-ca-jdk11.0.14.1-linux_musl_x64.tar.gz
dest: /usr/lib/jvm/
remote_src: yes
when:
- not zulu11_installed.stat.exists
tags: build_tools

- name: Create symlink to point at zulu-11
file:
src: /usr/lib/jvm/zulu11.54.25-ca-jdk11.0.14.1-linux_musl_x64
dest: /usr/lib/jvm/zulu11
state: link
when:
- not zulu11_installed.stat.exists
tags: build_tools

- name: Check if zulu-14 is already installed in the target location
stat: path=/usr/lib/jvm/zulu14
register: zulu14_installed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,20 @@
- adoptopenjdk_installed.rc != 0
tags: adoptopenjdk_install

- name: Install latest release if one not already installed (alpine-linux)
unarchive:
src: https://api.adoptopenjdk.net/v3/binary/latest/{{ jdk_version }}/ga/alpine-linux/{{ api_architecture }}/jdk/{{ bootjdk }}/normal/adoptopenjdk?project=jdk
dest: /usr/lib/jvm
remote_src: yes
retries: 3
delay: 5
register: adoptopenjdk_download
until: adoptopenjdk_download is not failed
when:
- ansible_distribution == "Alpine"
- adoptopenjdk_installed.rc != 0
tags: adoptopenjdk_install

# CentOS6 needs it's own task so it can use a different python interpreter.
# See: https://github.com/adoptium/infrastructure/issues/1877
- name: Install latest release if not already installed (CentOS6)
Expand Down