2023-08-22 00:18:02 -05:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
set -ex
|
|
|
|
|
|
2023-12-30 05:37:32 +00:00
|
|
|
# 5 minute wait for the lock timeout
|
|
|
|
|
apt-get -o DPkg::Lock::Timeout=600 autoremove -y
|
2023-08-22 00:18:02 -05:00
|
|
|
|
|
|
|
|
# Configure sshd to be faster
|
2023-12-06 08:21:32 -08:00
|
|
|
cat << EOF > /etc/ssh/sshd_config.d/00-vagrant_accept_pubkey.conf
|
2023-08-22 00:18:02 -05:00
|
|
|
UseDNS no
|
|
|
|
|
PubkeyAcceptedKeyTypes +ssh-rsa
|
|
|
|
|
EOF
|
|
|
|
|
|
|
|
|
|
# Clean up after ourselves
|
|
|
|
|
apt-get clean
|
2023-12-07 12:15:48 -06:00
|
|
|
|
|
|
|
|
virt="$(systemd-detect-virt)"
|
|
|
|
|
if [ "${virt}" == "microsoft" ]; then
|
2023-12-30 05:37:32 +00:00
|
|
|
apt-get install -y hyperv-daemons
|
|
|
|
|
systemctl enable hv-fcopy-daemon
|
|
|
|
|
systemctl enable hv-kvp-daemon
|
|
|
|
|
systemctl enable hv-vss-daemon
|
2024-11-18 23:42:28 -06:00
|
|
|
fi
|