use composite kind with registry action

This commit is contained in:
bakito 2022-12-26 11:09:32 +01:00
parent ddc8e9f31d
commit dcaad44315
No known key found for this signature in database
GPG key ID: BCCEB081DB8A24D8
3 changed files with 2 additions and 50 deletions

View file

@ -15,30 +15,12 @@ jobs:
- name: Checkout
uses: actions/checkout@v3
- name: Install Helm
run: |
curl https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 | bash
- name: Set up Registry Container
run: |
docker run -d --restart=always -p "127.0.0.1:5001:5000" --name kind-registry registry:2
- name: Install kind with registry
uses: bakito/kind-with-registry-action@main
- name: Build image
run: ./testdata/e2e/bin/build-image.sh
- name: Create kind cluster
uses: helm/kind-action@v1.5.0
with:
version: v0.17.0
kubectl_version: v1.25.3
config: testdata/e2e/kind/config.yaml
- name: Set up Local Registry
run: |
# https://kind.sigs.k8s.io/docs/user/local-registry/
docker network connect kind kind-registry
kubectl apply -f testdata/e2e/kind/configmap-registry.yaml
# image registry: localhost:5001/
- name: Install Helm Chart
run: ./testdata/e2e/bin/install-chart.sh
- name: Wait for sync to finish

View file

@ -1,21 +0,0 @@
kind: Cluster
apiVersion: kind.x-k8s.io/v1alpha4
nodes:
- role: control-plane
kubeadmConfigPatches:
- |
kind: InitConfiguration
nodeRegistration:
kubeletExtraArgs:
node-labels: "ingress-ready=true"
extraPortMappings:
- containerPort: 80
hostPort: 80
protocol: TCP
- containerPort: 443
hostPort: 443
protocol: TCP
containerdConfigPatches:
- |-
[plugins."io.containerd.grpc.v1.cri".registry.mirrors."localhost:5001"]
endpoint = ["http://kind-registry:5000"]

View file

@ -1,9 +0,0 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: local-registry-hosting
namespace: kube-public
data:
localRegistryHosting.v1: |
host: "localhost:5001"
help: "https://kind.sigs.k8s.io/docs/user/local-registry/"