Skip to content

Commit

Permalink
Revert
Browse files Browse the repository at this point in the history
  • Loading branch information
emil-jacero committed Sep 1, 2024
1 parent 90619ce commit b27d481
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 39 deletions.
40 changes: 16 additions & 24 deletions .github/workflows/build-and-publish-images.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
name: Build & Publish container images to GHCR

on:
workflow_run:
workflows: ["Integration Tests"]
types:
- completed
push:
branches:
- main
- 'feature/*'
tags:
- 'v*.*.*'
pull_request:
branches:
- main

jobs:
build-and-publish:
Expand All @@ -25,33 +30,20 @@ jobs:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Download workflow info
uses: dawidd6/action-download-artifact@v3
with:
workflow: Integration Tests
run_id: ${{ github.event.workflow_run.id }}
name: workflow-info

- name: Read workflow information
id: read_info
run: |
echo "git_ref=$(cat git_ref)" >> $GITHUB_OUTPUT
echo "is_tag=$(cat is_tag)" >> $GITHUB_OUTPUT
- name: Docker meta
id: meta
uses: docker/metadata-action@v5
env:
DESCRIPTION: kode-operator is a Kubernetes operator that manages the lifecycle of your development environments.
DESCRIPTION: kode-operator is a Kubernetes operator that manages the lifecycle your development environments.
with:
images: ghcr.io/jacero-io/kode-operator
tags: |
type=raw,value=latest,enable=${{ steps.read_info.outputs.git_ref == 'main' }}
type=raw,value=${{ steps.read_info.outputs.git_ref }},enable=${{ steps.read_info.outputs.is_tag == 'true' }}
type=semver,pattern=v{{version}},value=${{ steps.read_info.outputs.git_ref }},enable=${{ steps.read_info.outputs.is_tag == 'true' }}
type=semver,pattern=v{{major}}.{{minor}},value=${{ steps.read_info.outputs.git_ref }},enable=${{ steps.read_info.outputs.is_tag == 'true' }}
type=semver,pattern=v{{major}},value=${{ steps.read_info.outputs.git_ref }},enable=${{ steps.read_info.outputs.is_tag == 'true' }}
type=sha,prefix=sha-
type=semver,pattern=v{{version}},event=tag
type=semver,pattern=v{{major}}.{{minor}},event=tag
type=semver,pattern=v{{major}},event=tag
type=ref,event=pr
type=sha
type=raw,value=latest,enable={{is_default_branch}}
type=raw,value=dev-latest
labels: |
[email protected]
Expand Down
16 changes: 1 addition & 15 deletions .github/workflows/integration-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,6 @@ on:
jobs:
integration-tests:
runs-on: ubuntu-latest
outputs:
git_ref: ${{ steps.git_ref.outputs.ref }}
is_tag: ${{ steps.git_ref.outputs.is_tag }}

steps:
- name: Checkout code
Expand All @@ -43,19 +40,8 @@ jobs:
task tools:envtest
task tools:golangci-lint
- name: Get Git Ref
id: git_ref
run: |
if [[ $GITHUB_REF == refs/tags/* ]]; then
echo "ref=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
echo "is_tag=true" >> $GITHUB_OUTPUT
else
echo "ref=${GITHUB_REF#refs/heads/}" >> $GITHUB_OUTPUT
echo "is_tag=false" >> $GITHUB_OUTPUT
fi
- name: Run tests
env:
TEST_VERBOSITY: ""
run: |
task test:integration
task test:integration

0 comments on commit b27d481

Please sign in to comment.