From eeeb8157d1c4efa511ae1cf0f665fd175b33346e Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Mon, 30 Mar 2026 22:43:35 +0300 Subject: Update content for html --- gemfeed/atom.xml | 1156 ++++++++++++++++++++++++++++++++++++++++-------------- 1 file changed, 871 insertions(+), 285 deletions(-) (limited to 'gemfeed/atom.xml') diff --git a/gemfeed/atom.xml b/gemfeed/atom.xml index 33188a8e..0f27f0e8 100644 --- a/gemfeed/atom.xml +++ b/gemfeed/atom.xml @@ -1,11 +1,671 @@ - 2026-03-30T09:16:50+03:00 + 2026-03-30T22:42:23+03:00 foo.zone feed To be in the .zone! https://foo.zone/ + + f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD + + https://foo.zone/gemfeed/2026-04-02-f3s-kubernetes-with-freebsd-part-9.html + 2026-04-02T00:00:00+03:00 + + Paul Buetow aka snonux + paul@dev.buetow.org + + This is the 9th post in the f3s series about my self-hosting home lab. f3s? The 'f' stands for FreeBSD, and the '3s' stands for k3s, the Kubernetes distribution I use on FreeBSD-based physical machines. + +
+

f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD


+
+Published at 2026-04-02T00:00:00+03:00
+
+This is the 9th post in the f3s series about my self-hosting home lab. f3s? The "f" stands for FreeBSD, and the "3s" stands for k3s, the Kubernetes distribution I use on FreeBSD-based physical machines.
+
+2024-11-17 f3s: Kubernetes with FreeBSD - Part 1: Setting the stage
+2024-12-03 f3s: Kubernetes with FreeBSD - Part 2: Hardware and base installation
+2025-02-01 f3s: Kubernetes with FreeBSD - Part 3: Protecting from power cuts
+2025-04-05 f3s: Kubernetes with FreeBSD - Part 4: Rocky Linux Bhyve VMs
+2025-05-11 f3s: Kubernetes with FreeBSD - Part 5: WireGuard mesh network
+2025-07-14 f3s: Kubernetes with FreeBSD - Part 6: Storage
+2025-10-02 f3s: Kubernetes with FreeBSD - Part 7: k3s and first pod deployments
+2025-12-07 f3s: Kubernetes with FreeBSD - Part 8: Observability
+2026-04-02 f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD (You are currently reading this)
+
+f3s logo
+
+ArgoCD Application Resource Tree
+
+

Table of Contents


+
+
+

Introduction


+
+In previous posts, I deployed applications to the k3s cluster using Helm charts and Justfiles--running just install or just upgrade to push changes to the cluster. That worked, but it had some drawbacks:
+
+
    +
  • No single source of truth--cluster state depends on which commands were run and when
  • +
  • Every change requires manually running commands
  • +
  • No easy way to tell if the cluster drifted from the desired config
  • +
  • Rolling back means re-running old Helm commands
  • +
  • No audit trail for who changed what
  • +

+This post covers the migration to GitOps with ArgoCD. After this, the Git repo is the single source of truth, and ArgoCD keeps the cluster in sync automatically.
+
+

GitOps in a Nutshell


+
+The idea behind GitOps is simple: describe your entire desired state in Git, and let an agent in the cluster pull that state and reconcile it continuously. Every change goes through a commit, so you get version history, collaboration, and rollback for free.
+
+For Kubernetes specifically:
+
+
    +
  • All manifests, Helm charts, and config live in a Git repo
  • +
  • ArgoCD watches that repo
  • +
  • Push a change, ArgoCD applies it
  • +
  • If someone manually tweaks something in the cluster, ArgoCD detects the drift and reverts it
  • +

+

ArgoCD


+
+ArgoCD is a GitOps continuous delivery tool for Kubernetes. It runs as a controller in the cluster, continuously comparing live state against what's defined in Git.
+
+ArgoCD Documentation
+
+The features I care about most for f3s:
+
+
    +
  • Automatic sync--monitors Git and applies changes to the cluster
  • +
  • Application CRDs--each app is a Kubernetes custom resource
  • +
  • Health checks--knows whether an app is healthy or degraded
  • +
  • Web UI--visual overview of all applications and their sync status
  • +
  • Sync waves and hooks--control deployment order and run post-deploy jobs
  • +
  • Multi-source--combine upstream Helm charts with custom manifests
  • +

+

Why Bother for a Home Lab?


+
+Honestly, the biggest reason is disaster recovery. If the cluster dies, I can:
+
+
    +
  • Bootstrap a fresh k3s cluster
  • +
  • Install ArgoCD
  • +
  • Point it at the Git repo
  • +
  • Everything deploys automatically
  • +

+That's it. No "let me check my shell history to remember how I set this up."
+
+It's also a great way to learn. Setting up GitOps for real--even on a small cluster--teaches you things you won't pick up from tutorials alone. Debugging sync issues, figuring out sync waves, dealing with secrets management--all stuff that's directly applicable at work too.
+
+Beyond that: push to Git, things deploy. No SSH'ing to a workstation to run Helm commands. And if I manually tweak something while debugging and forget about it, ArgoCD reverts it back to the desired state. That's happened more than once.
+
+

Deploying ArgoCD


+
+ArgoCD manages everything else via GitOps, but ArgoCD itself needs a bootstrap. Chicken-and-egg problem.
+
+The installation lives in the config repo:
+
+codeberg.org/snonux/conf/f3s/argocd
+
+I deployed it using Helm via a Justfile:
+
+ +
$ cd conf/f3s/argocd
+$ just install
+helm repo add argo https://argoproj.github.io/argo-helm
+helm repo update
+kubectl create namespace cicd
+kubectl apply -f persistent-volumes.yaml
+helm install argocd argo/argo-cd --namespace cicd -f values.yaml
+kubectl apply -f ingress.yaml
+
+
+A few things worth noting in the values.yaml:
+
+Persistent storage for the repo-server so cloned Git repos survive pod restarts:
+
+
+repoServer:
+  volumes:
+    - name: repo-server-data
+      persistentVolumeClaim:
+        claimName: argocd-repo-server-pvc
+  volumeMounts:
+    - name: repo-server-data
+      mountPath: /home/argocd/repo-cache
+  env:
+    - name: XDG_CACHE_HOME
+      value: /home/argocd/repo-cache
+
+
+Server runs in insecure mode since TLS is terminated by the OpenBSD edge relays (same pattern as all other f3s services):
+
+
+server:
+  insecure: true
+configs:
+  params:
+    server.insecure: true
+
+
+Dex (SSO) and notifications are disabled--overkill for a single-user home lab:
+
+
+dex:
+  enabled: false
+notifications:
+  enabled: false
+
+
+The admin password is auto-generated on first install and stored in argocd-initial-admin-secret. It's preserved across Helm upgrades, so no manual secret creation needed:
+
+ +
$ just get-password
+# Reads from argocd-initial-admin-secret
+
+
+

Accessing ArgoCD


+
+After deployment, ArgoCD runs in the cicd namespace:
+
+ +
$ kubectl get pods -n cicd
+NAME                                                READY   STATUS    RESTARTS   AGE
+argocd-application-controller-0                     1/1     Running   0          45d
+argocd-applicationset-controller-66d6b9b8f4-vhm9k   1/1     Running   0          45d
+argocd-redis-77b8d6c6d4-mz9hg                       1/1     Running   0          45d
+argocd-repo-server-5f98f77b97-8xtcq                 1/1     Running   0          45d
+argocd-server-6b9c4b4f8d-kxw7p                      1/1     Running   0          45d
+
+
+ArgoCD login page
+
+The ingress exposes both a WAN and LAN endpoint:
+
+
+# WAN access (via OpenBSD relayd)
+- host: argocd.f3s.foo.zone
+# LAN access (via FreeBSD CARP VIP, with TLS)
+- host: argocd.f3s.lan.foo.zone
+
+
+

In-Cluster Git Server


+
+I didn't want ArgoCD pulling from Codeberg over the internet every time it checks for changes. If Codeberg is down (or my internet is), the cluster can't reconcile. So I set up a Git server inside the cluster itself.
+
+codeberg.org/snonux/conf/f3s/git-server (at 190473b)
+
+The git-server runs as a single pod in the cicd namespace with two containers sharing a PVC:
+
+
    +
  • An SSH git server (Alpine + OpenSSH + git-shell) for pushing changes from my laptop
  • +
  • A CGit web UI with git-http-backend (nginx + fcgiwrap) for browsing repos and HTTP clones
  • +

+ArgoCD uses the HTTP backend to clone repos. Most Application manifests point at:
+
+
+http://git-server.cicd.svc.cluster.local/conf.git
+
+
+For pushing, I use SSH via a NodePort (30022). The git user is locked down to git-shell--no actual shell access. SSH keys are managed through a Kubernetes Secret.
+
+There's a chicken-and-egg situation here. The git-server's own ArgoCD Application manifest points at Codeberg (not at itself), since ArgoCD needs to bootstrap the git-server before it can use it:
+
+
+# argocd-apps/cicd/git-server.yaml
+source:
+  repoURL: https://codeberg.org/snonux/conf.git
+  targetRevision: master
+  path: f3s/git-server/helm-chart
+
+
+Once the pod is up, all other apps use the in-cluster URL. The dependency chain is: Codeberg -> git-server -> everything else.
+
+The repo storage lives on NFS. Initial setup was just cloning the Codeberg repo as a bare repo into the NFS volume, then pointing my laptop's git remote at the NodePort:
+
+ +
$ git remote add f3s f3s-git:/repos/conf.git
+$ git push f3s master
+
+
+ArgoCD detects the change within a few minutes and syncs. No internet required. The whole thing is intentionally minimal--no database, no accounts, no webhooks. Just git over SSH for writes and HTTP for reads.
+
+

Repository Organization


+
+I reorganized the config repo to support GitOps. Application manifests are grouped by Kubernetes namespace:
+
+
+/home/paul/git/conf/f3s/
+├── argocd-apps/
+│   ├── cicd/                  # CI/CD tooling (2 apps)
+│   │   ├── argo-rollouts.yaml
+│   │   └── git-server.yaml
+│   ├── infra/                 # Infrastructure (4 apps)
+│   │   ├── cert-manager.yaml
+│   │   ├── pkgrepo.yaml
+│   │   ├── registry.yaml
+│   │   └── traefik-config.yaml
+│   ├── monitoring/            # Observability stack (6 apps)
+│   │   ├── alloy.yaml
+│   │   ├── grafana-ingress.yaml
+│   │   ├── loki.yaml
+│   │   ├── prometheus.yaml
+│   │   ├── pushgateway.yaml
+│   │   └── tempo.yaml
+│   ├── services/              # User-facing applications (18 apps)
+│   │   ├── anki-sync-server.yaml
+│   │   ├── apache.yaml
+│   │   ├── audiobookshelf.yaml
+│   │   ├── filebrowser.yaml
+│   │   ├── immich.yaml
+│   │   ├── ipv6test.yaml
+│   │   ├── jellyfin.yaml
+│   │   ├── keybr.yaml
+│   │   ├── kobo-sync-server.yaml
+│   │   ├── miniflux.yaml
+│   │   ├── navidrome.yaml
+│   │   ├── opodsync.yaml
+│   │   ├── pihole.yaml
+│   │   ├── radicale.yaml
+│   │   ├── syncthing.yaml
+│   │   ├── tracing-demo.yaml
+│   │   ├── wallabag.yaml
+│   │   └── webdav.yaml
+│   └── test/                  # Test/example applications
+├── miniflux/                  # Per-app directories (unchanged)
+│   ├── helm-chart/
+│   │   ├── Chart.yaml
+│   │   ├── values.yaml
+│   │   └── templates/
+│   └── Justfile
+├── prometheus/
+│   ├── manifests/             # Additional manifests for multi-source
+│   └── Justfile
+└── ...
+
+
+The per-app directories (miniflux, prometheus, etc.) stayed mostly the same--ArgoCD points at the same Helm charts. The main additions are the argocd-apps/ directory structure and manifests/ subdirectories for complex apps.
+
+

Migrating an App: Miniflux as Example


+
+I migrated all apps incrementally, one at a time. The procedure was the same for each. Here's miniflux as a concrete example.
+
+Before ArgoCD, the Justfile looked like this:
+
+ +
install:
+    kubectl apply -f helm-chart/persistent-volumes.yaml
+    helm install miniflux ./helm-chart --namespace services
+
+upgrade:
+    helm upgrade miniflux ./helm-chart --namespace services
+
+uninstall:
+    helm uninstall miniflux --namespace services
+
+
+Workflow: edit chart, run just upgrade, hope you didn't forget anything.
+
+To migrate, I created an Application manifest telling ArgoCD where the Helm chart lives and how to sync it:
+
+
+apiVersion: argoproj.io/v1alpha1
+kind: Application
+metadata:
+  name: miniflux
+  namespace: cicd
+  finalizers:
+    - resources-finalizer.argocd.argoproj.io
+spec:
+  project: default
+  source:
+    repoURL: http://git-server.cicd.svc.cluster.local/conf.git
+    targetRevision: master
+    path: f3s/miniflux/helm-chart
+  destination:
+    server: https://kubernetes.default.svc
+    namespace: services
+  syncPolicy:
+    automated:
+      prune: true
+      selfHeal: true
+    syncOptions:
+      - CreateNamespace=false
+    retry:
+      limit: 3
+      backoff:
+        duration: 5s
+        factor: 2
+        maxDuration: 1m
+
+
+Then applied it:
+
+ +
# 1. Apply the Application manifest
+$ kubectl apply -f argocd-apps/services/miniflux.yaml
+application.argoproj.io/miniflux created
+
+# 2. Verify ArgoCD adopted the existing resources
+$ argocd app get miniflux
+Name:               miniflux
+Sync Status:        Synced to master (4e3c216)
+Health Status:      Healthy
+
+# 3. Test that the app still works
+$ curl -I https://flux.f3s.foo.zone
+HTTP/2 200
+
+
+About 10 minutes, zero downtime. ArgoCD recognised the already-running resources matched the Helm chart in Git and adopted them without re-deploying.
+
+After the migration, the Justfile turned into utility commands--no more install/upgrade/uninstall:
+
+ +
status:
+    @kubectl get pods -n services -l app=miniflux-server
+    @kubectl get pods -n services -l app=miniflux-postgres
+    @kubectl get application miniflux -n cicd \
+        -o jsonpath='Sync: {.status.sync.status}, Health: {.status.health.status}'
+
+sync:
+    @kubectl annotate application miniflux -n cicd \
+        argocd.argoproj.io/refresh=normal --overwrite
+
+logs:
+    kubectl logs -n services -l app=miniflux-server --tail=100 -f
+
+restart:
+    kubectl rollout restart -n services deployment/miniflux-server
+
+port-forward port="8080":
+    kubectl port-forward -n services svc/miniflux {{port}}:8080
+
+psql:
+    kubectl exec -it -n services deployment/miniflux-postgres -- psql -U miniflux
+
+
+New workflow: edit chart, commit, push. ArgoCD picks it up within a few minutes. Run just sync if you're impatient.
+
+

Migration Order


+
+I started with the simplest services (miniflux, wallabag, radicale, etc.)--apps with straightforward Helm charts and no complex dependencies. This let me validate the pattern before touching anything critical.
+
+After that: infrastructure apps (registry, cert-manager, pkgrepo, traefik-config), then the monitoring stack (tempo, loki, alloy, and finally prometheus--the most complex one), and last the CI/CD tools (git-server, argo-rollouts).
+
+

Complex Migration: Prometheus Multi-Source


+
+Prometheus was the tricky one. It combines an upstream Helm chart with a bunch of custom manifests--recording rules, dashboards, persistent volumes, and a post-sync hook to restart Grafana.
+
+ArgoCD's multi-source feature handles this cleanly:
+
+
+apiVersion: argoproj.io/v1alpha1
+kind: Application
+metadata:
+  name: prometheus
+  namespace: cicd
+spec:
+  sources:
+    # Source 1: Upstream Helm chart
+    - repoURL: https://prometheus-community.github.io/helm-charts
+      chart: kube-prometheus-stack
+      targetRevision: 55.5.0
+      helm:
+        releaseName: prometheus
+        valuesObject:
+          kubeEtcd:
+            enabled: true
+            endpoints:
+              - 192.168.2.120
+              - 192.168.2.121
+              - 192.168.2.122
+          # ... hundreds of lines of config
+
+    # Source 2: Custom manifests from Git
+    - repoURL: http://git-server.cicd.svc.cluster.local/conf.git
+      targetRevision: master
+      path: f3s/prometheus/manifests
+
+  syncPolicy:
+    automated:
+      prune: false  # Manual pruning--too risky for the monitoring stack
+      selfHeal: true
+    syncOptions:
+      - ServerSideApply=true
+
+
+The prometheus/manifests/ directory has 13 files, each with a sync wave annotation to control deployment order:
+
+
+f3s/prometheus/manifests/
+├── persistent-volumes.yaml              # Wave 0
+├── grafana-restart-rbac.yaml            # Wave 0
+├── additional-scrape-configs-secret.yaml # Wave 1
+├── grafana-datasources-configmap.yaml   # Wave 1
+├── freebsd-recording-rules.yaml         # Wave 3
+├── openbsd-recording-rules.yaml         # Wave 3
+├── zfs-recording-rules.yaml             # Wave 3
+├── argocd-application-alerts.yaml       # Wave 3
+├── epimetheus-dashboard.yaml            # Wave 4
+├── zfs-dashboards.yaml                  # Wave 4
+├── argocd-applications-dashboard.yaml   # Wave 4
+├── node-resources-multi-select-dashboard.yaml # Wave 4
+├── prometheus-nodeport.yaml             # Wave 4
+└── grafana-restart-hook.yaml            # Wave 10 (PostSync)
+
+
+

Sync Waves


+
+Without sync waves, ArgoCD deploys all resources at once in no particular order. That's fine for simple apps, but for something like Prometheus it causes failures--a PersistentVolumeClaim can't bind if the PersistentVolume doesn't exist yet, and a PrometheusRule can't be created if the CRD hasn't been registered.
+
+Sync waves fix this. You annotate each resource with a wave number:
+
+
+annotations:
+  argocd.argoproj.io/sync-wave: "3"
+
+
+ArgoCD deploys all wave 0 resources first, waits until they're healthy, then moves to wave 1, waits again, and so on. Resources without the annotation default to wave 0.
+
+For the Prometheus stack, the waves look like this:
+
+
    +
  • Wave 0: PersistentVolumes, RBAC--infrastructure that everything else depends on
  • +
  • Wave 1: Secrets, ConfigMaps--config that Prometheus and Grafana need at startup
  • +
  • Wave 3: PrometheusRule CRDs--recording rules for FreeBSD, OpenBSD, ZFS, ArgoCD (the operator from wave 0 needs to be running first)
  • +
  • Wave 4: Dashboard ConfigMaps and nodeport config
  • +
  • Wave 10: PostSync hook--a Job that runs after all waves complete
  • +

+The PostSync hook is worth explaining. ArgoCD supports lifecycle hooks (PreSync, Sync, PostSync) that run Jobs at specific points. The Grafana restart hook is a good example--it restarts Grafana after every sync so it picks up updated datasources and dashboards:
+
+
+apiVersion: batch/v1
+kind: Job
+metadata:
+  name: grafana-restart-hook
+  namespace: monitoring
+  annotations:
+    argocd.argoproj.io/hook: PostSync
+    argocd.argoproj.io/hook-delete-policy: BeforeHookCreation
+    argocd.argoproj.io/sync-wave: "10"
+spec:
+  template:
+    spec:
+      serviceAccountName: grafana-restart-sa
+      restartPolicy: OnFailure
+      containers:
+        - name: kubectl
+          image: bitnami/kubectl:latest
+          command:
+            - /bin/sh
+            - -c
+            - |
+              kubectl wait --for=condition=available --timeout=300s \
+                deployment/prometheus-grafana -n monitoring || true
+              kubectl delete pod -n monitoring \
+                -l app.kubernetes.io/name=grafana --ignore-not-found=true
+  backoffLimit: 2
+
+
+

The Result


+
+All 30 applications across 5 namespaces, synced and healthy:
+
+ +
$ argocd app list
+NAME                      CLUSTER                         NAMESPACE    PROJECT  STATUS  HEALTH   SYNCPOLICY
+alloy                     https://kubernetes.default.svc  monitoring   default  Synced  Healthy  Auto-Prune
+anki-sync-server          https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+apache                    https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+argo-rollouts             https://kubernetes.default.svc  cicd         default  Synced  Healthy  Auto-Prune
+audiobookshelf            https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+cert-manager              https://kubernetes.default.svc  infra        default  Synced  Healthy  Auto-Prune
+filebrowser               https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+git-server                https://kubernetes.default.svc  cicd         default  Synced  Healthy  Auto-Prune
+grafana-ingress           https://kubernetes.default.svc  monitoring   default  Synced  Healthy  Auto-Prune
+immich                    https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+ipv6test                  https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+jellyfin                  https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+keybr                     https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+kobo-sync-server          https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+loki                      https://kubernetes.default.svc  monitoring   default  Synced  Healthy  Auto-Prune
+miniflux                  https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+navidrome                 https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+opodsync                  https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+pihole                    https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+pkgrepo                   https://kubernetes.default.svc  infra        default  Synced  Healthy  Auto-Prune
+prometheus                https://kubernetes.default.svc  monitoring   default  Synced  Healthy  Auto
+pushgateway               https://kubernetes.default.svc  monitoring   default  Synced  Healthy  Auto-Prune
+radicale                  https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+registry                  https://kubernetes.default.svc  infra        default  Synced  Healthy  Auto-Prune
+syncthing                 https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+tempo                     https://kubernetes.default.svc  monitoring   default  Synced  Healthy  Auto-Prune
+traefik-config            https://kubernetes.default.svc  infra        default  Synced  Healthy  Auto-Prune
+tracing-demo              https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+wallabag                  https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+webdav                    https://kubernetes.default.svc  services     default  Synced  Healthy  Auto-Prune
+
+
+ArgoCD managing all 30 applications in the f3s cluster
+
+

What Changed Day-to-Day


+
+The practical difference is pretty big:
+
+
    +
  • Single source of truth--clone the repo, look at argocd-apps/, and you know exactly what's running. No more helm list or guessing.
  • +
  • Push and forget--edit a Helm value, commit, push. ArgoCD picks it up within a few minutes. No SSH, no just upgrade.
  • +
  • Self-healing--I've tweaked things manually for debugging, forgotten about it, and ArgoCD quietly reverted it. That's saved me from some confusing "why is this behaving differently?" moments.
  • +
  • Rollback = git revert--git revert HEAD && git push and ArgoCD syncs back to the previous state.
  • +
  • Disaster recovery--bootstrap k3s, install ArgoCD, apply the Application manifests, wait. The cluster rebuilds itself. I haven't had to do this for real yet, but I've tested it and it works.
  • +
  • Drift detection--the ArgoCD UI shows immediately if something is out of sync. Much better than running kubectl commands and comparing output manually.
  • +

+

Challenges Along the Way


+
+

Helm Release Adoption


+
+When ArgoCD tries to manage resources already deployed by Helm, it can get confused. The fix: make sure the Application manifest matches the current Helm values exactly. ArgoCD then recognizes the resources and adopts them without re-deploying.
+
+

PersistentVolumes


+
+PVs are cluster-scoped, and many of my Helm charts created them with kubectl apply outside of Helm. For simple apps I moved PV definitions into the Helm chart templates. For complex apps like Prometheus, I used the multi-source pattern with PVs in a separate manifests/ directory at sync wave 0.
+
+

Secrets


+
+Secrets shouldn't live in Git as plaintext. For now, I create them manually with kubectl create secret and reference them from Helm charts. ArgoCD doesn't manage the secrets themselves. This works fine but isn't fully declarative--External Secrets Operator is on the list for the future.
+
+

Grafana Not Reloading


+
+After updating datasource ConfigMaps, Grafana wouldn't notice until the pod was restarted. The PostSync hook (the Grafana restart Job in sync wave 10) handles this automatically now.
+
+

Prometheus Multi-Source Ordering


+
+Without sync waves, Prometheus resources deployed in random order and things broke. PVs need to exist before PVCs, secrets before the operator, recording rules after the CRDs are registered. Adding sync wave annotations to everything in prometheus/manifests/ fixed all the ordering issues.
+
+

Wrapping Up


+
+The migration took a couple of days, doing one or two apps at a time. The result: 30 applications across 5 namespaces, all managed declaratively through Git. Push a change, it deploys. Break something, git revert. Cluster dies, rebuild from the repo.
+
+All the config lives here:
+
+codeberg.org/snonux/conf/f3s
+
+ArgoCD Application manifests organized by namespace:
+
+codeberg.org/snonux/conf/f3s/argocd-apps
+
+I can't imagine going back to running Helm commands manually.
+
+Other *BSD-related posts:
+
+2026-04-02 f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD (You are currently reading this)
+2025-12-07 f3s: Kubernetes with FreeBSD - Part 8: Observability
+2025-10-02 f3s: Kubernetes with FreeBSD - Part 7: k3s and first pod deployments
+2025-07-14 f3s: Kubernetes with FreeBSD - Part 6: Storage
+2025-05-11 f3s: Kubernetes with FreeBSD - Part 5: WireGuard mesh network
+2025-04-05 f3s: Kubernetes with FreeBSD - Part 4: Rocky Linux Bhyve VMs
+2025-02-01 f3s: Kubernetes with FreeBSD - Part 3: Protecting from power cuts
+2024-12-03 f3s: Kubernetes with FreeBSD - Part 2: Hardware and base installation
+2024-11-17 f3s: Kubernetes with FreeBSD - Part 1: Setting the stage
+2024-04-01 KISS high-availability with OpenBSD
+2024-01-13 One reason why I love OpenBSD
+2022-10-30 Installing DTail on OpenBSD
+2022-07-30 Let's Encrypt with OpenBSD and Rex
+2016-04-09 Jails and ZFS with Puppet on FreeBSD
+
+E-Mail your comments to paul@nospam.buetow.org :-)
+
+Back to the main site
+
+
+
Distributed Systems Simulator - Part 3: Advanced Examples and Protocol API @@ -4539,6 +5199,7 @@ $ curl -s -G "http://localhost:3200/api/search" \ 2025-07-14 f3s: Kubernetes with FreeBSD - Part 6: Storage
2025-10-02 f3s: Kubernetes with FreeBSD - Part 7: k3s and first pod deployments
2025-12-07 f3s: Kubernetes with FreeBSD - Part 8: Observability (You are currently reading this)
+2026-04-02 f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD

f3s logo

@@ -4634,10 +5295,10 @@ $ curl -s -G "http://localhost:3200/api/search" \ by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
$ git clone https://codeberg.org/snonux/conf.git
-$ cd conf
-$ git checkout 15a86f3  # Last commit before ArgoCD migration
-$ cd f3s/prometheus/
+
$ git clone https://codeberg.org/snonux/conf.git
+$ cd conf
+$ git checkout 15a86f3  # Last commit before ArgoCD migration
+$ cd f3s/prometheus/
 

**Current master branch** contains the ArgoCD-managed versions with:
@@ -4674,8 +5335,8 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
$ kubectl create namespace monitoring
-namespace/monitoring created
+
$ kubectl create namespace monitoring
+namespace/monitoring created
 

Installing Prometheus and Grafana


@@ -4690,8 +5351,8 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
$ helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
-$ helm repo update
+
$ helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
+$ helm repo update
 

Create the directories on the NFS server for persistent storage:
@@ -4700,8 +5361,8 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
[root@r0 ~]# mkdir -p /data/nfs/k3svolumes/prometheus/data
-[root@r0 ~]# mkdir -p /data/nfs/k3svolumes/grafana/data
+
[root@r0 ~]# mkdir -p /data/nfs/k3svolumes/prometheus/data
+[root@r0 ~]# mkdir -p /data/nfs/k3svolumes/grafana/data
 

Deploying with the Justfile


@@ -4717,18 +5378,18 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
$ cd conf/f3s/prometheus
-$ just install
-kubectl apply -f persistent-volumes.yaml
-persistentvolume/prometheus-data-pv created
-persistentvolume/grafana-data-pv created
-persistentvolumeclaim/grafana-data-pvc created
-helm install prometheus prometheus-community/kube-prometheus-stack \
-    --namespace monitoring -f persistence-values.yaml
-NAME: prometheus
-LAST DEPLOYED: ...
-NAMESPACE: monitoring
-STATUS: deployed
+
$ cd conf/f3s/prometheus
+$ just install
+kubectl apply -f persistent-volumes.yaml
+persistentvolume/prometheus-data-pv created
+persistentvolume/grafana-data-pv created
+persistentvolumeclaim/grafana-data-pvc created
+helm install prometheus prometheus-community/kube-prometheus-stack \
+    --namespace monitoring -f persistence-values.yaml
+NAME: prometheus
+LAST DEPLOYED: ...
+NAMESPACE: monitoring
+STATUS: deployed
 

The persistence-values.yaml configures Prometheus and Grafana to use the NFS-backed persistent volumes I mentioned earlier, ensuring data survives pod restarts. It also enables scraping of etcd and kube-controller-manager metrics:
@@ -4767,12 +5428,12 @@ kubeControllerManager: by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
[root@r0 ~]# cat >> /etc/rancher/k3s/config.yaml << 'EOF'
-kube-controller-manager-arg:
-  - bind-address=0.0.0.0
-etcd-expose-metrics: true
-EOF
-[root@r0 ~]# systemctl restart k3s
+
[root@r0 ~]# cat >> /etc/rancher/k3s/config.yaml << 'EOF'
+kube-controller-manager-arg:
+  - bind-address=0.0.0.0
+etcd-expose-metrics: true
+EOF
+[root@r0 ~]# systemctl restart k3s
 

Repeat for r1 and r2. After restarting all nodes, the controller-manager metrics endpoint will be accessible and etcd metrics are available on port 2381. Prometheus can now scrape both.
@@ -4783,8 +5444,8 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
[root@r0 ~]# curl -s http://127.0.0.1:2381/metrics | grep etcd_server_has_leader
-etcd_server_has_leader 1
+
[root@r0 ~]# curl -s http://127.0.0.1:2381/metrics | grep etcd_server_has_leader
+etcd_server_has_leader 1
 

The full persistence-values.yaml and all other Prometheus configuration files are available on Codeberg:
@@ -4805,9 +5466,9 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
$ kubectl get svc -n monitoring prometheus-kube-prometheus-prometheus
-NAME                                    TYPE        CLUSTER-IP      PORT(S)
-prometheus-kube-prometheus-prometheus   ClusterIP   10.43.152.163   9090/TCP,8080/TCP
+
$ kubectl get svc -n monitoring prometheus-kube-prometheus-prometheus
+NAME                                    TYPE        CLUSTER-IP      PORT(S)
+prometheus-kube-prometheus-prometheus   ClusterIP   10.43.152.163   9090/TCP,8080/TCP
 

Grafana connects to Prometheus using the internal service URL http://prometheus-kube-prometheus-prometheus.monitoring.svc.cluster.local:9090. The default Grafana credentials are admin/prom-operator, which should be changed immediately after first login.
@@ -4832,7 +5493,7 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
[root@r0 ~]# mkdir -p /data/nfs/k3svolumes/loki/data
+
[root@r0 ~]# mkdir -p /data/nfs/k3svolumes/loki/data
 

Deploying Loki and Alloy


@@ -4847,24 +5508,24 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
$ cd conf/f3s/loki
-$ just install
-helm repo add grafana https://grafana.github.io/helm-charts || true
-helm repo update
-kubectl apply -f persistent-volumes.yaml
-persistentvolume/loki-data-pv created
-persistentvolumeclaim/loki-data-pvc created
-helm install loki grafana/loki --namespace monitoring -f values.yaml
-NAME: loki
-LAST DEPLOYED: ...
-NAMESPACE: monitoring
-STATUS: deployed
-...
-helm install alloy grafana/alloy --namespace monitoring -f alloy-values.yaml
-NAME: alloy
-LAST DEPLOYED: ...
-NAMESPACE: monitoring
-STATUS: deployed
+
$ cd conf/f3s/loki
+$ just install
+helm repo add grafana https://grafana.github.io/helm-charts || true
+helm repo update
+kubectl apply -f persistent-volumes.yaml
+persistentvolume/loki-data-pv created
+persistentvolumeclaim/loki-data-pvc created
+helm install loki grafana/loki --namespace monitoring -f values.yaml
+NAME: loki
+LAST DEPLOYED: ...
+NAMESPACE: monitoring
+STATUS: deployed
+...
+helm install alloy grafana/alloy --namespace monitoring -f alloy-values.yaml
+NAME: alloy
+LAST DEPLOYED: ...
+NAMESPACE: monitoring
+STATUS: deployed
 

Loki runs in single-binary mode with a single replica (loki-0), which is appropriate for a home lab cluster. This means there's only one Loki pod running at any time. If the node hosting Loki fails, Kubernetes will automatically reschedule the pod to another worker node—but there will be a brief downtime (typically under a minute) while this happens. For my home lab use case, this is perfectly acceptable.
@@ -4879,44 +5540,44 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
discovery.kubernetes "pods" {
-  role = "pod"
-}
+
discovery.kubernetes "pods" {
+  role = "pod"
+}
 
-discovery.relabel "pods" {
-  targets = discovery.kubernetes.pods.targets
+discovery.relabel "pods" {
+  targets = discovery.kubernetes.pods.targets
 
-  rule {
-    source_labels = ["__meta_kubernetes_namespace"]
-    target_label  = "namespace"
-  }
+  rule {
+    source_labels = ["__meta_kubernetes_namespace"]
+    target_label  = "namespace"
+  }
 
-  rule {
-    source_labels = ["__meta_kubernetes_pod_name"]
-    target_label  = "pod"
-  }
+  rule {
+    source_labels = ["__meta_kubernetes_pod_name"]
+    target_label  = "pod"
+  }
 
-  rule {
-    source_labels = ["__meta_kubernetes_pod_container_name"]
-    target_label  = "container"
-  }
+  rule {
+    source_labels = ["__meta_kubernetes_pod_container_name"]
+    target_label  = "container"
+  }
 
-  rule {
-    source_labels = ["__meta_kubernetes_pod_label_app"]
-    target_label  = "app"
-  }
-}
+  rule {
+    source_labels = ["__meta_kubernetes_pod_label_app"]
+    target_label  = "app"
+  }
+}
 
-loki.source.kubernetes "pods" {
-  targets    = discovery.relabel.pods.output
-  forward_to = [loki.write.default.receiver]
-}
+loki.source.kubernetes "pods" {
+  targets    = discovery.relabel.pods.output
+  forward_to = [loki.write.default.receiver]
+}
 
-loki.write "default" {
-  endpoint {
-    url = "http://loki.monitoring.svc.cluster.local:3100/loki/api/v1/push"
-  }
-}
+loki.write "default" {
+  endpoint {
+    url = "http://loki.monitoring.svc.cluster.local:3100/loki/api/v1/push"
+  }
+}
 

This configuration automatically labels each log line with the namespace, pod name, container name, and app label, making it easy to filter logs in Grafana.
@@ -4929,9 +5590,9 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
$ kubectl get svc -n monitoring loki
-NAME   TYPE        CLUSTER-IP    PORT(S)
-loki   ClusterIP   10.43.64.60   3100/TCP,9095/TCP
+
$ kubectl get svc -n monitoring loki
+NAME   TYPE        CLUSTER-IP    PORT(S)
+loki   ClusterIP   10.43.64.60   3100/TCP,9095/TCP
 

To add Loki as a data source in Grafana:
@@ -4955,21 +5616,21 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
$ kubectl get pods -n monitoring
-NAME                                                     READY   STATUS    RESTARTS   AGE
-alertmanager-prometheus-kube-prometheus-alertmanager-0   2/2     Running   0          42d
-alloy-g5fgj                                              2/2     Running   0          29m
-alloy-nfw8w                                              2/2     Running   0          29m
-alloy-tg9vj                                              2/2     Running   0          29m
-loki-0                                                   2/2     Running   0          25m
-prometheus-grafana-868f9dc7cf-lg2vl                      3/3     Running   0          42d
-prometheus-kube-prometheus-operator-8d7bbc48c-p4sf4      1/1     Running   0          42d
-prometheus-kube-state-metrics-7c5fb9d798-hh2fx           1/1     Running   0          42d
-prometheus-prometheus-kube-prometheus-prometheus-0       2/2     Running   0          42d
-prometheus-prometheus-node-exporter-2nsg9                1/1     Running   0          42d
-prometheus-prometheus-node-exporter-mqr25                1/1     Running   0          42d
-prometheus-prometheus-node-exporter-wp4ds                1/1     Running   0          42d
-tempo-0                                                  1/1     Running   0          1d
+
$ kubectl get pods -n monitoring
+NAME                                                     READY   STATUS    RESTARTS   AGE
+alertmanager-prometheus-kube-prometheus-alertmanager-0   2/2     Running   0          42d
+alloy-g5fgj                                              2/2     Running   0          29m
+alloy-nfw8w                                              2/2     Running   0          29m
+alloy-tg9vj                                              2/2     Running   0          29m
+loki-0                                                   2/2     Running   0          25m
+prometheus-grafana-868f9dc7cf-lg2vl                      3/3     Running   0          42d
+prometheus-kube-prometheus-operator-8d7bbc48c-p4sf4      1/1     Running   0          42d
+prometheus-kube-state-metrics-7c5fb9d798-hh2fx           1/1     Running   0          42d
+prometheus-prometheus-kube-prometheus-prometheus-0       2/2     Running   0          42d
+prometheus-prometheus-node-exporter-2nsg9                1/1     Running   0          42d
+prometheus-prometheus-node-exporter-mqr25                1/1     Running   0          42d
+prometheus-prometheus-node-exporter-wp4ds                1/1     Running   0          42d
+tempo-0                                                  1/1     Running   0          1d
 

Note: Tempo (tempo-0) is deployed later in this post in the "Distributed Tracing with Grafana Tempo" section. It is included in the pod listing here for completeness.
@@ -4980,19 +5641,19 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
$ kubectl get svc -n monitoring
-NAME                                      TYPE        CLUSTER-IP      PORT(S)
-alertmanager-operated                     ClusterIP   None            9093/TCP,9094/TCP
-alloy                                     ClusterIP   10.43.74.14     12345/TCP
-loki                                      ClusterIP   10.43.64.60     3100/TCP,9095/TCP
-loki-headless                             ClusterIP   None            3100/TCP
-prometheus-grafana                        ClusterIP   10.43.46.82     80/TCP
-prometheus-kube-prometheus-alertmanager   ClusterIP   10.43.208.43    9093/TCP,8080/TCP
-prometheus-kube-prometheus-operator       ClusterIP   10.43.246.121   443/TCP
-prometheus-kube-prometheus-prometheus     ClusterIP   10.43.152.163   9090/TCP,8080/TCP
-prometheus-kube-state-metrics             ClusterIP   10.43.64.26     8080/TCP
-prometheus-prometheus-node-exporter       ClusterIP   10.43.127.242   9100/TCP
-tempo                                     ClusterIP   10.43.91.44     3200/TCP,4317/TCP,4318/TCP
+
$ kubectl get svc -n monitoring
+NAME                                      TYPE        CLUSTER-IP      PORT(S)
+alertmanager-operated                     ClusterIP   None            9093/TCP,9094/TCP
+alloy                                     ClusterIP   10.43.74.14     12345/TCP
+loki                                      ClusterIP   10.43.64.60     3100/TCP,9095/TCP
+loki-headless                             ClusterIP   None            3100/TCP
+prometheus-grafana                        ClusterIP   10.43.46.82     80/TCP
+prometheus-kube-prometheus-alertmanager   ClusterIP   10.43.208.43    9093/TCP,8080/TCP
+prometheus-kube-prometheus-operator       ClusterIP   10.43.246.121   443/TCP
+prometheus-kube-prometheus-prometheus     ClusterIP   10.43.152.163   9090/TCP,8080/TCP
+prometheus-kube-state-metrics             ClusterIP   10.43.64.26     8080/TCP
+prometheus-prometheus-node-exporter       ClusterIP   10.43.127.242   9100/TCP
+tempo                                     ClusterIP   10.43.91.44     3200/TCP,4317/TCP,4318/TCP
 

Let me break down what each pod does:
@@ -5069,7 +5730,7 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
paul@f0:~ % doas pkg install -y node_exporter
+
paul@f0:~ % doas pkg install -y node_exporter
 

Enable the service to start at boot:
@@ -5078,8 +5739,8 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
paul@f0:~ % doas sysrc node_exporter_enable=YES
-node_exporter_enable:  -> YES
+
paul@f0:~ % doas sysrc node_exporter_enable=YES
+node_exporter_enable:  -> YES
 

Configure node_exporter to listen on the WireGuard interface. This ensures metrics are only accessible through the secure tunnel, not the public network. Replace the IP with the host's WireGuard address:
@@ -5088,8 +5749,8 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
paul@f0:~ % doas sysrc node_exporter_args='--web.listen-address=192.168.2.130:9100'
-node_exporter_args:  -> --web.listen-address=192.168.2.130:9100
+
paul@f0:~ % doas sysrc node_exporter_args='--web.listen-address=192.168.2.130:9100'
+node_exporter_args:  -> --web.listen-address=192.168.2.130:9100
 

Start the service:
@@ -5098,8 +5759,8 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
paul@f0:~ % doas service node_exporter start
-Starting node_exporter.
+
paul@f0:~ % doas service node_exporter start
+Starting node_exporter.
 

Verify it's running:
@@ -5108,10 +5769,10 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
paul@f0:~ % curl -s http://192.168.2.130:9100/metrics | head -3
-# HELP go_gc_duration_seconds A summary of the wall-time pause...
-# TYPE go_gc_duration_seconds summary
-go_gc_duration_seconds{quantile="0"} 0
+
paul@f0:~ % curl -s http://192.168.2.130:9100/metrics | head -3
+# HELP go_gc_duration_seconds A summary of the wall-time pause...
+# TYPE go_gc_duration_seconds summary
+go_gc_duration_seconds{quantile="0"} 0
 

Repeat for the other FreeBSD hosts (f1, f2) with their respective WireGuard IPs.
@@ -5139,9 +5800,9 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
$ kubectl create secret generic additional-scrape-configs \
-    --from-file=additional-scrape-configs.yaml \
-    -n monitoring
+
$ kubectl create secret generic additional-scrape-configs \
+    --from-file=additional-scrape-configs.yaml \
+    -n monitoring
 

Update persistence-values.yaml to reference the secret:
@@ -5161,7 +5822,7 @@ prometheus: by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
$ just upgrade
+
$ just upgrade
 

After a minute or so, the FreeBSD hosts appear in the Prometheus targets and in the Node Exporter dashboards in Grafana.
@@ -5529,10 +6190,10 @@ zfs_pool_free_bytes{pool="zdata"} 3.48809678848e+11 by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
blowfish:~ $ doas pkg_add node_exporter
-quirks-7.103 signed on 2025-10-13T22:55:16Z
-The following new rcscripts were installed: /etc/rc.d/node_exporter
-See rcctl(8) for details.
+
blowfish:~ $ doas pkg_add node_exporter
+quirks-7.103 signed on 2025-10-13T22:55:16Z
+The following new rcscripts were installed: /etc/rc.d/node_exporter
+See rcctl(8) for details.
 

Enable the service to start at boot:
@@ -5541,7 +6202,7 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
blowfish:~ $ doas rcctl enable node_exporter
+
blowfish:~ $ doas rcctl enable node_exporter
 

Configure node_exporter to listen on the WireGuard interface. This ensures metrics are only accessible through the secure tunnel, not the public network. Replace the IP with the host's WireGuard address:
@@ -5550,7 +6211,7 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
blowfish:~ $ doas rcctl set node_exporter flags '--web.listen-address=192.168.2.110:9100'
+
blowfish:~ $ doas rcctl set node_exporter flags '--web.listen-address=192.168.2.110:9100'
 

Start the service:
@@ -5559,8 +6220,8 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
blowfish:~ $ doas rcctl start node_exporter
-node_exporter(ok)
+
blowfish:~ $ doas rcctl start node_exporter
+node_exporter(ok)
 

Verify it's running:
@@ -5569,10 +6230,10 @@ http://www.gnu.org/software/src-highlite --> by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
blowfish:~ $ curl -s http://192.168.2.110:9100/metrics | head -3
-# HELP go_gc_duration_seconds A summary of the wall-time pause...
-# TYPE go_gc_duration_seconds summary
-go_gc_duration_seconds{quantile="0"} 0
+
blowfish:~ $ curl -s http://192.168.2.110:9100/metrics | head -3
+# HELP go_gc_duration_seconds A summary of the wall-time pause...
+# TYPE go_gc_duration_seconds summary
+go_gc_duration_seconds{quantile="0"} 0
 

Repeat for the other OpenBSD host (fishfinger) with its respective WireGuard IP (192.168.2.111).
@@ -5934,35 +6595,35 @@ opentelemetry-instrumentation-requests==0.49b0 by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
from opentelemetry import trace
-from opentelemetry.sdk.trace import TracerProvider
-from opentelemetry.exporter.otlp.proto.grpc.trace_exporter import OTLPSpanExporter
-from opentelemetry.instrumentation.flask import FlaskInstrumentor
-from opentelemetry.instrumentation.requests import RequestsInstrumentor
-from opentelemetry.sdk.resources import Resource
+
from opentelemetry import trace
+from opentelemetry.sdk.trace import TracerProvider
+from opentelemetry.exporter.otlp.proto.grpc.trace_exporter import OTLPSpanExporter
+from opentelemetry.instrumentation.flask import FlaskInstrumentor
+from opentelemetry.instrumentation.requests import RequestsInstrumentor
+from opentelemetry.sdk.resources import Resource
 
-# Define service identity
-resource = Resource(attributes={
-    "service.name": "frontend",
-    "service.namespace": "tracing-demo",
-    "service.version": "1.0.0"
-})
+# Define service identity
+resource = Resource(attributes={
+    "service.name": "frontend",
+    "service.namespace": "tracing-demo",
+    "service.version": "1.0.0"
+})
 
-provider = TracerProvider(resource=resource)
+provider = TracerProvider(resource=resource)
 
-# Export to Alloy
-otlp_exporter = OTLPSpanExporter(
-    endpoint="http://alloy.monitoring.svc.cluster.local:4317",
-    insecure=True
-)
+# Export to Alloy
+otlp_exporter = OTLPSpanExporter(
+    endpoint="http://alloy.monitoring.svc.cluster.local:4317",
+    insecure=True
+)
 
-processor = BatchSpanProcessor(otlp_exporter)
-provider.add_span_processor(processor)
-trace.set_tracer_provider(provider)
+processor = BatchSpanProcessor(otlp_exporter)
+provider.add_span_processor(processor)
+trace.set_tracer_provider(provider)
 
-# Auto-instrument Flask and requests
-FlaskInstrumentor().instrument_app(app)
-RequestsInstrumentor().instrument()
+# Auto-instrument Flask and requests
+FlaskInstrumentor().instrument_app(app)
+RequestsInstrumentor().instrument()
 

The auto-instrumentation automatically:
@@ -6139,29 +6800,29 @@ curl -H "Host: tracing-demo.f3s.buetow.org" http://r0/api/process by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
{
-  "middleware_response": {
-    "backend_data": {
-      "data": {
-        "id": 12345,
-        "query_time_ms": 100.0,
-        "timestamp": "2025-12-28T18:35:01.064538",
-        "value": "Sample data from backend service"
-      },
-      "service": "backend"
-    },
-    "middleware_processed": true,
-    "original_data": {
-      "source": "GET request"
-    },
-    "transformation_time_ms": 50
-  },
-  "request_data": {
-    "source": "GET request"
-  },
-  "service": "frontend",
-  "status": "success"
-}
+
{
+  "middleware_response": {
+    "backend_data": {
+      "data": {
+        "id": 12345,
+        "query_time_ms": 100.0,
+        "timestamp": "2025-12-28T18:35:01.064538",
+        "value": "Sample data from backend service"
+      },
+      "service": "backend"
+    },
+    "middleware_processed": true,
+    "original_data": {
+      "source": "GET request"
+    },
+    "transformation_time_ms": 50
+  },
+  "request_data": {
+    "source": "GET request"
+  },
+  "service": "frontend",
+  "status": "success"
+}
 

**2. Find the trace in Tempo via API:**
@@ -6180,12 +6841,12 @@ kubectl exec -n monitoring tempo-0 -- wget -qO- \ by Lorenzo Bettini http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite --> -
{
-  "traceID": "4be1151c0bdcd5625ac7e02b98d95bd5",
-  "rootServiceName": "frontend",
-  "rootTraceName": "GET /api/process",
-  "durationMs": 221
-}
+
{
+  "traceID": "4be1151c0bdcd5625ac7e02b98d95bd5",
+  "rootServiceName": "frontend",
+  "rootTraceName": "GET /api/process",
+  "durationMs": 221
+}
 

**3. Fetch complete trace details:**
@@ -6309,6 +6970,7 @@ kubectl exec -n monitoring <tempo-pod> -- df -h /var/tempo
Other *BSD-related posts:

+2026-04-02 f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD
2025-12-07 f3s: Kubernetes with FreeBSD - Part 8: Observability (You are currently reading this)
2025-10-02 f3s: Kubernetes with FreeBSD - Part 7: k3s and first pod deployments
2025-07-14 f3s: Kubernetes with FreeBSD - Part 6: Storage
@@ -7233,6 +7895,7 @@ p hash.values_at(:a, :c) 2025-07-14 f3s: Kubernetes with FreeBSD - Part 6: Storage
2025-10-02 f3s: Kubernetes with FreeBSD - Part 7: k3s and first pod deployments (You are currently reading this)
2025-12-07 f3s: Kubernetes with FreeBSD - Part 8: Observability
+2026-04-02 f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD

f3s logo

@@ -8700,6 +9363,7 @@ replicaset.apps/miniflux-server-85d7c64664 1 1 1 54d
Other *BSD-related posts:

+2026-04-02 f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD
2025-12-07 f3s: Kubernetes with FreeBSD - Part 8: Observability
2025-10-02 f3s: Kubernetes with FreeBSD - Part 7: k3s and first pod deployments (You are currently reading this)
2025-07-14 f3s: Kubernetes with FreeBSD - Part 6: Storage
@@ -10007,6 +10671,7 @@ content = "{CODE}" 2025-07-14 f3s: Kubernetes with FreeBSD - Part 6: Storage (You are currently reading this)
2025-10-02 f3s: Kubernetes with FreeBSD - Part 7: k3s and first pod deployments
2025-12-07 f3s: Kubernetes with FreeBSD - Part 8: Observability
+2026-04-02 f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD

f3s logo

@@ -12161,6 +12826,7 @@ http://www.gnu.org/software/src-highlite -->
Other *BSD-related posts:

+2026-04-02 f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD
2025-12-07 f3s: Kubernetes with FreeBSD - Part 8: Observability
2025-10-02 f3s: Kubernetes with FreeBSD - Part 7: k3s and first pod deployments
2025-07-14 f3s: Kubernetes with FreeBSD - Part 6: Storage (You are currently reading this)
@@ -13235,6 +13901,7 @@ http://www.gnu.org/software/src-highlite --> 2025-07-14 f3s: Kubernetes with FreeBSD - Part 6: Storage
2025-10-02 f3s: Kubernetes with FreeBSD - Part 7: k3s and first pod deployments
2025-12-07 f3s: Kubernetes with FreeBSD - Part 8: Observability
+2026-04-02 f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD

f3s logo

@@ -14780,6 +15447,7 @@ earth$ curl https://ifconfig.me # Should show gateway's
Other *BSD-related posts:

+2026-04-02 f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD
2025-12-07 f3s: Kubernetes with FreeBSD - Part 8: Observability
2025-10-02 f3s: Kubernetes with FreeBSD - Part 7: k3s and first pod deployments
2025-07-14 f3s: Kubernetes with FreeBSD - Part 6: Storage
@@ -15373,6 +16041,7 @@ __ejm\___/________dwb`---`______________________ 2025-07-14 f3s: Kubernetes with FreeBSD - Part 6: Storage
2025-10-02 f3s: Kubernetes with FreeBSD - Part 7: k3s and first pod deployments
2025-12-07 f3s: Kubernetes with FreeBSD - Part 8: Observability
+2026-04-02 f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD

f3s logo

@@ -16063,6 +16732,7 @@ etcd_disk_wal_fsync_duration_seconds_bucket{le="0.004"} 408
Other *BSD-related posts:

+2026-04-02 f3s: Kubernetes with FreeBSD - Part 9: GitOps with ArgoCD
2025-12-07 f3s: Kubernetes with FreeBSD - Part 8: Observability
2025-10-02 f3s: Kubernetes with FreeBSD - Part 7: k3s and first pod deployments
2025-07-14 f3s: Kubernetes with FreeBSD - Part 6: Storage
@@ -16788,6 +17458,7 @@ This is perl, v5.8.8 built - https://foo.zone/gemfeed/2024-07-07-the-stoic-challenge-book-notes.html - 2024-07-07T12:46:55+03:00 - - Paul Buetow aka snonux - paul@dev.buetow.org - - These are my personal takeaways after reading 'The Stoic Challenge: A Philosopher's Guide to Becoming Tougher, Calmer, and More Resilient' by William B. Irvine. - -
-

"The Stoic Challenge" book notes


-
-Published at 2024-07-07T12:46:55+03:00
-
-These are my personal takeaways after reading "The Stoic Challenge: A Philosopher's Guide to Becoming Tougher, Calmer, and More Resilient" by William B. Irvine.
-
-
-         ,..........   ..........,
-     ,..,'          '.'          ',..,
-    ,' ,'            :            ', ',
-   ,' ,'             :             ', ',
-  ,' ,'              :              ', ',
- ,' ,'............., : ,.............', ',
-,'  '............   '.'   ............'  ',
- '''''''''''''''''';''';''''''''''''''''''
-                    '''
-
-
-

Table of Contents


-
-
-

God sets you up for a challenge


-
-Gods set you up for a challenge to see how resilient you are. Is getting angry worth the price? If you stay calm then you can find the optimal workaround for the obstacle. Stay calm even with big setbacks. Practice minimalism of negative emotions.
-
-Put a positive spin on everything. What should you do if someone wrong you? Don't get angry, there is no point in that, it just makes you suffer. Do the best what you got now and keep calm and carry on. A resilient person will refuse to play the role of a victim. You can develop the setback response skills. Turn a setback. e.g. a handycap, into a personal triumph.
-
-It is not the things done to you or happen to you what matters but how you take the things and react to these things.
-
-Don't row against the other boats but against your own lazy bill. It doesn't matter if you are first or last, as long as you defeat your lazy self.
-
-Stoics are thankful that they are mortal. As then you can get reminded of how great it is to be alive at all. In dying we are more alive we have ever been as every thing you do could be the last time you do it. Rather than fighting your death you should embrace it if there are no workarounds. Embrace a good death.
-
-

Negative visualization


-
-It is easy what we have to take for granted.
-
-
    -
  • Imagine the negative and then think that things are actually much better than they seem to be.
  • -
  • Close your eyes and imagine you are color blind for a minute, then open the eyes again and see all the colours. You will be grateful for being able to see the colours.
  • -
  • Now close your eyes for a minute and imagine you would be blind, so that you will never be able to experience the world again and let it sink in. When you open your eyes again you will feel a lot of gratefulness.
  • -
  • Last time meditation. Lets you appreciate the life as it is now. Life gets vitalised again.
  • -

-

Oh, nice trick, you stoic "god"! ;-)


-
-Take setbacks as a challenge. Also take it with some humor.
-
-
    -
  • A setback in a setback, how Genius :-)
  • -
  • A setback in a setback in a setback: the stoic god's work overtime, eh? :-)
  • -

-What would the stoic god's do next? This is just a test strategy by them. Don't be frustrated at all but be astonished of what comes next. Thank the stoic gods of testing you. This is comfort zone extension of the stoics aka toughness Training.
-
-E-Mail your comments to paul@nospam.buetow.org :-)
-
-Other book notes of mine are:
-
-2025-11-02 'The Courage To Be Disliked' book notes
-2025-06-07 'A Monk's Guide to Happiness' book notes
-2025-04-19 'When: The Scientific Secrets of Perfect Timing' book notes
-2024-10-24 'Staff Engineer' book notes
-2024-07-07 'The Stoic Challenge' book notes (You are currently reading this)
-2024-05-01 'Slow Productivity' book notes
-2023-11-11 'Mind Management' book notes
-2023-07-17 'Software Developers Career Guide and Soft Skills' book notes
-2023-05-06 'The Obstacle is the Way' book notes
-2023-04-01 'Never split the difference' book notes
-2023-03-16 'The Pragmatic Programmer' book notes
-
Back to the main site
-- cgit v1.2.3