I am trying to use a container with mounted folder pointing to /usb1 on an hAP ax³ and i am having problems with data persistence. When storing files in the mounted folder, the files get deleted when the container is removed. Even if i download them via /fetch directly.
Setup
I download an custon image file via fetch command to /usb1/image.tar and add/extract it. Then download files to my mount folder. These files should be editable from the container, they should be kept even if i redeploy or delete the container. USB storage ist formatted using EXT4. Container is run under root so i can see files in mounted folders are also root owned.
Add mount and container and download custom config
Code: Select all
/container/mounts/add name=data src=usb1/data dst=/data
/container/add file=usb1/image.tar interface=veth1 root-dir=usb1/container mounts=data workdir=/usr/src/node-red start-on-boot=yes logging=yes
/tool fetch url="https://www.mydomain.com/download/f/flows.json" mode=http dst-path=usb1/data/flows.json
Is there any way how i can keep files created inside or outside of the container and reuse the mounted folder?
Tried to remove mount points from the container and remove the container in a second step also cleares the mount folder!?
Thank you very much for your support