skip to Main Content

in host file :

 #
    127.0.0.1 localhost
    ::1 localhost
    127.0.0.1      daily_tasks.local    #laragon magic!   

D:laragonetcapache2sites-enabledauto.daily_tasks.local.conf :

<VirtualHost *:80> 
    DocumentRoot "D:/laragon/www/daily_tasks/public"
    ServerName daily_tasks.local
    ServerAlias *.daily_tasks.local
    <Directory "D:/laragon/www/daily_tasks/public">
        AllowOverride All
        Require all granted
    </Directory>
</VirtualHost>

# If you want to use SSL, enable it by going to Menu > Apache > SSL > Enabled

but whene run php artisan serv for run laravel. in browser this url http://daily_tasks.local:8000/ is working!

I don’t want it to be displayed :8000 !

2

Answers


  1. Laragon provides friendly url when the server is up. Only put your folder into www folder and restart Apache in Laragon, it’ll detect a new project and that is all. You won’t need php artisan serve.

    DOCS: https://laragon.org/docs/pretty-urls.html

    Login or Signup to reply.
  2. how about proxy pass?

    <VirtualHost *:80> 
      ...
      ProxyPreserveHost On
      ProxyRequests Off
      ProxyPass / http://localhost:8000/
      ProxyPassReverse / http://localhost:8000/
      ...
    </VirtualHost> 
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search