Show & Tell: Phase 8.4 — Docker/Helm containerisation deep-dive #292
web3guru888
started this conversation in
Show and tell
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Phase 8.4 — Docker/Helm: architecture walkthrough
This Show & Tell covers the containerisation and Kubernetes deployment design for ASI-Build Phase 8.4.
Component map
Why multi-stage Docker?
pip installuseradd -u 1000in stage 1Healthcheck strategy
The
HEALTHCHECKinstruction in Dockerfile uses only stdlib (urllib.request) since thepython:3.11-slimbase image has nocurlorwget.In Kubernetes, the same
/healthendpoint is reused for bothlivenessProbeandreadinessProbe:HPA autoscaling math
With
targetCPUUtilizationPercentage: 70andrequests.cpu: 500m:At peak (all 8 replicas):
8 × 500m = 4 CPU cores— fits in a 3-node cluster with 2 CPUs each.Prometheus ServiceMonitor integration
The
release: kube-prometheus-stacklabel on the ServiceMonitor must match the Prometheus Operator'sserviceMonitorSelector. Check with:All 5 Phase-8 metric families (DecisionTracer, CausalGraph, ExplainAPI, SleepOrchestrator, ReplayBuffer) are scraped via the single
metricsport (9100for core,8080for ExplainAPI).Prometheus metrics added in Phase 8.4
asi_docker_build_duration_secondsdocker buildasi_image_size_bytesasi_helm_install_duration_secondshelm upgrade --installasi_pod_restarts_totalasi_hpa_replica_countPromQL — pod restart alert
Open questions
python:3.11-slimvspython:3.11-slim-bookworm— does the Debian version matter for security scanning?linux/arm64required, or can we shiplinux/amd64only for Phase 8.4?oci://ghcr.io/...) or use a traditional Helm repo (gh-pagesbranch)?Beta Was this translation helpful? Give feedback.
All reactions