Hi All,
I deployed OpenVidu on AWS (ver. 2.15.0) following the CloudFormation walkthrough on OpenVidu docs.
After setting all the params, I got the aws instance running, but when I tried to access the service with the public IP or with the Domain name, I’m getting the following error:
404 Not Found - nginx 1.18
I have another instance on AWS running OpenVidu ver. 2.14.0, and it is working fine, when going to the server IP or domain name, I’m getting:
Please, what parameters did you use in your cloudformation and what region are you using? It is just to tests in my own AWS account what the problem could be.
These are the parameters I used:
Instance type: t2.xlarge
KeyName: (my SSH key)
LetsEncryptEmail : isralog@gmail.com (I used LetsEncrypt)
MyDomainName: ovd.cmt.biz
From what I can see in your logs, I think you’ve filled the Cloudformation template with selfsigned in Certificate type, but you must use letsencrypt in the certificate type. You also need an Elastic IP. Check this example and check what type of certificate you have used and if you’re using an Elastic IP:
After deploying with CloudFormation, if you need to change anything of the configuration, some changes will not apply using the control panel of Cloudformation. There’s some scripting in the OpenVidu EC2 instance and this kind of changes are not detected by cloudformation. You need to ssh into OpenVidu EC2 instance and edit the file located in /opt/openvidu/.env and change these parameters:
@Marco_Flores what configuration do you have in your /opt/openvidu/.env? Do you have a configured Domain name? If you’re using letsencrypt as @israelws you must have a domain name pointing to the public Ip of your instance.
@Marco_Flores the domain name you’re using is not pointing to 54.92.236.226
If this is a domain used by other service you have, you need a new one for OpenVidu. For example you can create a subdomain like openvidu.atwebpages.com and this subdomain must point to 54.92.236.226
When the Domain name is pointing to 54.92.236.226, change your DOMAIN_OR_PUBLIC_IP to openvidu.atwebpages.com (if you configured that one) in your /opt/openvidu/.env file.
After that remove the folder /opt/openvidu/certificates and restart openvidu with ./openvidu restart
I changed the param:
“DOMAIN_OR_PUBLIC_IP =”
to the actual domain that I’m using (I did enter it during the CloudFormation setup).
The value was the EC2 public ip4 DNS -> ec2-79-125-91-17.eu-west-1.compute.amazonaws.com
After changing I restarted the openVidu service and it is working now.
It may. be something with the CloudFormation new script, that for some reason is not updating this param with the domain value that I entered (I repeated this process many times) .
Correct, that’s the problem. Unfortunately It is not possible to detect some changes in the cloudformation. We recommend to make changes directly in the .env file because of that.