Raspberry Pi – setting up Web server

Abstract: This is how to setup a Web server on Raspberry Pi

Update your Raspberry Pi first.

Run this commands to install this
apt-get install apache2 The Apache web server
apt-get install php5 libapache2-mod-php5 php5 and php5 support for Apache
apt-get install mysql-server mysql-client MySQL server and client.
You will be prompted to enter a SQL root password.
apt-get install php5-mysql MySQL support for php

Configure Apache. By defualt, a single-page website is active – /var/www/index.html.

You can test php is working by creating a file: /var/www/phpinfo.php:

Then in your webbrowser, visit http://rpi/phpinfo.php and you will see the php configuration screen.

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *