HomePHP The Soothingly Seamless Setup of Apache, SSL, MySQL, and PHP
The Soothingly Seamless Setup of Apache, SSL, MySQL, and PHP
The much anticipated update to our original article on getting Apache, MySQL, Mod_SSL, and PHP to work seamlessly with each other is finally here! Ever try to get Apache, Mod_SSL, PHP, and MySQL all working in harmony on the same box? It's a very difficult task, but article author Israel Denis Jr. has come up with detailed instructions for compiling all these and getting them working together seamlessly to make the killer server software system.
Our objective is to install a web server that will allow us to host sites, that would be secure for e-commerce solutions, and that could be driven via scripts to connect to a database server and extract its data.
The tools for the job are:
Apache -- A Web Server
Mod_SSL -- A module for Secure Sockets Layer
OpenSSL -- Open Source Toolkit (required for Mod_SSL)
RSARef -- Only necessary for those in the US
MySQL -- A Database Server
PHP -- A Scripting Language
NOTE: All of these packages are free and are available for download on the net.
We are using just one of the many configurations that will fill our objective. We choose it because it is one of the simplest and fastest. We chose Apache because it is probably the most versatile web server ever to exist. Apache has the largest server market share partly because it is free, but mostly because it is the best. Mod_SSL and OpenSSL are added for the ability to conduct secure connections and because they are among the fastest and easiest to configure and setup. PHP is a simple, yet powerful scripting language which integrates easily with MySQL a powerful relational database server.
Hopefully after completing this guide, we will have achieved the following:
Installed and setup the MySQL database server -> Know how to check the status of the MySQL server -> Know how to access the MySQL server using the command line client -> Know how to access your database server from the web
Installed and setup the Apache web server with SSL -> Configure a simple virtual web site -> Know how to stop and start the server -> Know how to do some basic hosting configuration
Installed and setup the PHP 4.0 Hypertext Preprocessor for server-side-scripting -> Know how to write simple php code -> Know how to connect to a DB using php -> Create a simple site that is enabled with PHP to talk to a database
Create some sample certificates to use with Apache SSL -> Know how to generate a CSR file -> know how to encrypt a key -> Know how to sign your own certificates
In this article, quite a bit of information will be covered. We mean for it to be an introductory guide to get you started in the world of e-commerce, web site scripting, and Secure Sockets Layer (SSL), for the purpose of creating secure web sites driven by dynamic information stored in databases.
By no means is this article meant to be a detailed comprehensive document. We hope that it will help you get up and running with the aforementioned products, and hopefully get a better understanding of how everything works.
Our goal is to write this document so that any newbie can understand what we are talking about. If we have accomplish this, then we have done a good job. If you walk away wanting to create e-commerce sites, than we have done an excellent job.... :-) send us some comments.