Commit 88548b36 authored by JackV's avatar JackV
Browse files

First implementation of the live build

parents
umount /tmp/poul_live/boot
umount /tmp/poul_live
umount /tmp/poul_fat
losetup -d /dev/loop42
rm -r /tmp/poul_live
rm -r /tmp/poul_fat
label: gpt
label-id: 7F8FDF29-1D1E-8F4C-8EB3-0A764EAE6F04
device: /dev/loop42
unit: sectors
first-lba: 2048
last-lba: 31457246
/dev/loop42p1 : start= 2048, size= 4096, type=21686148-6449-6E6F-744E-656564454649, uuid=35B69932-8757-9D43-8A9C-F037F57F440A
/dev/loop42p2 : start= 6144, size= 262144, type=C12A7328-F81F-11D2-BA4B-00A0C93EC93B, uuid=8524C30B-FF65-7644-A1A5-559F440890AB
/dev/loop42p3 : start= 268288, size= 10485760, type=0FC63DAF-8483-4772-8E79-3D69D8477DE4, uuid=6D418A2D-054D-F647-83F8-51ECBFD16899
/dev/loop42p4 : start= 10754048, size= 20703199, type=0FC63DAF-8483-4772-8E79-3D69D8477DE4, uuid=D91F4DBD-53F4-9341-8ADF-6F431DDD74A0
#!/bin/bash
truncate -s 15G live.img
mknod -m 660 /dev/loop42 b 7 42
losetup /dev/loop42 live.img
sfdisk /dev/loop42 < disk_layout.sfdisk
mkfs.vfat -F32 /dev/loop42p2
mkfs.ext4 /dev/loop42p3
mkfs.ntfs -f /dev/loop42p4
mkdir /tmp/poul_live
mount /dev/loop42p3 /tmp/poul_live
mkdir /tmp/poul_live/boot
mount /dev/loop42p2 /tmp/poul_live/boot
pacstrap -c /tmp/poul_live $(tr '\n' ' ' < pkg_list.txt)
genfstab -U /tmp/poul_live >> /tmp/poul_live/etc/fstab
cp stage2.sh /tmp/poul_live
arch-chroot /tmp/poul_live /stage2.sh
mkdir /tmp/poul_fat
mount /dev/loop42p4 /tmp/poul_fat
IMG_END=$(fdisk -l /dev/loop42 | grep '^/dev/loop42p3' | awk '{print $3}')
qemu-img dd -f raw -O vdi bs=512 count=10754047 if=/dev/loop42 of=/tmp/poul_fat/poul_live.vdi
wget -P /tmp/poul_fat 'https://download.virtualbox.org/virtualbox/6.0.8/VirtualBox-6.0.8-130520-Win.exe'
wget -P /tmp/poul_fat 'https://download.virtualbox.org/virtualbox/6.0.8/VirtualBox-6.0.8-130520-OSX.dmg'
./cleanup.sh
base
grub
vim
firefox
arduino
arduino-avr-core
gdm
xf86-input-libinput
xf86-video-amdgpu
xf86-video-intel
xf86-video-nouveau
screen
zsh
#!/bin/bash
ln -sf /usr/share/zoneinfo/Europe/Rome /etc/localtime
echo 'en_US.UTF-8 UTF-8\nit_IT.UTF-8' >> /etc/locale.gen
locale-gen
echo 'KEYMAP=it-latin1' >> /etc/vconsole.conf
echo 'poul_live' > /etc/hostname
mkinitcpio -p linux
echo 'poul_live\npoul_live' | passwd
grub-install --target=i386-pc /dev/loop42
grub-install --target=x86_64-efi --efi-directory=/boot --removable --no-nvram
grub-mkconfig -o /boot/grub/grub.cfg
systemctl enable gdm
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment