Benoit Anastay Add-on: Paperless-ngx

Great plugin! Thanks for all the effort you have put in!

I am running Home Assistant OS. When I am on my wifi, I am able to connect to Paperless via the browser, but when I do it via the HA iPhone app, I get a CSRF error.

I see some other replies about this error, but I think these are all about running your own docker container.

Is there a way to get access to the plugin from the HA app?

And another question, is it possible to connect from an iPhone app like Paperparrot or Swift Paperless?

I do not have this issue, but thereā€™s one issue with core API when URLs are set to automatic, the current workaround is to manually add your domain to the allowed list.

domain list

Youā€™ll need to use direct access, maybe my documentation is not enough

Ingress and API

For API youā€™ll need to enable direct access to the Add-on by setting up a port under network in configuration tab

What URL should I add to the CSRF allowed list? The internal homeassistant.local? Or the external nabu case url? Both do not have the desired result.

What am I missing?

Youā€™ll need to use direct access, maybe my documentation is not enough

Can you give me a bit more hints on how to configure this?

You need to know with URL is rejected
NB : Since last update this error message was thrown once on my setup but after a page reload I was logged fine.

Dear Benoit,

at some point in the future I want to switch to a system, where some plugins are running ā€žstandaloneā€œ outside of HA. Will it be possible to backup your Paperless installation including the ā€žtrained aiā€œ to another docker container running paperless ngx?

Yup,

Youā€™ll just have to copy past folders to your new host

1 Like

Hi heimvon2,

canā€™t figure it out how you did that.
Is this configuration necessary to get access to paperless-ngx from outside?
How can I get die ip adress of my ha instance?

Hey Benoit,

thank you very much for qour Plug-In.

Does this mean I have to set up the add-on by advanced remote tunnel?

I do not use tunneling but reverse proxy with Nginx Proxy Manager I do set it that way

Fresh install and get:

[2024-03-08 08:53:22,150] [WARNING] [django.security.csrf] Forbidden (Origin checking failed - http://hass.domain.com:8123 does not match any trusted origins.): /api/hassio_ingress/LI2n4k9PHSfniOfKM38ppmyMWWvAeSe4KP-058drv78/accounts/login/

image

When URLs are set to automatic in Home Assistant OS, the domain isnā€™t reported to the addon, you have to add it manually to the CSRF allowed list in the addon configuration tab

thank you Benoit, I will try it

Not entirely sure what to do where, can you elevorate or show?

Put your domains here
domain list
Capture-more options

I solved the CSRF error by taking the following steps:

  • Copy the Nabu Casa URL in Settings / Home Assistant Cloud

  • Go to Settings / Add-ons / Paperless-ngx and in the configuration tab, paste the copied value in the CSRF Allowed domains. Be sure to remove the https:// part of the url! If you leave that in, it will not work.
1 Like

yep, my router has a network share support and USB is in the router plugged. Can you give me some hints what I have do change/edit now?

Iā€™m in the same boat. I just migrated from another instance of Paperless-ngx HA addon and this is missing the option to change paths. Iā€™ve tried a couple different ways and canā€™t get it to read my external drive like the other instance did. Please help!

Iā€™ll add an option to host files in media directory

1 Like

I have some questions, but first some information to my system:

I have Homeassistant with the latest version running on a Raspberry Pi 4 with 4 GB RAM.
The Homeasssitant running on a nvme SSD over USB3.0

Questtions:

  1. PDF Files with 300 dpi or round about 10 pages failing with the following error:
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/dist-packages/billiard/pool.py", line 1264, in mark_as_worker_lost
    raise WorkerLostError(
billiard.exceptions.WorkerLostError: Worker exited prematurely: signal 9 (SIGKILL) Job: 0.

Does someone have any idea what it means?
2. can i connect the Paperless NGX Android App to my System?
3. Is there any way to use 2FA?
4. how can i speed up the System to work on more than 1 PDF file?

Hello. i love the Home Assistant Version of Paperless!
Hello everyone,
Iā€™m trying to utilize the option where it uses the directory structure within the ā€œconsumeā€ folder as tags to label the PDFs. However, Iā€™m encountering an issue where it doesnā€™t seem to work as expected. With single PDFs inside the consume Folder it works perfect.

Whenever I attempt to implement this feature, I receive an error message similar to the following:

(xxx.pdf: The following error occurred while storing document xxx.pdf after parsing: [Errno 13] Permission denied: '/share/paperless/consume/xyz/xxx.pdf')

It appears to be a permission issue, I should note that Iā€™ve named the superuser the same as my admin user for the HomeAssistant installation, in case that might be relevant to diagnosing this issue. Has anyone else experienced this problem or have any insights on how to resolve it? Any help would be greatly appreciated.

Thank you in advance!

the consume folder has the permissions 1000 1000. The Folders i have copied inside the consume folder have the permissions root root.