Eyevinn / whip

Client and Server modules for WebRTC HTTP Ingestion Protocol (WHIP)
Apache License 2.0
94 stars 15 forks source link

feat: support for TLS termination #42

Closed birme closed 2 years ago

birme commented 2 years ago

This PR addresses #41 and enables support for TLS termination for WHIP and Broadcaster endpoints.

const endpoint = new WHIPEndpoint({ 
  port: 443, 
  hostname: "whip.lab.eyevinn",
  https: true,
  tls: {
    key: fs.readFileSync("./server-key.pem"),
    cert: fs.readFileSync("./server-cert.pem"),
  },
  iceServers: iceServers,
  enabledWrtcPlugins: [ "broadcaster" ], 
});