Commit 0bdcf4a0 authored by Ophélie Gagnard's avatar Ophélie Gagnard

install.sh:

- Label the relevant root partition.
- Add variables for relevant disks and parititions.
parent bac8b25f
# This script assumes to be run by the root user (with /sbin in the path).
# note: on the capri002 (as of the time those lines are wrote):
# OS disk: 250GB, /dev/nvme1n1
# /dev/nvme1n1p1 efi partition
# /dev/nvme1n1p2 root partition
# /dev/nvme1n1p3 swap partition
# Data disk: 4TB, /dev/nvme0n1 (but with a Debian installed on it...)
# /dev/nvme0n1p1 efi partition
# /dev/nvme0n1p2 root partition
# /dev/nvme0n1p3 swap partition
TARGET_DISK=/dev/nvme1n1
TARGET_EFI_PARTITION=${TARGET_DISK}p1
TARGET_ROOT_PARTITION=${TARGET_DISK}p2
# why?
e2label $TARGET_ROOT_PARTITION ROOT
# Create an initramfs image
dracut -c ./dracut.module/dracut.conf --force
cp -r /boot/efi/EFI /EFI
# Set the image as a boot option
efibootmgr --create --disk /dev/nvme1n1p1 --label "test_deploy" --loader /EFI/Linux/linux-5.10.0-11-amd64-7148af38f67e4d3d98495ccf849b82f4.efi
efibootmgr --create --disk $TARGET_EFI_PARTITION --label "test_deploy" --loader /EFI/Linux/linux-5.10.0-11-amd64-7148af38f67e4d3d98495ccf849b82f4.efi
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