Skip to content

Commit 6ce7183

Browse files
Update release (helidon-io#9210)
1 parent 9aa5681 commit 6ce7183

34 files changed

Lines changed: 992 additions & 514 deletions

.github/actions/common/action.yml

Lines changed: 2 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -33,18 +33,6 @@ inputs:
3333
description: Build cache id
3434
required: false
3535
default: 'default'
36-
GPG_PASSPHRASE:
37-
description: Value of the GPG_PASSPHRASE environment variable
38-
required: false
39-
default: ''
40-
GPG_PRIVATE_KEY:
41-
description: Value of the GPG_PRIVATE_KEY environment variable
42-
required: false
43-
default: ''
44-
MAVEN_SETTINGS:
45-
description: Value of the MAVEN_SETTINGS environment variable
46-
required: false
47-
default: ''
4836
run:
4937
description: The bash command to run
5038
required: true
@@ -147,13 +135,9 @@ runs:
147135
build-cache-${{ github.run_id }}-
148136
- name: Exec
149137
env:
150-
GPG_PASSPHRASE: ${{ inputs.GPG_PASSPHRASE }}
151-
GPG_PRIVATE_KEY: ${{ inputs.GPG_PRIVATE_KEY }}
152-
MAVEN_SETTINGS: ${{ inputs.MAVEN_SETTINGS }}
153138
MAVEN_ARGS: |
154139
${{ env.MAVEN_ARGS }}
155140
-Dmaven.repo.local=${{ github.workspace }}/.m2/repository
156-
-Dcache.record=${{ inputs.build-cache == 'read-write' }}
157141
run: ${{ inputs.run }}
158142
shell: bash
159143
- name: Archive test results
@@ -164,8 +148,8 @@ runs:
164148
if-no-files-found: 'ignore'
165149
name: ${{ inputs.test-artifact-name }}
166150
path: |
167-
**/target/surefire-reports/*.txt
168-
**/target/failsafe-reports/*.txt
151+
**/target/surefire-reports/**
152+
**/target/failsafe-reports/**
169153
**/target/it/**/*.log
170154
- name: Archive artifacts
171155
if: ${{ inputs.artifact-name != '' && inputs.artifact-path != '' && always() }}

.github/workflows/assign-issue-to-project.yml

Lines changed: 0 additions & 17 deletions
This file was deleted.

.github/workflows/assign-issue.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
#
2+
# Copyright (c) 2021, 2024 Oracle and/or its affiliates.
3+
#
4+
# Licensed under the Apache License, Version 2.0 (the "License");
5+
# you may not use this file except in compliance with the License.
6+
# You may obtain a copy of the License at
7+
#
8+
# http://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
16+
name: Assign Issue to Project
17+
18+
#on:
19+
# issues:
20+
# types: [opened, reopened]
21+
#env:
22+
# GITHUB_API_KEY: ${{ secrets.GITHUB_TOKEN }}
23+
24+
jobs:
25+
Assign-Issue-To-Backlog:
26+
runs-on: ubuntu-latest
27+
steps:
28+
- name: Check out repository code
29+
uses: actions/checkout@v4
30+
- run: etc/scripts/assign-issue.sh $GITHUB_REPOSITORY ${{ github.event.issue.number }} Backlog Triage
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
#
2+
# Copyright (c) 2022, 2024 Oracle and/or its affiliates.
3+
#
4+
# Licensed under the Apache License, Version 2.0 (the "License");
5+
# you may not use this file except in compliance with the License.
6+
# You may obtain a copy of the License at
7+
#
8+
# http://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
16+
name: Create Backport Issues
17+
18+
on:
19+
workflow_dispatch:
20+
inputs:
21+
issue:
22+
description: 'Issue number'
23+
required: true
24+
version:
25+
description: 'Helidon version this issue was reported for'
26+
required: true
27+
type: choice
28+
options:
29+
- 2.x
30+
- 3.x
31+
- 4.x
32+
default: '2.x'
33+
target-2:
34+
type: boolean
35+
description: 'Port to 2.x?'
36+
default: false
37+
target-3:
38+
type: boolean
39+
description: 'Port to 3.x?'
40+
default: true
41+
target-4:
42+
type: boolean
43+
description: 'Port to 4.x?'
44+
default: true
45+
46+
env:
47+
GITHUB_API_KEY: ${{ secrets.GITHUB_TOKEN }}
48+
49+
50+
jobs:
51+
Issue-Backport:
52+
runs-on: ubuntu-latest
53+
steps:
54+
- name: Check out repository code
55+
uses: actions/checkout@v4
56+
- run: etc/scripts/backport-issues.sh $GITHUB_REPOSITORY ${{ github.event.inputs.issue }} ${{ github.event.inputs.version }} ${{ github.event.inputs.target-2 }} ${{ github.event.inputs.target-3 }} ${{ github.event.inputs.target-4 }}

.github/workflows/create-backport-issues.yml

Lines changed: 0 additions & 41 deletions
This file was deleted.

.github/workflows/pr-merge.yaml

Lines changed: 0 additions & 22 deletions
This file was deleted.

.github/workflows/release.yaml

Lines changed: 87 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,66 +1,117 @@
1-
# Notes
2-
# - cannot run on Windows, as we use shell scripts
1+
#
2+
# Copyright (c) 2023, 2024 Oracle and/or its affiliates.
3+
#
4+
# Licensed under the Apache License, Version 2.0 (the "License");
5+
# you may not use this file except in compliance with the License.
6+
# You may obtain a copy of the License at
7+
#
8+
# http://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
315

416
name: "Release"
517

618
on:
719
push:
8-
branches:
9-
- 'release-*'
20+
branches: [ 'release-*' ]
21+
1022
env:
1123
JAVA_VERSION: '21'
1224
JAVA_DISTRO: 'oracle'
13-
MAVEN_HTTP_ARGS: '-Dmaven.wagon.httpconnectionManager.ttlSeconds=60 -Dmaven.wagon.http.retryHandler.count=3'
25+
MAVEN_ARGS: |
26+
-B -e
27+
-Dmaven.wagon.httpconnectionManager.ttlSeconds=60
28+
-Dmaven.wagon.http.retryHandler.count=3
29+
-Djdk.toolchain.version=${JAVA_VERSION}
30+
-Dcache.enabled=true
1431
1532
concurrency:
1633
group: release-${{ github.workflow }}-${{ github.ref }}
1734
cancel-in-progress: true
1835

1936
jobs:
20-
copyright:
21-
timeout-minutes: 10
37+
create-tag:
2238
runs-on: ubuntu-20.04
39+
environment: release
40+
outputs:
41+
version: ${{ steps.create-tag.outputs.version }}
42+
tag: ${{ steps.create-tag.outputs.tag }}
2343
steps:
2444
- uses: actions/checkout@v4
2545
with:
26-
fetch-depth: 0
27-
- name: Set up JDK ${{ env.JAVA_VERSION }}
28-
uses: actions/setup-java@v4.1.0
29-
with:
30-
distribution: ${{ env.JAVA_DISTRO }}
31-
java-version: ${{ env.JAVA_VERSION }}
32-
cache: maven
33-
- name: Copyright
34-
run: etc/scripts/copyright.sh
35-
release:
36-
timeout-minutes: 60
46+
fetch-depth: '0'
47+
token: ${{ secrets.SERVICE_ACCOUNT_TOKEN }}
48+
- id: create-tag
49+
run: ./etc/scripts/release.sh create_tag >> "${GITHUB_OUTPUT}"
50+
validate:
51+
needs: create-tag
52+
uses: ./.github/workflows/validate.yml
53+
with:
54+
ref: ${{ needs.create-tag.outputs.tag }}
55+
stage:
56+
needs: [ create-tag, validate ]
57+
strategy:
58+
matrix:
59+
moduleSet: [ core, integrations, others ]
3760
runs-on: ubuntu-20.04
61+
timeout-minutes: 30
3862
environment: release
3963
steps:
4064
- uses: actions/checkout@v4
4165
with:
42-
token: ${{ secrets.SERVICE_ACCOUNT_TOKEN }}
4366
fetch-depth: '0'
44-
- name: Set up JDK ${{ env.JAVA_VERSION }}
45-
uses: actions/setup-java@v4.1.0
67+
ref: ${{ needs.create-tag.outputs.tag }}
68+
- uses: actions/download-artifact@v4
4669
with:
47-
distribution: ${{ env.JAVA_DISTRO }}
48-
java-version: ${{ env.JAVA_VERSION }}
49-
cache: maven
50-
- name: Release
70+
pattern: "{javadoc-jars-${{ matrix.moduleSet }},docs}"
71+
merge-multiple: true
72+
- shell: bash
5173
env:
5274
GPG_PASSPHRASE: ${{ secrets.HELIDON_GPG_PASSPHRASE }}
5375
GPG_PRIVATE_KEY: ${{ secrets.HELIDON_GPG_PRIVATE_KEY }}
54-
GPG_PUBLIC_KEY: ${{ secrets.HELIDON_GPG_PUBLIC_KEY }}
55-
MAVEN_SETTINGS: ${{ secrets.MAVEN_SETTINGS }}
56-
RELEASE_WORKFLOW: "true"
76+
run: etc/scripts/setup-gpg.sh
77+
- uses: ./.github/actions/common
78+
with:
79+
build-cache: read-only
80+
artifact-name: io-helidon-artifacts-part-${{ matrix.moduleSet }}
81+
artifact-path: staging
82+
run: |
83+
mvn ${MAVEN_ARGS} \
84+
-DreactorRule=default \
85+
-DmoduleSet=${{ matrix.moduleSet }} \
86+
-Dcache.loadSuffixes=javadoc,docs \
87+
-Prelease,no-snapshots \
88+
-DskipTests \
89+
-DaltDeploymentRepository=":::file://${PWD}/staging" \
90+
deploy
91+
deploy:
92+
needs: [ create-tag, stage ]
93+
runs-on: ubuntu-24.04
94+
timeout-minutes: 20
95+
environment: release
96+
steps:
97+
- uses: actions/checkout@v4
98+
with:
99+
fetch-depth: '0'
100+
ref: ${{ needs.create-tag.outputs.tag }}
101+
- uses: actions/download-artifact@v4
102+
with:
103+
pattern: io-helidon-artifacts-part-*
104+
path: staging
105+
merge-multiple: true
106+
- shell: bash
107+
env:
108+
NEXUS_USER: ${{ secrets.NEXUS_USER }}
109+
NEXUS_PASSWORD: ${{ secrets.NEXUS_PASSWORD }}
57110
run: |
58-
git config user.email "helidon-robot_ww@oracle.com"
59-
git config user.name "Helidon Robot"
60-
etc/scripts/release.sh release_build
61-
- name: Upload Staged Artifacts
62-
uses: actions/upload-artifact@v4
111+
etc/scripts/nexus.sh deploy_release \
112+
--dir="staging" \
113+
--description="Helidon v%{version}"
114+
- uses: actions/upload-artifact@v4
63115
with:
64-
name: io-helidon-artifacts-${{ github.ref_name }}
65-
path: parent/target/nexus-staging/
66-
retention-days: 90
116+
name: io-helidon-artifacts-${{ needs.create-tag.outputs.version }}
117+
path: staging

0 commit comments

Comments
 (0)