NodeJs Express Https StartSSL certificate issue

  node.js, question

1. Inhttps://startssl.comThe above application for a free certificate

openssl req -newkey rsa:2048 -keyout ling.key -out ling.csr
 
 Again:
 others:
 1_Intermediate.crt  2_smkuse.info.crt    root.crt
 
 apacheServer:
 1_root_bundle.crt    2_smkuse.info
 
 nginxServer:
 1_smkuse.info_bundle.crt

2, want to use on Nodejs plus express

var express = require('express');
 var app = express();
 var fs = require('fs');
 //This is not right. I don't know how to use it.
 var options = {
 key: fs.readFileSync('./ssl/ling.key'),
 cert: fs.readFileSync('./ssl/2_smkuse.info.crt'),
 ca: [fs.readFileSync('./ssl/root.crt')]
 bracket
 var server = require('https').Server(options,app);

3. it was used when applying for the certificate: smkuse.info
4, thank you for your doubts

You can try using Nginx as a reverse proxy service instead of messing with it yourself.

After StartCOM applied for the certificate, it will give you the certificate for Nginxling.keyAnd1_smkuse.info_bundle.crtOn the server together/YOUR/PATH/Directory, and then configure Nginx

server {
 listen 80;
 listen [::]:80 ssl ipv6only=on;
 listen 443 ssl;
 listen [::]:443 ssl ipv6only=on;
 server_name  example.com ;
 
 ssl on;
 ssl_certificate /YOUR/PATH/1_smkuse.info_bundle.crt;
 ssl_certificate_key /YOUR/PATH/ling.key;
 bracket

The rest is how to configure the 80 and 443 jump rules