I have a paid web host on godaddy, I would like to know if it is possible that I use a custom port to redirect to a specific folder on the server (ex: a web mail server or a private folder)

link|improve this question
This question is nonsensical, sorry. – Sirex Nov 2 '10 at 8:13
@Sirex - in what way? It was perfectly clear to me. – ErikA Nov 2 '10 at 14:17
in that it makes no sense. custom port ? private folder ? – Sirex Nov 2 '10 at 15:58
@Sirex: What I was willing to do is installing a mail server then use a specific unused port rather than 80 so that only employees use to access the mail server. – sikas Nov 3 '10 at 21:56
feedback

1 Answer

up vote 2 down vote accepted

If it's a dedicated server and you have full root access (or at least access to do as you wish with apache), then sure, this should be quite simple.

Say, for instance, you wanted to associate port 8888 with a certain directory...in your main apache config file (apache.conf or httpd.conf), add:

Listen 8888
NameVirtualHost *:8888

Then add a VirtualHost:

<Virtualhost *:8080>
    ServerName foo.example.com
    DocumentRoot /path/to/directory
</VirtualHost>

I haven't tested this, so I'm not sure it's 100% correct, but it's very close, and you should be able to adapt it to your environment.

link|improve this answer
how can this be done? – sikas Nov 2 '10 at 20:16
Edited my answer to reflect your additional question. – ErikA Nov 2 '10 at 21:19
thanks, I will give it a try – sikas Nov 3 '10 at 21:54
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.