P6: S3 blob store, Helm chart, air-gapped installer verify loop
- S3BlobStore (object_store, path-style) behind the same BlobStore trait, tested against a REAL MinIO container (round trip, overwrite, NotFound on get and delete, nested keys); [storage] backend=local|s3 config with validation + server-side selection (S3 creds via env overlay) - Helm chart: server pod with the secret broker as a SIDECAR sharing a private emptyDir unix socket (no network hop carries credentials), frontend, optional local PVC vs S3, OIDC/oauth values, unbuffered-SSE ingress annotations, NetworkPolicies (frontend->server only), hardened securityContexts; ci/check-helm.sh lints AND asserts the rendered topology properties - deploy/airgapped/install.sh: offline signature+checksum verification via the bundled teamclaw-bundler BEFORE any docker load; --verify-only mode; ci/test-install.sh rehearses clean/tampered/wrong-key paths with the real binary - CI: helm gate + installer rehearsal wired in 149 Rust tests; helm lint + rendered assertions green; installer verify-path rehearsal green. Co-Authored-By: Claude Fable 5 <[email protected]>
This commit is contained in:
co-authored by
Claude Fable 5
parent
ccf96053e6
commit
70ec39f696
@@ -0,0 +1,124 @@
|
||||
# The server pod runs teamclaw-server with the secret broker as a sidecar
|
||||
# sharing a private emptyDir for the unix socket — the §15 topology: no
|
||||
# network hop carries credentials, and nothing else can reach the socket.
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: teamclaw-server
|
||||
labels: {{- include "teamclaw.labels" . | nindent 4 }}
|
||||
spec:
|
||||
replicas: {{ .Values.server.replicas }}
|
||||
selector:
|
||||
matchLabels: {{- include "teamclaw.serverSelector" . | nindent 6 }}
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
{{- include "teamclaw.serverSelector" . | nindent 8 }}
|
||||
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||
spec:
|
||||
securityContext:
|
||||
runAsNonRoot: true
|
||||
runAsUser: 10001
|
||||
seccompProfile: { type: RuntimeDefault }
|
||||
containers:
|
||||
- name: server
|
||||
image: "{{ .Values.image.registry }}/server:{{ .Values.image.tag }}"
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
ports:
|
||||
- { containerPort: 8080, name: http }
|
||||
env:
|
||||
- name: TEAMCLAW_CONFIG
|
||||
value: /etc/teamclaw/teamclaw.toml
|
||||
- name: TEAMCLAW_DATABASE__URL
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ .Values.database.urlSecretName }}
|
||||
key: url
|
||||
{{- if eq .Values.llm.provider "anthropic" }}
|
||||
- name: ANTHROPIC_API_KEY
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ .Values.llm.apiKeySecretName }}
|
||||
key: api-key
|
||||
{{- end }}
|
||||
{{- if eq .Values.storage.backend "s3" }}
|
||||
- name: TEAMCLAW_STORAGE__S3_ACCESS_KEY
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ .Values.storage.s3.credentialsSecretName }}
|
||||
key: access-key
|
||||
- name: TEAMCLAW_STORAGE__S3_SECRET_KEY
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ .Values.storage.s3.credentialsSecretName }}
|
||||
key: secret-key
|
||||
{{- end }}
|
||||
volumeMounts:
|
||||
- { name: config, mountPath: /etc/teamclaw, readOnly: true }
|
||||
- { name: broker-socket, mountPath: /run/teamclaw }
|
||||
{{- if eq .Values.storage.backend "local" }}
|
||||
- { name: data, mountPath: {{ .Values.storage.dataDir }} }
|
||||
{{- end }}
|
||||
readinessProbe:
|
||||
httpGet: { path: /healthz, port: http }
|
||||
initialDelaySeconds: 3
|
||||
resources: {{- toYaml .Values.server.resources | nindent 12 }}
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
capabilities: { drop: ["ALL"] }
|
||||
readOnlyRootFilesystem: true
|
||||
- name: broker
|
||||
image: "{{ .Values.image.registry }}/broker:{{ .Values.image.tag }}"
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
env:
|
||||
- name: TEAMCLAW_BROKER_SOCKET
|
||||
value: /run/teamclaw/broker.sock
|
||||
- name: TEAMCLAW_BROKER_KEY_FILE
|
||||
value: /etc/teamclaw-broker/broker.key
|
||||
- name: TEAMCLAW_DATABASE__URL
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ .Values.database.urlSecretName }}
|
||||
key: url
|
||||
volumeMounts:
|
||||
- { name: broker-socket, mountPath: /run/teamclaw }
|
||||
- { name: broker-key, mountPath: /etc/teamclaw-broker, readOnly: true }
|
||||
resources: {{- toYaml .Values.broker.resources | nindent 12 }}
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
capabilities: { drop: ["ALL"] }
|
||||
readOnlyRootFilesystem: true
|
||||
volumes:
|
||||
- name: config
|
||||
configMap: { name: teamclaw-config }
|
||||
- name: broker-socket
|
||||
emptyDir: {}
|
||||
- name: broker-key
|
||||
secret: { secretName: {{ .Values.broker.keySecretName }} }
|
||||
{{- if eq .Values.storage.backend "local" }}
|
||||
- name: data
|
||||
persistentVolumeClaim: { claimName: teamclaw-data }
|
||||
{{- end }}
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: teamclaw-server
|
||||
labels: {{- include "teamclaw.labels" . | nindent 4 }}
|
||||
spec:
|
||||
selector: {{- include "teamclaw.serverSelector" . | nindent 4 }}
|
||||
ports:
|
||||
- { name: http, port: 8080, targetPort: http }
|
||||
{{- if eq .Values.storage.backend "local" }}
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: teamclaw-data
|
||||
labels: {{- include "teamclaw.labels" . | nindent 4 }}
|
||||
spec:
|
||||
accessModes: ["ReadWriteOnce"]
|
||||
resources:
|
||||
requests:
|
||||
storage: {{ .Values.storage.pvcSize }}
|
||||
{{- end }}
|
||||
Reference in New Issue
Block a user