Member-only story

How To Serve Static Files With an Ubuntu VPS

Emma Boudreau
4 min readJan 17, 2020

--

For those who work with endpoints and executable servers might sometimes notice that a specific task doesn’t require a back-end to load. Examples of this are HTML template rendering (for static returns) and basic non-markup text transfer. But when this is the case, using a high-performance load balancer like Nginx can leave you scratching your head on the configuration. My good friend who originally mentioned this to me had a good point, as a quick search on Google yields results that are nearly all irrelevant towards the end goal:

Serving Static Files

This is understandable, as configuring Nginx to serve static files is pretty much like an end user configuring Apache to serve them. Luckily, these days Nginx is pretty robust (though it can be quite cumbersome), and setting up a standard Ubuntu server to serve static files is actually really easy. So without further ado, we’ll deploy my static portfolio site to http://emmettboudreau.com/

In the past 10 years, Ubuntu has been dominating the server market. This is also for good reason, because Ubuntu has a lot of advantages when it comes to a first timer, including:

  • Huge user-base, lots of information available.
  • Robust Package Manager (Apt)
  • Easily configurable firewall (ufw)

--

--

Emma Boudreau
Emma Boudreau

Written by Emma Boudreau

i am a computer nerd. I love art, programming, and hiking. https://github.com/emmaccode

No responses yet