Nextcloud and NGINX reverse proxy

Hi everyone, first time posting. I seem to be having some trouble with accessing my nextcloud instance off network.
My nextcloud instance runs on my TrueNAS machine and is accessible via local ip when on network.
I have a second machine running my nginx among other things. I found some virtual host configs for nginx/nextcloud and have them loaded (See below for nginx config).

I have also configured config.php on nextcloud to accept my domain, nginx ip, and the nextcloud instance ip to be trusted.

However, I keep running into too many redirects and nextcloud is unreachable via the reverse proxy.
I know that the nginx installation on TrueNAS also includes nginx, is there any config needed for that?

Any help is appreciated!

server {
	listen 80 default_server;
	listen [::]:80 default_server;
	server_name _;
	return 301 https://$host$request_uri;
server {
	listen 443 ssl;
	listen [::]:443 ssl;
	server_name nextcloud.***.***;

	access_log /var/log/nginx/nextcloud.***.***/access_log;
    	error_log /var/log/nginx/nextcloud.***.***/error_log;

	client_max_body_size 50;
	##underscores_in_headers on;

	ssl on;
	ssl_certificate /etc/letsencrypt/live/***.***/fullchain.pem;
	ssl_certificate_key /etc/letsencrypt/live/***.***/privkey.pem;

	ssl_stapling on;
	ssl_stapling_verify on;

	location / {
		proxy_headers_hash_max_size 512;
		proxy_headers_hash_bucket_size 64;
		proxy_set_header Host $host;
		proxy_set_header X-Forwarded-Proto $scheme;
		proxy_set_header X-Real-IP $remote_addr;
		proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;

		add_header Front-End-Https on;
	location /.well-known/carddav {
    	return 301 $scheme://$host/remote.php/dav;

	location /.well-known/caldav {
    	return 301 $scheme://$host/remote.php/dav;