fix: permanent DNS fix via daemon.json + CoreDNS, restart=always for kind container

This commit is contained in:
Szymon Wałachowski 2026-04-01 22:19:11 +02:00
parent 601a0328b8
commit 89f26e1dd1
3 changed files with 7 additions and 4 deletions

View file

@ -136,11 +136,13 @@ kubectl exec -it -n forgejo deployment/forgejo-runner -- \
### After server restart (if pods have ImagePullBackOff)
Kind container loses its DNS config on restart:
This should no longer happen — `/etc/docker/daemon.json` is configured with `"dns": ["8.8.8.8"]` to prevent the router's broken IPv6 DNS from being injected into containers. The kind container also has `restart=always` so it auto-starts with Docker.
If it does happen anyway (e.g. daemon.json was reset), quick fix:
```bash
docker exec szymicluster-control-plane bash -c 'echo "nameserver 8.8.8.8" > /etc/resolv.conf'
kubectl delete pods -n argocd --all
kubectl delete pods -A --field-selector=status.phase!=Running 2>/dev/null
```
### Checking overall health