Hi guys , can any one help me?
Hi @zhoxv welcome!
For file operations you need to explicitly mention those paths/folders into this N8N_RESTRICT_FILE_ACCESS_TO=/files and that /files should be an DIR, and once that is done you need to run this:
chown -R 1000:1000 ./local-files
So now your path should be writable.
hey @zhoxv β looks like the path field might not be in Expression mode. to evaluate $now.toMillis(), the field needs to start with =, so it would be ={{ '/files/' + $now.toMillis() + '.mp4' }}. without the = prefix, n8n treats the whole thing as a literal string including the curly braces, which is probably why itβs failing on the filename.
@zhoxv You should specify which directories n8n can access by setting the environment variable N8N_RESTRICT_FILE_ACCESS_TO=/files. This ensures n8n is restricted to only read from/write to the /files directory, then verify that the /files directory exists. It must be a valid directory path that n8n can access.
Run the following command to set the correct ownership for the directory so that it is writable by n8n:
chown -R 1000:1000 ./local-files
This command changes the ownership of /files to user ID 1000 and group ID 1000, which is typically the user n8n runs as in a Docker container.
Did this answer solve your question?
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.
