My photo website’s excellent software Gallery had gone end of life with no support. I used the opportunity to explore new photo gallery software, Koken, and move from shared hosting to my first VPS – Virtual Private Server. VPS is like going from renter to home owner, the good and bad news is…. you own it all! Install, setup, patching, security… everything but the hosting hardware and network. I chose Digital Ocean for it’s popularity, reviews, pay as you consume pricing (you can turn a test site on and off) and excellent tutorials which facilitated this project. Big Bonus moving to VPS – with shared hosting my sites would go offline 2-10 minutes quite often for who knows what. After moving to VPS I’ve had no downtime , no one else contending for resources and services – nice!
I’m a Windows/Mac guy so this project was both fun and hard. The end result is a clean, lean and fast site: http://photo.gfisk.com/
Zero downtime alerts from Uptime Robot, no unplanned downtime while I’m working, no email spammers or porno sites causing slow performance or application/system crashes…
Status = It’s always on and always up – unless I’m upgrading/breaking things!
Steps to get this rolling!
- Setup and connect to your droplet at Digital Ocean
- Install and configure Ubuntu
- Install and configure Apache, MySQL, PHP and phpMyAdmin
- Install Koken (if you fancy…)
Tools you will need (Windows OS)
- Putty – SSH client for windows
- PuttyGen – create authentication keys for SSH
- Using PuttyGen – how to from Digital Ocean
- Paegent – an SSH authentication agent for PuTTY, PSCP, PSFTP, and Plink
- FileZilla – SFTP (requires Paegent for
Setup your Digital Ocean Droplet
- Setup Droplet – Chose Ubuntu for the droplet image – 14.04 x86
Connect and setup your server – 3 doc set from Digital Ocean
- Connect via SSH
- Initial Server Setup with Ubuntu 14.04
- Additional Recommended Steps for New Ubuntu 14.04 Servers
Install LAMP – Linux, Apache web server, MySQL Database, PHP server side scripting language
Install phpMyAdmin to create and manage Databases (optional – GUI Database Manager)
- How To Install and Secure phpMyAdmin on Ubuntu 14.04
- Security – in addition to htaccess steps I change the default access point:
- Edit line three and change the alias in phpmyadmin.conf
- sudo nano /etc/apache2/conf-enabled/phpmyadmin.conf
# Alias /phpmyadmin /usr/share/phpMyAdmin
Alias /whateveryouwant /usr/share/phpMyAdmin
- Restart Apache – sudo service apache2 restart
- Access phpMyAdmin -http://yoursite.com/whateveryouwant
Create SSL Certificate for secure https transactions
- How To Create a SSL Certificate on Apache for Ubuntu 12.04
- This is a self signed certificate which is only good for development or protecting and admin area.
- How To Install an SSL Certificate from a Commercial Certificate Authority
Install Software of your choosing
- Install WordPress
- Install phpMyAdmin
- Install Koken (dead…)
Manually setting up a DigitalOcean droplet and installing LAMP stack on it takes a lot of time. I would instead recommend this method of setting up PHP on DigitalOcean (https://www.cloudways.com/blog/host-php-on-digitalocean/ ). This way you can save time and instead work on developing your application.
i am really happy by this article. Really helpful for noobie like me. Thanks