Skip to content

rossf7/green-k8s-lab

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

67 Commits
 
 
 
 
 
 
 
 

Repository files navigation

green-k8s-lab

My home lab. A bare metal Kubernetes cluster running K3s for experimenting with green software tools. Especially for measuring energy consumption using RAPL.

Install K3s

curl -sfL https://get.k3s.io | sh -s -- --flannel-backend none \
  --disable traefik \
  --disable-network-policy

Copy kubeconfig

mkdir -p ~/.kube
sudo cp /etc/rancher/k3s/k3s.yaml ~/.kube/config
sudo chown $(whoami):$(whoami) ~/.kube/config

Install Cilium CNI

CILIUM_CLI_VERSION=$(curl -s https://raw.githubusercontent.com/cilium/cilium-cli/main/stable.txt)
CLI_ARCH=amd64
if [ "$(uname -m)" = "aarch64" ]; then CLI_ARCH=arm64; fi
curl -L --fail --remote-name-all https://github.com/cilium/cilium-cli/releases/download/${CILIUM_CLI_VERSION}/cilium-linux-${CLI_ARCH}.tar.gz{,.sha256sum}
sha256sum --check cilium-linux-${CLI_ARCH}.tar.gz.sha256sum
sudo tar xzvfC cilium-linux-${CLI_ARCH}.tar.gz /usr/local/bin
rm cilium-linux-${CLI_ARCH}.tar.gz{,.sha256sum}
cilium install
cilium status --wait

Bootstrap Flux

export GITHUB_TOKEN=***your_token***
export GITHUB_USER=***your_user***

curl -s https://fluxcd.io/install.sh | sudo bash
flux bootstrap github \
  --owner=$GITHUB_USER \
  --repository=green-k8s-lab \
  --branch=main \
  --path=clusters \
  --personal

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published