Skip to content

Commit ccc5779

Browse files
committed
Updates to script b/c of invalid auth config
Signed-off-by: Matthias Wessendorf <[email protected]>
1 parent 1f409a0 commit ccc5779

File tree

2 files changed

+23
-3
lines changed

2 files changed

+23
-3
lines changed

build/kind.mk

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,7 @@ CONTAINER_ENGINE ?= $(shell command -v docker 2>/dev/null || command -v podman 2
99
kind-create-certs: ## Generate placeholder CA certificate for KIND bind mount
1010
@if [ ! -f hack/cert-manager-ca/ca.crt ]; then \
1111
echo "Creating placeholder CA certificate for bind mount..."; \
12-
mkdir -p hack/cert-manager-ca; \
13-
echo "placeholder" > hack/cert-manager-ca/ca.crt; \
14-
echo "⚠️ Placeholder CA created - will be replaced with cert-manager CA after cluster creation"; \
12+
./hack/generate-placeholder-ca.sh; \
1513
else \
1614
echo "✅ Placeholder CA already exists"; \
1715
fi

hack/generate-placeholder-ca.sh

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
#!/bin/bash
2+
set -e
3+
4+
# Generate a placeholder self-signed CA certificate for KIND cluster startup
5+
# This will be replaced with the real cert-manager CA after the cluster is created
6+
7+
CERT_DIR="hack/cert-manager-ca"
8+
CA_CERT="$CERT_DIR/ca.crt"
9+
CA_KEY="$CERT_DIR/ca.key"
10+
11+
mkdir -p "$CERT_DIR"
12+
13+
# Generate a self-signed CA certificate (valid placeholder)
14+
openssl req -x509 -newkey rsa:2048 -nodes \
15+
-keyout "$CA_KEY" \
16+
-out "$CA_CERT" \
17+
-days 365 \
18+
-subj "/CN=placeholder-ca" \
19+
2>/dev/null
20+
21+
echo "✅ Placeholder CA certificate created at $CA_CERT"
22+
echo "⚠️ This will be replaced with cert-manager CA after cluster creation"

0 commit comments

Comments
 (0)