0

I'm trying to learn how to set up a Janus server on a local machine. I am new to networking and servers so I could really use some help. I followed the instructions in the github and installed the Janus server, and also tried setting up an Nginx server and changed the server address in the videoroom demo to "/janus", as suggested in the "Deploy" section.

If I try to connect on the same machine with the private IP it works without issues (http:// or https://, without port), however if I try to connect with the private IP from a different machine on the same network, or with the public IP from a remote machine on a different network, I get a timeout error (or an ERR_ADDRESS_UNREACHABLE error).

The addresses I tried are:
http://:8088 (http://:8088/janus)
http://:8088/janus (https://:8089/janus)
and same with public IP.

If someone can help me understand if I did something wrong in the config files, or could it be something else (maybe router firewall blocking the connections?), I would really appreciate it.

Here are the config files that I made changes to (too long to post here):
Janus config - https://pastebin.com/Jd5aNK01
Janus transport config - https://pastebin.com/34awfCUr

And the Nginx config:

server {
    listen 80 default_server;
    listen [::]:80 default_server;

    # SSL configuration
    #
    listen 443 ssl;
    listen [::]:443 ssl;

        ssl_certificate /home/rp/Desktop/RPServer/certificate.crt;
        ssl_certificate_key /home/rp/Desktop/RPServer/private.key;
        ssl_password_file /home/rp/Desktop/RPServer/ssl.pass;
    #
    # Note: You should disable gzip for SSL traffic.
    # See: https://bugs.debian.org/773332
    #
    # Read up on ssl_ciphers to ensure a secure configuration.
    # See: https://bugs.debian.org/765782
    #
    # Self signed certs generated by the ssl-cert package
    # Don't use them in a production server!
    #
    # include snippets/snakeoil.conf;
    # Add index.php to the list if you are using PHP
    index index.html index.htm index.nginx-debian.html;

    server_name _;

    root    /opt/janus/share/janus/demos;

    location ~* \.(ico|css|js|gif|jpe?g|png)$ {
            expires 30d;
            add_header Vary Accept-Encoding;
            access_log off; 
    }

    location / {
        # First attempt to serve request as file, then
        # as directory, then fall back to displaying a 404.
        try_files $uri $uri/ =404;
    }

    location /janus {
        proxy_pass http://127.0.0.1:8088/janus;
    }

    # pass PHP scripts to FastCGI server
    #
    #location ~ \.php$ {
    #   include snippets/fastcgi-php.conf;
    #
    #   # With php-fpm (or other unix sockets):
    #   fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;
    #   # With php-cgi (or other tcp sockets):
    #   fastcgi_pass 127.0.0.1:9000;
    #}

    # deny access to .htaccess files, if Apache's document root
    # concurs with nginx's one
    #
    #location ~ /\.ht {
    #   deny all;
    #}
}

Thank you very much.

0 Answers0