Skip to content

Commit 7a2b083

Browse files
committed
BUILD/MINOR: update latest branch and doc.yaml source for docker releases
Update the GitHub Actions workflows for Docker manual and auto releases to align with the current branching strategy: - Change the fallback LATEST_BRANCH value from "dev" to "1.0". - Fetch doc.yaml from the "dev" branch instead of "master" to accurately determine the active version.
1 parent a410bf9 commit 7a2b083

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

.github/workflows/docker_auto_release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
env:
1313
DOCKER_PLATFORMS: linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64
1414
DOCKER_IMAGE: haproxytech/haproxy-unified-gateway
15-
LATEST_BRANCH: "dev"
15+
LATEST_BRANCH: "1.0"
1616
steps:
1717
- name: Login to Docker Hub
1818
id: login_docker
@@ -50,7 +50,7 @@ jobs:
5050
echo "BUILD_DATE=$(date +'%Y-%m-%d %H:%M:%S')" >> $GITHUB_ENV
5151
echo "GIT_SHA=$(git rev-parse --short HEAD | cut -c1-7)" >> $GITHUB_ENV
5252
echo "GIT_REF=$(git symbolic-ref -q --short HEAD || git describe --tags --exact-match)" >> $GITHUB_ENV
53-
echo "LATEST_BRANCH=$(curl -sfSL 'https://raw.githubusercontent.com/haproxytech/haproxy-unified-gateway/master/documentation/doc.yaml' 2>/dev/null | awk -F: '/^active_version/ {gsub(/^ /,"",$2); print $2}' || echo $LATEST_BRANCH)" >> $GITHUB_ENV
53+
echo "LATEST_BRANCH=$(curl -sfSL 'https://raw.githubusercontent.com/haproxytech/haproxy-unified-gateway/dev/documentation/doc.yaml' 2>/dev/null | awk -F: '/^active_version/ {gsub(/^ /,"",$2); print $2}' || echo $LATEST_BRANCH)" >> $GITHUB_ENV
5454
5555
- name: Build and push latest stable branch
5656
if: ${{ env.BUILD_BRANCH == env.LATEST_BRANCH }}

.github/workflows/docker_manual_release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
env:
1111
DOCKER_PLATFORMS: linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64
1212
DOCKER_IMAGE: haproxytech/haproxy-unified-gateway
13-
LATEST_BRANCH: "dev"
13+
LATEST_BRANCH: "1.0"
1414
steps:
1515
- name: Login to Docker Hub
1616
id: login_docker
@@ -52,7 +52,7 @@ jobs:
5252
echo "BUILD_DATE=$(date +'%Y-%m-%d %H:%M:%S')" >> $GITHUB_ENV
5353
echo "GIT_SHA=$(git rev-parse --short HEAD | cut -c1-7)" >> $GITHUB_ENV
5454
echo "GIT_REF=$(git symbolic-ref -q --short HEAD || git describe --tags --exact-match)" >> $GITHUB_ENV
55-
echo "LATEST_BRANCH=$(curl -sfSL 'https://raw.githubusercontent.com/haproxytech/haproxy-unified-gateway/master/documentation/doc.yaml' 2>/dev/null | awk -F: '/^active_version/ {gsub(/^ /,"",$2); print $2}' || echo $LATEST_BRANCH)" >> $GITHUB_ENV
55+
echo "LATEST_BRANCH=$(curl -sfSL 'https://raw.githubusercontent.com/haproxytech/haproxy-unified-gateway/dev/documentation/doc.yaml' 2>/dev/null | awk -F: '/^active_version/ {gsub(/^ /,"",$2); print $2}' || echo $LATEST_BRANCH)" >> $GITHUB_ENV
5656
5757
- name: Build and push latest stable branch
5858
if: ${{ env.BUILD_BRANCH == env.LATEST_BRANCH }}

0 commit comments

Comments
 (0)