Files
agent_management/k8s/deployment.yaml
T

84 lines
2.1 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
apiVersion: apps/v1
kind: Deployment
metadata:
name: agent-manager
namespace: agent-manager
labels:
app: agent-manager
spec:
replicas: 1
selector:
matchLabels:
app: agent-manager
template:
metadata:
labels:
app: agent-manager
spec:
serviceAccountName: agent-manager
imagePullSecrets:
- name: acr-secret
containers:
- name: agent-manager
image: agnettaiji.azurecr.io/ai-agents/agent-manager:heicode-v2-runtime-20260604014451-arm64
imagePullPolicy: Always
ports:
- containerPort: 8000
name: http
env:
- name: NAMESPACE
value: "ai-agents"
- name: SERVICE_PORT
value: "8000"
- name: SERVICE_HOST
value: "0.0.0.0"
# 可选:如果使用挂载的kubeconfig文件
# - name: KUBECONFIG_PATH
# value: "/root/.kube/config"
resources:
requests:
cpu: 200m
memory: 256Mi
limits:
cpu: 1000m
memory: 1Gi
# 可选:挂载kubeconfig Secret(如果不使用ServiceAccount)
# volumeMounts:
# - name: kubeconfig
# mountPath: /root/.kube
# readOnly: true
livenessProbe:
httpGet:
path: /api/agent/health
port: 8000
initialDelaySeconds: 30
periodSeconds: 10
readinessProbe:
httpGet:
path: /api/agent/health
port: 8000
initialDelaySeconds: 10
periodSeconds: 5
# 可选:定义kubeconfig volume(如果不使用ServiceAccount)
# volumes:
# - name: kubeconfig
# secret:
# secretName: kubeconfig-secret
---
apiVersion: v1
kind: Service
metadata:
name: agent-manager
namespace: agent-manager
labels:
app: agent-manager
spec:
type: LoadBalancer
ports:
- port: 80
targetPort: 8000
protocol: TCP
name: http
selector:
app: agent-manager