Configure Production and Approval paths on the server

Asked

Viewed 250 times

0

The server had version 5.5 of the PHP, then I had to switch to 7.1. But after restarting the apache, no longer loads the site.

There used to be the main website (production) and the testing (homologation), each in its folder within the "/var/www/", but now it seems that what made this path configuration was deleted, as the two are pointing to the default folder "html", how can I set this up again, since it wasn’t me who set up the first time?

  • Saw the error log?

  • You need to check the error log and also check that all the integration components between php and apache are up to date with php version 7.1. If I were, I would delete everything from php (all the same) via terminal and install everything in version 7.1.

  • I jumped into the error, checked and php is being loaded. The problem is that it points to a standard apache html file. I edited my question.

  • vc only updated php or also reinstalled apache? is it not missing to configure virtualhost?

  • You mean the 000-default.conf file? It seems to be with the default settings when installed apache, although I have not reinstalled apache. Then I thought they’d set it up some other way before.

  • When you play a new php file at the root it runs? or redirects to apache html?

  • I set the virtualhost to point to the type-approval and production folder. When I access the homologation charges correctly, but the production continues pointing to folder "html".

Show 2 more comments

1 answer

0

It is necessary that you configure a <VirtualHost> to the server and homologation and another to the production server.

apache comes with a configuration of <VirtualHost> pattern, which points to the folder /var/www/html. To modify this configuration standard, access the file /etc/apache2/sites-available/000-default.conf and create a new one with your domain or IP configuration.

Ex:

<VirtualHost seudomain.com:80>
    ServerAdmin [email protected]
    DocumentRoot "/var/www/seusite"
    ServerName dominio.com
    ErrorLog "logs/dominio-error.log"
    CustomLog "logs/dominio-access.log" common
</VirtualHost>

Browser other questions tagged

You are not signed in. Login or sign up in order to post.