Error 500 when loading previews in Files app

Nextcloud version (eg, 29.0.5): Nextcloud Hub 8 (29.0.6)
Operating system and version (eg, Ubuntu 24.04): Ubuntu 22.04.4
Apache or nginx version (eg, Apache 2.4.25): Docker using Apache, I'm using Nginx for proxy
PHP version (eg, 8.3): 8.3

The issue you are facing:
Image previews (thumbnails) are not loading in the Files app. Getting error “500 (Internal Server Error)” in the browser console when loading the page. If you click the photo, it loads fine.

Is this the first time you’ve seen this error? (Y/N): Y

The output of your Nextcloud log in Admin > Logging:

Irrelevant alerts

The output of your config.php file in /path/to/nextcloud (make sure you remove any identifiable information!):

https://gist.github.com/purejosh/c27230cc3695e6b6e38a324b010f1835

The output of your Apache/nginx/system log in /var/log/____:

No relevant information in the Nginx (proxy) logs. Unsure how to access docker container's apache logs. 

Output errors in nextcloud.log in /var/www/ or as admin user in top right menu, filtering for errors. Use a pastebin service if necessary.

No errors in logs that are related to this issue.

Output errors in chrome’s browser console.

GET https://cloud.purehosted.net/core/preview?fileId=1446&x=32&y=32&mimeFallback=true&a=0 500 (Internal Server Error)

I know I’m not providing much, but unfortunately, I’m not being provided much by my system. Or, at least, I’m not experienced enough to find the traces. I would really appreciate some assistance.

I’ve found the issue. It was the antivirus app. I had it installed, but not configured, and that was preventing thumbnails and previews from working.