Build Pre-Post-Installed Images #41
Description
A lot of the process that is happening during an install-party, that is, the installation of an InternetCube using install.labriqueinter.net is repeated in each installation. I would like to create InternetCube images that already ran the YunoHost post-install process to avoid repetition and reduce errors during installations.
To do so, I started modifying the image build script to run the post-install with default values. The idea is to only have to change some configuration during the install-party (user name and domain).
However, I run into issues during the post-install step.
The code of my latest attempt is available here:
https://github.com/keomabrun/build.labriqueinter.net
The only interesting adding is the following line:
chroot_deb $TARGET_DIR "yunohost tools postinstall -d foo.bar.labriqueinter.net -p yunohost --ignore-dyndns"
When I run this code, I run into the following error during the post-install:
Error: Unable to reach LDAP server
This might be because we are running in a chroot environment as documented here.
Because we are running in a chroot environment I can not assess the status of services, including slapd.
Should we use systemd-nspawn
or lxc
to build our images ?
https://superuser.com/questions/688733/start-a-systemd-service-inside-chroot
Note that the raspbian build script does not.