58ca57a627
Dashboard: - Optional DASHBOARD_TOKEN env var (K8s secret 'snek-dashboard-secret') - Flask before_request check via Authorization header or ?token= param - /webhook and /healthz remain public (SNEK POST needs to reach webhook) - Frontend prompts for token on first load, stores in localStorage - Token forwarded on fetch() calls and EventSource URL README decoding section: - Split into two full sub-sections for Sens'it Discovery (v3) and Sens'it v2 - Explicit bit ordering note (MSB-LSB v3 vs LSB-MSB v2) - Byte-by-byte tables, formulas per mode, worked examples - Note that auto-detection uses byte 0 bits 2-0 == 0b110 marker for v3 Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
82 lines
1.7 KiB
YAML
82 lines
1.7 KiB
YAML
apiVersion: v1
|
|
kind: PersistentVolumeClaim
|
|
metadata:
|
|
name: dashboard-data
|
|
namespace: snek
|
|
spec:
|
|
accessModes:
|
|
- ReadWriteOnce
|
|
storageClassName: local-path
|
|
resources:
|
|
requests:
|
|
storage: 1Gi
|
|
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: snek-dashboard
|
|
namespace: snek
|
|
spec:
|
|
replicas: 1
|
|
strategy:
|
|
type: Recreate
|
|
selector:
|
|
matchLabels:
|
|
app: snek-dashboard
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: snek-dashboard
|
|
spec:
|
|
containers:
|
|
- name: dashboard
|
|
image: 192.168.1.100:30500/snek-dashboard:latest
|
|
imagePullPolicy: Always
|
|
ports:
|
|
- containerPort: 3000
|
|
name: http
|
|
env:
|
|
- name: DB_PATH
|
|
value: /data/messages.db
|
|
- name: DASHBOARD_TOKEN
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: snek-dashboard-secret
|
|
key: token
|
|
optional: true
|
|
volumeMounts:
|
|
- name: data
|
|
mountPath: /data
|
|
readinessProbe:
|
|
httpGet:
|
|
path: /healthz
|
|
port: 3000
|
|
initialDelaySeconds: 5
|
|
periodSeconds: 10
|
|
resources:
|
|
requests:
|
|
cpu: 50m
|
|
memory: 64Mi
|
|
limits:
|
|
cpu: 500m
|
|
memory: 256Mi
|
|
volumes:
|
|
- name: data
|
|
persistentVolumeClaim:
|
|
claimName: dashboard-data
|
|
---
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: snek-dashboard
|
|
namespace: snek
|
|
spec:
|
|
type: LoadBalancer
|
|
loadBalancerIP: 192.168.1.213
|
|
selector:
|
|
app: snek-dashboard
|
|
ports:
|
|
- name: http
|
|
port: 80
|
|
targetPort: 3000
|