Last active
April 9, 2020 06:21
-
-
Save djravine/aeaaaf28e7ce9b51188c1403f1db6560 to your computer and use it in GitHub Desktop.
Install Virtualbox6.0 on Ubuntu18.04
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -o pipefail | |
# GIST: https://gist.github.com/djravine/aeaaaf28e7ce9b51188c1403f1db6560 | |
# USAGE: curl -sL https://gist.github.com/djravine/aeaaaf28e7ce9b51188c1403f1db6560/raw | sudo bash -s -- | |
apt-get remove -y --purge virtualbox* | |
apt-get autoremove -y | |
wget -q https://www.virtualbox.org/download/oracle_vbox.asc -O- | apt-key add - | |
wget -q https://www.virtualbox.org/download/oracle_vbox_2016.asc -O- | apt-key add - | |
echo "deb [arch=amd64] https://download.virtualbox.org/virtualbox/debian $(lsb_release -sc) contrib" | sudo tee /etc/apt/sources.list.d/virtualbox.list | |
apt-get update | |
apt-get install -y virtualbox-6.0 | |
ln -s /usr/lib/virtualbox/UnattendedTemplates /usr/share/virtualbox/UnattendedTemplates | |
# FIX BUG - https://www.virtualbox.org/ticket/18411 | |
sed -i "s|/bin/bash /root/vboxpostinstall.sh --preseed-late-command|/bin/sh /target/root/vboxpostinstall.sh --need-target-bash --preseed-late-command|g" /usr/lib/virtualbox/UnattendedTemplates/ubuntu_preseed.cfg |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment