]> git.immae.eu Git - perso/Immae/Projets/Puppet.git/blame - scripts/hetzner_server/arch_chroot_script.sh
Add hetzner server scripts
[perso/Immae/Projets/Puppet.git] / scripts / hetzner_server / arch_chroot_script.sh
CommitLineData
367c391a
IB
1#!/bin/bash
2
3pacman-key --init
4pacman-key --populate archlinux
5
6UUID=$(cat /device_uuid)
7PART="/dev/disk/by-uuid/$UUID"
8DEVICE=$(realpath "$PART")
9
10mkfs.ext4 -F -U "$UUID" "$DEVICE"
11mount "$DEVICE" /mnt
12
13pacstrap -G /mnt base git puppet
14
15echo "$PART / auto defaults 0 1" > /mnt/etc/fstab
16
17umount /mnt
18