Protocol error can’t connect to server

Hello, i’ve installed nextcloud 14.0 on a frenas machine, using this script ( with no SSL, since it’s being handled by a nginx reverse proxy. I can connect to the server from windows without any issue and via iOS locally. If i use the domain i set up, i cannot connect with iOS (app, safari or firefox)

A few infos about what i’m using:

-Nextcloud 14.0.0 (running on Apache)
-FreeNas 11.1-u6
-Nginx as reverse proxy

server {
listen 80;
#listen [::]:80;
return 301$request_uri;

server {
    listen       443 ssl;
    ssl on;
    ssl_certificate /etc/letsencrypt/live/;
    ssl_certificate_key /etc/letsencrypt/live/;
    #include ssl_common.conf;

    client_max_body_size 0;

    ssl_session_cache shared:SSL:10m;

    location / {

Apache YOUR_FQDN.conf
DocumentRoot “/usr/local/www/apache24/data/nextcloud”
RewriteEngine On
RewriteCond %{HTTP:Authorization} ^(.)
RewriteRule .
<FilesMatch .php$>
SetHandler “proxy:fcgi://localhost:9000”

DirectoryIndex /index.php index.php
<Directory /usr/local/www/apache24/data/nextcloud>
AllowOverride all

Let me know if i can provide anything else to help troubleshoot this.

Thanks in advance for any help.