Setup Note: Container - takumaw/Configs GitHub Wiki
Container Setup Note
Docker Setup
Docker Installation
See:
For macOS, also do:
brew install docker-completion
Daemon Configuration
sudo vim /etc/docker/daemon.json
{
"log-driver": "json-file",
"log-opts": {
"max-size": "100m"
},
"live-restore": true,
"bip": "10.0.0.1/24",
"default-address-pools": [
{
"base": "10.0.0.0/16",
"size": 24
}
],
"max-concurrent-downloads": 10,
"max-concurrent-uploads": 10,
"registry-mirrors": [
"http://DOCKER_REGISTRY_MIRROR/"
],
"insecure-registries": [
"http://DOCKER_REGISTRY_MIRROR/"
],
"proxies": {
"http-proxy": "http://HOST:PORT",
"https-proxy": "http://HOST:PORT",
"no-proxy": "NO_PROXY_HOSTS"
}
}
sudo systemctl enable --now docker
sudo systemctl restart docker
See also:
- https://docs.docker.com/engine/daemon/proxy/
- https://docs.docker.com/docker-hub/mirror/
- https://docs.docker.com/engine/logging/drivers/json-file/
- https://docs.docker.com/reference/cli/dockerd/
Client Configuration
mkdir -p ~/.docker
vim ~/.docker/config.json
{
"proxies": {
"default": {
"httpProxy": "http://HOST:PORT",
"httpsProxy": "http://HOST:PORT",
"ftpProxy": "http://HOST:PORT",
"noProxy": "NO_PROXY_HOSTS"
}
}
}
See also:
WSL2 Workarounds
Enable systemd:
sudo vim /etc/wsl.conf
[boot]
systemd=true
See:
Podman Setup
Podman Installation
sudo apt install -y \
podman \
podman-remote \
podman-docker \
podman-compose
Podman Configuration
sudo vim /etc/containers/registries.conf.d/registries.conf
unqualified-search-registries = ["registry.access.redhat.com", "registry.redhat.io", "quay.io", "docker.io"]
See:
WSL2 Workarounds
Mount / as recursively shared:
sudo vim /etc/wsl.conf
[boot]
systemd=false
command=mount --make-rshared /
See:
- https://github.com/microsoft/WSL/issues/7477
- https://learn.microsoft.com/ja-jp/windows/wsl/wsl-config
Kubernetes Installation
Kubelet Installation
See:
CRI-O Installation
See:
Minikube Installation
See:
Minikube Initialization
minikube start --driver=podman --container-runtime=cri-o
See: