• Deploying Hugo the Golang CMS on DigitalOcean - Nginx

    Deploying Hugo the Golang CMS on DigitalOcean

    Creating a Droplet

    I am a bit partial to CentOS. The lastest version as of this writing is CentOS Linux release 7.1.1503 (Core).

    Setting up a droplet is always very simple. Just turn it on basically. Upload your ssh keys. Done.

    Install Nginx

    Add the epel repo:

    yum install epel-release
    

    Install

    yum install nginx
    

    Start it

    service nginx start
    systemctl enable nginx
    

    Create the Folders

    mkdir -p /var/www/ursite/
    chown -R nginx:nginx /var/www
    touch /var/www/ursite/index.html - or clone your site
    cp /etc/nginx/sites-available/default /etc/nginx/sites-available/ursite
    

    Configure nginx

    open the config file: vim /etc/nginx/conf.d/virtual.conf

  • Hugo: A replacement for Wordpress

    Hugo: A Replacement for Wordpress

    TL;DR

    • I researched go
    • Found Hugo
    • Setup a test
    • Migrated my Wordpress instance
    • Launched DigitalOcean Droplet
    • Deployed

    Total time: 6 hours

    Continued:

    My problems started almost a year before I took up this cause. At the time I only had 2 Wordpress sites. Very very low traffic. Only a couple users a day. They were mostly place holders for business sites.

    Wordpress is hungry

    What was annoying about the case was that they would randomly carsh! I realized they were running out of memory. I couldn’t figure out why because I just wouldn’t let myself believe that a couple instances of Wordpress were enough to run out of memory. It was an AWS box running with .5GB of memory and some swap space. I can’t remember what. Maybe I was just too optimistic.