Git Product home page Git Product logo

flux2-gitops's Introduction

k3s flux renovate

k8s clusters backed by Flux v2

Kubernetes clusters using the GitOps tool Flux.
The Git repository is the driving the state of the Kubernetes clusters.
The awesome Flux SOPS integration is used to encrypt secrets with gpg.

๐Ÿ“‚ Repository structure

The Git repository contains the following directories:

๐Ÿ“
โ”œโ”€๐Ÿ“ apps
โ”‚  โ”œโ”€๐Ÿ“ all          # apps available for intallation
โ”‚  โ””โ”€๐Ÿ“ production   # kustomization and overlays for app installations per cluster
โ”œโ”€๐Ÿ“ base
โ”‚  โ”œโ”€๐Ÿ“ flux-system  # flux & gitops operator
โ”‚  โ””โ”€๐Ÿ“ production   # flux configuration per cluster
โ”œโ”€๐Ÿ“ charts          # helm chart repos
โ”œโ”€๐Ÿ“ config          # configs per cluster
โ””โ”€๐Ÿ“ crds            # custom resources required by apps

๐Ÿ’ปย  Software

The following apps are installed on the clusters.

Software Purpose
Flux2 GitOps Tool managing the cluster
Longhorn Persistent Block Storage Provisioner
NGINX Ingress Controller Cluster Ingress controller
MetalLB Bare metal LoadBalancer
Cert-Manager Letsencrypt certificates with Cloudflare DNS
ExternalDNS Configure Cloudflare DNS Servers
kube-vip Virtual IP Load-Balancer for Control Plane High Availability
Kube-Prometheus Stack Prometheus & Exporters to monitor the cluster
Grafana Monitoring & Logging Dashboard
Alertmanager Monitoring Alerts
Grafana Loki Log aggregation system
System Upgrade Controller Automated k3s upgrades
Weave GitOps Powerful WebUI extension to Flux for deployment insights
MinIO Amazon S3 compatible high Performance Object Storage
Authelia SSO & 2FA authentication server for Cluster Web Apps
Paperless-ngx Document management system
Rancher Kubernetes Management Dashboard
Homer Static dashboard for the cluster applications
Pod-Gateway Route traffic through a VPN gateway
Descheduler Evicts pods to optimize scheduling
Goldilocks Utility to help identifying good resource requests and limits
X.509 Certificate Exporter A Prometheus exporter to monitor x509 certificates
SMB CSI Driver CSI Driver for SMB
kured Kubernetes Reboot Daemon (only used for Monitoring)
Kubernetes Metrics Server Source of container resource metrics for Kubernetes

๐Ÿค–ย  Automation

Renovate Bot makes sure the components are never outdated.

It creates PullRequests when Helm charts or Docker images have newer versions available and even keeps Flux and k3s up-to-date.

๐Ÿคย  Thanks

Big shout out to k8s@home and everyone from awesome-home-kubernetes for the inspiration โค๏ธ

๐Ÿ“–ย  Notes

๐Ÿ“ Installation Notes

tl;dr

kubectl create namespace flux-system --dry-run=client -o yaml | kubectl apply -f -
sops -d ./base/flux-system/init/flux-sops-gpg-secret.sops.yaml | kubectl apply -f -
sops -d ./base/flux-system/init/flux-secret.sops.yaml | kubectl apply -f -
kubectl apply --kustomize=./base/flux-system
kubectl apply --kustomize=./base/staging
  1. Pre-create the flux-system namespace
kubectl create namespace flux-system --dry-run=client -o yaml | kubectl apply -f -
  1. Add the Flux GPG key in-order for Flux to decrypt SOPS secrets
sops -d ./base/flux-system/init/flux-sops-gpg-secret.sops.yaml | kubectl apply -f -
  1. (Optional) Add the Flux SSH key in-order for Flux to pull private git repositories
sops -d ./base/flux-system/init/flux-secret.sops.yaml | kubectl apply -f -
  1. Install Flux
kubectl apply --kustomize=./base/flux-system
  1. Configure Flux
kubectl apply --kustomize=./base/staging

flux2-gitops's People

Contributors

renovate[bot] avatar pumba98 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.