

The following tutorial demonstrates how to host a website from the Raspberry Pi 4. Now imagine you’ve just been kicked off the cloud… where do you go? The Internet is still an open platform, but you’re faced with the ugly prospect of a reverse cloud migration back to on-prem physical servers. Whether you agree or not, it was within Amazon’s legal rights to make this move. It is something like this .x.AWS recently banned Parler from it’s cloud platform, effectively destroying its 10M user app with the flick of a switch. This number is called the internet protocol (IP) address.

The modem in your house gives a number to all devices connected to it to understand the devices. We are going to make our server available worldwide to the internet! Let's start connecting our Raspberry Pi web server to the internet. You can only access your server within your local network. Now, you won't be able to access your server from another network. Now, we are going to make our local server available to the whole world! Follow the steps below to do it: Giving your Raspberry Pi a Static IP Address Now, you can have your own site by customizing the index.html or by inserting a customized HTML file and renaming it as index.html in the Now that you also have a database of your own, you can maintain the site with it. If you can log in successfully, voila! That's done. If that doesn't work, just try with the phpMyAdmin password. If it doesn't, you should repeat with the commands listed above and check for errors.Īs the username, you can type in "root", and as the password, you can type in the password you gave for the MySQL server. Now you should see a page saying "It works!" If you see it, the server is set up correctly. If you have SSH'd into it, type the Pi's IP address in your browser. Type "localhost" or "127.0.0.1" in the Pi's web browser. Testing the Installed Packages on the Raspberry Pi

Enter a password that you will remember. That's it! You have completed the first step! Now reboot the Pi. Now we can install the MySQL server, which stores everything and acts as our database for the Raspberry Pi web server:Īpt-get install mysql-server mysql-clientĭuring this installation, you will be asked for a password for the server.

Now we should install the package for database connectivity (PHP->SQL): For that, use the following command:Īpt-get install apache2 apache2-doc apache2-utilsĪfter this, it is time to install PHP on our Pi:Īpt-get install libapache2-mod-php5 php5 php-pear php5-xcache Now, let's install Apache, the main component of the project.
