56 lines
2.3 KiB
Markdown
56 lines
2.3 KiB
Markdown
# n8n Workload
|
|
|
|
> [!NOTE]
|
|
> This directory contains the configuration and deployment manifests for **n8n**, a workflow automation tool, deployed in the `n8n` namespace.
|
|
|
|
## Workload Information
|
|
|
|
* **Namespace**: `n8n`
|
|
* **Deployment**: `mop-n8n` (Managed via Helm)
|
|
* **Database**: PostgreSQL managed by CloudNativePG operator with cluster name `db`.
|
|
* **Ingress**: `n8n.moritzgraf.de` (NGINX Ingress, Let's Encrypt certificates).
|
|
|
|
|
|
### Key Files
|
|
|
|
* `n8n.secret.yml`: The Helm values file containing configurations, secrets, DB connections, and Ingress settings. Use git-crypt to unlock before editing.
|
|
|
|
|
|
## Maintenance Instructions
|
|
|
|
> [!IMPORTANT]
|
|
> **Update Strategy**: Never update two things at the same time! Update only one component at a time (e.g., the Helm chart OR the n8n application image). After updating one component, automatically verify its functionality and **always ask the human to verify functionality before continuing** to the next update.
|
|
|
|
### 1. How to Redeploy/Apply Changes to n8n
|
|
|
|
When making changes to `n8n.secret.yml` (e.g., updating configuration or resource limits), you need to re-apply the Helm chart from the `k8s` directory:
|
|
|
|
```bash
|
|
# Run this from the infrapuzzle/k8s directory
|
|
cd ../k8s # if you are in n8n
|
|
helm upgrade --cleanup-on-fail --install mop-n8n \
|
|
oci://8gears.container-registry.com/library/n8n \
|
|
--namespace n8n --values n8n/n8n.secret.yml --version 2.0.1
|
|
```
|
|
*(Note: The `--version 2.0.1` flag specifies the Helm Chart version. See Section 2 for updating the chart.)*
|
|
|
|
To verify the installation:
|
|
```bash
|
|
helm get manifest mop-n8n -n n8n | less
|
|
```
|
|
|
|
### 2. How to Update the n8n Helm Chart Version
|
|
|
|
1. Check the [8gears n8n-helm-chart Releases page](https://github.com/8gears/n8n-helm-chart/releases) for the latest chart version.
|
|
2. When running the `helm upgrade` command, change the `--version` argument (e.g., `--version 2.0.1`) to the latest version.
|
|
3. Verify the deployment functionality automatically and with the human user before proceeding.
|
|
|
|
### 3. How to Update the n8n Application Version
|
|
|
|
1. Check the [n8n GitHub Releases page](https://github.com/n8n-io/n8n/releases) for the latest version tag (e.g., `2.13.4`).
|
|
2. Update the `tag:` value in `n8n/n8n.secret.yml`.
|
|
3. Re-run the `helm upgrade` command mentioned above.
|
|
4. Verify the deployment functionality automatically and with the human user before proceeding.
|
|
|
|
|