i should be using a branch and this is my last push before branch

This commit is contained in:
Brandon Gulla
2020-08-28 19:32:40 -04:00
parent 592963578c
commit 722f311fc8
3 changed files with 43 additions and 6 deletions

View File

@@ -23,10 +23,15 @@
```
WARNING- Work In Progress
## Prerequisites
* CentOS 7
* User with root/sudo privileges
*
## Installing on an airgap network
1) (Skip if you aren't using SELINUX) Install the `selinux` dependencies. `yum localinstall -y ./artifacts/yum/*`.
2)
2) For some reason, centos doesn't add `/usr/local/bin` to the path. Add it with `echo 'export PATH=${PATH}:/usr/local/bin' >> ~/.bashrc`
3)

View File

@@ -45,6 +45,12 @@ uninstall_k3s(){
fi
}
check_deps(){
#TODO
echo "TODO: check to ensure that the dependencies are in place."
#rpm -qa | grep k3s-selinux
}
#gather_selinux_rpms(){
# if ! yum list installed yum-utils >/dev/null 2>&1; then
# yum install -y yum-utils
@@ -78,14 +84,30 @@ check_selinux(){
fi
}
copy_yaml_manifests(){
cp -r ./yaml/* /var/lib/rancher/k3s/server/manifests
}
copy_local_bins(){
if [ -f "./artifacts/k9s" ]; then
cp -v ./artifacts/k9s /usr/local/bin/
fi
}
copy_local_kubectl(){
echo "TODO"
}
iptable_block_docker_io() {
# iptables -A OUTPUT -p tcp -m string --string "docker.io" --algo kmp -j REJECT
echo "iptable_block_docker_io() disabled"
}
## TODO: Make this interactive with case statements
# debug
uninstall_k3s
copy_local_bins
iptable_block_docker_io
check_deps
check_firewalld
#check_selinux
install_k3s ./artifacts/k3s-airgap-images-amd64.tar
@@ -93,4 +115,14 @@ copy_images
copy_yaml_manifests
/usr/local/bin/k3s kubectl get pods -A -w
/usr/local/bin/k3s kubectl get pods -A -w
#######
# Notes:
# - workaround: busybox is not included in the main images.txt list and therefor the pvcs cannot create.
# - VAGRANT FAIL: INFO[0000] Preparing data dir /var/lib/rancher/k3s/data ... for some reason local-path provisioner cannot create vols in vagrant
# - bug: RunContainerError results you try to reinstall k3s on top of an old instance WHEN RUNNING SELINUX
#######

View File

@@ -104,7 +104,7 @@ spec:
- ReadWriteOnce
resources:
requests:
storage: 20Gi
storage: 1Gi
---
@@ -166,4 +166,4 @@ spec:
- backend:
serviceName: registrysvc
servicePort: 5000
pathType: ImplementationSpecific
pathType: ImplementationSpecific