Answer the question
In order to leave comments, you need to log in
How to set up yii2 on linux?
I can't get the site to output from the yii2 framework. I approximately implemented a virtual host for yii2 following the action The yii2 project itself is located in the /var/www/html/trainingYii
. It's just a symbolic link. Then I created a file in the directory /etc/apache2/sites-available/yii2-app.conf
and wrote in it
<VirtualHost *:80>
ServerName yii2-app
ServerAdmin [email protected]
DocumentRoot /var/www/html/trainingYii
<Directory /var/www/html/trainingYii>
Options Indexes FollowSymlinks
AllowOverride All
Order allow,deny
allow from all
</Directory>
ErrorLog /var/www/yii2-app/logs/error.log
CustomLog /var/www/yii2-app/logs/access.log combined
</VirtualHost>
sudo ln -s /etc/apache2/sites-available/yii2-app.conf /etc/apache2/sites-enabled/yii2-app.conf
I get a link and then I /etc/hosts
entered in 127.0.0.1 yii2-app
And then I rebooted apache2 and got this answer[email protected]:/etc/apache2/sites-available$ sudo service apache2 restart
Job for apache2.service failed because the control process exited with error code.
See "systemctl status apache2.service" and "journalctl -xe" for details.
[Sat Feb 10 12:52:58.622686 2018] [mpm_prefork:notice] [pid 7009] AH00169: caught SIGTERM, shutting down
Answer the question
In order to leave comments, you need to log in
Good afternoon.
Why make a symbolic link?
You need to disable the old configuration and connect your own.
This is done by commands in the console
a2dissite name_file.conf
a2ensite name_file.conf
127.0.0.1 localhost
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question