From ab829af8ce147faf9021e6e7ce62e33c4e747ce5 Mon Sep 17 00:00:00 2001 From: Alex Hultman Date: Thu, 17 Jan 2019 11:42:53 +0100 Subject: [PATCH] Point all examples to demo key/cert --- examples/HelloWorld.js | 4 ++-- examples/Router.js | 4 ++-- examples/Upload.js | 4 ++-- examples/VideoStreamer.js | 4 ++-- examples/WebSockets.js | 4 ++-- 5 files changed, 10 insertions(+), 10 deletions(-) diff --git a/examples/HelloWorld.js b/examples/HelloWorld.js index e783637..5b26001 100644 --- a/examples/HelloWorld.js +++ b/examples/HelloWorld.js @@ -4,8 +4,8 @@ const uWS = require('../dist/uws.js'); const port = 9001; const app = uWS./*SSL*/App({ - key_file_name: '/home/alexhultman/key.pem', - cert_file_name: '/home/alexhultman/cert.pem', + key_file_name: 'misc/key.pem', + cert_file_name: 'misc/cert.pem', passphrase: '1234' }).get('/*', (res, req) => { res.end('Hello World!'); diff --git a/examples/Router.js b/examples/Router.js index eba0850..ce86429 100644 --- a/examples/Router.js +++ b/examples/Router.js @@ -4,8 +4,8 @@ const uWS = require('../dist/uws.js'); const port = 9001; const app = uWS./*SSL*/App({ - key_file_name: '/home/alexhultman/key.pem', - cert_file_name: '/home/alexhultman/cert.pem', + key_file_name: 'misc/key.pem', + cert_file_name: 'misc/cert.pem', passphrase: '1234' }).get('/user/agent', (res, req) => { /* Read headers */ diff --git a/examples/Upload.js b/examples/Upload.js index 7c652c4..8353026 100644 --- a/examples/Upload.js +++ b/examples/Upload.js @@ -8,8 +8,8 @@ const uWS = require('../dist/uws.js'); const port = 9001; const app = uWS./*SSL*/App({ - key_file_name: '/home/alexhultman/key.pem', - cert_file_name: '/home/alexhultman/cert.pem', + key_file_name: 'misc/key.pem', + cert_file_name: 'misc/cert.pem', passphrase: '1234' }).post('/*', (res, req) => { console.log('Posted to ' + req.getUrl()); diff --git a/examples/VideoStreamer.js b/examples/VideoStreamer.js index a4bf5fa..0424c9c 100644 --- a/examples/VideoStreamer.js +++ b/examples/VideoStreamer.js @@ -56,8 +56,8 @@ function pipeStreamOverResponse(res, readStream, totalSize) { /* Yes, you can easily swap to SSL streaming by uncommenting here */ const app = uWS.SSLApp({ - key_file_name: '/home/alexhultman/key.pem', - cert_file_name: '/home/alexhultman/cert.pem', + key_file_name: 'misc/key.pem', + cert_file_name: 'misc/cert.pem', passphrase: '1234' }).get('/sintel.mkv', (res, req) => { /* Log */ diff --git a/examples/WebSockets.js b/examples/WebSockets.js index be718ee..889b0eb 100644 --- a/examples/WebSockets.js +++ b/examples/WebSockets.js @@ -4,8 +4,8 @@ const uWS = require('../dist/uws.js'); const port = 9001; const app = uWS./*SSL*/App({ - key_file_name: '/home/alexhultman/key.pem', - cert_file_name: '/home/alexhultman/cert.pem', + key_file_name: 'misc/key.pem', + cert_file_name: 'misc/cert.pem', passphrase: '1234' }).ws('/*', { /* Options */