Skip to content

Commit

Permalink
workflows: 3.2 release from master support
Browse files Browse the repository at this point in the history
Signed-off-by: Patrick Stephens <[email protected]>
  • Loading branch information
patrick-stephens committed Sep 30, 2024
1 parent b3475eb commit 1132f15
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 26 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/cron-unstable-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ on:
schedule:
- cron: "0 6 * * *" # master build
- cron: "0 12 * * *" # 3.0 build
- cron: "0 18 * * *" # 3.1 build

# We do not want a new unstable build to run whilst we are releasing the current unstable build.
concurrency: unstable-build-release
Expand Down Expand Up @@ -57,6 +58,12 @@ jobs:
echo "cron_branch=3.0" >> $GITHUB_ENV
shell: bash

- name: 3.1 run
if: github.event_name == 'schedule' && github.event.schedule=='0 18 * * *'
run: |
echo "cron_branch=3.1" >> $GITHUB_ENV
shell: bash

- name: Output the branch to use
id: branch
run: |
Expand Down
51 changes: 25 additions & 26 deletions .github/workflows/staging-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -502,9 +502,8 @@ jobs:
TAG: ${{ steps.get-tag.outputs.tag }}

staging-release-images-latest-tags:
# Only update latest tags for 3.1 releases
if: startsWith(github.event.inputs.version, '3.1')
# if: startsWith(github.event.inputs.version, '4.0')
# Only update latest tags for 3.2 releases
if: startsWith(github.event.inputs.version, '3.2')
name: Release latest Linux container images
runs-on: ubuntu-latest
needs:
Expand Down Expand Up @@ -804,8 +803,7 @@ jobs:
target_commitish: '3.0'
make_latest: false

- name: Release 3.1 and latest
# TODO: change to 3.1 branch once 4.0 series is ready
- name: Release 3.1 - not latest
uses: softprops/action-gh-release@v2
if: startsWith(inputs.version, '3.1')
with:
Expand All @@ -814,18 +812,19 @@ jobs:
generate_release_notes: true
name: "Fluent Bit ${{ inputs.version }}"
tag_name: v${{ inputs.version }}
make_latest: true
target_commitish: '3.1'
make_latest: false

# - name: Release 4.0 and latest
# uses: softprops/action-gh-release@v2
# if: startsWith(inputs.version, '4.0')
# with:
# body: "https://fluentbit.io/announcements/v${{ inputs.version }}/"
# draft: false
# generate_release_notes: true
# name: "Fluent Bit ${{ inputs.version }}"
# tag_name: v${{ inputs.version }}
# make_latest: true
- name: Release 3.2 and latest
uses: softprops/action-gh-release@v2
if: startsWith(inputs.version, '3.2')
with:
body: "https://fluentbit.io/announcements/v${{ inputs.version }}/"
draft: false
generate_release_notes: true
name: "Fluent Bit ${{ inputs.version }}"
tag_name: v${{ inputs.version }}
make_latest: true

staging-release-windows-checksums:
name: Get Windows checksums for new release
Expand Down Expand Up @@ -919,20 +918,20 @@ jobs:
ref: 3.0
token: ${{ secrets.GH_PA_TOKEN }}

- name: Release 3.1 and latest
# TODO: change to 3.1 branch once 4.0 series is ready
- name: Release 3.1 - not latest
if: startsWith(inputs.version, '3.1')
uses: actions/checkout@v4
with:
repository: fluent/fluent-bit-docs
ref: 3.1
token: ${{ secrets.GH_PA_TOKEN }}

# - name: Release 4.0 and latest
# if: startsWith(inputs.version, '4.0')
# uses: actions/checkout@v4
# with:
# repository: fluent/fluent-bit-docs
# token: ${{ secrets.GH_PA_TOKEN }}
- name: Release 3.2 and latest
if: startsWith(inputs.version, '3.2')
uses: actions/checkout@v4
with:
repository: fluent/fluent-bit-docs
token: ${{ secrets.GH_PA_TOKEN }}

- name: Ensure we have the script we need
run: |
Expand Down Expand Up @@ -1018,8 +1017,8 @@ jobs:
with:
ref: 3.1

- name: Release 4.0
if: startsWith(inputs.version, '4.0')
- name: Release 3.2
if: startsWith(inputs.version, '3.2')
uses: actions/checkout@v4
with:
ref: master
Expand Down

0 comments on commit 1132f15

Please sign in to comment.