一
下载minicube
curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64
mv minikube-linux-amd64 /usr/local/bin/minikube && chmod +x /usr/local/bin/minikube
以docker方式启动
minikube config set driver docker
curl -o rootless-install.sh -fsSL https://get.docker.com/rootless
chmod +x rootless-install.sh
adduser admin
passwd admin
Changing password for user admin.
New password:
BAD PASSWORD: The password contains the user name in some form
Retype new password:
passwd: all authentication tokens updated successfully.
groupadd docker
groupadd: group 'docker' already exists
usermod -aG docker $USER
newgrp docker
sudo gpasswd -a admin docker
vi /etc/profile
export PATH=$HOME/bin:$PATH
export DOCKER_HOST=unix://run/user/1000/docker.sock
sudo sh -eux <<EOF
# Set user.max_user_namespaces
cat <<EOT > /etc/sysctl.d/51-rootless.conf
user.max_user_namespaces = 28633
EOT
sysctl --system
EOF
exit
使用admin账号登录
dockerd-rootless-setuptool.sh install -f
docker context use rootless
export PATH=/usr/bin:$PATH
export DOCKER_HOST=unix:///run/user/1000/docker.sock
/etc/sysconfig/selinux修改为SELINUX=disabledsetenforce 0 https://blog.csdn.net/hnmpf/article/details/82866770
sudo minikube start --driver=docker --container-runtime=containerd
二
#root
yum erase docker-ce
#admin
curl -o install.sh -fsSL https://get.docker.com
sudo bash install.sh
dockerd-rootless-setuptool.sh install
PATH=/usr/bin:/sbin:/usr/sbin:$PATH dockerd-rootless.sh
docker context use rootless
#cgroup2
ls /sys/fs/cgroup/cgroup.controllers
minikube start --driver=docker --container-runtime=containerd --image-mirror-country='cn'
minikube start --image-mirror-country='cn' --cpus=4 --memory=4096mb
三
minikube delete --all
minikube start --driver=docker --container-runtime=containerd --registry-mirror=https://registry.docker-cn.com
minikube start --driver=docker --container-runtime=containerd --image-mirror-country='cn' --image-repository='registry.cn-hangzhou.aliyuncs.com/google_containers' --base-image='registry.cn-hangzhou.aliyuncs.com/google_containers/kicbase:v0.0.28'
链接:https://blog.csdn.net/u010953609/article/details/121536434
systemctl --user start docker
systemctl --user status docker
https://docs.docker.com/engine/security/rootless/
四
kicbase/stable v0.0.28
registry.cn-hangzhou.aliyuncs.com/google_containers/kicbase v0.0.28
docker tag registry.cn-hangzhou.aliyuncs.com/google_containers/kicbase:v0.0.28@sha256:4780f1897569d2bf77aafb3d133a08d42b4fe61127f06fcfc90c2c5d902d893c gcr.io/k8s-minikube/kicbase:v0.0.28
docker pull registry.cn-hangzhou.aliyuncs.com/google_containers/coredns/coredns:v1.8.4
docker pull registry.cn-hangzhou.aliyuncs.com/google_containers/coredns:v1.8.4
docker tag registry.cn-hangzhou.aliyuncs.com/google_containers/coredns:v1.8.4 k8s.gcr.io/coredns/coredns:v1.8.4
docker pull registry.cn-hangzhou.aliyuncs.com/google_containers/kube-controller-manager:v1.22.3
docker tag registry.cn-hangzhou.aliyuncs.com/google_containers/kube-controller-manager:v1.22.3 k8s.gcr.io/kube-controller-manager:v1.22.3
docker pull registry.cn-hangzhou.aliyuncs.com/google_containers/kube-scheduler:v1.22.3
docker tag registry.cn-hangzhou.aliyuncs.com/google_containers/kube-scheduler:v1.22.3 k8s.gcr.io/kube-scheduler:v1.22.3
docker pull registry.cn-hangzhou.aliyuncs.com/google_containers/etcd:3.5.0-0
docker tag registry.cn-hangzhou.aliyuncs.com/google_containers/etcd:3.5.0-0 k8s.gcr.io/etcd:3.5.0-0
docker pull registry.cn-hangzhou.aliyuncs.com/google_containers/kube-proxy:v1.22.3
docker tag registry.cn-hangzhou.aliyuncs.com/google_containers/kube-proxy:v1.22.3 k8s.gcr.io/kube-proxy:v1.22.3
docker pull registry.cn-hangzhou.aliyuncs.com/google_containers/storage-provisioner:v5
docker tag registry.cn-hangzhou.aliyuncs.com/google_containers/storage-provisioner:v5 gcr.io/k8s-minikube/storage-provisioner:v5
五
https://www.cnblogs.com/builderman/p/13670012.html
六
sudo curl -Lo minikube https://storage.googleapis.com/minikube/releases/v1.18.1/minikube-linux-amd64 &&sudo chmod +x minikube && sudo mv minikube /usr/local/bin/
minikube start
--registry-mirror=https://bmtb46e4.mirror.aliyuncs.com
--driver=docker
--base-image="anjone/kicbase"
--image-repository=registry.cn-hangzhou.aliyuncs.com/google_containers
minikube start --driver=docker --image-mirror-country='cn' --image-repository='registry.cn-hangzhou.aliyuncs.com/google_containers'
kubectl get pods --all-namespaces