mirror of
https://gitee.com/dcren/initializr.git
synced 2025-08-20 09:28:57 +08:00
Build against Java 17
See gh-1342
This commit is contained in:
parent
ac16ddc8f5
commit
d88285934c
@ -77,7 +77,7 @@ The `initializr-service-sample` showcases a basic custom instance with dedicated
|
|||||||
|
|
||||||
[[build]]
|
[[build]]
|
||||||
== Building from Source
|
== Building from Source
|
||||||
You need Java 1.8 and a bash-like shell.
|
You need Java 17 and a bash-like shell.
|
||||||
|
|
||||||
[[building]]
|
[[building]]
|
||||||
=== Building
|
=== Building
|
||||||
|
|||||||
@ -1,8 +0,0 @@
|
|||||||
FROM ubuntu:focal-20220922
|
|
||||||
|
|
||||||
ADD setup.sh /setup.sh
|
|
||||||
ADD get-jdk-url.sh /get-jdk-url.sh
|
|
||||||
RUN ./setup.sh java11
|
|
||||||
|
|
||||||
ENV JAVA_HOME /opt/openjdk
|
|
||||||
ENV PATH $JAVA_HOME/bin:$PATH
|
|
||||||
@ -1,8 +0,0 @@
|
|||||||
FROM ubuntu:focal-20220922
|
|
||||||
|
|
||||||
ADD setup.sh /setup.sh
|
|
||||||
ADD get-jdk-url.sh /get-jdk-url.sh
|
|
||||||
RUN ./setup.sh java17
|
|
||||||
|
|
||||||
ENV JAVA_HOME /opt/openjdk
|
|
||||||
ENV PATH $JAVA_HOME/bin:$PATH
|
|
||||||
@ -2,7 +2,7 @@ FROM ubuntu:focal-20220922
|
|||||||
|
|
||||||
ADD setup.sh /setup.sh
|
ADD setup.sh /setup.sh
|
||||||
ADD get-jdk-url.sh /get-jdk-url.sh
|
ADD get-jdk-url.sh /get-jdk-url.sh
|
||||||
RUN ./setup.sh java8
|
RUN ./setup.sh java17
|
||||||
|
|
||||||
ENV JAVA_HOME /opt/openjdk
|
ENV JAVA_HOME /opt/openjdk
|
||||||
ENV PATH $JAVA_HOME/bin:$PATH
|
ENV PATH $JAVA_HOME/bin:$PATH
|
||||||
@ -2,12 +2,6 @@
|
|||||||
set -e
|
set -e
|
||||||
|
|
||||||
case "$1" in
|
case "$1" in
|
||||||
java8)
|
|
||||||
echo "https://github.com/bell-sw/Liberica/releases/download/8u345+1/bellsoft-jdk8u345+1-linux-amd64.tar.gz"
|
|
||||||
;;
|
|
||||||
java11)
|
|
||||||
echo "https://github.com/bell-sw/Liberica/releases/download/11.0.16.1+1/bellsoft-jdk11.0.16.1+1-linux-amd64.tar.gz"
|
|
||||||
;;
|
|
||||||
java17)
|
java17)
|
||||||
echo "https://github.com/bell-sw/Liberica/releases/download/17.0.4.1+1/bellsoft-jdk17.0.4.1+1-linux-amd64.tar.gz"
|
echo "https://github.com/bell-sw/Liberica/releases/download/17.0.4.1+1/bellsoft-jdk17.0.4.1+1-linux-amd64.tar.gz"
|
||||||
;;
|
;;
|
||||||
|
|||||||
104
ci/pipeline.yml
104
ci/pipeline.yml
@ -121,18 +121,6 @@ resources:
|
|||||||
source:
|
source:
|
||||||
<<: *registry-image-resource-source
|
<<: *registry-image-resource-source
|
||||||
repository: ((docker-hub-organization))/initializr-ci
|
repository: ((docker-hub-organization))/initializr-ci
|
||||||
- name: ci-image-jdk11
|
|
||||||
type: registry-image
|
|
||||||
icon: docker
|
|
||||||
source:
|
|
||||||
<<: *registry-image-resource-source
|
|
||||||
repository: ((docker-hub-organization))/initializr-ci-jdk11
|
|
||||||
- name: ci-image-jdk17
|
|
||||||
type: registry-image
|
|
||||||
icon: docker
|
|
||||||
source:
|
|
||||||
<<: *registry-image-resource-source
|
|
||||||
repository: ((docker-hub-organization))/initializr-ci-jdk17
|
|
||||||
- name: artifactory-repo
|
- name: artifactory-repo
|
||||||
type: artifactory-resource
|
type: artifactory-resource
|
||||||
icon: package-variant
|
icon: package-variant
|
||||||
@ -149,22 +137,6 @@ resources:
|
|||||||
access_token: ((github-ci-status-token))
|
access_token: ((github-ci-status-token))
|
||||||
branch: ((branch))
|
branch: ((branch))
|
||||||
context: build
|
context: build
|
||||||
- name: repo-status-jdk11-build
|
|
||||||
type: github-status-resource
|
|
||||||
icon: eye-check-outline
|
|
||||||
source:
|
|
||||||
repository: ((github-repo-name))
|
|
||||||
access_token: ((github-ci-status-token))
|
|
||||||
branch: ((branch))
|
|
||||||
context: jdk11-build
|
|
||||||
- name: repo-status-jdk17-build
|
|
||||||
type: github-status-resource
|
|
||||||
icon: eye-check-outline
|
|
||||||
source:
|
|
||||||
repository: ((github-repo-name))
|
|
||||||
access_token: ((github-ci-status-token))
|
|
||||||
branch: ((branch))
|
|
||||||
context: jdk17-build
|
|
||||||
- name: slack-alert
|
- name: slack-alert
|
||||||
type: slack-notification
|
type: slack-notification
|
||||||
icon: slack
|
icon: slack
|
||||||
@ -189,32 +161,10 @@ jobs:
|
|||||||
vars:
|
vars:
|
||||||
ci-image-name: ci-image
|
ci-image-name: ci-image
|
||||||
<<: *registry-mirror-vars
|
<<: *registry-mirror-vars
|
||||||
- task: build-ci-image-jdk11
|
|
||||||
privileged: true
|
|
||||||
file: git-repo/ci/tasks/build-ci-image.yml
|
|
||||||
output_mapping:
|
|
||||||
image: ci-image-jdk11
|
|
||||||
vars:
|
|
||||||
ci-image-name: ci-image-jdk11
|
|
||||||
<<: *registry-mirror-vars
|
|
||||||
- task: build-ci-image-jdk17
|
|
||||||
privileged: true
|
|
||||||
file: git-repo/ci/tasks/build-ci-image.yml
|
|
||||||
output_mapping:
|
|
||||||
image: ci-image-jdk17
|
|
||||||
vars:
|
|
||||||
ci-image-name: ci-image-jdk17
|
|
||||||
<<: *registry-mirror-vars
|
|
||||||
- in_parallel:
|
- in_parallel:
|
||||||
- put: ci-image
|
- put: ci-image
|
||||||
params:
|
params:
|
||||||
image: ci-image/image.tar
|
image: ci-image/image.tar
|
||||||
- put: ci-image-jdk11
|
|
||||||
params:
|
|
||||||
image: ci-image-jdk11/image.tar
|
|
||||||
- put: ci-image-jdk17
|
|
||||||
params:
|
|
||||||
image: ci-image-jdk17/image.tar
|
|
||||||
- name: build
|
- name: build
|
||||||
serial: true
|
serial: true
|
||||||
public: true
|
public: true
|
||||||
@ -248,58 +198,6 @@ jobs:
|
|||||||
- put: slack-alert
|
- put: slack-alert
|
||||||
params:
|
params:
|
||||||
<<: *slack-success-params
|
<<: *slack-success-params
|
||||||
- name: jdk11-build
|
|
||||||
serial: true
|
|
||||||
public: true
|
|
||||||
plan:
|
|
||||||
- get: ci-image-jdk11
|
|
||||||
- get: git-repo
|
|
||||||
- get: daily
|
|
||||||
trigger: true
|
|
||||||
- put: repo-status-jdk11-build
|
|
||||||
params: { state: "pending", commit: "git-repo" }
|
|
||||||
- do:
|
|
||||||
- task: build-project
|
|
||||||
image: ci-image-jdk11
|
|
||||||
<<: *build-project-task-params
|
|
||||||
on_failure:
|
|
||||||
do:
|
|
||||||
- put: repo-status-jdk11-build
|
|
||||||
params: { state: "failure", commit: "git-repo" }
|
|
||||||
- put: slack-alert
|
|
||||||
params:
|
|
||||||
<<: *slack-fail-params
|
|
||||||
- put: repo-status-jdk11-build
|
|
||||||
params: { state: "success", commit: "git-repo" }
|
|
||||||
- put: slack-alert
|
|
||||||
params:
|
|
||||||
<<: *slack-success-params
|
|
||||||
- name: jdk17-build
|
|
||||||
serial: true
|
|
||||||
public: true
|
|
||||||
plan:
|
|
||||||
- get: ci-image-jdk17
|
|
||||||
- get: git-repo
|
|
||||||
- get: daily
|
|
||||||
trigger: true
|
|
||||||
- put: repo-status-jdk17-build
|
|
||||||
params: { state: "pending", commit: "git-repo" }
|
|
||||||
- do:
|
|
||||||
- task: build-project
|
|
||||||
image: ci-image-jdk17
|
|
||||||
<<: *build-project-task-params
|
|
||||||
on_failure:
|
|
||||||
do:
|
|
||||||
- put: repo-status-jdk17-build
|
|
||||||
params: { state: "failure", commit: "git-repo" }
|
|
||||||
- put: slack-alert
|
|
||||||
params:
|
|
||||||
<<: *slack-fail-params
|
|
||||||
- put: repo-status-jdk17-build
|
|
||||||
params: { state: "success", commit: "git-repo" }
|
|
||||||
- put: slack-alert
|
|
||||||
params:
|
|
||||||
<<: *slack-success-params
|
|
||||||
- name: build-pull-requests
|
- name: build-pull-requests
|
||||||
serial: true
|
serial: true
|
||||||
public: true
|
public: true
|
||||||
@ -413,7 +311,7 @@ jobs:
|
|||||||
body: generated-changelog/changelog.md
|
body: generated-changelog/changelog.md
|
||||||
groups:
|
groups:
|
||||||
- name: "build"
|
- name: "build"
|
||||||
jobs: ["build", "jdk11-build", "jdk17-build", "windows-build"]
|
jobs: ["build", "windows-build"]
|
||||||
- name: "releases"
|
- name: "releases"
|
||||||
jobs: ["stage-release", "promote-release", "create-github-release"]
|
jobs: ["stage-release", "promote-release", "create-github-release"]
|
||||||
- name: "ci-images"
|
- name: "ci-images"
|
||||||
|
|||||||
@ -14,7 +14,7 @@
|
|||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<main.basedir>${basedir}/..</main.basedir>
|
<main.basedir>${basedir}/..</main.basedir>
|
||||||
<java.version>1.8</java.version>
|
<java.version>17</java.version>
|
||||||
<commons-compress.version>1.21</commons-compress.version>
|
<commons-compress.version>1.21</commons-compress.version>
|
||||||
<commons-text.version>1.10.0</commons-text.version>
|
<commons-text.version>1.10.0</commons-text.version>
|
||||||
<maven-resolver.version>1.7.3</maven-resolver.version>
|
<maven-resolver.version>1.7.3</maven-resolver.version>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user