ci: 添加 Gitea Actions 部署流水线 + K3s 清单
对齐 jimeng-clone 的流水线结构(master→prod / dev→dev),适配 AirShelf 纯静态形态: - 电商AI平台/Dockerfile · 纯 nginx,无 build 阶段 - 电商AI平台/nginx.conf · 多入口 try_files,不 fallback 到 index.html - k8s/ · web-deployment + ingress + cert-issuer + redirect middleware - .gitea/workflows/deploy.yaml · build/push 重试 3 次,deploy 重试 5 次,失败上报日志中心 - prod 域名 airshelf.airlabs.art / dev 域名 airshelf.test.airlabs.art Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,59 @@
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: airshelf-web
|
||||
labels:
|
||||
app: airshelf-web
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: airshelf-web
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: airshelf-web
|
||||
spec:
|
||||
imagePullSecrets:
|
||||
- name: cr-pull-secret
|
||||
containers:
|
||||
- name: airshelf-web
|
||||
image: ${CI_REGISTRY_IMAGE}/airshelf-web:latest
|
||||
imagePullPolicy: Always
|
||||
ports:
|
||||
- containerPort: 80
|
||||
livenessProbe:
|
||||
httpGet:
|
||||
path: /
|
||||
port: 80
|
||||
initialDelaySeconds: 10
|
||||
periodSeconds: 10
|
||||
timeoutSeconds: 3
|
||||
failureThreshold: 3
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /
|
||||
port: 80
|
||||
initialDelaySeconds: 5
|
||||
periodSeconds: 5
|
||||
timeoutSeconds: 3
|
||||
failureThreshold: 3
|
||||
resources:
|
||||
requests:
|
||||
memory: "32Mi"
|
||||
cpu: "20m"
|
||||
limits:
|
||||
memory: "128Mi"
|
||||
cpu: "150m"
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: airshelf-web
|
||||
spec:
|
||||
selector:
|
||||
app: airshelf-web
|
||||
ports:
|
||||
- protocol: TCP
|
||||
port: 80
|
||||
targetPort: 80
|
||||
Reference in New Issue
Block a user