Can’t setup paperless-ngx on TrueNAS SCALE 24.10.0

Hello everyone,
I’m trying to setup paperless-ngx on TrueNAS SCALE 24.10.0 with host path. When I am using ixvolume it works fine. I have created the datasets and have set up the acl rights. But i have problems with postgres that i can’t figure out.
Any idea what’s causing the problem?

 Fehler: Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/middlewared/job.py", line 488, in run
    await self.future
  File "/usr/lib/python3/dist-packages/middlewared/job.py", line 535, in __run_body
    rv = await self.middleware.run_in_thread(self.method, *args)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/middlewared/main.py", line 1364, in run_in_thread
    return await self.run_in_executor(io_thread_pool_executor, method, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/middlewared/main.py", line 1361, in run_in_executor
    return await loop.run_in_executor(pool, functools.partial(method, *args, **kwargs))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/middlewared/service/crud_service.py", line 268, in nf
    rv = func(*args, **kwargs)
         ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/middlewared/schema/processor.py", line 55, in nf
    res = f(*args, **kwargs)
          ^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/middlewared/schema/processor.py", line 183, in nf
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/middlewared/plugins/apps/crud.py", line 203, in do_create
    return self.create_internal(job, app_name, version, data['values'], complete_app_details)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/middlewared/plugins/apps/crud.py", line 248, in create_internal
    raise e from None
  File "/usr/lib/python3/dist-packages/middlewared/plugins/apps/crud.py", line 241, in create_internal
    compose_action(app_name, version, 'up', force_recreate=True, remove_orphans=True)
  File "/usr/lib/python3/dist-packages/middlewared/plugins/apps/compose_utils.py", line 57, in compose_action
    raise CallError(
middlewared.service_exception.CallError: [EFAULT] Failed 'up' action for 'paperless-ngx' app, please check /var/log/app_lifecycle.log for more details

1 Like

How do you have the ACL configured for that Postgres container?

image

unfortunately having the same problem, exact same host-path setup and errors. not sure what to do…

If it’s truly the exactly same issue, the question from @DjP-iX applies to you too.

Hello everyone. Apparently I also have the same problem. All other Docker apps run without any problems. Here is an excerpt from the log (/var/log/app_lifecycle.log). The installation via Dockge (stack) runs without any problems. I would be very happy to receive support (maybe I’m just being stupid).

[2024/11/10 23:15:20] (ERROR) app_lifecycle.compose_action():56 - Failed 'up' action for 'paperless-ngx' app:  Network ix-paperless-ngx_default  Creating
 Network ix-paperless-ngx_default  Created
 Container ix-paperless-ngx-permissions-1  Creating
time="2024-11-10T23:15:14+01:00" level=warning msg="config `uid`, `gid` and `mode` are not supported, they will be ignored"
time="2024-11-10T23:15:14+01:00" level=warning msg="config `uid`, `gid` and `mode` are not supported, they will be ignored"
 Container ix-paperless-ngx-permissions-1  Created
 Container ix-paperless-ngx-postgres-1  Creating
 Container ix-paperless-ngx-redis-1  Creating
 Container ix-paperless-ngx-redis-1  Created
 Container ix-paperless-ngx-postgres-1  Created
 Container ix-paperless-ngx-paperless-1  Creating
 Container ix-paperless-ngx-paperless-1  Created
 Container ix-paperless-ngx-permissions-1  Starting
 Container ix-paperless-ngx-permissions-1  Started
 Container ix-paperless-ngx-permissions-1  Waiting
 Container ix-paperless-ngx-permissions-1  Waiting
 Container ix-paperless-ngx-permissions-1  Exited
 Container ix-paperless-ngx-postgres-1  Starting
 Container ix-paperless-ngx-permissions-1  Exited
 Container ix-paperless-ngx-redis-1  Starting
 Container ix-paperless-ngx-redis-1  Started
 Container ix-paperless-ngx-postgres-1  Started
 Container ix-paperless-ngx-redis-1  Waiting
 Container ix-paperless-ngx-permissions-1  Waiting
 Container ix-paperless-ngx-postgres-1  Waiting
 Container ix-paperless-ngx-permissions-1  Exited
 Container ix-paperless-ngx-postgres-1  Error
 Container ix-paperless-ngx-redis-1  Healthy
dependency failed to start: container ix-paperless-ngx-postgres-1 is unhealthy

I had the same issue. I got around it by changing the perms on the host path for the postgress folder. I added full perms via ACLs for apps and netdata to the postgres folder, but it didn’t help. What did work, I went into the shell on my Truenas and browsed to the folder above the postgres folder and chown’d it to netdata, then I was able to install paperless without issue.

sudo chown netdata: postgres

Just discovered that checking the “Enable ACL” box under the “Postgres” volume solves the problem. All permissions are set correctly and the application runs normally.
The folders look like this:

drwxrwx---  2 apps    apps    2 Apr 26 21:40 Consume
drwxrwx---  4 apps    apps    7 Apr 26 21:40 Data
drwx------ 19 netdata docker 26 Apr 26 21:34 Database
drwxrwx---  3 apps    apps    4 Apr 26 21:40 Media
drwxrwx---  2 apps    apps    2 Apr 26 21:40 Trash