Created
June 20, 2016 12:58
-
-
Save mikaelz/e89e848d0cee2d9092e4ef4f403e5755 to your computer and use it in GitHub Desktop.
Change Apache document root with htaccess. Just symlink current to release directory that you want to serve
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
Options +FollowSymLinks | |
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteCond %{REQUEST_URI} !current/ | |
RewriteRule (.*) /current/$1 [L] | |
# http://localhost/example.com | |
# RewriteRule (.*) /example.com/current/$1 [L] | |
</IfModule> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment