Skip to content

Merge pull request #224 from jenkins-x/upgrade #34

Merge pull request #224 from jenkins-x/upgrade

Merge pull request #224 from jenkins-x/upgrade #34

name: Release
jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
token: ${{ secrets.GIT_BOT_TOKEN }}
- run: git fetch --depth=1 origin +refs/tags/*:refs/tags/*
- uses: fregante/setup-git-user@v1
- name: prep
id: prep
uses: jenkins-x-plugins/[email protected]
with:
tag: true
github-token: ${{ secrets.GIT_BOT_TOKEN }}
- env:
GITHUB_TOKEN: ${{ secrets.GIT_BOT_TOKEN }}
VERSION: ${{ steps.prep.outputs.version }}
name: release-binary
uses: docker://golang:1.23.2@sha256:a7f2fc9834049c1f5df787690026a53738e55fc097cd8a4a93faa3e06c67ee32
with:
args: -c "make release"
entrypoint: bash
- env:
GITHUB_TOKEN: ${{ secrets.GIT_BOT_TOKEN }}
VERSION: ${{ steps.prep.outputs.version }}
name: chart-docs
uses: docker://jnorwood/helm-docs:v1.4.0
with:
args: -c "if [ -d \"charts/$REPO_NAME\" ]; then cd charts/$REPO_NAME; helm-docs;
else echo no charts; fi"
entrypoint: /bin/ash
- env:
GITHUB_TOKEN: ${{ secrets.GIT_BOT_TOKEN }}
REPO_NAME: ${{ github.event.repository.name }}
VERSION: ${{ steps.prep.outputs.version }}
name: changelog
uses: docker://ghcr.io/jenkins-x/jx-boot:3.10.166
with:
entrypoint: .github/workflows/jenkins-x/changelog.sh
- env:
GITHUB_TOKEN: ${{ secrets.GIT_BOT_TOKEN }}
REPOSITORY: ${{ github.repository }}
VERSION: ${{ steps.prep.outputs.version }}
name: upload-binaries
uses: docker://ghcr.io/jenkins-x/jx-goreleaser-image:1.0.0@sha256:35070795367fea9a789c1c3a138b5e32262e4253d38e47406ba9ab7833ff15b2
with:
entrypoint: .github/workflows/jenkins-x/upload-binaries.sh
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: jenkins-x-bot-test
password: ${{ secrets.GIT_BOT_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v3
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm64
push: true
build-args: |
VERSION=${{ steps.prep.outputs.version}}
tags: |
ghcr.io/${{ github.repository }}:latest
ghcr.io/${{ github.repository }}:${{ steps.prep.outputs.version }}
- env:
GITHUB_TOKEN: ${{ secrets.GIT_BOT_TOKEN }}
GIT_USERNAME: jenkins-x-bot-test
DOCKER_REGISTRY_ORG: jenkins-x
REPO_NAME: ${{ github.event.repository.name }}
VERSION: ${{ steps.prep.outputs.version }}
name: Generate and Push SBOM
uses: docker://ghcr.io/oras-project/oras:v0.13.0
with:
entrypoint: .github/workflows/jenkins-x/sbom-container.sh
- env:
GITHUB_TOKEN: ${{ secrets.GIT_BOT_TOKEN }}
JX_REPOSITORY_USERNAME: jenkins-x-bot-test
VERSION: ${{ steps.prep.outputs.version }}
name: release-chart
uses: docker://ghcr.io/jenkins-x/jx-boot:3.3.4
with:
entrypoint: .github/workflows/jenkins-x/release-chart.sh
- env:
GIT_USERNAME: jenkins-x-bot-test
GITHUB_TOKEN: ${{ secrets.GIT_BOT_TOKEN }}
VERSION: ${{ steps.prep.outputs.version }}
XDG_CONFIG_HOME: /github/home/.config
name: promote-release
uses: docker://ghcr.io/jenkins-x/jx-updatebot:0.0.84
with:
entrypoint: jx-updatebot
args: pr --git-credentials
"on":
push:
branches:
- main
- master