preinstall: # hardcoded users and groups $(inroot) useradd --system --comment="created from appliance building - jitsi user" --home-dir="/usr/share/jitsi-videobridge" --shell="/sbin/nologin" --no-create-home --uid 606 --user-group jitsi $(inroot) useradd --system --comment="created from appliance building - jitsi jicofo user" --home-dir="/usr/share/jicofo" --shell="/bin/bash" --no-create-home --uid 607 --gid 606 jicofo $(inroot) useradd --system --comment="created from appliance building - jitsi videobridge user" --home-dir="/usr/share/jitsi-videobridge" --shell="/bin/bash" --no-create-home --uid 608 --gid 606 jvb # switch to hardened, build hardened toolchain, rebuild everything mkdir -p $(CHROOT)/etc/portage/profile echo "-hardened" >> $(CHROOT)/etc/portage/profile/use.mask $(inroot) $(EMERGE) $(USEPKG) --oneshot gcc $(inroot) $(EMERGE) $(USEPKG) --oneshot binutils virtual/libc -$(gcc_config) $(inroot) $(EMERGE) $(USEPKG) --emptytree @world $(inroot) bash -c 'yes YES | etc-update --automode -9' postinstall: base/timesyncd.conf base/firstboot.start # Konfigurationen anpassen cp base/timesyncd.conf $(CHROOT)/etc/systemd/timesyncd.conf mkdir -p $(CHROOT)/etc/local.d cp base/firstboot.start $(CHROOT)/etc/local.d/firstboot.start touch $(CHROOT)/firstboot sed -i 's/# %wheel ALL=(ALL) ALL/%wheel ALL=(ALL) ALL/' $(CHROOT)/etc/sudoers sed -i 's#^auth.*$$#auth [success=2 default=ignore] pam_ssh_agent_auth.so file=~/.ssh/authorized_keys\nauth include system-auth#' $(CHROOT)/etc/pam.d/sudo echo "Defaults env_keep += SSH_AUTH_SOCK" > $(CHROOT)/etc/sudoers.d/ssh_auth_sock $(inroot) useradd -m -G users,wheel -s /bin/bash --comment="virtual appliance admin" --uid 2000 admin $(inroot) passwd -d admin; $(inroot) passwd -e admin $(inroot) systemctl enable tmux@root.service cp base/tmux.conf $(CHROOT)/root/.tmux.conf # Beispiel feste IP-Adresse cp base/00-eth0.network $(CHROOT)/00-eth0.network.example # Nginx-Konfiguration mkdir $(CHROOT)/etc/nginx/conf.d cp nginx/conf.d/meet.example.com.conf $(CHROOT)/etc/nginx/conf.d/meet.example.com.conf mv $(CHROOT)/etc/nginx/nginx.conf $(CHROOT)/etc/nginx/nginx.conf.orig cp nginx/nginx.conf $(CHROOT)/etc/nginx/nginx.conf ## # Start services ## $(inroot) systemctl enable nginx ## $(inroot) systemctl enable jicofo ## $(inroot) systemctl enable jitsi-videobridge clean: