-
Notifications
You must be signed in to change notification settings - Fork 166
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to use node-rtsp-stream with https connections? Since this package uses websockets internally, where do we mention configutations for "wss"? #37
Comments
Look in videoStream.js and do the following. const server = https.createServer({ this.wsServer = new ws.Server({ You also have to adapt the VideoStream.prototype.stop |
my wss server working but i dont get frames with jsmpeg and html |
Unfortunately this module isn't designed to use wss right now. If this grows as a request I will look into adding it. It would be great to have, but for now I'm not sure I can dig into it. Thanks for the suggestion though! |
Sorry for my late answer. I have use your code for wss and now its work with jsmpeg. |
So does this mean this will only still work on http sites? Sorry for the confusion but I would love to learn how to get it going on https. |
Figured it out hopefully it can help another! The issue was solved using a wss with a slight modification. Inspired by this Sample index.js for node
Also changed it up a little on the videoStream.js as well, what this is doing is making a Websocket Server without a port
With this approach, I can have many SECURE ws connections without getting any server errors. On express route I have an express route that creates this ClientStreams in this way
|
@alphabin Thanks so much! This is great! Closing issue for now. |
I'm still having some major issues getting this to work. The provided instructions detailed aren't really clear on where things are supposed to go. I've generated certs but cannot get the first reply to function, the server just instantly closes. |
I am facing error when I try to change the RTSP URL dynamically in node-rtsp-stream, can anyone help me to fix this. my error is look like this:
and my post API is :
|
No description provided.
The text was updated successfully, but these errors were encountered: