김시환

add https

Showing 1 changed file with 2 additions and 3 deletions
...@@ -51,9 +51,8 @@ app.post('/hook', function (req, res) { ...@@ -51,9 +51,8 @@ app.post('/hook', function (req, res) {
51 }); 51 });
52 try { 52 try {
53 const option = { 53 const option = {
54 - ca: fs.readFileSync('/etc/letsencrypt/live/' + domain +'/fullchain.pem'), 54 + key: fs.readFileSync('./rootca.key', 'utf8'),
55 - key: fs.readFileSync(path.resolve(process.cwd(), '/etc/letsencrypt/live/' + domain +'/privkey.pem'), 'utf8').toString(), 55 + cert: fs.readFileSync('./rootca.crt' ,'utf8'),
56 - cert: fs.readFileSync(path.resolve(process.cwd(), '/etc/letsencrypt/live/' + domain +'/cert.pem'), 'utf8').toString(),
57 }; 56 };
58 57
59 HTTPS.createServer(option, app).listen(sslport, () => { 58 HTTPS.createServer(option, app).listen(sslport, () => {
......