diff --git a/.ko.yaml b/.ko.yaml index a05c1ce..eb623cb 100644 --- a/.ko.yaml +++ b/.ko.yaml @@ -3,7 +3,7 @@ defaultBaseImage: ghcr.io/distroless/static:latest builds: - id: admission-sidecar dir: . - main: ./cmd + main: ./cmd/admission-sidecar env: - CGO_ENABLED=0 flags: diff --git a/Makefile b/Makefile index bcbbb50..83548b7 100644 --- a/Makefile +++ b/Makefile @@ -1,12 +1,12 @@ GIT_TAG ?= $(shell git describe --tags --always --dirty) GIT_HASH ?= $(shell git rev-parse HEAD) -LDFLAGS="" +LDFLAGS= KO_DOCKER_REPO ?= ghcr.io/chainguard-dev/admission-sidecar .PHONY: ko-resolve ko-resolve: - LDFLAGS="$(LDFLAGS)" \ + LDFLAGS="$(LDFLAGS)" KO_DOCKER_REPO=$(KO_DOCKER_REPO) \ ko resolve --tags $(GIT_TAG),latest --base-import-paths --recursive \ --filename ./config --platform=all \ --image-refs imagerefs > release-$(GIT_TAG).yaml diff --git a/cmd/main.go b/cmd/admission-sidecar/main.go similarity index 100% rename from cmd/main.go rename to cmd/admission-sidecar/main.go diff --git a/config/proxy.yaml b/config/proxy.yaml index 43b7534..51b925e 100644 --- a/config/proxy.yaml +++ b/config/proxy.yaml @@ -21,7 +21,7 @@ spec: serviceAccountName: chainguard-proxy containers: - name: controller - image: ko://github.com/chainguard-dev/admission-sidecar/cmd/ + image: ko://github.com/chainguard-dev/admission-sidecar/cmd/admission-sidecar resources: requests: cpu: 50m