1
0
mirror of https://github.com/bpatrik/pigallery2.git synced 2024-12-10 11:10:35 +02:00

fixing preview filling job's logs

This commit is contained in:
Patrik J. Braun 2022-02-06 20:01:37 +01:00
parent 4d7dfca26a
commit 77767f27b0
2 changed files with 3 additions and 2 deletions

View File

@ -9,7 +9,7 @@ services:
volumes:
- "./pigallery2/benchmark_config:/app/data/config" # CHANGE ME
- "db-benchmark-data:/app/data/db"
- "./pigallery2/images:/app/data/images" # CHANGE ME
- "./pigallery2/images:/app/data/images" # CHANGE ME, ':ro' mean read-only
- "./pigallery2/tmp:/app/data/tmp" # CHANGE ME
expose:
- "80"

View File

@ -20,6 +20,7 @@ export class PreviewFillingJob extends Job {
protected async step(): Promise<boolean> {
if (!this.directoryToSetPreview) {
this.Progress.log('Loading Directories to process');
this.directoryToSetPreview = await ObjectManagers.getInstance().PreviewManager.getPartialDirsWithoutPreviews();
this.Progress.Left = this.directoryToSetPreview.length + 2;
return true;
@ -65,7 +66,7 @@ export class PreviewFillingJob extends Job {
return false;
}
const directory = this.directoryToSetPreview.shift();
this.Progress.log('Setting preview: ' + directory.path + '/' + directory.name);
this.Progress.log('Setting preview: ' + directory.path + directory.name);
this.Progress.Left = this.directoryToSetPreview.length;
await ObjectManagers.getInstance().PreviewManager.setAndGetPreviewForDirectory(directory);