fix(dev-vm): forward port 8080 to expose kubeconfig HTTP from QEMU
Some checks failed
ARM64 Build / Build generic ARM64 disk image (push) Failing after 5s
CI / Go Tests (push) Successful in 2m7s
CI / Shellcheck (push) Successful in 1m1s
CI / Build Go Binaries (amd64, linux, linux-amd64) (push) Successful in 1m35s
CI / Build Go Binaries (arm64, linux, linux-arm64) (push) Successful in 1m48s
Some checks failed
ARM64 Build / Build generic ARM64 disk image (push) Failing after 5s
CI / Go Tests (push) Successful in 2m7s
CI / Shellcheck (push) Successful in 1m1s
CI / Build Go Binaries (amd64, linux, linux-amd64) (push) Successful in 1m35s
CI / Build Go Binaries (arm64, linux, linux-arm64) (push) Successful in 1m48s
90-kubesolo.sh starts an nc-based HTTP server on port 8080 inside the VM to serve the admin kubeconfig (serial console truncates the base64-encoded cert lines, so HTTP is the reliable retrieval path). hack/dev-vm-arm64.sh only forwarded ports 6443 (kube-apiserver) and 2222 (ssh), so `curl http://localhost:8080` from the Mac returned empty — the connect attempt landed on a closed Mac-side port. Add the third hostfwd. Now `curl http://localhost:8080` from the host machine reaches the in-VM HTTP server and returns the kubeconfig. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -133,7 +133,7 @@ if [ "$MODE" = "disk" ]; then
|
|||||||
-bios "$UEFI_FW" \
|
-bios "$UEFI_FW" \
|
||||||
-drive "file=$DISK_IMAGE,format=raw,if=virtio,media=disk" \
|
-drive "file=$DISK_IMAGE,format=raw,if=virtio,media=disk" \
|
||||||
-net "nic,model=virtio" \
|
-net "nic,model=virtio" \
|
||||||
-net "user,hostfwd=tcp::6443-:6443,hostfwd=tcp::2222-:22"
|
-net "user,hostfwd=tcp::6443-:6443,hostfwd=tcp::2222-:22,hostfwd=tcp::8080-:8080"
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -199,4 +199,4 @@ qemu-system-aarch64 \
|
|||||||
-append "console=ttyAMA0 kubesolo.data=/dev/vda kubesolo.debug $EXTRA_APPEND" \
|
-append "console=ttyAMA0 kubesolo.data=/dev/vda kubesolo.debug $EXTRA_APPEND" \
|
||||||
-drive "file=$DATA_DISK,format=raw,if=virtio" \
|
-drive "file=$DATA_DISK,format=raw,if=virtio" \
|
||||||
-net "nic,model=virtio" \
|
-net "nic,model=virtio" \
|
||||||
-net "user,hostfwd=tcp::6443-:6443,hostfwd=tcp::2222-:22"
|
-net "user,hostfwd=tcp::6443-:6443,hostfwd=tcp::2222-:22,hostfwd=tcp::8080-:8080"
|
||||||
|
|||||||
Reference in New Issue
Block a user