diff --git a/roles/n8n/defaults/main.yml b/roles/n8n/defaults/main.yml index 2eb203a..bf6eb63 100644 --- a/roles/n8n/defaults/main.yml +++ b/roles/n8n/defaults/main.yml @@ -56,3 +56,8 @@ n8n_data_max_age: 2160 # Memory limit for the service, in MB n8n_mem_limit: 2048 + +# Extra env var to pass to the service +# n8n_env_var: +# NODE_FUNCTION_ALLOW_BUILTIN: request-promise-native +n8n_env_var: {} diff --git a/roles/n8n/templates/env.j2 b/roles/n8n/templates/env.j2 index c7ac527..5465e24 100644 --- a/roles/n8n/templates/env.j2 +++ b/roles/n8n/templates/env.j2 @@ -5,3 +5,6 @@ VUE_APP_URL_BASE_API={{ n8n_public_url }} N8N_ENCRYPTION_KEY={{ n8n_secret_key | quote }} EXECUTIONS_DATA_PRUNE=true EXECUTIONS_DATA_MAX_AGE={{ n8n_data_max_age }} +{% for env in n8n_env_var.keys() | list %} +{{ env }}={{ n8n_env_var[env] }} +{% endfor %}