CI / CI (push) Successful in 5m38s
Root cause: image updater used 'digest' strategy with allow-tags=latest
but 'digest' requires a version constraint. Result: updater errored every
2min cycle and never promoted new images.
Fix:
- Strategy: newest-build (picks most recently pushed tag)
- Allow-tags: regexp:^[a-f0-9]{7}$ (matches 7-char git SHA tags from CI)
- Alias: app (matches ArgoCD app annotation)
87 lines
2.4 KiB
YAML
87 lines
2.4 KiB
YAML
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: portfolio
|
|
namespace: portfolio
|
|
labels:
|
|
app.kubernetes.io/name: portfolio
|
|
app.kubernetes.io/component: web
|
|
annotations:
|
|
argocd-image-updater.argoproj.io/image-list: app=forgejo.riotpiao.com/rock/portfolio
|
|
argocd-image-updater.argoproj.io/app.update-strategy: newest-build
|
|
argocd-image-updater.argoproj.io/app.allow-tags: "regexp:^[a-f0-9]{7}$"
|
|
spec:
|
|
replicas: 2
|
|
selector:
|
|
matchLabels:
|
|
app.kubernetes.io/name: portfolio
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app.kubernetes.io/name: portfolio
|
|
spec:
|
|
containers:
|
|
- name: portfolio
|
|
image: forgejo.riotpiao.com/rock/portfolio:latest
|
|
imagePullPolicy: Always
|
|
env:
|
|
- name: FORGEJO_TOKEN
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: portfolio-secrets
|
|
key: FORGEJO_TOKEN
|
|
# OAuth credentials for LLM API (client_credentials grant)
|
|
- name: AUTHENTIK_CLIENT_ID
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: portfolio-agent-oidc
|
|
key: CLIENT_ID
|
|
- name: AUTHENTIK_CLIENT_SECRET
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: portfolio-agent-oidc
|
|
key: CLIENT_SECRET
|
|
- name: AUTHENTIK_TOKEN_URL
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: portfolio-agent-oidc
|
|
key: TOKEN_URL
|
|
# LLM API configuration (from encrypted ConfigMap)
|
|
- name: LLM_API_URL
|
|
valueFrom:
|
|
configMapKeyRef:
|
|
name: portfolio-llm-config
|
|
key: LLM_API_URL
|
|
- name: LLM_MODEL
|
|
valueFrom:
|
|
configMapKeyRef:
|
|
name: portfolio-llm-config
|
|
key: LLM_MODEL
|
|
ports:
|
|
- name: http
|
|
containerPort: 3000
|
|
protocol: TCP
|
|
livenessProbe:
|
|
httpGet:
|
|
path: /
|
|
port: http
|
|
initialDelaySeconds: 10
|
|
periodSeconds: 10
|
|
timeoutSeconds: 5
|
|
failureThreshold: 3
|
|
readinessProbe:
|
|
httpGet:
|
|
path: /
|
|
port: http
|
|
initialDelaySeconds: 5
|
|
periodSeconds: 5
|
|
timeoutSeconds: 3
|
|
failureThreshold: 2
|
|
resources:
|
|
requests:
|
|
cpu: 100m
|
|
memory: 128Mi
|
|
limits:
|
|
cpu: 500m
|
|
memory: 512Mi
|