forked from openclaw-rocks/k8s-operator
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathopenclaw_v1alpha1_openclawinstance_full.yaml
More file actions
214 lines (200 loc) · 5.06 KB
/
openclaw_v1alpha1_openclawinstance_full.yaml
File metadata and controls
214 lines (200 loc) · 5.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
# Full OpenClawInstance example with all options
apiVersion: openclaw.rocks/v1alpha1
kind: OpenClawInstance
metadata:
name: production-openclaw
namespace: openclaw
labels:
environment: production
spec:
# Container image configuration
image:
repository: ghcr.io/openclaw/openclaw
tag: "2026.2.3"
pullPolicy: IfNotPresent
# pullSecrets:
# - name: ghcr-pull-secret
# Provider-agnostic configuration
# Option A: Reference external ConfigMap with your openclaw.json
# config:
# configMapRef:
# name: my-openclaw-config
# key: openclaw.json
# Option B: Inline raw config (any valid openclaw.json content)
config:
raw:
agents:
defaults:
model:
primary: "anthropic/claude-sonnet-4-20250514"
sandbox: true
session:
scope: "per-sender"
# Environment variables for API keys and configuration
envFrom:
- secretRef:
name: openclaw-api-keys # Contains ANTHROPIC_API_KEY, OPENAI_API_KEY, etc.
# Gateway authentication — use an existing Secret instead of auto-generation
# The Secret must have a key named "token"
# gateway:
# existingSecret: my-gateway-token
env:
# If gateway.existingSecret is not set, OPENCLAW_GATEWAY_TOKEN is auto-injected.
# Override manually only if you need a specific value:
# - name: OPENCLAW_GATEWAY_TOKEN
# valueFrom:
# secretKeyRef:
# name: gateway-token
# key: token
- name: OPENCLAW_DISABLE_BONJOUR
value: "1"
# Resource requirements
resources:
requests:
cpu: "500m"
memory: "1Gi"
limits:
cpu: "2000m"
memory: "4Gi"
# Security configuration
security:
podSecurityContext:
runAsUser: 1000
runAsGroup: 1000
fsGroup: 1000
runAsNonRoot: true
containerSecurityContext:
allowPrivilegeEscalation: false
readOnlyRootFilesystem: false
capabilities:
drop:
- ALL
networkPolicy:
enabled: true
allowedIngressNamespaces:
- ingress-nginx
allowedIngressCIDRs:
- 10.0.0.0/8
allowDNS: true
rbac:
createServiceAccount: true
# Storage configuration
storage:
persistence:
enabled: true
storageClass: premium-rwo
size: 50Gi
accessModes:
- ReadWriteOnce
# Chromium sidecar for browser automation
chromium:
enabled: true
image:
repository: ghcr.io/browserless/chromium
tag: "v2.0.0"
# Recommended: pin to a specific digest
# digest: "sha256:abc123..."
resources:
requests:
cpu: "250m"
memory: "512Mi"
limits:
cpu: "1000m"
memory: "2Gi"
# Persist browser profiles (cookies, localStorage, session tokens) across pod restarts
persistence:
enabled: true
# storageClass: "" # uses cluster default if empty
size: "1Gi"
# existingClaim: "" # use a pre-existing PVC instead
# Custom sidecar containers
# sidecars:
# - name: cloud-sql-proxy
# image: gcr.io/cloud-sql-connectors/cloud-sql-proxy:2.14.3
# args:
# - "--structured-logs"
# - "my-project:us-central1:my-db"
# ports:
# - containerPort: 5432
# resources:
# requests:
# cpu: "100m"
# memory: "128Mi"
# limits:
# cpu: "500m"
# memory: "256Mi"
# securityContext:
# runAsNonRoot: true
# sidecarVolumes:
# - name: proxy-creds
# secret:
# secretName: cloud-sql-proxy-sa
# Networking configuration
networking:
service:
type: ClusterIP
annotations:
service.beta.kubernetes.io/aws-load-balancer-internal: "true"
ingress:
enabled: true
className: nginx
annotations:
cert-manager.io/cluster-issuer: letsencrypt-prod
hosts:
- host: openclaw.internal.example.com
paths:
- path: /
pathType: Prefix
tls:
- secretName: openclaw-tls
hosts:
- openclaw.internal.example.com
security:
forceHTTPS: true
enableHSTS: true
rateLimiting:
enabled: true
requestsPerSecond: 50
# Health probes
probes:
liveness:
enabled: true
initialDelaySeconds: 30
periodSeconds: 10
timeoutSeconds: 5
failureThreshold: 3
readiness:
enabled: true
initialDelaySeconds: 5
periodSeconds: 5
timeoutSeconds: 3
failureThreshold: 3
startup:
enabled: true
periodSeconds: 5
failureThreshold: 60
# Observability
observability:
metrics:
enabled: true
port: 9090
serviceMonitor:
enabled: true
interval: 15s
labels:
release: prometheus
logging:
level: info
format: json
# High availability
availability:
podDisruptionBudget:
enabled: true
maxUnavailable: 1
nodeSelector:
node-type: application
tolerations:
- key: dedicated
operator: Equal
value: openclaw
effect: NoSchedule