mirror of
https://github.com/hanzoai/bootnode.git
synced 2026-10-25 02:31:30 +00:00
Commerce is called at /v1, the indexer at /v1/indexer, and the operator serves /v1/clusters. The console's unused fleet helpers called a /api base nothing serves; they are gone. The legacy Quart env files named an app that no longer exists. Claude-Session: https://claude.ai/code/session_011i2AG9nwpiKUCVxAdDzYuU
106 lines
3.3 KiB
YAML
106 lines
3.3 KiB
YAML
# Bootnode web console — ONE deployment, every brand.
|
|
#
|
|
# This file used to declare four near-identical Deployments and four Services
|
|
# (bootnode-web-{hanzo,lux,zoo,pars}) running the SAME image, differing only in
|
|
# NEXT_PUBLIC_BRAND / _API_URL / _WS_URL / _IAM_URL / _IAM_CLIENT_ID /
|
|
# _IAM_DOMAIN. Two things were wrong with that:
|
|
#
|
|
# 1. It contradicted its own header comment ("one universal image, brand
|
|
# selected at runtime") — the brand was selected at DEPLOY time, four
|
|
# times, and had to be kept in sync with IAM by hand.
|
|
# 2. None of those variables did anything. The image is a Next.js static
|
|
# export served by the Go hanzoai/static binary; NEXT_PUBLIC_* is inlined
|
|
# into the client bundle when the image is BUILT, and no process in the
|
|
# container ever reads its environment. Four copies of a setting that was
|
|
# never applied.
|
|
#
|
|
# console/lib/brand.ts now resolves brand, theme, API origin, IAM issuer and OIDC
|
|
# client from window.location.hostname. One Deployment serves bootno.de,
|
|
# web3.hanzo.ai, lux.cloud, zoo.cloud and cloud.zoo.network, and adding the
|
|
# sixth host is an ingress rule plus a callback registration — no new workload.
|
|
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: bootnode-web
|
|
namespace: bootnode
|
|
labels:
|
|
app: bootnode-web
|
|
component: frontend
|
|
spec:
|
|
# Was 4 deployments x 2 replicas = 8 pods serving one identical bundle.
|
|
replicas: 3
|
|
selector:
|
|
matchLabels:
|
|
app: bootnode-web
|
|
strategy:
|
|
type: RollingUpdate
|
|
rollingUpdate:
|
|
maxSurge: 1
|
|
maxUnavailable: 0
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: bootnode-web
|
|
component: frontend
|
|
spec:
|
|
containers:
|
|
- name: web
|
|
image: ghcr.io/hanzoai/bootnode:latest-web
|
|
imagePullPolicy: Always
|
|
ports:
|
|
- name: http
|
|
containerPort: 3001
|
|
protocol: TCP
|
|
# No env. Every value that was here is now hostname-derived in the
|
|
# browser, which is the only layer that knows which brand is being
|
|
# served on this request.
|
|
resources:
|
|
requests:
|
|
cpu: "100m"
|
|
memory: "128Mi"
|
|
limits:
|
|
cpu: "1000m"
|
|
memory: "512Mi"
|
|
# Probe `/`. The runtime is a static file server: `/` is the one path
|
|
# guaranteed to exist and it proves the bundle is actually being served.
|
|
livenessProbe:
|
|
httpGet:
|
|
path: /
|
|
port: http
|
|
initialDelaySeconds: 10
|
|
periodSeconds: 15
|
|
timeoutSeconds: 5
|
|
failureThreshold: 5
|
|
readinessProbe:
|
|
httpGet:
|
|
path: /
|
|
port: http
|
|
initialDelaySeconds: 3
|
|
periodSeconds: 10
|
|
timeoutSeconds: 5
|
|
failureThreshold: 5
|
|
securityContext:
|
|
runAsNonRoot: true
|
|
runAsUser: 1001
|
|
allowPrivilegeEscalation: false
|
|
readOnlyRootFilesystem: true
|
|
capabilities:
|
|
drop: ["ALL"]
|
|
imagePullSecrets:
|
|
- name: ghcr-secret
|
|
---
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: bootnode-web
|
|
namespace: bootnode
|
|
spec:
|
|
type: ClusterIP
|
|
ports:
|
|
- name: http
|
|
port: 3001
|
|
targetPort: http
|
|
selector:
|
|
app: bootnode-web
|