Skip to content

Commit

Permalink
Use RELEASE_TAG (#50)
Browse files Browse the repository at this point in the history
* Use RELEASE_TAG

* Fix registry setup

---------

Co-authored-by: ekarlso <[email protected]>
  • Loading branch information
ekarlso and ekarlso authored Sep 10, 2023
1 parent c568ab9 commit 4d8982e
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 15 deletions.
11 changes: 4 additions & 7 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@ on:
tags:
- "v*"
env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}
REGISTRY: ghcr.io/${{ github.repository }}
GO_VERSION: "1.20"

permissions:
Expand Down Expand Up @@ -50,7 +49,7 @@ jobs:
uses: docker/metadata-action@v4
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}-${{ matrix.target }}
images: ${{ env.REGISTRY }}/${{ matrix.target }}-controller
flavor: latest=false
tags: type=ref,event=tag

Expand Down Expand Up @@ -120,15 +119,13 @@ jobs:
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
images: |
${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}-controlplane
${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}-bootstrap
${{ env.REGISTRY }}/controlplane-controller
${{ env.REGISTRY }}/bootstrap-controller
flavor: latest=false
tags: type=ref,event=tag

- name: manifest
run: |
BOOTSTRAP_IMG_TAG=$RELEASE_TAG
CONTROLPLANE_IMG_TAG=$RELEASE_TAG
make release
- name: manifest
Expand Down
17 changes: 9 additions & 8 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,6 @@ TOOLS_BIN_DIR := $(shell pwd)/$(BIN_DIR)
$(TOOLS_BIN_DIR):
mkdir -p $(TOOLS_BIN_DIR)

# Image URL to use all building/pushing image targets
BOOTSTRAP_IMG_TAG ?= v0.2.0
BOOTSTRAP_IMG ?= ghcr.io/cluster-api-provider-k3s/cluster-api-k3s/bootstrap-controller:$(BOOTSTRAP_IMG_TAG)

# Image URL to use all building/pushing image targets
CONTROLPLANE_IMG_TAG ?= v0.2.0
CONTROLPLANE_IMG ?= ghcr.io/cluster-api-provider-k3s/cluster-api-k3s/controlplane-controller:$(CONTROLPLANE_IMG_TAG)


# Produce CRDs that work back to Kubernetes 1.11 (no version conversion)
CRD_OPTIONS ?= "crd:trivialVersions=true"
Expand Down Expand Up @@ -118,6 +110,15 @@ $(RELEASE_DIR):
$(RELEASE_NOTES_DIR):
mkdir -p $(RELEASE_NOTES_DIR)/

REGISTRY ?= ghcr.io/cluster-api-provider-k3s/cluster-api-k3s

# Image URL to use all building/pushing image targets
BOOTSTRAP_IMG_TAG ?= $(RELEASE_TAG)
BOOTSTRAP_IMG ?= $(REGISTRY)/bootstrap-controller:$(BOOTSTRAP_IMG_TAG)

# Image URL to use all building/pushing image targets
CONTROLPLANE_IMG_TAG ?= $(RELEASE_TAG)
CONTROLPLANE_IMG ?= $(REGISTRY)/controlplane-controller:$(CONTROLPLANE_IMG_TAG)

all-bootstrap: manager-bootstrap

Expand Down

0 comments on commit 4d8982e

Please sign in to comment.