Skip to content

Commit c14eece

Browse files
committed
Merge branch '4.0.x' into 4.1.x
Closes gh-1926
2 parents 765ad60 + adefb7e commit c14eece

3 files changed

Lines changed: 144 additions & 0 deletions

File tree

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: ensure-cve-issues
2+
3+
# The fix of a CVE that is pushed to a frozen, an active or a long-term support branch of the
4+
# commercial repository (a commit that says `Fixes CVE-2026-1234`, made on the branch or merged into it) gets a
5+
# closed issue, in the milestone of the release that has it. What it does is in the guide of the
6+
# reusable workflow that does it:
7+
#
8+
# https://github.com/spring-io/spring-security-actions/blob/0.0.32/docs/cve-issues.md
9+
#
10+
# The reusable workflow and its actions are in the repository spring-io/spring-security-actions,
11+
# and are called at the commit of a tag.
12+
#
13+
# The embargoed branches, the milestones and the issues of the fixes are only in the commercial
14+
# repository, so it only runs in a repository whose name ends with -commercial: it is skipped in the
15+
# OSS repository, which has this file too. It needs no secret: the issues are written with the token
16+
# of the run.
17+
18+
on:
19+
push:
20+
branches:
21+
- "embargoed/frozen/**"
22+
- "embargoed/active/**"
23+
- "embargoed/lts/**"
24+
25+
permissions:
26+
contents: read
27+
issues: write
28+
29+
jobs:
30+
ensure-cve-issues:
31+
name: Ensure the issues of the CVE fixes
32+
if: ${{ endsWith(github.repository, '-commercial') }}
33+
uses: spring-io/spring-security-actions/.github/workflows/ensure-cve-issues.yml@fb60de7ce6004db5cf697c61f69ab33e61673a47 # 0.0.33
34+
with:
35+
runs-on: ${{ vars.UBUNTU_RUNS_ON }}

‎.github/workflows/post-publish.yml‎

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
name: "Post Publish"
2+
run-name: "${{ inputs.tag || github.ref_name }}: Post Publish${{ github.event_name == 'workflow_dispatch' && inputs.dry-run && ' (dry run)' || '' }}"
3+
4+
# What is done after a release was made public and its tag is pushed (the tag is the release
5+
# version, 7.1.3): its issues are copied to the OSS repository, the tag is merged forward into the
6+
# newer branches, and the branches that were built for the testing and the staging are deleted.
7+
# It runs when a tag of a version is pushed (for real), and by hand with the tag as an input (a dry
8+
# run unless it is unticked). What it does, and the secret that it needs, are in the guide of the
9+
# reusable workflow that does it:
10+
#
11+
# https://github.com/spring-io/spring-security-actions/blob/0.0.32/docs/post-publish.md
12+
#
13+
# The reusable workflow and its actions are in the repository spring-io/spring-security-actions,
14+
# and are called at the commit of a tag.
15+
#
16+
# This file is the same in the OSS repository and in the commercial one: the work is always done
17+
# in the commercial repository, which is the OSS one with -commercial, whichever of the two the tag
18+
# is pushed to. Both repositories need the secret RELEASE_AUTOMATION_TOKEN. The caller has to be in
19+
# the history of the tagged commit, as a tag runs the file of the commit that it points to.
20+
21+
"on":
22+
push:
23+
tags:
24+
- "[0-9]*.[0-9]*.[0-9]*"
25+
workflow_dispatch:
26+
inputs:
27+
tag:
28+
description: "The tag, which is the version of the release, for example 7.1.3"
29+
required: true
30+
type: string
31+
ref:
32+
description: "Dry run only, before the tag exists: a branch or a commit of the commercial repository that stands in for the tag, for example release/7.1.3"
33+
required: false
34+
type: string
35+
dry-run:
36+
description: "Only say what would be done: nothing is copied, pushed or deleted"
37+
default: true
38+
type: boolean
39+
40+
# The reusable workflow has jobs that need more than read access (deploy-docs dispatches a workflow,
41+
# publish-release-notes creates the GitHub release), and a called workflow cannot be given more
42+
# than its caller has: with less, the run fails at startup.
43+
permissions:
44+
actions: write
45+
contents: write
46+
issues: read
47+
pull-requests: read
48+
49+
jobs:
50+
post-publish:
51+
name: Post publish
52+
uses: spring-io/spring-security-actions/.github/workflows/post-publish.yml@fb60de7ce6004db5cf697c61f69ab33e61673a47 # 0.0.33
53+
with:
54+
tag: ${{ inputs.tag || github.ref_name }}
55+
ref: ${{ github.event_name == 'workflow_dispatch' && inputs.ref || '' }}
56+
dry-run: ${{ github.event_name == 'workflow_dispatch' && inputs.dry-run }}
57+
runs-on: ${{ vars.UBUNTU_RUNS_ON }}
58+
secrets:
59+
RELEASE_AUTOMATION_TOKEN: ${{ secrets.RELEASE_AUTOMATION_TOKEN }}
60+
GH_WEBSITE_COMMERCIAL_CONTENT_TOKEN: ${{ secrets.GH_WEBSITE_COMMERCIAL_CONTENT_TOKEN }}
61+
GH_ACTIONS_REPO_TOKEN: ${{ secrets.GH_ACTIONS_REPO_TOKEN }}
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: release-branches
2+
3+
# Every push to an embargoed branch builds the branches of its release, again from the
4+
# pushed commit every time (nobody commits to them): release/<version> and a snapshot
5+
# branch (none for embargoed/lts/**), or for an active embargoed branch the hotfix. Once the
6+
# branches are pushed, the release joins the release train. What it builds, and the secret and
7+
# the variable that it needs, are in the guide of the reusable workflow that does it:
8+
#
9+
# https://github.com/spring-io/spring-security-actions/blob/0.0.32/docs/release-branches.md
10+
#
11+
# The reusable workflow and its actions are in the repository spring-io/spring-security-actions,
12+
# and are called at the commit of a tag.
13+
#
14+
# The embargoed branches only exist in the commercial repository, so this never runs in
15+
# this one. The commercial repository needs the secret RELEASE_AUTOMATION_TOKEN, and may set
16+
# the variable RELEASE_TRAIN_REPOSITORY (spring-io/release-train if it is not set), and the
17+
# variable SNAPSHOT_SUFFIX_OVERRIDES to choose -SNAPSHOT or -INTERNAL-SNAPSHOT for a dependency
18+
# (see the docs of the workflow).
19+
20+
on:
21+
push:
22+
branches:
23+
- "embargoed/frozen/**"
24+
- "embargoed/active/**"
25+
- "embargoed/lts/**"
26+
# Run it by hand on an embargoed branch, for example after the due date of a milestone was set:
27+
# it builds the branches again from the head of the branch, and joins the train if it has not.
28+
workflow_dispatch:
29+
30+
permissions:
31+
contents: read
32+
33+
# One run at a time for a branch, and the newest wins: a run only pushes at the very end,
34+
# once, and what it creates on the way (the issues) is found again by the next run.
35+
concurrency:
36+
group: release-branches-${{ github.ref }}
37+
cancel-in-progress: true
38+
39+
jobs:
40+
release-branches:
41+
name: Build the branches
42+
uses: spring-io/spring-security-actions/.github/workflows/release-branches.yml@fb60de7ce6004db5cf697c61f69ab33e61673a47 # 0.0.33
43+
with:
44+
runs-on: ${{ vars.UBUNTU_RUNS_ON }}
45+
release-train-repository: ${{ vars.RELEASE_TRAIN_REPOSITORY }}
46+
snapshot-suffix-overrides: ${{ vars.SNAPSHOT_SUFFIX_OVERRIDES }}
47+
secrets:
48+
RELEASE_AUTOMATION_TOKEN: ${{ secrets.RELEASE_AUTOMATION_TOKEN }}

0 commit comments

Comments
 (0)