MAMP : Custom local domain


  1. Open httpd.conf

  2. Scroll to end of file paste the code below


<VirtualHost *:80>

    ServerName localhost

    DocumentRoot "/Applications/MAMP/htdocs"

    <Directory "/Applications/MAMP/htdocs">

        Options Indexes FollowSymLinks

        AllowOverride All

        Require all granted

    </Directory>

</VirtualHost>

<VirtualHost *:80>

    ServerName app.happyhive.local

    DocumentRoot "/Applications/MAMP/htdocs/smap"

    <Directory "/Applications/MAMP/htdocs/smap">

        Options Indexes FollowSymLinks

        AllowOverride All

        Require all granted

    </Directory>

</VirtualHost>


  1. Open terminal / iterm and paste the code below 127.0.0.1    app.happyhive.local

  2. Restart Mamp and dont forget update .env BASE_URL.

Comments

Popular posts from this blog

Create Slack application

Tips testing local untuk programmer 📌

Get list of controller in Codeigniter