apt-get install -y kubelet=1.10.0-00 kubeadm=1.10.0-00 kubectl=1.10.0-00 --allow-downgrades --allow-change-held-packages
kubectl patch deployment camera -p "{"spec":{"template":{"metadata":{"labels":{"date":"date +'%s'"}}}}}"
Rebuild master:
flash --hostname master https://github.com/hypriot/image-builder-rpi/releases/download/v1.9.0/hypriotos-rpi-v1.9.0.img.zip edit /boot/user-data as needed
Go edit /boot/cmdline.txt with your favorite editor, or use sudo nano /boot/cmdline and add this at the very end. Don't press enter. cgroup_enable=cpuset cgroup_enable=memory
Note that KUBELET_NETWORK_ARGS is what tells kubelet which kind of network plugin to expect. If you remove it then kubelet expects no plugin, and therefore you get whatever the underlying container runtime gives you: typically Docker "bridge" networking.
vi /etc/systemd/system/kubelet.service.d/10-kubeadm.conf
As root:
apt-get update && apt-get install -y apt-transport-https curl
curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -
cat <<EOF >/etc/apt/sources.list.d/kubernetes.list
deb http://apt.kubernetes.io/ kubernetes-xenial main
EOF
apt-get update && apt-get install -y kubelet=1.10.0-00 kubeadm=1.10.0-00 kubectl=1.10.0-00
on master: swapoff -a && kubeadm init --pod-network-cidr 10.244.0.0/16 --apiserver-advertise-address=192.168.1.100
kubeadm token create --print-join-command
on each node: swapoff -a && kubeadm join <master-tokens-info> --ignore-preflight-errors=cri
swapoff -a &&kubeadm join 192.168.1.100:6443 --token 1r31mu.7pe44s1kf861yw7w --discovery-token-ca-cert-hash sha256:85f66aae43c48c18c733729850b9c536149a26a874952b14d6bd8edc6e236edb --ignore-preflight-errors=cr
As non-root
mkdir -p $HOME/.kube sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config sudo chown $(id -u):$(id -g) $HOME/.kube/config export KUBECONFIG=$HOME/.kube/config echo 'export KUBECONFIG=$HOME/.kube/config' >> ~/.profile
kubectl apply -f https://raw.githubusercontent.com/coreos/flannel/master/Documentation/kube-flannel.yml
kubectl label node master nginx-controller=traefik
kubectl apply -f https://raw.githubusercontent.com/hypriot/rpi-traefik/master/traefik-k8s-example.yaml
sudo apt-get install weavedconnectd
sudo weavedinstaller
Content type
Image
Digest
Size
1.3 GB
Last updated
over 8 years ago
docker pull rcampbell/camera