Enabling SSL

1. Get a certificate

You can use your existing certificate or create a new one using mkcertarrow-up-right utility. Follow the installation guidearrow-up-right for your platform.

After installation install mkcert certificate into your system by running the command below:

mkcert -install

Now we need to create a certificate. To create a certificate run command below:

> mkcert localhost 127.0.0.1

Created a new certificate valid for the following names ๐Ÿ“œ
 - "localhost"
 - "127.0.0.1"

The certificate is at "./localhost+1.pem" and the key at "./localhost+1-key.pem" โœ…

It will expire on 13 May 2023 ๐Ÿ—“

Now we have all files that we need for CMA config.

2. Setup CMA

Add to your cma.js file field ssl with the following object:

That is it! Just now we have enabled SSL in our application! Now to apply changes we need to run start command without -s option.

circle-exclamation

Last updated