Last active
January 5, 2017 16:20
-
-
Save mssoylu/aac9ff9198d2aa6c1f4dc0f5d0561ba7 to your computer and use it in GitHub Desktop.
Apache2 Virtualhost Basics
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Symfony3.2 Virtualhost | |
.htpasswd | |
PHP cancel for directory | |
<VirtualHost dys.com:80> | |
ServerName dys.com | |
DocumentRoot /var/www/dys/root/web | |
# <Directory "/var/www/dys/root/web/uploads"> | |
# AllowOverride None | |
# RemoveHandler .php .phtml .php3 | |
# RemoveType .php .phtml .php3 | |
# php_flag engine off | |
# </Directory> | |
<Directory /var/www/dys/root/web> | |
Options Indexes Multiviews FollowSymLinks | |
AuthType Digest | |
AuthName "staff" | |
AuthUserFile /etc/apache2/.htpasswd | |
Require valid-user | |
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteCond %{REQUEST_FILENAME} !-f | |
RewriteRule ^(.*)$ /app.php [QSA,L] | |
# for production app.php | |
</IfModule> | |
</Directory> | |
</VirtualHost> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment