Kubernetes

Kubernetes kubectl autocomplete Ubuntu:

https://komodor.com/learn/kubectl-autocomplete-enabling-and-using-in-bash-zsh-and-powershell/
https://stackoverflow.com/a/77694825

apt-get install bash-completion -y
echo ‘source /etc/bash_completion’ >>~/.bashrc
echo ‘source <(kubectl completion bash)’ >>~/.bashrc
source ~/.bashrc

Configure NFS shares in Windows for k8s:

https://operavps.com/docs/install-nfs-server/

Kubernetes autostart Ubuntu:

nano /etc/systemd/system/minikube.service
[Unit]
Description=minikube service autostart
After=docker.service

[Service]
Type=oneshot
ExecStart=/usr/local/bin/minikube –force –driver=docker start
RemainAfterExit=true
ExecStop=/usr/local/bin/minikube stop
StandardOutput=journal
User=root
Group=

[Install]
WantedBy=multi-user.target

systemctl daemon-reload
systemctl enable minikube

reboot

Fix ubuntu apt-get and release upgrade errors

Fix fetching updates:

When you get “Unable to fetch some archives, maybe run apt-get update or try with –fix-missing?” error do this:

cd /etc/apt
mv sources.list sources.list.old
lsb_release -a
sudo cat sources.list.old |grep RELEASECODENAME |grep -v "#" |sed 's|us.archive.|old-releases.|g' >> sources.list

(del and retype >> in console if error occures)

 

https://www.tech-notes.net/issues-wit-apt-ubuntu-12-04/

https://stackoverflow.com/questions/38743951/unable-to-fetch-some-archives-maybe-run-apt-get-update-or-try-with-fix-missin

https://askubuntu.com/questions/91815/how-to-install-software-or-upgrade-from-an-old-unsupported-release/91821#91821

 

Resume a release upgrade:
https://askubuntu.com/questions/346678/how-do-i-resume-a-release-upgrade