Torizoncore-builder provide /home/torizon directory on build

Is it possible to include home folders in customization when building new image using torizon-core builder ?

Greetings @spasoye,

Just to clarify your question. What is your objective?

Do you want to capture changes to the /home/torizon directory? Are you doing this to store data or some other goal?

In general we recommend users to do changes to /etc instead. This is because of how certain directories are treated by our update system. But first I’d like to hear your use-case/objective first before I say more.

Best Regards,

Hey @jeremias.tx,

This is how I imagened my use case. After booting my image, docker-compose starts my container/s, one of the containers maps application folder stored in my home directory and starts the application. Application update consists of just updating application folder in my home directory instead of building new container image, pushing it to registry and pull it every time i decide to change application.

maps application folder stored in my home directory

In this case I would suggest to use another location like /etc.

In short our update system uses OSTree. In OSTree home directories are actually symlinked under /var. So the real path would be something like /var/rootdirs/home/torizon. However, the way OSTree works is that the entire /var directory is not tracked by updates. This is so there’s a place to store persistent data where it would not be affected/wiped by an oncoming update. But, for your use-case this means you can’t use /home if you intend to regularly update this location.

Therefore just use a directory that is tracked by OSTree, like /etc. Unless there’s some specific reason you must use the home directory?

Best Regards,

Thanks @jeremias.tx for explanation. Whole project development is currently stalled, but I will leave feedback when we decide further steps.

By the way another thing I should point out. Your method to “update” your containers by updating the application folder on the OS. May I ask why exactly you went for such an unorthodox method?

Is the cycle of a creating a new container for updates difficult in some way for your project’s process?

One issue I see is that updating the OS requires a reboot of the system to finish. While updating containers does not. Therefore by updating your containers in this way, your system would need to perform a reboot each time. Which may or may not be desirable depending on your needs.

Best Regards,