0

I want to deploy laravel on VM Instance, I am following this link, when I completed upto setting up of database, I could not see my applications landing page, it instead shows Apache2 Debian Default Page, is it because I didnt configured Server name and Server Admin in this section?

<VirtualHost *:80>
    ServerName laravel.imarishwa.com

    ServerAdmin webmaster@localhost
    DocumentRoot /var/www/html/your-project-directory/public

    <Directory /var/www/html/your-project-directory>
        AllowOverride All
    </Directory>

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>

Or is there any other reason?

Michael Hampton
  • 244,070
  • 43
  • 506
  • 972

1 Answers1

0

Yes, when you miss server name and open address in browser data fetch from default document root address of apache. you can use this sample for edit your apache virtualhost

<VirtualHost *:80>
    ServerName example.com
    ServerAlias www.example.com
    ServerAdmin webmaster@example.com
    DocumentRoot /var/www/example.com/public_html

    <Directory /var/www/example.com/public_html>
        Options -Indexes +FollowSymLinks
        AllowOverride All
    </Directory>

    ErrorLog ${APACHE_LOG_DIR}/example.com-error.log
    CustomLog ${APACHE_LOG_DIR}/example.com-access.log combined
</VirtualHost>