#!/bin/bash# Checkifuserisrootif [ "$UID"-ne0 ]; thenecho"You are not the root user."exit1fiecho"You are the root user."# Checkifk3s-killall.shexistsin/usr/local/binif [ -f"/usr/local/bin/k3s-killall.sh" ]; thenecho"Executing k3s-killall.sh..."/usr/local/bin/k3s-killall.shelseecho"k3s-killall.sh does not exist in /usr/local/bin."fi# Checkifk3s-uninstall.shexistsin/usr/local/binif [ -f"/usr/local/bin/k3s-uninstall.sh" ]; thenecho"Executing k3s-uninstall.sh..."/usr/local/bin/k3s-uninstall.shelseecho"k3s-uninstall.sh does not exist in /usr/local/bin."fiaptinstalliptablesiptables-save|awk'/^[*]/ { print $1 } /COMMIT/ { print $0; }'|sudoiptables-restoreiptables-Siptables-Fupdate-alternatives--setiptables/usr/sbin/iptables-legacyupdate-alternatives--setip6tables/usr/sbin/ip6tables-legacyreboot
#!/bin/bash# Checkifuserisrootif [ "$UID"-ne0 ]; thenecho"You are not the root user."exit1fiecho"You are the root user."# Checkifk3s-killall.shexistsin/usr/local/binif [ -f"/usr/local/bin/k3s-killall.sh" ]; thenecho"Executing k3s-killall.sh..."/usr/local/bin/k3s-killall.shelseecho"k3s-killall.sh does not exist in /usr/local/bin."fi# Checkifk3s-agent-uninstall.shexistsin/usr/local/binif [ -f"/usr/local/bin/k3s-agent-uninstall.sh" ]; thenecho"Executing k3s-agent-uninstall.sh..."/usr/local/bin/k3s-agent-uninstall.shelseecho"k3s-agent-uninstall.sh does not exist in /usr/local/bin."fiaptinstalliptablesiptables-save|awk'/^[*]/ { print $1 } /COMMIT/ { print $0; }'|sudoiptables-restoreiptables-Siptables-Fupdate-alternatives--setiptables/usr/sbin/iptables-legacyupdate-alternatives--setip6tables/usr/sbin/ip6tables-legacyreboot
#!/bin/bash# Checkifuserisrootif [ "$UID"-ne0 ]; thenecho"You are not the root user."exit1fiecho"You are the root user."# Checkifrancherd-killall.shexistsin/usr/local/binif [ -f"/usr/local/bin/rancherd-killall.sh" ]; thenecho"Executing rancherd-killall.sh..."/usr/local/bin/rancherd-killall.shelseecho"rancherd-killall.sh does not exist in /usr/local/bin."fi# Checkifrancherd-uninstall.shexistsin/usr/local/binif [ -f"/usr/local/bin/rancherd-uninstall.sh" ]; thenecho"Executing rancherd-uninstall.sh..."/usr/local/bin/rancherd-uninstall.shelseecho"rancherd-uninstall.sh does not exist in /usr/local/bin."fiaptinstalliptablesiptables-save|awk'/^[*]/ { print $1 } /COMMIT/ { print $0; }'|sudoiptables-restoreiptables-Siptables-Fupdate-alternatives--setiptables/usr/sbin/iptables-legacyupdate-alternatives--setip6tables/usr/sbin/ip6tables-legacyreboot
Add cgroup entries into the cmdline.txt on each nodes that is running on ARM processor.#
1
sudo vim /boot/cmdline.txt
Add at the end of the line that starts with console= the below entries:
The sample below uses the NGINX ingress controller to establish a deployment and expose it. Because SSL will be utilized by default and produce an error for a nonexistent certificate, it’s critical to pay attention to the annotation nginx.ingress.kubernetes.io/ssl-redirect: “false”.
The domain name that is used is another crucial factor. I’m going to use the domain name test.localhost, but you should obviously change it to your own and direct it to your k3s instance node.
Create a file called my-example.yaml and use the following syntax to implement this example for Ingress testing:
Comments