[LE10] Change Docker root Directory

  • Hello,

    I want to change docker default root directory which is set in '/storage/.kodi/userdata/addon_data/service.system.docker/config/docker.cfg'.

    From:

    /storage/.kodi/userdata/addon_data/service.system.docker/docker

    To:

    /media/Docker/root

    But after doing so, there is something going wrong. When I install the Docker version of Portainer-ce, its docker-compose throws 'Invalid Plugin', 'Permissions denied' errors.

    This doesn't happen with the default root location. Do I need to change something else as well or am I missing something?

    Regards~

  • Most of the LE filesystem is read-only which would explain the permissions error. You need to use a writeable area like /storage or if using a removable drive, somewhere under /var/media/<drive> where the drive is auto-mounted. I'm not anywhere near an LE device to check but I'm not sure /media is a valid location in the OS.

  • /var/media is symlinked to /media

    Yes, my /media/Docker is an removable external drive connected by USB. I wish the RK3399 had the install to eMMC on the official LE10 builds. Because putting Docker root on the sdcard is like decreasing its life.

    Edit 1:

    How can tell docker.service to start after usb storages are mounted? It should be After=xxx.mount

    Edited once, last by Aciel (October 11, 2021 at 10:11 AM).

  • You can edit the docker .service file (somewhere in the add-on dirs) to add the after dependency; don't forget daemon-reload afterwards to update systemd.

    I'm also fairly sure you can just dd the LE image to eMMC, I don't think RK doesn't anything too fancy with boot unlike other SoC types.