Skip to content

Commit

Permalink
DEBUG
Browse files Browse the repository at this point in the history
  • Loading branch information
ekampf committed Dec 19, 2024
1 parent 137d4e3 commit 6565f0f
Showing 1 changed file with 75 additions and 73 deletions.
148 changes: 75 additions & 73 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ on:
push:
tags:
- v[0-9]+.[0-9]+.[0-9]+
branches:
- 'feature/oss-25-publish-versioned-chart'

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
Expand All @@ -14,48 +16,48 @@ env:
POETRY_VERSION: 1.8.5

jobs:
create_release:
runs-on: ubuntu-latest

steps:
- name: Checkout Code
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Get previous tag
id: previousTag
run: |
name=$(git --no-pager tag --sort=creatordate --merged ${{ github.ref_name }} | tail -2 | head -1)
echo "previousTag: $name"
echo "previousTag=$name" >> $GITHUB_ENV
- name: Update CHANGELOG
id: changelog
uses: requarks/changelog-action@v1
with:
token: ${{ github.token }}
fromTag: ${{ github.ref_name }}
toTag: ${{ env.previousTag }}
includeRefIssues: true
writeToFile: false
useGitmojis: true
reverseOrder: true

- name: Create Release
uses: ncipollo/release-action@v1.14.0
with:
allowUpdates: true
draft: true
makeLatest: true
name: ${{ github.ref_name }}
body: ${{ steps.changelog.outputs.changes }}
token: ${{ secrets.GITHUB_TOKEN }}
# create_release:
# runs-on: ubuntu-latest
#
# steps:
# - name: Checkout Code
# uses: actions/checkout@v4
# with:
# fetch-depth: 0
#
# - name: Get previous tag
# id: previousTag
# run: |
# name=$(git --no-pager tag --sort=creatordate --merged ${{ github.ref_name }} | tail -2 | head -1)
# echo "previousTag: $name"
# echo "previousTag=$name" >> $GITHUB_ENV
#
# - name: Update CHANGELOG
# id: changelog
# uses: requarks/changelog-action@v1
# with:
# token: ${{ github.token }}
# fromTag: ${{ github.ref_name }}
# toTag: ${{ env.previousTag }}
# includeRefIssues: true
# writeToFile: false
# useGitmojis: true
# reverseOrder: true
#
# - name: Create Release
# uses: ncipollo/release-action@v1.14.0
# with:
# allowUpdates: true
# draft: true
# makeLatest: true
# name: ${{ github.ref_name }}
# body: ${{ steps.changelog.outputs.changes }}
# token: ${{ secrets.GITHUB_TOKEN }}

release_prod_helm:
runs-on: ubuntu-latest
name: Release PROD Helm Chart
needs: [create_release, release_prod]
# needs: [create_release, release_prod]
steps:
- uses: actions/checkout@v4
with:
Expand Down Expand Up @@ -87,38 +89,38 @@ jobs:
helm package deploy/twingate-operator --version $CHART_VERSION --app-version $APP_VERSION
helm push twingate-operator-$CHART_VERSION.tgz oci://$REGISTRY/twingate/helmcharts
release_prod:
name: Release PROD
runs-on: ubuntu-latest
needs: [create_release]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ env.PYTHON_VERSION }}
- name: Install and configure Poetry
uses: snok/install-poetry@v1
with:
version: ${{ env.POETRY_VERSION }}
virtualenvs-create: true
virtualenvs-in-project: true
installer-parallel: true

- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Expose GitHub Runtime (ACTION_* env vars required for docker caching)
uses: crazy-max/ghaction-github-runtime@v3

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- run: make multiarch-image-build-push-prod
env:
DOCKER_BUILDX_CACHE: --cache-to type=gha,mode=max --cache-from type=gha
# release_prod:
# name: Release PROD
# runs-on: ubuntu-latest
# needs: [create_release]
# steps:
# - uses: actions/checkout@v4
# - uses: actions/setup-python@v5
# with:
# python-version: ${{ env.PYTHON_VERSION }}
# - name: Install and configure Poetry
# uses: snok/install-poetry@v1
# with:
# version: ${{ env.POETRY_VERSION }}
# virtualenvs-create: true
# virtualenvs-in-project: true
# installer-parallel: true
#
# - name: Login to Docker Hub
# uses: docker/login-action@v3
# with:
# username: ${{ secrets.DOCKERHUB_USERNAME }}
# password: ${{ secrets.DOCKERHUB_TOKEN }}
#
# - name: Expose GitHub Runtime (ACTION_* env vars required for docker caching)
# uses: crazy-max/ghaction-github-runtime@v3
#
# - name: Set up QEMU
# uses: docker/setup-qemu-action@v3
#
# - name: Set up Docker Buildx
# uses: docker/setup-buildx-action@v3
#
# - run: make multiarch-image-build-push-prod
# env:
# DOCKER_BUILDX_CACHE: --cache-to type=gha,mode=max --cache-from type=gha

0 comments on commit 6565f0f

Please sign in to comment.