EE 24.10 RC.2 All Custom Apps Failing 'Up' Action - Log says 'Error Creating Mount Source Path...Read Only Filesystem'

Hi all. I’ve been looking forward to trying out custom apps in Electric Eel but I don’t really have that much experience with Docker so I’m probably missing a crucial step or few. I’ve tried to install a few different apps and I’m getting the same error with each of them.

As an example, one of the apps I’ve tried to install is jdownloader2 so I’ve taken the ‘docker run’ script on its dockerhub page, run it through composerise and put the following into the custom app section:

services:
    jdownloader-2:
        container_name: jdownloader-2
        ports:
            - 5800:5800
        volumes:
            - /docker/appdata/jdownloader-2:/config:rw
            - /mnt/downloads:/output:rw
        image: jlesage/jdownloader-2

It then spits out

Error FAILED

[EFAULT] Failed 'up' action for 'jdownloader2' app, please check /var/log/app_lifecycle.log for more details
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 1363, 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 1360, 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 185, in do_create
    return self.middleware.call_sync('app.custom.create', data, job)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/middlewared/main.py", line 1661, in call_sync
    return methodobj(*prepared_call.args)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/middlewared/plugins/apps/custom_app.py", line 95, in create
    raise e from None
  File "/usr/lib/python3/dist-packages/middlewared/plugins/apps/custom_app.py", line 80, in create
    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 'jdownloader2' app, please check /var/log/app_lifecycle.log for more details

The log file has this to say:

jdownloader-2 Pulled
 Network ix-jdownloader2_default  Creating
 Network ix-jdownloader2_default  Created
 Container jdownloader-2  Creating
 Container jdownloader-2  Created
 Container jdownloader-2  Starting
Error response from daemon: error while creating mount source path '/docker/appdata/jdownloader-2': mkdir /docker: read-only file system

[2024/10/03 11:34:12] (ERROR) app_lifecycle.compose_action():56 - Failed 'up' action for 'jdownloader2' app:  Network ix-jdownloader2_default  Creating
 Network ix-jdownloader2_default  Created
 Container jdownloader-2  Creating
 Container jdownloader-2  Created
 Container jdownloader-2  Starting
Error response from daemon: error while creating mount source path '/docker/appdata/jdownloader-2': mkdir /docker: read-only file system

Do I need to change permissions somewhere or is the default location for docker apps not applicable for TrueNAS?

I’ve also tried this with aria2 and onlyoffice so far and have the same results.

System specs:

CPU: Intel Core i5 7500
Motherboard: Asus Prime B250M-A
RAM: 16GB (4x4GB) Corsair Vengeance LPX DDR4 2133 CL15
NIC: Edimax (Realtek) 2.5Gb
Boot Drive: Gigabyte 256GB NVME SSD
Mass Storage: 5x8TB WD Blue 5640RPM WD80EAZZ

/ is mounted read-only. Did you mean to bind to /mnt/docker/appdata/jdownloader-2 instead?

I wouldn’t have thought so. I feel like I may have this the wrong way around though. Are the volumes I’m specifying in the script meant to be within the docker container itself or are they an equivalent of host paths? I’ve been assuming it’s the former but if it’s the latter, where am I supposed to have the ‘/docker/appdata…’ etc. folder?

Within the dataset for my pool, I have three child datasets, two of which are mine for dedicated shares and then the ‘ix-applications’ dataset. I assumed it would create itself in there by default but do I have to point it specifically somewhere in there? Something like below:

services:
    jdownloader-2:
        container_name: jdownloader-2
        ports:
            - 5800:5800
        volumes:
            - /mnt/The Lost Sock/ix-applications/docker/appdata/jdownloader-2:/config:rw
            - /mnt/The Lost Sock/Media/downloads:/output:rw
        image: jlesage/jdownloader-2

Does /docker exist on the host? By default / is mounted ro in Scale, but I have not upgraded to EE, so have no idea if that’s a new mount from iX. I wouldn’t expect the compose to create new paths on the host either.

If you start a container with a volume that doesn’t yet exist, Docker creates the volume for you.

From your file, you are asking Docker to map the folder “/config” from inside the JDownloader Docker to the actual folder in TrueNAS “/docker/appdata/jdownloader-2” (and make it read/write enabled.)

That is fine, except the log states it can’t create the “/docker” folder in TrueNAS because (as stated by @Craig_L ) the “/” folder in TrueNAS is mounted as read-only.

You want to map the folder inside the docker container to a folder in TrueNAS that you actually own.

For example, I have a pool named “vmpool”. Pools are mounted in the “/mnt” directory. So I would use

volumes:
            - /mnt/vmpool/docker/appdata/jdownloader-2:/config:rw

Assuming you want JDownloader to put the downloads into the TrueNAS folder “/mnt/downloads” the second volume line is fine (and is why no error in the log from it.)