Install with snap on Ubuntu
sudo snap install kubectl --classic
kubectl version
1.1 Install virtualbox
https://tecadmin.net/install-oracle-virtualbox-on-ubuntu/
2. Install minikube
https://github.com/kubernetes/minikube/blob/v0.29.0/README.md
curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64 \ && sudo install minikube-linux-amd64 /usr/local/bin/minikube
minikube start
and then ... can't allocate memory :(
2nd attempt
https://kubernetes.io/docs/setup/independent/install-kubeadm/
2. Install minikube
https://github.com/kubernetes/minikube/blob/v0.29.0/README.md
curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64 \ && sudo install minikube-linux-amd64 /usr/local/bin/minikube
and then ... can't allocate memory :(
2nd attempt
https://kubernetes.io/docs/setup/independent/install-kubeadm/
cat <<EOF > /etc/yum.repos.d/kubernetes.repo
[kubernetes]
name=Kubernetes
baseurl=https://packages.cloud.google.com/yum/repos/kubernetes-el7-x86_64
enabled=1
gpgcheck=1
repo_gpgcheck=1
gpgkey=https://packages.cloud.google.com/yum/doc/yum-key.gpg https://packages.cloud.google.com/yum/doc/rpm-package-key.gpg
exclude=kube*
EOF
# Set SELinux in permissive mode (effectively disabling it)
setenforce 0
sed -i 's/^SELINUX=enforcing$/SELINUX=permissive/' /etc/selinux/config
yum install -y kubelet kubeadm kubectl --disableexcludes=kubernetes
systemctl enable kubelet && systemctl start kubelet
Installing a pod network add-on ???
kubectl apply -f "https://cloud.weave.works/k8s/net?k8s-version=$(kubectl version | base64 | tr -d '\n')"
before kubeadm init, run below
sudo cp /etc/kubernetes/admin.conf $HOME/
sudo chown $(id -u):$(id -g) $HOME/admin.conf
export KUBECONFIG=$HOME/admin.conf
before kubeadm init, run below
sudo cp /etc/kubernetes/admin.conf $HOME/
sudo chown $(id -u):$(id -g) $HOME/admin.conf
export KUBECONFIG=$HOME/admin.conf
Install docker
yum install -y docker
systemctl enable docker
systemctl start docker
No comments:
Post a Comment