Proxy is not configured properly

I’ve just finished installing Nextcloud Docker AIO. By far the easiest install process I’ve done yet. I’m getting the error

Your remote address was identified as “MY.WAN.IP.ADDR” and is bruteforce throttled at the moment slowing down the performance of various requests. If the remote address is not your address this can be an indication that a proxy is not configured correctly. Further information can be found in the documentation :arrow_upper_right:.

The way I have this setup is as follows:
Internet -> [pfsense -> HAProxy] -> [Ubuntu 22.04 VM -> Apache2.4 -> Nextcloud Docker]

pfSense and HAProxy handle the certs and encryption. This makes propping up new subdomains relatively painless.

I suspect the issue is with my Apache config:


<VirtualHost *:80>
    ServerAdmin **PRIVATE**
    ServerName **PRIVATE**

    RewriteEngine On
    RewriteCond %{HTTPS} off
    RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}
    RewriteCond %{SERVER_NAME} =**PRIVATE**
    RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]

<VirtualHost *:443>
    ServerAdmin **PRIVATE**
    ServerName **PRIVATE**

    RewriteEngine On
    ProxyPreserveHost On
    AllowEncodedSlashes NoDecode

    ProxyPass / nocanon
    ProxyPassReverse /

    RewriteCond %{HTTP:Upgrade} websocket [NC]
    RewriteCond %{HTTP:Connection} upgrade [NC]
    RewriteCond %{THE_REQUEST} "^[a-zA-Z]+ /(.*) HTTP/\d+(\.\d+)?$"
    RewriteRule .? "ws://localhost:11000/%1" [P,L]

    Protocols h2 h2c http/1.1

    H2WindowSize 5242880

    TraceEnable off
    <Files ".ht*">
        Require all denied

     # I've added this because I've had to use it in the past, so my thought was this would fix the issue. 
    <IfModule mod_headers.c>
        Header always set Strict-Transport-Security "max-age=15552000' includeSubDomains"
        Header always set Referrer-Policy "no-referrer"

    LimitRequestBody 0


  'trusted_domains' =>
  array (
    0 => '',
    1 => '',
    2 => '',
  'trusted_proxies' => 
  array (
    0 => '',
    1 => '::1',
    2 => '',

Let me know if there’s anything else that would be helpful for debugging this issue.

Solved by adjusting my run command:

sudo docker run \
 --init \
 --sig-proxy=false \
 --name nextcloud-aio-mastercontainer \
 --restart always \
 --publish 8080:8080 \
 --env APACHE_PORT=11000 \
 --env APACHE_IP_BINDING= \ ## <== Changed from to
 --volume nextcloud_aio_mastercontainer:/mnt/docker-aio-config \
 --volume /var/run/docker.sock:/var/run/docker.sock:ro \
 --env NEXTCLOUD_DATADIR="/opt/nextcloud-data" \