Skip to content

Commit 9d75675

Browse files
committed
Merge pull request #12 from cordellcalitz/master
Add support for specifying custom ssl key and cert for https mode
2 parents 33d3904 + 3d92ea9 commit 9d75675

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

README.md

+6
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,12 @@ $ pm2 set pm2-webshell:port 7890
3131
3232
# HTTPS
3333
$ pm2 set pm2-webshell:https true
34+
35+
# SSL Certificate file
36+
$ pm2 set pm2-webshell: ssl_cert ~/path/to/ssl.cert
37+
38+
# SSL Key file
39+
$ pm2 set pm2-webshell: ssl_key ~/path/to/ssl.key
3440
````
3541
3642
## Uninstall

app.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,8 @@ ssh_conf.users[conf.username] = conf.password;
103103

104104
if (JSON.parse(conf.https) === true) {
105105
ssh_conf['https'] = {
106-
"key": "./term-default.key",
107-
"cert": "./term-default.crt"
106+
"key": conf.ssl_key || "./term-default.key",
107+
"cert": conf.ssl_cert || "./term-default.crt"
108108
};
109109
}
110110

0 commit comments

Comments
 (0)