Skip to content

Installation

Mischa Braam edited this page Nov 7, 2022 · 15 revisions

❗ Please check the issue queue for existing bugs if Valet+ is not working correctly after install. Valet+ uses many dependencies and can break as these dependencies develop.

❗ If you're encountering bugs related to linking binaries. Please check all known linking errors.

⚠️ Valet+ requires macOS and Homebrew. Before installation, you should make sure that no other programs such as Apache or Nginx are binding to your local machine's port 80.

  1. Install or update Homebrew to the latest version using brew update.
  2. Add the Homebrew PHP tap for Valet+ via brew tap henkrehorst/php.
  3. Install PHP 7.3 using Homebrew via brew install [email protected] --build-from-source.
  4. Link your PHP version using the brew link [email protected] --force command.

⚠️ Sometimes you need to restart all terminal windows for the link to take effect after install. Especially if you just installed a homebrew PHP version for the first time.

  1. Install Composer using Homebrew via brew install composer.
  2. Install Valet+ with Composer via composer global require weprovide/valet-plus.
  3. Add export PATH="$PATH:$HOME/.composer/vendor/bin" to .bash_profile (for bash) or .zshrc (for zsh) depending on your shell (echo $SHELL)
  4. Run the valet fix command. This will check for common issues preventing Valet+ from installing.
  5. Run the valet install command. Optionally add --with-mariadb to use MariaDB instead of MySQL This will configure and install Valet+ and DnsMasq, and register Valet's daemon to launch when your system starts.
  6. Once Valet+ is installed, try pinging any *.test domain on your terminal using a command such as ping -c1 foobar.test. If Valet+ is installed correctly you should see this domain responding on 127.0.0.1. If not you might have to restart your system. Especially when coming from the Dinghy (docker) solution.

ℹ️ Valet+ will automatically start its daemon each time your machine boots. There is no need to run valet start or valet install ever again once the initial Valet+ installation is complete.

Laravel Valet to Valet+

To install valet-plus after having installed Laravel valet. Please follow the following steps.

  1. Remove the valet package composer remove laravel/valet.
  2. Follow the installation instructions.

Installation config

When installing you can use parameters to choose which database application you wish to use.

  • valet install (default: installs mysql 5.7)
  • valet install --with-mysql-8 (installs mysql 8)
  • valet install --with-mariadb (installs mariadb)
Clone this wiki locally