Skip to content

Commit

Permalink
Use github packages image repository
Browse files Browse the repository at this point in the history
  • Loading branch information
jsturtevant committed Jun 3, 2021
1 parent fe82cd4 commit dc75308
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
5 changes: 3 additions & 2 deletions admission-webhook/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@ SHELL := /bin/bash
WEBHOOK_ROOT := $(CURDIR)

DEV_IMAGE_NAME = k8s-windows-gmsa-webhook-dev
# FIXME: find a better way to distribute/publish this image
IMAGE_NAME = wk88/k8s-gmsa-webhook:latest
VERSION = $(shell git describe --tags --always `git rev-parse HEAD`)
IMAGE_REPO = sigwindowstools/k8s-gmsa-webhook
IMAGE_NAME = $(IMAGE_REPO):$(VERSION)

CURL = $(shell which curl 2> /dev/null)
WGET = $(shell which wget 2> /dev/null)
Expand Down
4 changes: 2 additions & 2 deletions admission-webhook/deploy/deploy-gmsa-webhook.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ usage: $0 --file MANIFESTS_FILE [--name NAME] [--namespace NAMESPACE] [--image I
MANIFESTS_FILE is the path to the file the k8s manifests will be written to.
NAME defaults to 'gmsa-webhook' and is used in the names of most of the k8s resources created.
NAMESPACE is the namespace to deploy to; defaults to 'gmsa-webhook'.
IMAGE_NAME is the name of the Docker image containing the webhook; defaults to 'wk88/k8s-gmsa-webhook:latest' (FIXME: figure out a better way to distribute this image)
IMAGE_NAME is the name of the Docker image containing the webhook; defaults to 'sigwindowstools/k8s-gmsa-webhook:latest'
CERTS_DIR defaults to 'gmsa-webhook-certs'
If --dry-run is set, the script echoes what command it would perform
Expand Down Expand Up @@ -82,7 +82,7 @@ main() {
local MANIFESTS_FILE=
local NAME='gmsa-webhook'
local NAMESPACE='gmsa-webhook'
local IMAGE_NAME='wk88/k8s-gmsa-webhook:latest'
local IMAGE_NAME='sigwindowstools/k8s-gmsa-webhook:latest'
local CERTS_DIR='gmsa-webhook-certs'
local DRY_RUN=false
local OVERWRITE=false
Expand Down
3 changes: 2 additions & 1 deletion admission-webhook/make/image.mk
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# must stay consistent with the go version defined in .travis.yml
GO_VERSION = 1.16
VERSION = $(shell git rev-parse HEAD)
DOCKER_BUILD = docker build . --build-arg GO_VERSION=$(GO_VERSION) --build-arg VERSION=$(VERSION)

.PHONY: image_build_dev
Expand All @@ -10,7 +9,9 @@ image_build_dev:
.PHONY: image_build
image_build:
$(DOCKER_BUILD) -f dockerfiles/Dockerfile -t $(IMAGE_NAME)
docker tag $(IMAGE_NAME) $(IMAGE_REPO):latest

.PHONY: image_push
image_push:
docker push $(IMAGE_NAME)
docker push $(IMAGE_REPO):latest

0 comments on commit dc75308

Please sign in to comment.