kaj 316 Posted November 29, 2020 Posted November 29, 2020 I've setup Emby in a docker, as well as Swag, as my reverse proxy. Everything is working great.....perhaps a little too great I can connect without problems, both locally and remotely. The trouble is when I connect remotely the user is seen as a local user (not a remotely connected user) and so will not transcode media when needed due to slow internet. Also, I have my remote users hidden from login screens on the local network, so now they don't appear. Apparently my nginx .conf is correct, so I'm thinking it may be the Network Setting in emby itself. My .conf server { listen 443 ssl; listen [::]:443 ssl; server_name katv.*; include /config/nginx/ssl.conf; client_max_body_size 0; location / { include /config/nginx/proxy.conf; resolver 127.0.0.11 valid=30s; set $upstream_app embydock; set $upstream_port 8096; set $upstream_proto http; proxy_pass $upstream_proto://$upstream_app:$upstream_port; proxy_set_header Range $http_range; proxy_set_header If-Range $http_if_range; } } Any ideas as why my remote users are being seen as local network users? Thanks. @Happy2Play please move my postings from this thread into a new topic. Thanks.
cappapp 7 Posted November 29, 2020 Posted November 29, 2020 39 minutes ago, kaj said: Any ideas as why my remote users are being seen as local network users? Thanks. In the nginx/swag conf file at the top it says the settings you need to set in emby. I assume you have done those too? EG; Public https port number: 443 and set your external domain name and set secure connection mode to handled by reverse proxy?
kaj 316 Posted November 29, 2020 Author Posted November 29, 2020 4 minutes ago, cappapp said: In the nginx/swag conf file at the top it says the settings you need to set in emby. I assume you have done those too? EG; Public https port number: 443 and set your external domain name and set secure connection mode to handled by reverse proxy? Yes, everything works. I can connect remotely and locally. The problem is that Emby is seeing the remote connections as local ones, so I only see the local login users, not the remote login users. And remote users with low bandwidth direct stream, rather than transcoding, as Emby thinks they are local.
kaj 316 Posted November 29, 2020 Author Posted November 29, 2020 (edited) So if I put, in Server - Network - Lan networks a complete junk IP address (I rebooted Emby after this), I can still connect through to Emby, on the local network. It seems as if Emby is ignoring this? Edited November 29, 2020 by kaj
Luke 42077 Posted November 30, 2020 Posted November 30, 2020 19 hours ago, kaj said: So if I put, in Server - Network - Lan networks a complete junk IP address (I rebooted Emby after this), I can still connect through to Emby, on the local network. It seems as if Emby is ignoring this? Hi, did you read the help text underneath the option?
kaj 316 Posted November 30, 2020 Author Posted November 30, 2020 6 minutes ago, Luke said: Hi, did you read the help text underneath the option? I did. I think it means that all connections, apart from the 193.100.1.1, will be treated as remote connection. But they are not, they are all treated as local connections
Luke 42077 Posted November 30, 2020 Posted November 30, 2020 What you probably want to do instead is configure the proxy so that emby server will see the original ip addresses of the remote connections. Then on the server dashboard activity viewer you'll see the correct ip address for each remote connection.
kaj 316 Posted November 30, 2020 Author Posted November 30, 2020 24 minutes ago, Luke said: What you probably want to do instead is configure the proxy so that emby server will see the original ip addresses of the remote connections. Then on the server dashboard activity viewer you'll see the correct ip address for each remote connection. Thanks Luke. According to the help I asked for on the docker/nginx forums, it's already setup correctly for this. I think I will have to give up I'll try to find why my docker installation is so much quicker than my Synology one. Is there a way to rebuild the database without losing everything?
kaj 316 Posted December 9, 2020 Author Posted December 9, 2020 On 30/11/2020 at 22:26, Luke said: What is rebuild the database? I just vacuumed the database on my non-docker installation (4.2.0.32 - Vacuum database config switch - Emby Server - Emby Community) and now the server is able to stop and restart much much faster, and Searching is now super-speedy too
iBoss 31 Posted May 27, 2022 Posted May 27, 2022 @Luke please I need your support I think I have the same issue here or related. My issue when I use emby with reverse proxy all users connected have seen as local IP. Please see the screenshoot here emby Not Docker (4.7.1.0) Using Docker Nginx Proxy Manager 2.9.18 My config: server { set $forward_scheme http; set $server "172.21.0.1"; set $port 8096; listen 80; listen [::]:80; listen 443 ssl http2; listen [::]:443 ssl http2; server_name subdomain.mydomain.com; # Let's Encrypt SSL include conf.d/include/letsencrypt-acme-challenge.conf; include conf.d/include/ssl-ciphers.conf; ssl_certificate /etc/letsencrypt/live/npm-20/fullchain.pem; ssl_certificate_key /etc/letsencrypt/live/npm-20/privkey.pem; # HSTS (ngx_http_headers_module is required) (63072000 seconds = 2 years) add_header Strict-Transport-Security "max-age=63072000; preload" always; # Force SSL include conf.d/include/force-ssl.conf; access_log /data/logs/proxy-host-14_access.log proxy; error_log /data/logs/proxy-host-14_error.log warn; listen 8096; proxy_buffering off; sendfile off; gzip_disable "msie6"; gzip_comp_level 6; gzip_min_length 1100; gzip_buffers 16 8k; gzip_proxied any; gzip_types text/plain text/css text/js text/xml text/javascript application/javascript application/x-javascript application/json application/xml application/rss+xml image/svg+xml; proxy_connect_timeout 1h; proxy_send_timeout 1h; proxy_read_timeout 1h; location / { proxy_hide_header X-Powered-By; proxy_set_header Range $http_range; proxy_set_header If-Range $http_if_range; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; # Proxy! include conf.d/include/proxy.conf; } # Custom include /data/nginx/custom/server_proxy[.]conf; }
Luke 42077 Posted May 27, 2022 Posted May 27, 2022 3 hours ago, iBoss said: @Luke please I need your support I think I have the same issue here or related. My issue when I use emby with reverse proxy all users connected have seen as local IP. Please see the screenshoot here emby Not Docker (4.7.1.0) Using Docker Nginx Proxy Manager 2.9.18 My config: server { set $forward_scheme http; set $server "172.21.0.1"; set $port 8096; listen 80; listen [::]:80; listen 443 ssl http2; listen [::]:443 ssl http2; server_name subdomain.mydomain.com; # Let's Encrypt SSL include conf.d/include/letsencrypt-acme-challenge.conf; include conf.d/include/ssl-ciphers.conf; ssl_certificate /etc/letsencrypt/live/npm-20/fullchain.pem; ssl_certificate_key /etc/letsencrypt/live/npm-20/privkey.pem; # HSTS (ngx_http_headers_module is required) (63072000 seconds = 2 years) add_header Strict-Transport-Security "max-age=63072000; preload" always; # Force SSL include conf.d/include/force-ssl.conf; access_log /data/logs/proxy-host-14_access.log proxy; error_log /data/logs/proxy-host-14_error.log warn; listen 8096; proxy_buffering off; sendfile off; gzip_disable "msie6"; gzip_comp_level 6; gzip_min_length 1100; gzip_buffers 16 8k; gzip_proxied any; gzip_types text/plain text/css text/js text/xml text/javascript application/javascript application/x-javascript application/json application/xml application/rss+xml image/svg+xml; proxy_connect_timeout 1h; proxy_send_timeout 1h; proxy_read_timeout 1h; location / { proxy_hide_header X-Powered-By; proxy_set_header Range $http_range; proxy_set_header If-Range $http_if_range; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; # Proxy! include conf.d/include/proxy.conf; } # Custom include /data/nginx/custom/server_proxy[.]conf; } Hi, I would suggest comparing your nginx configuration to that of @pir8radio:
iBoss 31 Posted May 27, 2022 Posted May 27, 2022 1 minute ago, Luke said: Hi, I would suggest comparing your nginx configuration to that of @pir8radio: @Luke My config already from him but still all users are connected have seen as local IP
Luke 42077 Posted May 27, 2022 Posted May 27, 2022 Just now, iBoss said: @Luke My config already from him but still all users are connected have seen as local IP The answer to this is specific to your network environment, so I can't really tell just by looking at your config. But maybe you could diff it vs his and show us what the exact differences are.
iBoss 31 Posted May 27, 2022 Posted May 27, 2022 The issue is same as this topic @kaj have you solved this issue? please I need your help. @pir8radio please any idea? Thanks
kaj 316 Posted May 27, 2022 Author Posted May 27, 2022 Hi @iBoss No, i never figured it out....reverse proxies are beyond me... I just stayed with a simple SSL cert and protect my remote connections that way.
pir8radio 1312 Posted May 30, 2022 Posted May 30, 2022 if your config is the same as mine all remote users can not be seen as local. looks like you are using "proxy manager" try the real version of nginx by itself. proxy manager overwrites configs as it sees fit.
iBoss 31 Posted May 31, 2022 Posted May 31, 2022 @pir8radio Many thanks for reply I dont think because only a proxy manager that a local IP appear. I think the issue from Docker Anyway, I'll do the real version of nginx (in Docker) for you to make sure.
pir8radio 1312 Posted June 3, 2022 Posted June 3, 2022 On 5/31/2022 at 1:03 AM, iBoss said: @pir8radio Many thanks for reply I dont think because only a proxy manager that a local IP appear. I think the issue from Docker Anyway, I'll do the real version of nginx (in Docker) for you to make sure. that could be true.. I don't really use docker, but is it setup with a bridged network or nat?
adminExitium 355 Posted June 3, 2022 Posted June 3, 2022 You may also want to check whether docker is using the userland proxy for the traffic or not. With the userland proxy, the source will always be the docker ip irrespective of the network config.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now