From 0d4f060e9489e886c55cf681424f10ac780f3346 Mon Sep 17 00:00:00 2001 From: decentral1se Date: Wed, 3 Aug 2022 11:50:15 +0300 Subject: [PATCH] add note on previewgenerator --- README.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/README.md b/README.md index f00e4d8..f40fcca 100644 --- a/README.md +++ b/README.md @@ -166,3 +166,25 @@ Here is an example CSS config which hides the local login and makes space for a [nextcloud-docker]: https://hub.docker.com/_/nextcloud/ [`abra`]: https://git.autonomic.zone/autonomic-cooperative/abra [`coop-cloud/traefik`]: https://git.autonomic.zone/coop-cloud/traefik + +## Using [`previewgenerator`](https://github.com/nextcloud/previewgenerator) app + +After you install, enable etc. then you need to run the generation (**warning**: it can take a long time!): + +``` +abra app run app bash -u www-data +./occ preview:generate-all +``` + +To set up the cron to run again, there is [no clear solution in the context of +containers](https://github.com/nextcloud/previewgenerator/issues/1). So, a +pretty dodgy hack is to run it from the system directly: + +``` +root@foo.com /etc/cron.hourly $ cat foo-com-preview-generate +#!/bin/bash + +docker exec -u www-data $(docker ps -f name=foo_com__app -q) ./occ preview:pre-generate +``` + +This app will improve performance of image browsing at the cost of storage space.