if [[ ! $DISTRO ]]; then
- if ifclass STABLE_BOOTSTRAP; then
+ if ifclass VOL_STABLE_BOOTSTRAP; then
DISTRO=debianstable_bootstrap
- elif ifclass STRETCH64; then
+ elif ifclass VOL_STRETCH; then
DISTRO=debiantesting
- elif ifclass STABLE; then
+ elif ifclass VOL_STABLE; then
DISTRO=debianstable
- elif ifclass XENIAL64; then
+ elif ifclass VOL_XENIAL; then
DISTRO=ubuntuxenial
- elif ifclass BELENOS64; then
+ elif ifclass VOL_BELENOS; then
DISTRO=trisquelbelenos
else
echo "PARTITIONER ERROR: no distro class/var set" >&2
cd /mnt
btrfs subvolume create root_$DISTRO
- [[ -e nocow ]] || btrfs subvolume create nocow
- chown root:1000 nocow
- chattr +C nocow
mkdir -p /mnt/root_$DISTRO/boot
# could set default subvol like this, but no reason to.
ROOT_PARTITION=$first_boot_dev
EOF
else
- # note, fai creates the mountpoints like /nocow
+ # note, fai creates the mountpoints listed here
cat > /tmp/fai/fstab <<EOF
$first_root_crypt / btrfs noatime,subvol=root_$DISTRO 0 0
-$first_root_crypt /nocow btrfs noatime,subvol=nocow 0 0
$first_root_crypt /mnt/root btrfs noatime,subvolid=0 0 0
$first_boot_dev /boot btrfs noatime,subvol=$boot_vol 0 0
EOF