Skip to content

Commit

Permalink
Merge pull request #25 from spectrocloud/ci-edge
Browse files Browse the repository at this point in the history
ci: add edge release workflow
  • Loading branch information
nianyush authored Jan 28, 2025
2 parents 0a64fd0 + 958cdf5 commit 6dfd135
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 2 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/edge-release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Edge Release

on:
workflow_dispatch:

permissions:
contents: write

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
release:
runs-on: ubuntu-22.04
strategy:
matrix:
fips: [yes, no]
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
ref: ${{ github.ref }}
- name: Set up QEMU
uses: docker/setup-qemu-action@master
with:
platforms: all
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@master
- run: echo "${{ secrets.ARTIFACT_IMG_PUSH_EDGE }}" | base64 -d | docker login -u _json_key --password-stdin us-docker.pkg.dev
- name: Build artifacts
env:
FIPS_ENABLE: ${{ matrix.fips }}
run: |
if [ ${{ matrix.fips }} = "yes" ]; then
export REPOSITORY=us-docker.pkg.dev/palette-images-fips/edge
else
export REPOSITORY=us-docker.pkg.dev/palette-images/edge
fi
make docker
3 changes: 1 addition & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,12 @@ LDFLAGS=-ldflags "-s -w -X=main.Version=$(VERSION) -X=main.Build=$(BUILD) -extld
DOCKERTAG ?= $(VERSION)
REPOSITORY ?= gcr.io/spectro-dev-public/release

GOLANG_VERSION=1.22
GOLANG_VERSION=1.23
FIPS_ENABLE ?= ""
BUILD_ARGS = --build-arg CRYPTO_LIB=${FIPS_ENABLE} --build-arg GOLANG_VERSION=${GOLANG_VERSION}
PLATFORM ?= "linux/amd64,linux/arm64"
ifeq ($(FIPS_ENABLE),yes)
REPOSITORY = gcr.io/spectro-dev-public/release-fips
PLATFORM = "linux/amd64"
endif


Expand Down

0 comments on commit 6dfd135

Please sign in to comment.