Skip to content

Commit a686ee7

Browse files
author
Per Goncalves da Silva
committed
🌱 Move registry to registry:3 and make in-cluster registry visibile to kubelet
Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
1 parent 1333f7b commit a686ee7

File tree

10 files changed

+11
-109
lines changed

10 files changed

+11
-109
lines changed

Makefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,6 @@ E2E_REGISTRY_IMAGE=localhost/e2e-test-registry:devel
251251
image-registry: export GOOS=linux
252252
image-registry: export GOARCH=amd64
253253
image-registry: ## Build the testdata catalog used for e2e tests and push it to the image registry
254-
go build $(GO_BUILD_FLAGS) $(GO_BUILD_EXTRA_FLAGS) -tags '$(GO_BUILD_TAGS)' -ldflags '$(GO_BUILD_LDFLAGS)' -gcflags '$(GO_BUILD_GCFLAGS)' -asmflags '$(GO_BUILD_ASMFLAGS)' -o ./testdata/registry/bin/registry ./testdata/registry/registry.go
255254
go build $(GO_BUILD_FLAGS) $(GO_BUILD_EXTRA_FLAGS) -tags '$(GO_BUILD_TAGS)' -ldflags '$(GO_BUILD_LDFLAGS)' -gcflags '$(GO_BUILD_GCFLAGS)' -asmflags '$(GO_BUILD_ASMFLAGS)' -o ./testdata/push/bin/push ./testdata/push/push.go
256255
$(CONTAINER_RUNTIME) build -f ./testdata/Dockerfile -t $(E2E_REGISTRY_IMAGE) ./testdata
257256
$(CONTAINER_RUNTIME) save $(E2E_REGISTRY_IMAGE) | $(KIND) load image-archive /dev/stdin --name $(KIND_CLUSTER_NAME)
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[host."https://localhost:30000"]
2+
capabilities = ["pull", "resolve"]
3+
skip_verify = true

kind-config.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,10 @@ nodes:
1919
apiServer:
2020
extraArgs:
2121
enable-admission-plugins: OwnerReferencesPermissionEnforcement
22+
extraMounts:
23+
- hostPath: ./hack/kind-config/containerd/certs.d
24+
containerPath: /etc/containerd/certs.d
25+
containerdConfigPatches:
26+
- |-
27+
[plugins."io.containerd.grpc.v1.cri".registry]
28+
config_path = "/etc/containerd/certs.d"

testdata/.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1 @@
11
push/bin
2-
registry/bin

testdata/Dockerfile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,8 @@ FROM gcr.io/distroless/static:nonroot
22

33
WORKDIR /
44

5-
COPY registry/bin/registry registry
65
COPY push/bin/push push
76

87
COPY images images
98

10-
EXPOSE 5000
11-
129
USER 65532:65532

testdata/build-test-registry.sh

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -71,12 +71,8 @@ spec:
7171
spec:
7272
containers:
7373
- name: registry
74-
image: ${image}
74+
image: registry:3
7575
imagePullPolicy: IfNotPresent
76-
command:
77-
- /registry
78-
args:
79-
- "--registry-address=:5000"
8076
volumeMounts:
8177
- name: certs-vol
8278
mountPath: "/certs"

testdata/registry/README.md

Lines changed: 0 additions & 15 deletions
This file was deleted.

testdata/registry/go.mod

Lines changed: 0 additions & 8 deletions
This file was deleted.

testdata/registry/go.sum

Lines changed: 0 additions & 36 deletions
This file was deleted.

testdata/registry/registry.go

Lines changed: 0 additions & 40 deletions
This file was deleted.

0 commit comments

Comments
 (0)