https://github.com/lrusso/webserver
Simple Node.js Web server with SSL support
https://github.com/lrusso/webserver
js node server simple ssl web
Last synced: 2 months ago
JSON representation
Simple Node.js Web server with SSL support
- Host: GitHub
- URL: https://github.com/lrusso/webserver
- Owner: lrusso
- Created: 2024-01-27T18:47:31.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-07-12T02:36:33.000Z (over 1 year ago)
- Last Synced: 2024-07-13T03:46:41.408Z (over 1 year ago)
- Topics: js, node, server, simple, ssl, web
- Language: JavaScript
- Homepage:
- Size: 85.9 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Simple Node.js Web Server
Simple Node.js Web server with SSL support.
## Running the Web server
* Standard ports: ```node server.js```
* Customs ports: ```node server.js 8080 4430```
## Workaround for browsing to localhost using SSL
1. Run ```node server.js```
2. Open Chrome and browse to ```https://localhost```
3. Click on ```ADVANCED```
4. Click on ```Proceed to localhost (unsafe)```
This workaround is useful for testing purposes because, for example, a Web App may require access to the webcam and that is not allowed using a non-secure connection.
## Running the Web server in the background
1. Install Forever: ```npm install -g forever```
2. Start the server: ```forever start -a -l /dev/null -c node server.js > /dev/null 2>&1```
3. Stop the server: ```forever stop -a -l /dev/null -c node server.js > /dev/null 2>&1```