DIY Web Server

//

//

DIY Web Server

My first order of real business was setting up a webserver. I need a place to host the first of the 2 domains I purchased. I’m not real fond of monthly (subscription) fees, and I happen to have access to an extra routable IP address, so off into the self-hosting abyss I go…

The Hardware

I don’t need much for hardware, the only thing the computer will do is run this one website, and I don’t expect large amounts of traffic viewing this site. A quick search online and I think I found the perfect candidate. I purchased a Beelink Mini PC (GK35) from Amazon for $185. It came preloaded with Windows 10 Pro, has an Intel 3.2 GHz Celeron J3455 processor (4 core / 4 thread), 8G DDR3 / 128G SSD, HDMI, Gigabit Ethernet. Once I fix the Windows problem, I think this little machine will work just fine.

Installing Linux

So the first thing I had to do was fix the Windows problem. I downloaded the latest version of AlmaLinux 9. Created a bootable usb thumb drive from the AlmaLinux iso, booted the Beelink and installed Linux, formatting the SSD drive and erasing Windows forever – my Windows problem is fixed! AlmaLinux can be set up as a server sans gui, as a server with a basic gui, and as a desktop/workstation. I set mine up with a basic gnome desktop to get me started. Once it is set up I will use remote software to administration and maintance. If you’re interested in the details, you can find them in this post.

Web Server Setup

Once I had a basic linux server up and running, it was time to install a web server. For this task I chose Apache Web Server software. Apache was downloaded, installed, and setup, giving me a working webserver. I tested it by typing the ip address into my laptop web browser and receiving the Apache demo webpage. I now had a working webserver. If you’re interested in the details, you can find them in this post (coming soon).

Unleashing PHP

Next up was the installation of PHP. PHP is a scripting language and is the engine behind a dynamic website. Using the Remi repo to grab the latest version of PHP, I did a quick install. I setup and started PHP-FPM, which is basically a PHP process manager. The last thing was to create a test page and make sure everything was working fine. If you’re interested in the details, you can find them in this post (coming soon).

DB Setup and Hardening

So far I have a working web server with PHP. The next thing I will need is a database. I will be using Mariadb. It is an open source replacement for MySQL in the LAMP stack. After installing Mariadb, I ran the MySQL Secure Installation script to harden my database. If you’re interested in the details, you can find them in this post (coming soon).

WordPress Wizardry

Now that I have a working LAMP stack, I need to get WordPress up and running so I can start posting all this great content. I got WordPress downloaded, installed, setup, and running. I won’t bore you with all the details here. If you want those, you can find them in this post (coming soon).

No Pilot’s License Required

The last program I installed, was a program called Cockpit. Cockpit will allow me to administer my web server from a remote desktop. And like all the other sections above, if you’re interested in the details, you can find them in this post (coming soon).

Finishing Strong

So my web server is setup and running. The domain has been set, and the DNS records created. A few additional tweaks to lockdown the server and I’m all set to start posting. The details of the final tweaks can be found in this post (coming soon).

And there you have it. My website is up and running – which is why you are able to read this page right now. I hope that this will be the beginning of a long term ongoing project for me.

Search


Categories


Recent Posts