Redirecting access in Apache to https://
Josh Glover
colug at jmglov.net
Thu May 27 07:57:12 EDT 2004
Quoth Ken Bradford (Wed 2004-05-26 05:14:26PM -0400):
>
> > Hi. I had a similar problem at some point. Below is what I came up
> > with at the time [1]:
[...]
> > [sjs at viper etc]$ cat httpd/conf.d/foo.conf
> > <VirtualHost *:80>
> > RedirectMatch /foo/(.*) https://khadrin.com/foo/$1
> > </VirtualHost>
>
> This also works very well too. (Using <Location> & Redirect inside of
> <VirtualHost> was the other.) Now I've got a couple of options to play with.
And here is one more:
<VirtualHost *:80>
ServerName mail.jmglov.net
DocumentRoot /data/httpd/htdocs/squirrelmail
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteOptions inherit
RewriteRule ^(.*)$ https://mail.jmglov.net$1 [R,L]
</IfModule>
</VirtualHost>
Cheers,
Josh
--
Josh Glover
Gentoo Developer (http://dev.gentoo.org/~jmglov/)
Tokyo Linux Users Group Listmaster (http://www.tlug.jp/)
GPG keyID 0xDE8A3103 (C3E4 FA9E 1E07 BBDB 6D8B 07AB 2BF1 67A1 DE8A 3103)
gpg --keyserver pgp.mit.edu --recv-keys DE8A3103
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://www.colug.net/pipermail/colug/attachments/20040527/798aeee3/attachment.bin
More information about the colug
mailing list