I have Nextcloud 27 installed from docker, on my Linux VM. The Photos app installed is the default one that comes with the installation, specifically at version 2.3.0.
I have a bunch of photos that I took on my android phone, all of them JPGs of 3264x2448 size.
I uploaded the files onto Nextcloud and they appear completely visible to my installation. I can even open the photos in the Photos app and view them at their native size.
My only issue is that there are no previews generated when I’m looking at all the photos in the overview screen (see attached image). The previews are missing and all I see are monochromatic squares with empty checkboxes in the corner, instead of actual previews.
Also attached you can find a screenshot of a Javascript error that I am seeing, something about an “DOMException: The operation is insecure.” error that I keep seeing in my browser.
My nextcloud instance is secured by HTTPS, so I don’t know why it claims it’s insecure.
I’m using Firefox 114.0 (64-bit), if it has any relevance. When browsing the same web page from Google Chrome, the previews seem to generate naturally and without any issues, so I don’t think that this is a server-side issue.
If you click on the arrow-ish thing to the left of the DOMException in Firefox does it provide more info? Usually (in Chrome at least) I think there’s more info so you can get a better idea of the trigger.
Even I am using Nextcloud Hub 5 (27.0.0.8). And tried what not. Gone through the rabbit hole of previewGeneration App. Generated preview files, changed the ownership of those files to www-data user. And what not. I am running in an LAN insecure mode(http). Restarted docker instance of nextcloud numerous times. No result . While I can also see the previews in Files tab but not photos tab… this should be such an obvious issue with a solution in the community. I don’t know what direction to work.
My problem was kinda solved. I use http because I don’t want to use ssl certification services, I don’t even have my own domain. If I open nextcloud via https then everything works and previews are shown, if I open via http then there is no previews. This is somehow related to the cache, I have not yet figured out how to fix it.
In memories and files apps previews are working just fine.
Cause does seem seem to be to the PreviewService.js, getting a ton of errors there
This only happens in Firefox (115.0.2, Win10); Google Chrome is loading the same page just fine. I have tried relaxing Firefox’s safe browsing setting from strict to standard, deactivated ublock and ClearURLs plugins, but no difference.
I also installed the preview app and tried to generate the previews in the beginning by let nextcloud 27.0.1 create them on my to small server with only 1GiB RAM. That took on ~1100 photos one to two days. Then I managed to optimize the server with redis, APCu/OPcache and using my home pc with a nextcloud/aio-imaginary docker container behind a 100k down/40k up line. Even that took half of an hour up to an hour to create all the previews. My PC got quite a load with it. Intel Core i5-3475S with 16GiB RAM.
To generate all the Previews from 3.5GiB Photos took 3h and collected 3,8GiB under /var/www/vhosts/mydomain.de/.nextcloud/data/77c1cfa7461b/appdata_ocbnm8xcv5a4/preview
But also with that preview cache the Photo App looses the previews and if they are beeing created I think it does NOT use the previews, because on my PC imaginary starts to POST them with such lines in the logs. And maybe the next hour or the next day nextcloud tries to recreate the previews from picture 000.1.jpg up to 1100.jpg again. I think it’s only the Browsers Cache on local client side which speeds it sometimes up. But if the browser gets rid of the cached previews, imaginary is at work again on the same set of photos in the album.
So I thought on using imaginary on the same server to shut down my home PC, but in this scenario that would not work, because the load would be too high with the unused previews, or what it’s causing the recreation of the previews.
Server and Home PC are using ubuntu 22.04 and php 8.2.8 (server, cli, php-fpm) and Alpine Linux v3.18 in the docker container with the current imaginary dev version.
I strongly suggest to use the App “Memories” instead. It detects the created albums in “Photos” and so it does with the generated previews. also it sorts by creation date extracted from the exif header of the photos (if available and not stripped). So it does show the photos chronologically and way smoother and fluently. The previews are all there. On my small server there are sometimes also hiccups with “memories”, but a simple reload of the page in the Browser (CRTL+R) does bring it back on the right track.
Hopefully the developer of “Photos” some day will overcome all those issues with their app too.
Apparently the issue is only reproducible on my latest Fedora Linux 38 KDE spin release. Firefox on macOS, at least, seems to generate the previews without any issues.
Just wanted to let you guys know that this could be related to that
Turns out this is a browser issue for me. On my primary laptop where I still run Debian 11 with Firefox 102 the issue is present. But when I installed latest available Firefox 117 the issue is gone.
Still the same issue on 27.1.2 on docker compose 24.0.6 on Rocky Linux 9.2 in all browsers. Look blelove… only on Directorys menu previews are displayed…