gcloud-lab/apps/base/customer1/n8n/deployment.yaml
2026-04-28 03:31:52 +00:00

102 lines
2 KiB
YAML

apiVersion: apps/v1
kind: Deployment
metadata:
name: customer1-n8n
namespace: customer1
labels:
app: customer1-n8n
spec:
selector:
matchLabels:
app: customer1-n8n
replicas: 1
strategy:
rollingUpdate:
type: RollingUpdate
template:
metadata:
labels:
app: customer1-n8n
spec:
securityContext:
runAsNonroot: True
runAsUser: 1000
runAsGroup: 1000
fsGroup: 1000
seccompProfile:
type: RuntimeDefault
containers:
- name: customer1-n8n
image: docker.n8n.io/n8nio/n8n:2.1.4
imagePullPolicy: IfNotPresent
resources:
requests:
memory: "500Mi"
cpu: "250m"
limits:
memory: "1Gi"
cpu: "500"
livenessProbe:
httpGet:
path: /healthz
port: 3008
initialDelaySeconds: 30
timeoutSeconds: 5
failureThreshold: 3
readinessProbe:
httpGet:
path: /healthz
port: 3008
initialDelaySeconds: 5
periodSeconds: 5
timeoutSeconds: 3
failureThreshold: 3
securityContext:
allowPrivilegeEscalation: false
readOnlyRootFilesystem: True
capabilites:
drop:
- ALL
envFrom:
- configMapRef:
name: customer1-n8n-config
- secretRef:
name: customer1-n8n-secret
ports:
- containerPort: 5678
name: n8n-port
volumeMounts:
- name: cache
mountPath: /home/node/
- name: tmp
mountPath: /tmp
volumes:
- name: cache
emptyDir: {}
- name: tmp
emptyDir: {}
restartPolicy: Always