152 lines
4.1 KiB
YAML
152 lines
4.1 KiB
YAML
# =============================================================================
|
|
# n8n Helm Chart - Custom Values
|
|
# =============================================================================
|
|
# Aula 06 - Deploy n8n via Helm
|
|
#
|
|
# Chart: community-charts/n8n
|
|
# Docs: https://community-charts.github.io/docs/charts/n8n/configuration
|
|
# =============================================================================
|
|
|
|
# -----------------------------------------------------------------------------
|
|
# Imagem
|
|
# -----------------------------------------------------------------------------
|
|
image:
|
|
repository: n8nio/n8n
|
|
tag: "2.1.4"
|
|
pullPolicy: IfNotPresent
|
|
|
|
# -----------------------------------------------------------------------------
|
|
# Chave de Criptografia
|
|
# -----------------------------------------------------------------------------
|
|
encryptionKey: "workshop-n8n-encryption-key-32ch"
|
|
|
|
# -----------------------------------------------------------------------------
|
|
# Banco de Dados PostgreSQL
|
|
# -----------------------------------------------------------------------------
|
|
db:
|
|
type: postgresdb
|
|
|
|
postgresql:
|
|
enabled: true
|
|
auth:
|
|
database: n8n
|
|
username: n8n
|
|
password: "n8n-postgres-workshop-2025"
|
|
primary:
|
|
persistence:
|
|
enabled: true
|
|
size: 5Gi
|
|
|
|
# -----------------------------------------------------------------------------
|
|
# Redis (necessário para Queue Mode)
|
|
# -----------------------------------------------------------------------------
|
|
redis:
|
|
enabled: true
|
|
architecture: standalone
|
|
auth:
|
|
enabled: true
|
|
password: "n8n-redis-workshop-2025"
|
|
|
|
# -----------------------------------------------------------------------------
|
|
# Ingress NGINX
|
|
# -----------------------------------------------------------------------------
|
|
ingress:
|
|
enabled: true
|
|
className: nginx
|
|
annotations:
|
|
nginx.ingress.kubernetes.io/proxy-body-size: "50m"
|
|
nginx.ingress.kubernetes.io/proxy-read-timeout: "3600"
|
|
nginx.ingress.kubernetes.io/proxy-send-timeout: "3600"
|
|
hosts:
|
|
- host: n8n.localhost
|
|
paths:
|
|
- path: /
|
|
pathType: Prefix
|
|
|
|
# -----------------------------------------------------------------------------
|
|
# Main Node
|
|
# -----------------------------------------------------------------------------
|
|
main:
|
|
extraEnvVars:
|
|
N8N_SECURE_COOKIE: "false" # Permite HTTP sem HTTPS (apenas para dev/workshop)
|
|
persistence:
|
|
enabled: true
|
|
size: 2Gi
|
|
mountPath: "/home/node/.n8n"
|
|
resources:
|
|
requests:
|
|
cpu: 100m
|
|
memory: 256Mi
|
|
limits:
|
|
cpu: 1000m
|
|
memory: 1Gi
|
|
|
|
# -----------------------------------------------------------------------------
|
|
# Workers (Queue Mode)
|
|
# -----------------------------------------------------------------------------
|
|
worker:
|
|
mode: queue
|
|
count: 2
|
|
concurrency: 10
|
|
extraEnvVars:
|
|
N8N_SECURE_COOKIE: "false"
|
|
resources:
|
|
requests:
|
|
cpu: 100m
|
|
memory: 256Mi
|
|
limits:
|
|
cpu: 500m
|
|
memory: 512Mi
|
|
autoscaling:
|
|
enabled: true
|
|
minReplicas: 2
|
|
maxReplicas: 5
|
|
metrics:
|
|
- type: Resource
|
|
resource:
|
|
name: cpu
|
|
target:
|
|
type: Utilization
|
|
averageUtilization: 70
|
|
- type: Resource
|
|
resource:
|
|
name: memory
|
|
target:
|
|
type: Utilization
|
|
averageUtilization: 80
|
|
|
|
# -----------------------------------------------------------------------------
|
|
# Webhooks (Queue Mode)
|
|
# -----------------------------------------------------------------------------
|
|
webhook:
|
|
mode: queue
|
|
count: 1
|
|
url: "http://n8n.localhost"
|
|
extraEnvVars:
|
|
N8N_SECURE_COOKIE: "false"
|
|
resources:
|
|
requests:
|
|
cpu: 50m
|
|
memory: 128Mi
|
|
limits:
|
|
cpu: 250m
|
|
memory: 256Mi
|
|
autoscaling:
|
|
enabled: true
|
|
minReplicas: 1
|
|
maxReplicas: 3
|
|
metrics:
|
|
- type: Resource
|
|
resource:
|
|
name: cpu
|
|
target:
|
|
type: Utilization
|
|
averageUtilization: 70
|
|
|
|
# -----------------------------------------------------------------------------
|
|
# Configurações de Segurança
|
|
# -----------------------------------------------------------------------------
|
|
securityContext:
|
|
runAsNonRoot: true
|
|
runAsUser: 1000
|