Install and run KMS

I used the below instruction to generate the certificate.

Generate a selfsigned certificate (run in your Docker console)

openssl req -newkey rsa:2048 -new -nodes -x509 -days 3650 -subj '//CN=www.mydom.com\O=My Company LTD.\C=US' -keyout key.pem -out cert.pem

Run with SSL flag

http-server -S

Hi Pablo,

The issues is resolved now ,

but now i have another issues . when i am trying to run from another computer on same network with http://MY IP: 8080. and joining the session the camera is not seen. the screen is blank .
but when i run https://myip:4443. camera is working and session is getting established.

i am running docker my command to start the server is

sudo -E docker run -p 4443:4443 --rm -e openvidu.secret=123 -e openvidu.publicurl=https://myIP:4443/ openvidu/openvidu-server-kms:2.11.0

Hi ,

Finally my openvidu-library-angular is running fine. now i have another issue of screen sharing . I am able to share the screen but its not visible on another computer screen on same network. I am trying to test this,
screen is shared but its not visible on another computer.

Do you have any idea why this is happening . The chat and video is working perfectly

screen sharing is happening its shown going to vendor.js
and no error in console , but screen on other side is not visible

Hi Pablo,

Please do help my screen sharing is not working fbelowcode looks okey. I am not getting any error , the default chrome extension is installed and i am able to share screen ( Participant 1 and Session A) but (Participant 2 and session A) is not able to see screen

do i need to change in the below code some where . on look every thing looks fine

  const mediaConstraints: MediaStreamConstraints = {
    audio,
    video
  };




    if (!!publisherProperties.videoSource && typeof publisherProperties.videoSource === 'string') {

      if (publisherProperties.videoSource === 'screen' ||
        publisherProperties.videoSource === 'window' ||
        (platform.name === 'Electron' && publisherProperties.videoSource.startsWith('screen:'))) 

================= some issues here

else {
// Default screen sharing extension for Chrome/Opera, or is Firefox < 66
const firefoxString = platform.name!.indexOf(‘Firefox’) !== -1 ? publisherProperties.videoSource :’;.getScreenId(firefoxString, (error, sourceId, screenConstraints) => {

==========

else {
mediaConstraints.video = screenConstraints.video;
resolve(mediaConstraints);
}
});
}
}

            publisherProperties.videoSource = 'screen';

Hi ,

When i am changing the videoSource:“screen”, i am able to share only screen no video call can any one help where to change setting of videoSource: " Screen"

==================================================
OpenVidu.prototype.initPublisher = function (targetElement, param2, param3) {
var properties;
if (!!param2 && (typeof param2 !== ‘function’)) {
// Matches ‘initPublisher(targetElement, properties)’ or ‘initPublisher(targetElement, properties, completionHandler)’
properties = param2;
properties = {
audioSource: (typeof properties.audioSource !== ‘undefined’) ? properties.audioSource : undefined,
frameRate: (typeof MediaStreamTrack !== ‘undefined’ && properties.videoSource instanceof MediaStreamTrack) ? undefined : ((typeof properties.frameRate !== ‘undefined’) ? properties.frameRate : undefined),
insertMode: (typeof properties.insertMode !== ‘undefined’) ? ((typeof properties.insertMode === ‘string’) ? VideoInsertMode_1.VideoInsertMode[properties.insertMode] : properties.insertMode) : VideoInsertMode_1.VideoInsertMode.APPEND,
mirror: (typeof properties.mirror !== ‘undefined’) ? properties.mirror : true,
publishAudio: (typeof properties.publishAudio !== ‘undefined’) ? properties.publishAudio : true,
publishVideo: (typeof properties.publishVideo !== ‘undefined’) ? properties.publishVideo : true,
resolution: (typeof MediaStreamTrack !== ‘undefined’ && properties.videoSource instanceof MediaStreamTrack) ? undefined : ((typeof properties.resolution !== ‘undefined’) ? properties.resolution : ‘640x480’),
videoSource: (typeof properties.videoSource !== ‘undefined’) ? properties.videoSource : undefined,
filter: properties.filter
};
}
else {
// Matches ‘initPublisher(targetElement)’ or ‘initPublisher(targetElement, completionHandler)’
properties = {
insertMode: VideoInsertMode_1.VideoInsertMode.APPEND,
mirror: false,
videoSource:“screen”,
publishAudio: true,
publishVideo: true,
resolution: ‘640x480’
};

Already the properties = param2 is taking the videoSource= undefined and when i share the screen it shares the screen but is not visible to other participant

Hello PabloFuente,
I’m getting following error:

see this code for screen share

this error you getting because of your app not connected from openvidu server So its not getting token