Commit graph

182 commits

Author SHA1 Message Date
Lance Walters
f290b3c457 apps(osint): deploy OSINT dashboard stack to k8s at osint.siriusdevops.com
New namespace `osint` with the full dashboard stack ported from the Pi docker
compose file: TimescaleDB+PostGIS Postgres, NATS JetStream, FastAPI app,
ingester, camera-discovery service, TiTiler tile proxy, and the vendored news
pipeline (Scrapy scraper + Nous Portal summarizer).

- Images built amd64 (the Pi CI only builds arm64) and pushed to the Forgejo
  registry as :amd64-c48788d4b614; nats/titiler mirrored there too so every
  pod pulls from one host.
- All workloads pinned to siriussec (Gateway/Envoy co-location, local-path PVs).
- Postgres is a Deployment+PVC, not CNPG: the alembic chain needs postgis +
  timescaledb extensions and create_hypertable().
- HTTPRoute osint.siriusdevops.com: /titiler prefix-stripped to TiTiler,
  everything else to the app (incl. /ws/live).
- DB password is Secret osint-db, created out of band (not in git).
- Analyst model = meituan/longcat-2.5:free on Nous Portal (free tier).
2026-11-13 20:14:42 -05:00
Lance Walters
6049a09c6e apps(sirius-growth): pin blog 4378680 (new SG-tree mark, favicon-32, apple-touch-icon) 2026-11-06 16:36:06 -05:00
Lance Walters
017718ba41 apps(sirius-growth): pin site 413d98f (new SG-tree logo icons) 2026-11-06 16:19:05 -05:00
Lance Walters
fd555ffb87 apps(sirius-growth): pin site 494632d (radish hero plate restored, two-column hero) 2026-11-05 21:08:57 -05:00
Lance Walters
c4f7e6378e apps(sirius-growth): pin site 2b10d99 (hero plate removed, one-column hero) 2026-11-05 20:50:04 -05:00
Lance Walters
aa71da2f31 apps(sirius-growth): blog Deployment/Service + pin site d44446c (journal mount)
- deployment-blog.yaml / service-blog.yaml: blog FastAPI on 8092, siriussec,
  env from sirius-growth-blog-app + sirius-growth-blog-s3,
  PUBLIC_BASE_URL=https://siriusgrowthsolutions.com/journal. No HTTPRoute: the
  site nginx proxies /journal to this ClusterIP service.
- deployment.yaml: site 4285926 -> d44446c (nginx /journal proxy, nav menu).
- portal Deployment untouched.
2026-11-05 13:07:26 -05:00
Lance Walters
be8233079b apps(sirius-growth): pin portal ce350ed + site 4285926 (calendar page, feed kind, application series) 2026-11-05 11:39:32 -05:00
Lance Walters
1fb49c0507 apps(sirius-growth): pin portal efd5b61 + site 7d7fd4c (phase 3: action items, .ics feed, alerts, print view) 2026-11-04 01:39:11 -05:00
Lance Walters
5a9400790c apps(sirius-growth): wire TG_TOKEN/TG_CHAT into the portal from sirius-growth-contact
The portal-api image gained Telegram-only operator alerts (phase 3C) but reads
TG_TOKEN/TG_CHAT at startup; unset, it logs one line and no-ops. Reuse the same
bot and secret the contact service already uses - no new secret, no value in git.
2026-11-04 01:39:10 -05:00
Lance Walters
b7f5e0105d apps(sirius-growth): pin portal 71c7eec + site a72ea75 (phase 2: crew logging schema, thread attachments)
portal-api: multipart message attachments with magic-byte sniffing, owner-checked
GET /api/portal/attachments/{id}; measured_by/application logging with
logged_by_role. site: crew self-logging forms, Specialist/Crew badges, photo
picker + lazy inline thumbnails.
2026-11-04 00:41:01 -05:00
Lance Walters
6cfa86d25d apps(sirius-growth): pin site 1bdcdcd (phase 1 dashboard: baseline panel, target bands, readings table) 2026-11-03 23:42:31 -05:00
Lance Walters
07caa865da apps(sirius-growth): pin portal 540ca05 (phase 1 diagnostics API: input readings, zone targets, site baseline) 2026-11-03 23:42:31 -05:00
Lance Walters
e4c7fd9ff7 apps(sirius-growth): pin site 040d3e1 (root-absolute admin CSS/JS)
site :040d3e1d5c6bae57c7b4d5edd00b4a969bb8718d (deploy-site run 91,
success) loads style.css/portal.css/portal.js root-absolute so
/admin/leads and /admin/settings stop 404ing on /admin/css/… and
/admin/js/… and the Leads table renders. Registry digest
sha256:bd83baa6…ffcd. Portal pin untouched.
2026-11-03 21:33:01 -05:00
Lance Walters
a80d7e233f apps(sirius-growth): pin portal 0f156d2 + site 0b4a8c0 (admin split, zones, messages, inline files)
portal :0f156d2f17aab3461ba4c5d7d4d8988861b2b14b (deploy-portal run 87,
success) carries the zones API (bcdba9d), inline file disposition and the
last-message fields; registry digest sha256:90d9c89d...6643.

site :0b4a8c0a27c35855eab03ebaa23a7ab5229245a8 (deploy-site run 90, success)
is the admin split plus per-client zones/messages UI and the dashboard zone
filter with inline previews, and gates /admin/leads + /admin/settings in all
three nginx variants; registry digest sha256:ab680c5b...5adf.
2026-11-03 21:14:54 -05:00
Lance Walters
695bd90449 apps(sirius-growth): pin portal bcdba9d (named zones per client) 2026-11-03 20:38:59 -05:00
Lance Walters
6ca43350fa apps(sirius-growth): pin portal f02cea9 + site b274454 (onboarding validation errors) 2026-11-03 19:44:35 -05:00
Lance Walters
b68b22288e apps(sirius-growth): pin site ed3ca8f (root-check hook band + second diagnostics link) 2026-11-03 14:36:19 -05:00
Lance Walters
c2b502ba57 apps(sirius-growth): pin site db63ff1 (admin password 401 redirects to /signin?next=/admin) 2026-11-03 13:17:40 -05:00
5036d853bf SGS portal: nginx login gate — rate-limit /api/portal/login (12r/m, burst 6) 2026-11-03 18:16:03 +00:00
Lance Walters
c77b5a6e80 apps(sirius-growth): pin site be32304 (js/css revalidate rule, narrowed to /js/ /css/) 2026-11-03 13:13:42 -05:00
Lance Walters
418f2c5fc0 apps(sirius-growth): pin portal adbf227 (Cache-Control: no-store on /api/portal/*) 2026-11-03 12:49:44 -05:00
Lance Walters
45c3b8533b apps(sirius-growth): sgs-leadgen weekly CronJob (ET) + monthly NCDA job + state PVC
Runs the published amd64 image forgejo.../sgs-leadgen:eef9358 with DATABASE_URL
from sirius-growth-portal-app and the contact bot's Telegram pair; /data on a
local-path PVC pins to siriussec, /tmp on an emptyDir so the root fs stays RO.
2026-11-03 12:46:27 -05:00
Lance Walters
d5193c2525 apps(sirius-growth): pin site c03101f3 (admin UI) and portal a150b6f3 (leads/password/remove) 2026-11-03 12:36:37 -05:00
Lance Walters
c2c7e8d9e7 apps(sirius-growth): pin the site to 37329e3 (alt-band alignment fix) 2026-11-03 12:21:24 -05:00
Lance Walters
5c6c8b71c0 apps: re-pin the contact APIs to their new :sha tags
Both contact APIs now have amd64 build+push pipelines:
sirius-growth/.forgejo/workflows/deploy-contact.yml (contact-api/)
and sirius/websites/.forgejo/workflows/deploy-phs-contact.yml
(phs-contact-api/). Each printed the tag for its first run, so the
@sha256: pins (which existed only because there was no build path)
become ordinary :<sha> tags an operator can bump.

docs/site-image-pinning.md: drop the 'no CI build path' section and
record the two workflows in the pins table.
2026-11-02 18:09:48 -05:00
Lance Walters
bbcf02e68a docs(site-image-pinning): record the buildx-from-dind fix and the real stall host 2026-11-02 17:51:53 -05:00
Lance Walters
41bacb90e4 apps: retire the site-deployer ServiceAccount
Nothing in CI holds cluster credentials any more: every site image is pinned
by tag/digest in this repo and rolled by Flux, so the siriusdevops and
sirius-growth 'site-deployer' SA/Role/RoleBinding are dead. Dropping them from
the kustomizations lets Flux prune all six objects, which also revokes the
8760h tokens behind the KUBE_CONFIG action secrets (deleted separately, and
only after the pins were verified live).

piedmont never had a deployer.yaml: its CI identity (phs-site-deployer) was
created out-of-band and is removed by hand in the same change.
2026-11-02 17:22:06 -05:00
Lance Walters
5273a993f2 apps: pin every first-party site image to an immutable ref
Replace ':latest' + imagePullPolicy: Always on all seven site images with a
pinned tag (or digest) and IfNotPresent, so the image a Deployment runs is
chosen by this repo and rolled by Flux, not by CI patching restartedAt.

Every pin is the image that was already running, so the change is a no-op for
visitors: each pinned tag's manifest/config digest equals the running pod's
imageID (siriusdevops-* f0dde2f4, growth-site ea306b7, growth-portal d9e558c4,
phs-site 5b590cd).

sirius-growth-contact and phs-contact have no CI build path (no workflow has
ever pushed anything but :latest for them), so they are pinned by @sha256:
digest rather than inventing a pipeline; documented in
docs/site-image-pinning.md along with the operator flow.
2026-11-02 17:17:36 -05:00
5825714bcd Merge pull request 'README: public front door for hiring managers' (#12) from wt/t_c9eac612 into master
Reviewed-on: #12
2026-10-29 05:53:10 +00:00
Lance Walters
1b6441123c README: rewrite the public front door from the live cluster 2026-10-29 01:23:33 -04:00
Lance Walters
aa0f67fe33 README: no site/app containers on the Pi — registry + garage only 2026-10-28 01:21:47 -04:00
Lance Walters
954324e169 README: document the live cluster — three nodes incl. linode, real ingress origin, running services
Rewrites the stale README (Flux-later framing, two-node table, 127.0.0.1:8080
origin, dedicated=network gateway) against kubectl/curl output: node table with
siriussec/rpi/linode and their labels+taints, Cilium native routing over WG,
public origin 10.10.0.2:8080 with the single-gateway-node rule, internal
Gateways 8081/8084 on the bare IP, lab.internal DNS, a services table covering
every live workload, placement rules, and the clusters/home dead-tree warning.
2026-10-28 01:11:25 -04:00
hermes
5aff48a223 docs(arm64 runner dind): as-built section — what landed, deviations, evidence, rollback drill 2026-10-27 04:02:00 -04:00
hermes
0a97d9305f forgejo runners(arm64): dind registries need --insecure-registry for the Pi's WG address
First post-cutover deploy-site run (task 1732) built the image and then died
pushing it: docker only treats 127.0.0.0/8 as insecure by default, so
'Get "https://10.10.0.1:5000/v2/": http: server gave HTTP response to HTTPS
client'. Flag the daemon, not the job image, on both arm64 runners so no
workflow needs to know.
2026-10-27 02:57:48 -04:00
Lance Walters
c2eb2b2fa3 monitoring: suppress the dead kubelet_volume_stats rules in kubernetes-storage
kube-prometheus-stack's kubernetes-storage group ships five rules; four of
them (both severities of KubePersistentVolumeFillingUp and of
KubePersistentVolumeInodesFillingUp) select kubelet_volume_stats_*. Those
series have no producer here: kubelet v1.36.4 404s on /metrics/volumes on all
three nodes (404s since kubelet 1.34, kubernetes/kubernetes#133847) and
count(kubelet_volume_stats_used_bytes) returns 0 series. The rules loaded fine
and reported health=ok/active=false, which reads as 'no PVC is filling' when
nothing can ever fire.

Disabled per rule via defaultRules.disabled (not by dropping the group): the
group's fifth alert, KubePersistentVolumeErrors, uses kube-state-metrics'
kube_persistentvolume_status_phase, which is live (40 series), so it stays.

Verified by rendering the chart with these values: group kubernetes-storage
now contains exactly one rule.
2026-10-27 02:22:46 -04:00
Lance Walters
af73b261b3 monitoring: name the dind data-root precisely in the runner disk alert 2026-10-27 02:13:11 -04:00
Lance Walters
e572f84b0b monitoring: replace the dead kubelet_volume_stats alerts with runner-scoped disk rules
kubelet_volume_stats_* was an ALPHA metric set served from kubelet's
/metrics/volumes endpoint; that endpoint returns 404 on every node of this
cluster (kubelet v1.36.4 — upstream loss in 1.34, kubernetes#133847), and
/metrics carries no volume-stats series. RunnerDindPvcHighWatermark and
RunnerDindPvcCritical therefore could never fire while showing as healthy.

Per-PVC bytes are not measurable here and no scrape config can change that,
so the pair is replaced by RunnerDindDiskHighWatermark (80%) and
RunnerDindDiskCritical (90%): root-filesystem usage on nodes that actually
run a forgejo-runner pod, which is the filesystem holding the dind data-root
under /opt/local-path-provisioner. New arm64 dind PVCs are covered as soon
as their runner is scheduled; nodes without runners (linode) do not
duplicate the generic disk-capacity group.

Also corrects the cause in docs, the dashboard notes and the prune CronJob
comment (it is not a hostPath quirk, the endpoint is gone).
2026-10-27 02:07:07 -04:00
Lance Walters
131b9bc7c9 forgejo runners(arm64): run both arm64 runners as in-cluster dind pods
The Pi's host Docker is no longer the arm64 job-container daemon. Both
forgejo-runner-arm64 and forgejo-runner-deploy-arm64 now run a privileged
docker:27-dind sidecar (--mtu=1420, socket on an emptyDir shared with the
runner, data-root on a PVC), the same shape as forgejo-runner-amd64.

- labels preserved verbatim: shared keeps docker-arm64/arm64/docker, deploy
  keeps deploy-arm64 only; capacity 1 on both
- runner.ini moved from hostPath to the data PVC by copy, uuid preserved
  (4e07c1e9... / a41aad73...); the deploy runner's register init container is
  inverted into a guard so a missing file cannot burn a token and create a
  second runner
- dind limits.memory 4Gi (measured peak 3.10GiB) and 2Gi for the deploy runner
  so a CI run and a deploy cannot both claim the Pi's 7GiB
- static hostPath PVs pinned to rpi with Retain: dynamic local-path cannot
  provision there (helper pod hardcoded to siriussec)
- docker CLI/buildx come from the dind image instead of the host's docker-static
- Pi registry additionally published on 10.10.0.1:5000 (out of band on the Pi)
- RpiDindDataRootFillingUp at 70%: the real cap, since a static PV does not
  enforce its claim and kubelet_volume_stats_* does not exist here

Design and measured proof: docs/arm64-runner-dind.md (t_627c231c).
2026-10-27 02:03:11 -04:00
Lance Walters
a243af6591 docs: arm64 runner -> in-cluster dind — coupling inventory, measured POC, sizing
Design + proof for moving both arm64 Forgejo runners off the Pi's host
Docker socket onto in-cluster dind. No cutover in this commit.

Measured on rpi in a temporary runner-poc namespace (deleted): dind starts
overlay2 on ext4 with --mtu=1420, pulls node:20-bullseye 15s and
rust:1.98-bookworm 30s, builds the real sirius-growth Dockerfile.cluster in
12s arm64 / 13s amd64 under qemu, and a ci.yml-shaped Rust job runs in 27s
vs 28s on the host daemon (cargo 25.69 vs 25.56s). Peak pod RSS 3.10 GiB.

Three blocking findings: a dynamic local-path PVC cannot be provisioned on
rpi (helper-pod nodeSelector is hardcoded to siriussec), the Pi registry is
bound to 127.0.0.1 only so deploy-site's Pi-image push fails from dind, and
the 512Mi memory limit would OOM the daemon on the first build.
2026-10-27 01:52:56 -04:00
Lance Walters
e97c6894c4 docs: nightly disk reclamation — daemons, retention, cap mechanism, alerts
Records the two corrected premises (capacity flags are a no-op on buildx
0.20.1; kubelet exports no volume_stats_* on this cluster) and the one-line
manual run.
2026-10-27 01:51:06 -04:00
Lance Walters
58b7ed4a13 forgejo/prune: keep the job pod out of dind discovery
The Job pod carried app=forgejo-runner, so every run matched itself and
logged a confusing skip. It now carries app=forgejo-prune; discovery is
unchanged (label app=forgejo-runner + a dind container).
2026-10-27 01:45:57 -04:00
Lance Walters
f1fcf21a94 forgejo/prune: prune every Docker daemon, cap builder cache by age, alert on growth
The nightly CronJob reported Complete while never reclaiming build cache:
docker 27/buildx 0.20.1 accepts --keep-storage and --max-used-space but
returns 'Total: 0B' for both (measured: 21.44GB cache with a 20GB cap, and
541MB cache with a 100MB cap). The comment claiming 53GB reclaimed was true
on an older CLI and is now false. --filter until= does reclaim, so the cash
cap is enforced by walking age windows down (72h -> 0s) and stopping as soon
as the cache is under the cap.

Coverage is now every daemon, discovered not listed: the Pi host socket and
every in-cluster dind pod matching label app=forgejo-runner with a dind
container, pruned over pods/exec with a namespace-scoped ServiceAccount, so
the arm64 dind migration is picked up without editing this job.

Busy guard skips a daemon with a live build and still exits 0. Named volumes
are never pruned; their sizes are printed every run. Adds PrometheusRule
forgejo-prune: cronjob staleness/failure plus node filesystem high-watermark.
2026-10-27 01:43:20 -04:00
Lance Walters
e63af123c5 dashboards: zero-render stats, drop the aspirational folder annotation, keep the validator in the repo
- every count-style stat that can legitimately have no series now ends in
  'or vector(0)', so an empty result renders 0 instead of 'No data' (that bit
  the Pending-pods stat the moment the one Pending pod went away)
- no grafana_folder annotation: the sidecar's API reload 401s (Grafana's live
  admin password is the out-of-band one; the Secret is the first-boot seed), so
  the dashboards are imported by Grafana's file provider, which has no
  per-dashboard folder option and puts them in General. The annotation described
  a path the boards never take.
- validate_panels.py lives next to build.py: reads the panel PromQL out of the
  provisioned ConfigMap and queries Prometheus, so 'every panel returns data' is
  a command, not a claim. 55/55 targets pass.
2026-10-27 01:40:15 -04:00
Lance Walters
28632e61c6 dashboards: fix runner pod selector and custom-metric labels after panel validation
Panel validation against the live Prometheus API caught three real faults:
- pod=~"forgejo-runner-.*" also matched the forgejo-runner-prune-* CronJob pods,
  which are Completed and permanently not-Ready, so the not-Ready stat read 3.
- CNPG custom-query metrics carry namespace/pod from the scrape, not the
  exporter's cluster label, so cluster="pg" matched nothing (empty panels).
- a missing paren in the memory-working-set expression (HTTP 400 from Prometheus).

Also make two legitimately-empty stats render a hard 0 (or vector(0)) instead of
'No data': not-Ready runner pods, and nodes with DiskPressure.

55/55 panel targets now return non-empty results.
2026-10-27 01:36:02 -04:00
Lance Walters
9e851f4dfe monitoring: custom Forgejo runner, CNPG and workload dashboards from git
Dashboards (uid forgejo-runners, cnpg-postgres, home-lab-workloads) live as
ConfigMaps generated from monitoring/controllers/home/dashboards/build.py and are
loaded by the kube-prometheus-stack grafana sidecar.

Postgres was not scraped at all before this: add a hand-written PodMonitor per
CNPG cluster (release=kube-prometheus-stack, which is what this Prometheus's
podMonitorSelectorNilUsesHelmValues default requires) plus
spec.monitoring.customQueriesConfigMap on both Clusters. enablePodMonitor stays
false — deprecated in CNPG 1.27 and it gives no control over labels.

pg-actions-queries.yaml adds the Forgejo Actions queue/outcome/last_online
metrics that only the forgejo database can answer.

prometheus-node-exporter is no longer pinned to siriussec: the arm64 runner's
jobs are host containers on rpi, so the Pi's root filesystem is the disk that
matters there and kubelet cannot see it.

docs/monitoring-dashboards.md documents the PromQL, the exporter GRANT and the
known unknowns (arm64 per-job breakdown, hostPath PVs have no kubelet volume
stats, single-instance replication, no backups).
2026-10-27 01:32:20 -04:00
Lance Walters
de30bc43e7 docs(internal gateway): record the on-demand repro and the label alert firing 2026-10-27 01:19:21 -04:00
Lance Walters
5c7fbfefa8 internal gateway probe: alert when the gateway label is not on exactly one node
The probe catches the symptom; this catches the cause. kube-state-metrics
exposes role labels as kube_node_role, so no extra scrape target is needed.
2026-10-27 01:08:53 -04:00
Lance Walters
951f1e5faa docs: Grafana persistence + admin-password ownership and recovery path
Records what persists (sqlite DB on a 5Gi local-path PVC, pinned
GF_SECURITY_SECRET_KEY), that provisioned dashboards still win over UI edits,
that the Secret is only the first-boot seed, the reset-admin-password recovery
path, and the one-off rollingUpdate patch the Recreate transition needed.
2026-10-27 01:07:34 -04:00
Lance Walters
b2d63270be docs(internal gateway): the flap was rpi being a second, broken gateway node
503 after exactly 5.000s, including from the Pi own 127.0.0.1 - not a stuck
listener. Envoy config dump shows identical listeners on both nodes, so the
fault was node placement, not config. Label removed from rpi: one gateway node.

Record the three-vantage-point matrix, the nft accept counters, the blackbox
Probe/PrometheusRule and the four negatives.
2026-10-27 01:06:40 -04:00
Lance Walters
53e85ca6e4 docs: Grafana persistence + admin-password ownership and recovery path
Records what now persists (sqlite DB on a 5Gi local-path PVC, pinned
GF_SECURITY_SECRET_KEY), that provisioned dashboards still win over UI edits,
that the Secret is only the first-boot seed (the DB owns the password after
that), the reset-admin-password recovery path, and the one-off rollingUpdate
patch the Recreate transition needed.
2026-10-27 01:04:12 -04:00