gorush/k8s/gorush-deployment.yaml

41 lines
883 B
YAML

apiVersion: apps/v1
kind: Deployment
metadata:
name: gorush
namespace: gorush
spec:
replicas: 3
selector:
matchLabels:
app: gorush
tier: frontend
template:
metadata:
labels:
app: gorush
tier: frontend
spec:
containers:
- image: appleboy/gorush
name: gorush
imagePullPolicy: Always
ports:
- containerPort: 8088
livenessProbe:
httpGet:
path: /healthz
port: 8088
initialDelaySeconds: 3
periodSeconds: 3
env:
- name: GORUSH_STAT_ENGINE
valueFrom:
configMapKeyRef:
name: gorush-config
key: stat.engine
- name: GORUSH_STAT_REDIS_ADDR
valueFrom:
configMapKeyRef:
name: gorush-config
key: stat.redis.host