"404 page not found" because of n8n folder attributes

Hi. I’m joining the problem.
Almost according to the instructions (almost, because I prefer my own way of docker installation) I repeated what you are doing:

root@ilove_n8n:~# history
    1  apt update
    2  apt upgrade -y
    3  curl -fsSL https://get.docker.com -o install-docker.sh && sh install-docker.sh
    4  vi docker-compose.yml
    5  vi .env
    6  mkdir n8n
    7  docker compose up

the problem persists, even when using the command that supposedly grants permissions.

Okay, we’ll try your option:

root@ilove_n8n:~# history
    7  docker compose up
    8  docker run --rm -it --user root -v ~/.n8n:/home/node/.n8n --entrypoint chown n8nio/base:16 -R node:node /home/node/.n8n
    9  docker compose up

I think you are overdoing it by hiding permissions inside the container for the node user. add a command to change permissions directly in the Dockerfile of the image build.

I will also test this option to solve the problem.

1 Like

Your instructions on the page n8n v1.0 migration guide | n8n Docs and the command you mentioned above are not quite correct.

docker run --rm -it --user root -v /root/n8n/.n8n:/home/node/.n8n --entrypoint chown n8nio/base:16 -R node:node /home/node/.n8n
where instead of root -v ~/n8n/.n8n:/home/node/.n8n I used the folder that is specified as data_folder in the .env file

4 Likes

Thank you @brewoutlay

Confirmed. This fixes the whole issue.

1 Like

Hey @brewoutlay,

That is a good spot, I had made an assumption that folk would replace ~/.n8n with their volume mount as it isn’t always a data_folder environment option.

I will update the guide to make this a bit clearer, Although it shouldn’t be needed at all for new installations and I am looking into what is going on there between other issues.

3 Likes

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.