Remote addresses in log are all docker gateway

I am using the latest docker image from dockerhub (apache2 version), running on my Raspberry Pi 4B. Recently, when I launched my Nextcloud APP and Photos APP I found there were a lot of warnings in the nextcloud.log as follows:

My server runs like:

I am very confused about how to show real IP from frpc. It does’t look like a frp error, because my Jellyfin are running in almost the same way and it could show the correct IP. Please help me :sob:

I try to use frpc to connect my cloud server, and my frpc.ini is as follows:

type = http
local_port = 8080
subdomain = cloud

As for the cloud server side, frps.ini is as follows:

bind_port = 2956
vhost_http_port = 7080
vhost_https_port = 7443
subdomain_host = xxxxxxx

and nginx.conf:

server {
        listen       443 ssl;
        ssl_certificate      /usr/local/nginx/cert/.pem;
        ssl_certificate_key  /usr/local/nginx/cert/.key;
        ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
        ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:HIGH:!aNULL:!MD5:!RC4:!DHE;
        ssl_session_cache    shared:SSL:1m;
        ssl_session_timeout  5m;

        #ssl_ciphers  HIGH:!aNULL:!MD5;
        ssl_prefer_server_ciphers  on;
        location / {
            #root   html;
            #index  index.html index.htm;
            add_header Strict-Transport-Security "max-age=15768000; includeSubDomains; preload;" always;
            proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
            proxy_set_header Host $http_host;
            proxy_set_header X-NginX-Proxy true;
            proxy_http_version 1.1;
            proxy_set_header Upgrade $http_upgrade;
            proxy_set_header Connection "upgrade";
            proxy_max_temp_file_size 0;
            proxy_redirect off;
            proxy_read_timeout 240s;

My docker gateway is, all of the remote addresses in my nextcloud log are that. I suspect maybe the default Apache config is wrong. But I have no idea where the config is either how to fix that. :sob:

welcome to the forum @IndigoFloyd :handshake:

Please review you have all required reverse proxy settings in place. Newer Docker images should have the fix built-in already but definitely worth following Apache Docker behind reverse proxy


Thank you for your kindly help. I tried to reset my Nginx config, and the wrong IP in the log somehow changed to . Then I appended it to the trusted_proxies array. Surprisingly I found it worked, and I thought maybe I have handled this problem. :yum:

if your Nginx runs on the same system this is expected and the setting you applied is right for reverseproxy on the same system as Nextcloud (localhost)