View Full Version : local LAMP server
3rd August 2004, 03:17 AM
i want to set up apache, mysql, and php locally on my computer to test out php scripts. i want it to be secure and i don't want anyone else to be able to access it. how would i go about doing that?
3rd August 2004, 03:30 AM
install them and use firewall to block port 80 (apache) :p
use apachetoolbox.com to compile a LAMP
3rd August 2004, 05:42 AM
Things to do:
1. Make sure the servers (Apache, MySQL) are ONLY listening to localhost
2. edit /etc/hosts.deny and add this "ALL: ALL EXCEPT LOCAL"
this will deny access to ALL services except when being access from
3. (optional) edit /etc/security/access.conf
4. setup your firewall
5. make sure the servers are up to date.
3rd August 2004, 05:48 AM
no need to compile lamp, unless you want the optimize it (not advisible it you are new to LAMP and are just testing). just install the neccessary components via yum.
7th August 2004, 02:40 PM
i have local test platform (FC2) for php and other testing purposes. I made second ip for eth0 (eth0:1) as 10.0.0.1. On apache htppd.conf file i set apache to listen only ip 10.0.0.1 on port 80 (10.0.0.1:80). I have several domain names so i set NameVirtualHost to point to 10.0.0.1:80 and created namebased virtual domains same way as i have on public server. It is helpful to have local "clone" of the public server. This setup works for me :D
7th August 2004, 05:45 PM
just run it on localhost only (only on local NIC)... in httpd.conf add: "Listen 127.0.0.1:80" and that is it... it will be only accessible at http://localhost/
7th August 2004, 07:10 PM
thanks for all the tips. i went with the normal fedora rpms for apache and mysql, and compiled php5 from source because there were no rpms (that i could find). then i used kosmosik's method of restricting access. everything seems to work fine.
vBulletin® v3.8.7, Copyright ©2000-2013, vBulletin Solutions, Inc.