This post will show how to configure NGINX as a reverse proxy with SSL support, then how (and why) I have migrated to Traefik.

Image by author

The article has four sections:

  • Introduction of the project where the migration took place
  • Deployment with NGINX and Certbot
  • Moving to Traefik and its benefits
  • Configuring Traefik with a wildcard SSL certificate

Intro

NGINX is an extremely popular Web Server: it is fast, free and simple to start with. It was my immediate choice when developing one of my personal projects:

CryptoLastMinute provides a detailed view of the price changes in the last 60 minutes for 500+ cryptocurrencies. It displays the prices in multiple currencies (EUR, USD, Yuan, Ruble) and allows saving your favourite coins.

The architecture comprises a (React) website and 2 (Python) services, Docker containers and a remote database storage.

Running with NGINX

The initial needs at the outset of the project were: manage the incoming HTTP traffic, forward requests to the backend services and ensuring HTTPS.

I opted for NGINX for various reasons: I had already some experience with it and the setup (with Docker) was pretty simple.

With this approach I had to consider the following:

  • provide the
  • define the
  • use Certbot to create and renew the SSL certificate

The includes the configuration of the components involved in the runtime of the website: NGINX and the services.

#traefik #docker

From NGINX to Traefik (with Docker on DigitalOcean)
2.55 GEEK