summaryrefslogtreecommitdiff
path: root/backend/modules/init
blob: cfe37e1ba1fb643ab3e799234610713b50e0185a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/bash

function init_installer()
{
	[ -f /etc/default/distro ] && . /etc/default/distro
	export FLL_DISTRO_MODE FLL_DISTRO_NAME FLL_LIVE_USER
	mkdir -p /live/filesystem
	if [ ! -d /live/filesystem/usr ]; then
		LOOPDEV="$(losetup --all | awk -F: '/\/live\/image\/live/&&/filesystem/{print $1}')"
		[ "$LOOPDEV" ] && mount -o ro "$LOOPDEV" /live/filesystem
	fi
	cfg_set hostname "${FLL_DISTRO_NAME}Box"
}