Skip to content

Commit a07440a

Browse files
committed
server-ssl.js
detect if node.js is already installed /root │ ├── /error │ ├── 404.html │ └── 500.html │ ├── /ssl │ ├── /openssl │ ├── /acme │ │ ├── /crypt │ │ ├── /jose │ │ └── lets-encrypt-acme-client.js │ │ │ ├── acmeKeys │ ├── private-key.pem │ └── certificate.pem │ └── ssl.js │ ├── /website │ └── index.html <---- Your website goes here │ ├── node.exe ├── server-ssl.js <--- server config └── start-windows.bat
1 parent d962802 commit a07440a

1 file changed

Lines changed: 13 additions & 22 deletions

File tree

README.md

Lines changed: 13 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -94,11 +94,14 @@ You can remove everything inside `HTTPS_SERVER` and do whatever you like.
9494

9595
There are also helpers you can use in `S_SSL`
9696

97+
> [!NOTE]
98+
> If you don't already have [`Node.js`](https://nodejs.org/en) installed then `start-windows.bat` will download the latest version of `node.exe` to the root folder
99+
97100
--------
98101

99-
### Default Structure
102+
### Default Layout
100103

101-
This structure is designed to keep the project organized and maintainable, separating error handling, website content, and server configuration.
104+
This layout keeps the project organized and maintainable, separating error handling, website content, and server configuration.
102105

103106
```
104107
/root
@@ -114,15 +117,13 @@ This structure is designed to keep the project organized and maintainable, separ
114117
│ │ ├── /jose
115118
│ │ └── lets-encrypt-acme-client.js
116119
│ │
117-
│ ├── acmeKeys
118120
│ ├── private-key.pem
119121
│ └── certificate.pem
120122
│ └── ssl.js
121123
122124
├── /website
123125
│ └── index.html <---- Your website goes here
124126
125-
├── node.exe
126127
├── server-ssl.js <--- server config
127128
└── start-windows.bat
128129
```
@@ -145,22 +146,12 @@ These pages will automatically select light/dark mode
145146

146147
### Bring Your Own SSL Certificate
147148

148-
```
149-
./start-windows.bat --cert="your-certificate.pem" --pk="your-private-key.pem"
150-
node server-ssl.js --cert="your-certificate.pem" --pk="your-private-key.pem"
151-
```
152-
153-
> [!IMPORTANT]
154-
> Your `Certificate` and `Private Key` should be relative to the `SSL` folder if you bring your own
155-
156-
### Create SSL Certificate
157-
158-
`start-windows.bat` will automatically create a `Certificate` and `Private Key` when you run it if you don't provide any and none exist
159-
160-
[![](https://i.imgur.com/vAMuDOG.png)](https://github.com/FirstTimeEZ/server-ssl/archive/refs/heads/main.zip)
149+
Convert your `certificate` and `private key` to `PEM` format and place them in the `ssl` folder
161150

162-
--------
163-
164-
### Node.js
165-
166-
If you don't already have [`Node.js`](https://nodejs.org/en) installed then `start-windows.bat` will download the latest version of `node.exe` to the root folder
151+
```
152+
├── /ssl
153+
│ │
154+
│ ├── private-key.pem <--- Your private key goes here
155+
│ └── certificate.pem <--- Your certificate goes here
156+
│ └── ssl.js
157+
```

0 commit comments

Comments
 (0)