Logo Not Showing in Nextcloud Notifications

This was working earlier, and then changed, either as a result of something I did or an update in the software. Not sure which. The screen snip below shows the issue:

MY SYSTEM:
Ubuntu 22.04 fully upgraded
Apache latest stable
Php latest stable
MariaDB latest stable
I run Fail2Ban, but it’s configs and version are the same since before this issue.

In the browser console it reports:
proxy:1 GET https://cloud.EXAMPLE.com/apps/mail/proxy?src=https%3A%2F%2Fcloud.EXAMPLE.com%2Fcore%2Fimg%2Flogo%2Flogo.png%3Fv%3D5&requesttoken=e16PpUcl3Lii+axHGuZepVYa3DX/C9b4 500 (Internal Server Error)

and under networking it reports:
GENERAL:
Request URL: https://cloud.EXAMPLE.com/apps/mail/proxy?src=https%3A%2F%2Fcloud.EXAMPLE.com%2Fapps%2Fdeck%2Fimg%2Fdeck-dark.svg&requesttoken=e16PpUcl3Lii+axHGuZepVYa3DX/C9b4
Request Method: GET
Status Code: 500 Internal Server Error
Remote Address: 64.24.41.101:443
Referrer Policy: no-referrer
RESPONSE HEADERS
Cache-Control: no-store, no-cache, must-revalidate
Connection: close
Content-Length: 4004
Content-Security-Policy: default-src ‘self’; script-src ‘self’ ‘nonce-SFB0Szl5MURPOFVKejZRVTkzeHZrNmt1ZXo1aGxxc2ZuVE54ZzlnMGVUcz06ZWNwOHAxMFdXS2s2ZzgxOTNCMFgyKzViSVZzUndQSitybmNwckpzTkd3OD0=’; style-src ‘self’ ‘unsafe-inline’; frame-src *; img-src * data: blob:; font-src ‘self’ data:; media-src *; connect-src *; object-src ‘none’; base-uri ‘self’;
Content-Type: text/html; charset=UTF-8
Date: Tue, 12 Jul 2022 20:16:28 GMT
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Pragma: no-cache
Referrer-Policy: no-referrer
Server: Apache/2.4.52 (Ubuntu)
Strict-Transport-Security: max-age=15552000; includeSubDomains
X-Content-Type-Options: nosniff
X-Frame-Options: SAMEORIGIN
X-Permitted-Cross-Domain-Policies: none
X-Robots-Tag: none
X-XSS-Protection: 1; mode=block

I have the following relevant configurations.
In config/config.php:

<?php $CONFIG = array ( 'instanceid' => 'some instance id', 'passwordsalt' => 'some salt', 'secret' => 'some secret', 'trusted_domains' => array ( 0 => 'localhost', 1 => 'cloud.example.com', # I have the actual top level domain here. ), 'datadirectory' => '/var/www/nextcloud/data', 'dbtype' => 'mysql', 'version' => '24.0.2.1', 'overwrite.cli.url' => 'https://cloud.EXAMPLE.com/', # I have the actual top level domain here. 'dbname' => 'databasename', 'dbhost' => 'localhost', 'dbport' => '', 'dbtableprefix' => 'oc_', 'mysql.utf8mb4' => true, 'dbuser' => 'databaseuser', 'dbpassword' => 'password', 'installed' => true, 'htaccess.RewriteBase' => '/', 'default_phone_region' => 'US', 'memcache.local' => '\\OC\\Memcache\\APCu', 'memcache.distributed' => '\\OC\\Memcache\\Redis', 'redis' => array ( 'host' => '/var/run/redis/redis-server.sock', 'port' => 0, ), 'memcache.locking' => '\\OC\\Memcache\\Redis', 'maintenance' => false, 'logfile' => '/var/www/nextcloud/data/nextcloud.log', 'loglevel' => 2, 'logtimezone' => 'America/New_York', 'mail_smtpmode' => 'smtp', 'mail_smtpsecure' => 'tls', 'mail_sendmailmode' => 'smtp', 'mail_from_address' => 'cloud', 'mail_domain' => 'zoovs.com', 'mail_smtpauthtype' => 'LOGIN', 'mail_smtpauth' => 1, 'mail_smtphost' => 'mail.EXAMPLE.com', 'mail_smtpport' => '587', 'mail_smtpname' => 'cloud@EXAMPLE.com', 'mail_smtppassword' => 'Password', 'app_install_overwrite' => array ( 0 => 'files_reader', 1 => 'mindmap_app', 2 => 'richdocumentscode', ), 'ncd_yt_binary' => '/usr/local/bin/youtube-dl', 'ncd_aria2_binary' => '/usr/bin/aria2c', 'music.lastfm_api_key' => 'Secret Key', 'theme' => '', ); In my /etc/hosts file I have: # have have real tld instead of EXAMPLE 127.0.0.1 mail.EXAMPLE.com cloud.EXAMPLE.com collabora.EXAMPLE.com localhost # have real hostname instead of hostname 127.0.1.1 hostname # The following lines are desirable for IPv6 capable hosts ::1 ip6-localhost ip6-loopback fe00::0 ip6-localnet ff00::0 ip6-mcastprefix ff02::1 ip6-allnodes ff02::2 ip6-allrouters Finally my apache2 config file is: #!/bin/sh DocumentRoot /var/www/nextcloud/ ServerName cloud.EXAMPLE.com Require all granted AllowOverride All Options FollowSymLinks MultiViews Satisfy Any Dav off ErrorLog ${APACHE_LOG_DIR}/error.log CustomLog ${APACHE_LOG_DIR}/access.log combined RewriteEngine on RewriteCond %{SERVER_NAME} =cloud.EXAMPLE.com RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent] Also, mod rewrite for Apache is turned on and enabled. I feel like this problem has something to do with proxy rewrites and maybe the presence of cloud.EXAMPLE.com and mail.EXAMPLE.com in my /etc/hosts files. However, I am not confident of how to go about trying to determine the source of the problem. Any helpful suggestions are appreciated.

Okay, so I took cloud.EXAMPLE.com out of my /etc/hosts file and that restored the logo image in the notification, however, as I expected it broke the ability connect through Nextcloud Office to the Collabora instance I am running on the same server due to some XSS issues. I guess I will just be fine with the missing image until I learn more about these configurations.