Skip to content
This repository has been archived by the owner on Oct 31, 2024. It is now read-only.

Commit

Permalink
Merge pull request #155 from zhiweiyin318/release-job
Browse files Browse the repository at this point in the history
add release action job
  • Loading branch information
openshift-merge-robot authored Jul 21, 2021
2 parents e6435f3 + 9fdd9f7 commit 85f1e3d
Show file tree
Hide file tree
Showing 4 changed files with 89 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/go-presubmit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ jobs:
- name: setup kind
uses: engineerd/[email protected]
with:
version: v0.10.0
version: v0.11.1
- name: Load image on the nodes of the cluster
run: |
kind load docker-image --name=kind quay.io/open-cluster-management/registration:latest
Expand Down
57 changes: 57 additions & 0 deletions .github/workflows/go-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: GoRelease

on:
push:
tags:
- 'v*.*.*'
env:
# Common versions
GO_VERSION: '1.16'
GO_REQUIRED_MIN_VERSION: ''
GOPATH: '/home/runner/work/registration/registration/go'
GITHUB_REF: ${{ github.ref }}

defaults:
run:
working-directory: go/src/open-cluster-management.io/registration

jobs:
release:
name: release
runs-on: ubuntu-latest
steps:
- name: checkout code
uses: actions/checkout@v2
with:
fetch-depth: 1
path: go/src/open-cluster-management.io/registration
- name: install Go
uses: actions/setup-go@v2
with:
go-version: ${{ env.GO_VERSION }}
- name: install imagebuilder
run: go install github.com/openshift/imagebuilder/cmd/[email protected]
- name: images
run: make images
- name: get release version
run: |
echo "RELEASE_VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
- name: get major release version
run: |
echo "MAJOR_RELEASE_VERSION=${RELEASE_VERSION%.*}" >> $GITHUB_ENV
- name: push image
run: |
echo ${{ secrets.DOCKER_PASSWORD }} | docker login quay.io --username ${{ secrets.DOCKER_USER }} --password-stdin
docker tag quay.io/open-cluster-management/registration:latest quay.io/open-cluster-management/registration:$RELEASE_VERSION
docker push quay.io/open-cluster-management/registration:$RELEASE_VERSION
- name: generate changelog
run: |
echo "# Registration $RELEASE_VERSION" > /home/runner/work/changelog.txt
echo "- See the [CHANGELOG](https://github.com/open-cluster-management-io/registration/blob/main/CHANGELOG/CHANGELOG-${MAJOR_RELEASE_VERSION}.md) for more details." >> /home/runner/work/changelog.txt
echo "- The released image is quay.io/open-cluster-management/registration:$RELEASE_VERSION" >> /home/runner/work/changelog.txt
- name: publish release
uses: softprops/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
body_path: /home/runner/work/changelog.txt
30 changes: 30 additions & 0 deletions CHANGELOG/CHANGELOG-v0.4.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Changelog since v0.3.0
All notable changes to this project will be documented in this file.

## v0.4.0

### New Features
* Support managedClusterAddon registration and maintain the lease of managedClusterAddon.

### Added
* Support DNS names for client cert.
* Support to use non-root user to run registration.
* Support to use null, true or false as managed cluster name.
* Add clusterClaim feature gate.

### Changes
* Upgrade k8s api lib to v0.21.1.
* Upgrade k8s client-go lib to v0.21.1.
* Upgrade OCM CRDs to v1.
* Upgrade Go to 1.16.
* Merge managed cluster capacity status.
* Reset csr name only if csr sync failed or secret saved.
* Use `livez` API instead of `readyz` API to check the status of managed cluster kube-apiserver.
* Use `clusterRole` instead of `role` for managed cluster add-ons to reduce number of hub resources.

### Bug Fixes
* Fix the managedClusterAddon lease compatibility issue.
* Fix the invalid client certificate issue.

### Removed & Deprecated
N/C
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
SHELL :=/bin/bash

all: build
.PHONY: all
Expand Down

0 comments on commit 85f1e3d

Please sign in to comment.