Skip to content

Instantly share code, notes, and snippets.

Last active February 19, 2020 10:36
What would you like to do?
Homestead Base Setup


  1. Check your current timezone with date in the command line. You should get something like this. Fri Oct 3 10.32:13 UTC 2014 where UTC is your current timezone.
  2. To change your timezone just run sudo dpkg-reconfigure tzdata and follow the instructions. Easy!
  3. Check the timezone again with date. Now your timezone should be in this example CEST


Homestead provides an Ubuntu System and has by default only english locales installed. In PHP locales are important if you work for example with strftime. Check the currently installed locales with locale -a. To add a new locale, you have to generate it. For example for a german locale enter sudo locale-gen de_DE.UTF-8 If you check again, the new locale should be included.


Source: StackOverflow

Simplest way I've found so far is to create a new server block (vhost) for phpmyadmin.

Assuming that your projects live in home/vagrant/Code :

  1. sudo apt-get install phpmyadmin Do not select apache2 nor lighttpd when prompted. Just hit tab and enter.
  2. sudo ln -s /usr/share/phpmyadmin/ /home/vagrant/Code/phpmyadmin
  3. cd ~/Code && serve /home/vagrant/Code/phpmyadmin
  4. Open the /etc/hosts file on your host machine and add
  5. Go to


Source Adam Engebretson

// Install MailCatcher
$ sudo apt-get install ruby1.9.1-dev libsqlite3-dev
$ sudo gem install mailcatcher
// Run Mailcatcher
$ mailcatcher --ip

Run MailCatcher - the IP depends on the Homestead IP - configurable in Homestead.yaml Make an alias for MailCatcher in the 'aliases' file

alias mailcatcher='mailcatcher --ip'

You can now access MailCatcher in your browser at

To use MailCatcher in your Laravel application, you'll have to edit the configuration in /app/config/mail.php. However, it's recommended to copy this file to /app/config/local/mail.php so that the configuration only applies to your local development environment. Here's my mail.php config file.


return [

  'driver'     => 'smtp',

  'host'       => '',

  'port'       => 1025,

  'from'       => array('address' => '', 'name' => 'Test Email Sender'),

  'encryption' => false,

  'username'   => null,

  'password'   => null,


It's important that you set the port to 1025, and you disable encryption

Debugging with X-Debug and PHPStorm

Source: Elena Kolevska - Debugging Laravel Apps on Homestead (PhpStorm + Xdebug + Postman setup)

Additional XDebug Settings for Sublime


Project Settings in Sublime Text

"settings": {
        "xdebug": {
            "path_mapping": {
                     "home/vagrant/path/to/your/folder" : "/Users/markus/path/to/your/folder",
        "url": "",
        "super_globals": true,
        "close_on_stop": true

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment