gstreamill icon indicating copy to clipboard operation
gstreamill copied to clipboard

Authorization for admin zone

Open ponasromas opened this issue 6 years ago • 3 comments

Hello,

How to implement basic authorization to the admin area of gstream? Is it possible at all?

ponasromas avatar Feb 05 '19 13:02 ponasromas

use nginx as the proxy

zhangping avatar Feb 05 '19 14:02 zhangping

Could you drop some simple example? I've tried with Apache proxy but with null results.

ponasromas avatar Feb 05 '19 14:02 ponasromas

https://christianfei.com/posts/setup-nginx-as-a-reverse-proxy-with-basic-auth-for-an-upstream/

my nginx conf example:

worker_processes 4;

events {
  worker_connections 1024;
}

http {
  upstream app {
    server 127.0.0.1:20118;
    keepalive 64;
  }

  server {
    listen *:20228;
    server_name _;
    access_log /var/log/nginx/nginx.access.log;
    error_log /var/log/nginx/nginx.error.log;
    auth_basic "Restricted Area";
    auth_basic_user_file /etc/nginx/.htpasswd;

    location / {
      proxy_pass http://app;
    }
  }
}

zhangping avatar Feb 07 '19 02:02 zhangping