Skip to main content

Deployment

Deployment Methods

There are so many ways of deployment that I cannot cover all of them.

With a VM

Here are a few videos I made to explain how to deploy web app on AWS EC2 (VM). Load Balancer service is used for SSL certificate.

This method is not recommended, but it gives you an idea of the old way and how things work.

Load Balancer is expensive and redundant for a small project.

BaaS / PaaS

Read more about BaaS (Backend as a Service) / PaaS (Platform as a Service) here.

Basically you leave everything to some cloud. All you need to do it to upload the content.

SSL certificate is taken care of, so not much to worry about.

Usually, you can choose to use CLI to manually deploy, or use CICD to deploy automatically when triggered (usually a push or release).

Reverse Proxy

Cloudflare Illustration

Nginx (Reverse Proxy) + Certbot (SSL)

Read Reverse Proxy for what it is.

We can use Nginx as reverse proxy to direct traffic from client to backend; but the main purpose of using Nginx as a reverse proxy here is to have a easy way of setting up SSL certificate, to support HTTPS.

Certbot has nginx plugin for easy SSL deployment with letsencrypt.

Nginx + letsencrypt

https://youtu.be/oykl1Ih9pMg

Docker + Nginx + letsencrypt

https://youtu.be/zJPlyjfV4C0