X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=bin%2Finstall_script.sh;h=d9d3808fdbb8f7f9fbf0650c553c48f76288b322;hb=28f9451daeac73f91b031470060c883008b4a363;hp=f250285840785abeb0025d4e32778cc5f94f208c;hpb=ec1096d8c0d897ebd1ea445d9c5404a13c33ce2e;p=perso%2FImmae%2FProjets%2FPuppet.git diff --git a/bin/install_script.sh b/bin/install_script.sh index f250285..d9d3808 100755 --- a/bin/install_script.sh +++ b/bin/install_script.sh @@ -1,28 +1,102 @@ #!/bin/bash +usage() { +cat < $ARCH_PUPPET_INITIAL_CONFIGURATION + cat > $ARCH_HOST_SCRIPT < /tmp/root.x86_64/etc/pacman.d/mirrorlist -DEVICE_STR=\$(cat /proc/mounts | grep "/dev/sd.. /mnt/") +DEVICE_STR=\$(cat /proc/mounts | grep "/dev/[sv]d.. /mnt/") DEVICE=\$(echo "\$DEVICE_STR" | cut -d' ' -f1) MOUNTPOINT=\$(echo "\$DEVICE_STR" | cut -d' ' -f2) @@ -58,6 +132,7 @@ cp /tmp/arch_chroot_script.sh /tmp/root.x86_64/ mount "\$DEVICE" cp /tmp/arch_install_script.sh "\$MOUNTPOINT/root/" +cp /tmp/puppet_variables.json "\$MOUNTPOINT/root/" /tmp/root.x86_64/bin/arch-chroot "\$MOUNTPOINT" /root/arch_install_script.sh EOF @@ -97,7 +172,7 @@ EOF cat > $ARCH_INSTALL_SCRIPT < $ARCH_PUPPET_CONFIGURATION_SCRIPT < $ARCH_HOST_PUPPET_CONFIGURATION_SCRIPT <