How to update your n8n self hosted n8n instance

Robm writes:

Keep your n8n self-hosted instance running smoothly! In this video, we’ll guide you through the process of updating your n8n setup to ensure you have the latest features and security improvements. Whether you’re a seasoned user or just getting started, this tutorial will help you navigate the update process effortlessly. In this video, you’ll learn:

  • The importance of keeping your n8n instance updated. :arrows_counterclockwise:
  • Step-by-step instructions to update your self-hosted n8n. :gear:
  • How to troubleshoot common issues during the update process. :hammer_and_wrench:
1 Like

Hi! I run n8n with npx n8n, is there something we need to do to update? May be just restart the process? Thanks!

@050505 see our documentation:

Hi,

Please make a tutorial for people install n8n via Cyberpanel Docker feature.
It’s very fast to install. But no tutorial yet for updating. (i tried and failed many times)

Thanks

This is what I got when i try to update the last command

root@aaa:~/n8n-docker-caddy# docker compose up -d
WARN[0000] /root/n8n-docker-caddy/docker-compose.yml: the attribute `version` is obsolete, it will be ignored, please remove it to avoid potential confusion 
[+] Running 1/1
 ✔ Network n8n-docker-caddy_default  Created                                                                                                                                                                                                    0.7s 
external volume "n8n_data" not found
root@aaa:~/n8n-docker-caddy#

What’s can be wrong if I update and I see this message?

Webhook node version 1 (Latest version: 2)

I am self hosting as well and i am wanting upgrade instance to pro, but when attempting to upgrade to pro, a seperate instance is created.

It works! If someone installed it on digital ocean from market place, you can use this exact same guide.

Just make sure you first use this command

cd …/opt/n8n-docker-caddy/

Hey, I’m not too sure if this error should fall under this thread but hope someone has an answer. I’m currently stuck at this step when self hosting n8n via Digital Ocean and got this error message:

WARN[0000] /home/veraops/n8n-docker-caddy/docker-compose.yml: the attribute `version` is obsolete, it will be ignored, please remove it to avoid potential confusion 
service "n8n" refers to undefined volume home/veraops/n8n-docker-caddy/local_files: invalid compose project

Anyone got any fix for this?

1 Like

can u share ure .yml

its likely one of the below

Absolute path

volumes:
  - /home/veraops/n8n-docker-caddy/local_files:/local_files

Relative path (from the Compose file’s directory)

volumes:
  - ./local_files:/local_files

just make sre formatted correctly etc depending which way

if you want docker volume

  volumes:
    - n8n_storage:/home/node/.n8n

##just make sure to include at top of yml file the below declaring the volumes.

volumes:
  db_storage:
  n8n_storage:

etc at top of yml

@King_Samuel_David

Hey, here’s my .yml before implementing any of your solutions:

services:
  n8n:
    image: docker.n8n.io/n8nio/n8n
    container_name: n8n
    restart: always
    ports:
      - 5678:5678
    environment:
      - N8N_HOST=localhost
      - N8N_PORT=5678
      - WEBHOOK_URL=http://localhost:5678
    volumes:
      - n8n_data:/home/node/.n8n

volumes:
  n8n_data:

It doesn’t seem to be working even w/ your solutions. It might be due to how I change the code. Could you show me exactly how to change them?

Btw I’m using MacBook Air M2 and my .yml is currently sitting on one of my Desktop folders (n8n-veraops).

Also, would appreciate if you could provide me w/ more workarounds so I can test them out in case these 3 codes don’t work.

Thanks!