LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 07-31-2004, 12:30 AM   #1
leiavoia
Member
 
Registered: Mar 2002
Distribution: Debian Testing & Kubuntu
Posts: 72

Rep: Reputation: 15
need help: how to configure Apache for personal use


I have just installed Apache on a Debian testing desktop box, It responds to http://127.0.0.1/ I have installed and hackep up apache before, but i want to know how to do it right this time. What i want to do is use Apache locally on my desktop computer to test dynamic web page content. What do i have to do in order to get my computer with Apache to respond to:

http://youknow.myboxname.com/
http://whatever.myboxname.com/
http://something.myboxname.com/

( three different test websites running locally )

I want these 3 testing sites to be located in my home directory at:

/home/myname/websites/youknow/
/home/myname/websites/whatever/
/home/myname/websites/something/

???

What i would like to do is properly configure virtual hosts. What settings do i have to alter with:

1) Apache config itself (i just put "allow all" for a hack)?
2) Virtual hosts config? (i think i can figure that one out)
3) DNS and computer settings to recognise domain name of my choosing (I'm not even sure what it really is)

I would really appreicate your help. Thank you very much for taking the time to respond.

Last edited by leiavoia; 07-31-2004 at 12:32 AM.
 
Old 07-31-2004, 08:03 AM   #2
marghorp
Senior Member
 
Registered: Jan 2004
Location: Slovenia
Distribution: Slackware 10.1, SLAX to the MAX :)
Posts: 1,040

Rep: Reputation: 45
Edit the httpd.conf file (it's called this in RH products, holds the configuration for Apache server) find a line called /var/www/ (it is usually the home directory of your websites. Change it to what you please... /home/username/websites/ for example...

Then copy all your files to your /home/username/websites/ for example directory. Then edit the /etc/hosts file and put into it

127.0.0.1/site1 www.mysite1.com
127.0.0.1/site2 www.mysite2.com
127.0.0.1/site3 www.mysite3.com

That way you should be able to get to the sites you want Not a great solution, but works though (only locally).

Good luck!

Peace!
 
Old 07-31-2004, 09:19 PM   #3
leiavoia
Member
 
Registered: Mar 2002
Distribution: Debian Testing & Kubuntu
Posts: 72

Original Poster
Rep: Reputation: 15
How do i get my computer to recognise some arbitrary URL? like:

http://websitename.boxname.com/

What files control that sort of thing? I used to know how to do it in mandrake, but i'm now using Debian.

thanks
 
Old 07-31-2004, 11:21 PM   #4
idaho
Member
 
Registered: Aug 2003
Location: Portland, Oregon
Distribution: RedHat, Libranet
Posts: 438

Rep: Reputation: 30
websitename.boxname.com needs to be resolvable.

If this is not resolvable via your DNS server, then an entry in your /etc/hosts file for websitename.boxname.com should work. If it doesn't you probably need to tweak /etc/nsswitch.conf to include a line that looks like:
hosts: files dns
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Installing Apache on SuSE 9.1 Personal WebScud Linux - Distributions 11 03-08-2007 04:51 PM
Mambo and personal web page: Apache? Lead Expression Linux - Newbie 2 09-19-2005 02:46 PM
setting up apache on SuSE 9.1 Personal nick1 SUSE / openSUSE 1 04-01-2005 11:24 AM
can't configure sound device on Acer TravelMate with Suse 9 Personal brianryer Linux - Hardware 0 11-14-2003 07:21 PM
Startup Files to Configure for personal settings AMH Linux - Newbie 1 06-05-2001 05:42 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:32 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration