Deploy recording using docker

I am trying to learn about openvidu products and I’ve successfully learnt how to build a few custom apps as well. I love how well engineered this product is.
I came across the tutorial for recording using node and wanted to deploy it. After some digging around (a whole lot of trials and errors for a few days) I realized that I could do this just by swapping out the image: openvidu/openvidu-call:2.16.0 with the image for openvidu/openvidu-recording:2.16.0 in the docker-compose.override.yml. But That didn’t work. Can you please tell me what changes I need to make in the docker-compose to get this to work?

No, that’s not how it works.
Recordings are automatically launched by OpenVidu Server.

You don’t need to replace openvidu/openvidu-call:2.16.0 with openvidu/openvidu-recording:2.16.0

In the docker-compose.override.yml should be your containerized node app running at port 5442.
Take a look here: OpenVidu Docs

Thank you for the Reply. I tried what you proposed. I am using the openvidu-recording-node tutorial application in this case. (I have installed the app natively)

  1. I changed the app to use ‘http’ instead of ‘https’. var https = require('http');
  2. The app is listening on port 5442 instead of the default 5000
  3. var OPENVIDU_URL = http://localhost:5443
  4. var OPENVIDU_SECRET = "MY_SECRET";

I am now seeing an 404 for https://…/api/get-token and upon changing it to use http in the front end I get an error Blocked loading mixed active content. How can I rectify this?

you are using openvidu on server or local ?
and where is your nodejs app in same server or different server or local ?
Thanks
Vipin

AWS EC2 instance - both openvidu and nodejs app are hosted on there

Every time I perform a POST request, I think NGINX is redirecting it to use https and in the process changing the POST to a get GET.

Here are the changes I made in the .env

DOMAIN_OR_PUBLIC_IP=ec2-xxx-xxx-xxx-xxx.compute-1.amazonaws.com
OPENVIDU_SECRET=MY_SECRET

and server.js

var https = require('http');
https.createServer(options, app).listen(5442);
var OPENVIDU_URL = "http://localhost:5443";
var OPENVIDU_SECRET = "MY_SECRET";

I Will say use your openvidu domain instead localhost

changed it to

var OPENVIDU_URL = "http://ec2-xxx-xxx-xxx-xxx.compute-1.amazonaws.com:5443";

Still on the same error. All get requests to the application server i.e the node server are going through, but for post requests i get a cannot GET /api/get-token (when queried using postman, get-token is a post method) or a
Request of TOKEN gone WRONG: (404) {"timestamp":"2021-01-11T17:05:04.361+00:00","status":404,"error":"Not Found","message":"","path":"/api/get-token"} on the console warning

I’m wondering if I have correctly followed the “Application must be server in plain http, without https.” instruction. Maybe NGINX is rerouting http requests to https and this is screwing things up somehow?

Yes you need accept the ssl certificate if you are not using domain

Yes, I did accept the certificate when my browser threw a warning about security. But, I am still facing this issue.

Try using:

var OPENVIDU_URL = "http://ec2-xxx-xxx-xxx-xxx.compute-1.amazonaws.com";

instead of:

var OPENVIDU_URL = "http://ec2-xxx-xxx-xxx-xxx.compute-1.amazonaws.com:5443";

OpenVidu is configured in port 443 externally by default.

Regards

Yes @cruizba Is correct why you are using port 5443