apps(osint): pin the auth build and wire the single-admin Secret
osint-dashboard master d8113b37b8ac adds app/auth.py: deny-by-default on /api/* with a public read allowlist, so visitors get the map + news and only the admin gets keys/settings/mutations. Pin the amd64 image (:amd64-d8113b37b8ac) on app, camera-service and ingester, and feed ADMIN_USER / ADMIN_PASSWORD_HASH / ADMIN_SESSION_SECRET from Secret osint-admin. The refs are optional: true on purpose — a missing Secret must not stop the pod; the app then fails closed (admin routes 403) while the public HUD serves.
This commit is contained in:
parent
4ac1cd42d1
commit
426fc24d66
3 changed files with 26 additions and 4 deletions
|
|
@ -24,7 +24,7 @@ spec:
|
||||||
initContainers:
|
initContainers:
|
||||||
# Wait for Postgres before alembic runs (the entrypoint migrates).
|
# Wait for Postgres before alembic runs (the entrypoint migrates).
|
||||||
- name: wait-for-db
|
- name: wait-for-db
|
||||||
image: forgejo.siriusdevops.com/sirius/osint-dashboard:amd64-c48788d4b614
|
image: forgejo.siriusdevops.com/sirius/osint-dashboard:amd64-d8113b37b8ac
|
||||||
imagePullPolicy: IfNotPresent
|
imagePullPolicy: IfNotPresent
|
||||||
command:
|
command:
|
||||||
- python
|
- python
|
||||||
|
|
@ -42,7 +42,7 @@ spec:
|
||||||
sys.exit("postgres did not become reachable in 300s")
|
sys.exit("postgres did not become reachable in 300s")
|
||||||
containers:
|
containers:
|
||||||
- name: app
|
- name: app
|
||||||
image: forgejo.siriusdevops.com/sirius/osint-dashboard:amd64-c48788d4b614
|
image: forgejo.siriusdevops.com/sirius/osint-dashboard:amd64-d8113b37b8ac
|
||||||
imagePullPolicy: IfNotPresent
|
imagePullPolicy: IfNotPresent
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 8000
|
- containerPort: 8000
|
||||||
|
|
@ -56,6 +56,28 @@ spec:
|
||||||
secretKeyRef:
|
secretKeyRef:
|
||||||
name: osint-db
|
name: osint-db
|
||||||
key: password
|
key: password
|
||||||
|
# Single-admin auth (app/auth.py). optional: true on purpose — a
|
||||||
|
# missing Secret must not block startup; the app then fails closed
|
||||||
|
# (admin routes 403 "admin auth not configured") while the public
|
||||||
|
# read-only HUD still serves.
|
||||||
|
- name: ADMIN_USER
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: osint-admin
|
||||||
|
key: ADMIN_USER
|
||||||
|
optional: true
|
||||||
|
- name: ADMIN_PASSWORD_HASH
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: osint-admin
|
||||||
|
key: ADMIN_PASSWORD_HASH
|
||||||
|
optional: true
|
||||||
|
- name: ADMIN_SESSION_SECRET
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: osint-admin
|
||||||
|
key: ADMIN_SESSION_SECRET
|
||||||
|
optional: true
|
||||||
readinessProbe:
|
readinessProbe:
|
||||||
httpGet:
|
httpGet:
|
||||||
path: /api/health
|
path: /api/health
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,7 @@ spec:
|
||||||
kubernetes.io/hostname: siriussec
|
kubernetes.io/hostname: siriussec
|
||||||
containers:
|
containers:
|
||||||
- name: camera-service
|
- name: camera-service
|
||||||
image: forgejo.siriusdevops.com/sirius/osint-dashboard:amd64-c48788d4b614
|
image: forgejo.siriusdevops.com/sirius/osint-dashboard:amd64-d8113b37b8ac
|
||||||
imagePullPolicy: IfNotPresent
|
imagePullPolicy: IfNotPresent
|
||||||
command: ["python", "app/run_camera_service.py"]
|
command: ["python", "app/run_camera_service.py"]
|
||||||
envFrom:
|
envFrom:
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,7 @@ spec:
|
||||||
kubernetes.io/hostname: siriussec
|
kubernetes.io/hostname: siriussec
|
||||||
containers:
|
containers:
|
||||||
- name: ingester
|
- name: ingester
|
||||||
image: forgejo.siriusdevops.com/sirius/osint-dashboard:amd64-c48788d4b614
|
image: forgejo.siriusdevops.com/sirius/osint-dashboard:amd64-d8113b37b8ac
|
||||||
imagePullPolicy: IfNotPresent
|
imagePullPolicy: IfNotPresent
|
||||||
command: ["python", "app/run_ingester.py"]
|
command: ["python", "app/run_ingester.py"]
|
||||||
envFrom:
|
envFrom:
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue