Installing software on MacOS can be cumbersome sometimes. The process of finding various dependencies is a PITA.
Fortunately Homebrew, the missing package manager, is here to save. In this tutorial, we will use Homebrew to install Vagrant and highlight some specific issues and solution you may encounter along the way.
Run the following command from the terminal to install Homebrew:
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
Run the following command to add Homebrew path to your environment variable:
echo 'export PATH="/usr/local/bin:$PATH"' >> ~/.bash_profile
Run the following command to verify the installation, you should see a successful message:
brew doctor
Homebrew uses Virtualbox to handle OS virtualization. Run the following command to install virtual box:
brew cask install virtualbox
If you are using Mac OS (High Sierra), because of secure kext, you may run into an security related issue, in that case, run the following command:
brew cask install --force virtualbox
At last, we can run the following command to install Vagrant:
brew cask install vagrant
We hope you find this tutorial helpful.