A
A
Alexander Bagirov2014-06-03 13:03:22
linux
Alexander Bagirov, 2014-06-03 13:03:22

How to upload project files to Apache?

Hello.
Now I am installing this script. It has a web folder, which contains index.php and other files.
My Apache server folder is /var/www. It turns out that I need to install it and upload all folders to /home/administrator (home folder), and upload the contents of the web folder to /var/www?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
I
Ivan, 2014-06-03
@alexbagirov

First you need to decide on a virtual host. Is he there? Set up? Where does the DocumentRoot directive look? It is best to score on /var/www and use the path /home/username/sites/domain.ru/ for sites.
I would do this:

Directory structure:
/home/administrator/sites/domain.ru/logs/
/home/administrator/sites/domain.ru/tmp/
/home/administrator/sites/domain.ru/www/
/home/administrator/sites/domain.ru/www/.../
/home/administrator/sites/domain.ru/www/.../
/home/administrator/sites/domain.ru/www/web/
/home/administrator/sites/domain.ru/www/.../

In apache config:
<VirtualHost 127.0.0.1:8080>
    ...
    DocumentRoot /home/administrator/sites/domain.ru/web
    ErrorLog /home/administrator/sites/domain.ru/logs/apache_error.log
    CustomLog /home/administrator/sites/domain.ru/logs/apache_access.log combined
    ...
</VirtualHost>

Those. throw all the contents of the script into the www folder of the desired site, and specify .../www/web in the DocumentRoot

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question