From 69b0587f4152f064394bb108e21718f92dd1d53f Mon Sep 17 00:00:00 2001 From: funman300 Date: Wed, 2 Sep 2026 16:15:59 -0700 Subject: [PATCH] Update n8n deployment configuration --- apps/n8n/deployment.yaml | 80 ++++++++++++++++++++++++++++++++++++---- 1 file changed, 72 insertions(+), 8 deletions(-) diff --git a/apps/n8n/deployment.yaml b/apps/n8n/deployment.yaml index 1680277..9e86c50 100644 --- a/apps/n8n/deployment.yaml +++ b/apps/n8n/deployment.yaml @@ -3,77 +3,138 @@ kind: Deployment metadata: name: n8n namespace: n8n + spec: replicas: 1 + strategy: type: Recreate + selector: matchLabels: app: n8n + template: metadata: labels: app: n8n + spec: containers: - name: n8n image: docker.n8n.io/n8nio/n8n:2.32.7 imagePullPolicy: IfNotPresent + ports: - containerPort: 5678 + env: + # ------------------------------------------------ + # n8n URL / reverse proxy + # ------------------------------------------------ + - name: N8N_HOST value: n8n.aleshym.co + - name: N8N_PORT value: "5678" + - name: N8N_PROTOCOL value: https - - name: WEBHOOK_URL - value: https://n8n.aleshym.co/ + - name: N8N_EDITOR_BASE_URL value: https://n8n.aleshym.co/ + + - name: N8N_WEBHOOK_URL + value: https://n8n.aleshym.co/ + + - name: N8N_PROXY_HOPS + value: "1" + + - name: N8N_SECURE_COOKIE + value: "true" + + # Required for the Google OAuth callback issue + # we're currently troubleshooting. + - name: N8N_SKIP_AUTH_ON_OAUTH_CALLBACK + value: "true" + + # ------------------------------------------------ + # Locale / timezone + # ------------------------------------------------ + - name: GENERIC_TIMEZONE value: America/Vancouver + - name: TZ value: America/Vancouver + + # ------------------------------------------------ + # PostgreSQL + # ------------------------------------------------ + - name: DB_TYPE value: postgresdb + - name: DB_POSTGRESDB_HOST value: n8n-postgres + - name: DB_POSTGRESDB_PORT value: "5432" + - name: DB_POSTGRESDB_DATABASE value: n8n + - name: DB_POSTGRESDB_USER valueFrom: secretKeyRef: name: n8n-secrets key: postgres-user + - name: DB_POSTGRESDB_PASSWORD valueFrom: secretKeyRef: name: n8n-secrets key: postgres-password + + # ------------------------------------------------ + # n8n credential encryption + # ------------------------------------------------ + - name: N8N_ENCRYPTION_KEY valueFrom: secretKeyRef: name: n8n-secrets key: encryption-key - - name: N8N_SECURE_COOKIE - value: "true" - - name: N8N_PROXY_HOPS - value: "1" - - name: N8N_SKIP_AUTH_ON_OAUTH_CALLBACK - value: "true" + + # ------------------------------------------------ + # Community nodes + # ------------------------------------------------ + + # Required to continue using n8n-nodes-vikunja when + # n8n changes the future default to false. - name: N8N_UNVERIFIED_PACKAGES_ENABLED value: "true" + + # ------------------------------------------------ + # Execution history + # ------------------------------------------------ + - name: EXECUTIONS_DATA_PRUNE value: "true" + - name: EXECUTIONS_DATA_MAX_AGE value: "336" + + # Explicitly preserve the current n8n task timeout + # before the future default changes to 60 seconds. + - name: N8N_RUNNERS_TASK_TIMEOUT + value: "300" + volumeMounts: - name: n8n-data mountPath: /home/node/.n8n + readinessProbe: httpGet: path: /healthz @@ -82,6 +143,7 @@ spec: periodSeconds: 10 timeoutSeconds: 5 failureThreshold: 6 + livenessProbe: httpGet: path: /healthz @@ -90,12 +152,14 @@ spec: periodSeconds: 20 timeoutSeconds: 5 failureThreshold: 6 + resources: requests: cpu: 100m memory: 256Mi limits: memory: 1Gi + volumes: - name: n8n-data persistentVolumeClaim: