Ok I have created the co-domain. When I type in the username I get the following error now: --- Not Found The requested URL / was not found on this server. Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request. --- This to me seems like I'm now just having problems creating my directive. As before any ideas would be appreciated. I'm trying to do some more reading to see what else I can try.
Co-Domains are not the same as DNS. A co-domain is a alias domain of a apache vhost and not a DNS record. DNS-Records are managed in the DNS-Manager. If a domain is not an alias for a vhost, you can not do any rewriting for this domain in the vhosts.
Ok then what would you recommend I try? I have a DNS record point to the IP address of my sever. I have entered my apache directive (as per posted). I have created a co-domain. I receive the error mentioned previously. With a co-domain created this creates a vhost entry so that the respective directive will be initied?
Yes I am trying to use 'jason'. However, I have kept the wildcards from the examples to see if in the future all I need to do is create the appropriate records and not have to update the directive.
Sorry Falko, The address is: jason.shewchuk.ca And the user name is web7_jason. I have not changed the index.html file for my user.
Is 142.179.186.168 your server's IP address? What's the output of Code: ifconfig ? What's in Vhosts_ispconfig.conf?
I'm not sure what you are looking for. The server is correctly configured ie I haven't made any changes from the default install. Just having trouble with the mod_rewrite. I am having no other unusual problems. RewriteEngine on RewriteLog /tmp/rewShewchuk.log RewriteLogLevel 3 RewriteCond %{HTTP_HOST} ^.+.shewchuk.ca$ RewriteRule ^(.+) %{HTTP_HOST}$1 [C] RewriteRule [^.]+.shewchuk.ca(.*) /var/www/web1/user/web1_$1$2
What are you trying to do with Code: RewriteCond %{HTTP_HOST} ^.+.shewchuk.ca$ RewriteRule ^(.+) %{HTTP_HOST}$1 [C] RewriteRule [^.]+.shewchuk.ca(.*) /var/www/web1/user/web1_$1$2 ?
I am trying to use mod_rewrite to allow a user to type jason.shewchuk.ca and access the files stored within the users space normally accessed through shewchuk.ca/~jason. As per first post.
I was able to solve my mod_rewrite problem. As I suspected it was a problem with my rewrite command. I finally got the book "The Definitive Guide to Apache mod_rewrite" today in the mail today. I recommend it, using the wildcard information in the book I was able to create the script I needed. Thx for the help.
For those interested in having the ability to go username.domain.ca then you can use this general mod_rewrite: RewriteEngine on RewriteCond %{HTTP_HOST} !^www. RewriteCond %{HTTP_HOST} ^([^.]+).[domain.ca] RewriteRule ^/(.*)$ /var/www/web[IDNumber]/user/web[IDNumber]_%1/web/$1 [L] Replace domain with your own domain and [IDNumber] with the ID number assigned from ISPConfig. This is the simplest method. If you want to address error handling etc then you need to customize and add a few extra lines.