Setting up a Local Nginx with a Self-Signed Certificate

In this blog post, we will discuss how to create a local Nginx server with 443 port and redirect 80 to 443 with Docker Compose. We will also include the command for generating a self-certificate. Setting up the Docker Compose File Firstly, we need to create a docker-compose.yml file in the root directory of our project. In this file, we will define the service for the Nginx server. 1 2 3 4 5 6 7 8 9 10 11 12 13 version: "3....

July 6, 2023 · 4 min · Justin Hung