๐Ÿ“ท Yet another photo management app for Nextcloud

Overview

Memories

๐Ÿ“ท Yet another photo management app for Nextcloud

Screenshot

How is this different?

  • ๐Ÿ“ธ Photo and Video Timeline: Sorts photos by date taken, parsed from Exif data.
  • ๐Ÿค” Quick Recap: Jump to anywhere in the timeline instantly.
  • ๐Ÿ–ผ๏ธ Folders: Browse your and shared folders with a similar, efficient timeline.
  • ๐ŸŽฆ Slideshow: View photos from your timeline and folders easily.
  • ๐Ÿ“ฑ Mobile Support: Relive your memories on devices of any shape and size through the web app.
  • ๐Ÿ—‘๏ธ Recycle: Select and delete multiple photos and videos at once.
  • โšก๏ธ Fast: Memories is extremely fast. Period. More details below.

๐Ÿš€ Installation

  1. Install the app from the Nextcloud app store
  2. โš’๏ธ Install exiftool (see below).
  3. Run php ./occ memories:index to generate metadata indices for existing photos.
  4. Open the ๐Ÿ“ท Memories app in Nextcloud and set the directory containing your photos. Photos from this directory will be displayed in the timeline, including any photos in nested subdirectories.
  5. Installing the preview generator for pre-generating thumbnails is strongly recommended.

๐Ÿ”จ Installing Dependencies

The exact steps depend on your Nextcloud platform. If you use Docker for your Nextcloud instance, you can install Exiftool by using a custom docker image.

  • Ubuntu/Debian: sudo apt install libimage-exiftool-perl
  • Fedora: sudo dnf install perl-Image-ExifTool
  • Arch Linux: sudo pacman -S perl-image-exiftool
  • Alpine: apk add --no-cache exiftool
  • MacOS: brew install exiftool
  • FreeBSD: sudo pkg install p5-Image-ExifTool

๐Ÿ— Development setup

  1. โ˜ Clone this into your apps folder of your Nextcloud.
  2. ๐Ÿ‘ฉโ€๐Ÿ’ป In a terminal, run the command make dev-setup to install the dependencies.
  3. ๐Ÿ— Then to build the Javascript whenever you make changes, run make build-js. To create a pull request use make build-js-production. Watch changes with: make watch-js.
  4. โœ… Enable the app through the app management of your Nextcloud.
  5. ๐ŸŽ‰ Partytime!

๐Ÿค” Why a separate app?

The approach of this app is fundamentally different from the official Nextcloud Photos app, which is very lightweight and works entirely using webdav. This app instead maintains special metadata in a separate table on the backend, and thus can be considered to have different objectives.

โšก Performance

  • Once properly configured, Memories is extremely fast, possibly one of the fastest web photo viewers.
  • On a server with relatively cheap hardware (Intel Pentium G6400 / 8GB RAM / SSD), loading the timeline takes only ~400ms without cache on a laptop (Intel Core i5-1035G1 / Windows 11 / Chrome) for a library of ~17000 photos totaling 100GB. The test was performed on Nextcloud 24 with nginx, php-fpm and mariadb running in Docker.
  • For best performance, install the preview generator and make sure HTTP/2 is enabled for your Nextcloud instance.

๐Ÿ“ Notes

  • You may need to configure the Nextcloud preview generator and Imagemagick / ffmpeg to support all types of images and videos (e.g. HEIC). If using the official docker image, add OC\Preview\HEIC to enabledPreviewProviders in your config.php.
  • If local time is not found in the photo (especially for videos), the server timezone is used.
  • The app can work with external storage for photos.
    • The photos in the external storage needs to be at the same relative path that is configured for the timeline. For example, if your storage is mounted as /External/ and your photos are in /External/MyPhotos/, then you need to configure the timeline to be MyPhotos/. This will look for MyPhotos/ in all external storages as well as your root home directory, and aggregate these photos.
    • You also need to set up a cron job for the index command if you:
      • Use the same timeline for multiple users.
      • Delete and restore files from the external storage.
    • If you add any photos from outside Nextcloud, you must run the scan and index commands.
    • Indexing may be slow, since all files must be downloaded from the storage. The app currently assumes that the Exif data is present with the first 20MB of each file.
    • This function is experimental and may not work as expected. Please report any issues.

Special Thanks

Nextcloud team. At least one half of the code is based on the work of the Nextcloud Photos.

Comments
  • Syntax Error when enabling Memories app

    Syntax Error when enabling Memories app

    I've followed the installation instructions, but when trying to run the index occ command, I'm getting a syntax error:

    sudo -u www-data php /var/www/nextcloud/occ apps:memories
    An unhandled exception has been thrown:
    ParseError: syntax error, unexpected ')', expecting '|' or variable (T_VARIABLE) in /var/www/nextcloud/apps/memories/lib/Db/TimelineWrite.php:58
    Stack trace:
    #0 /var/www/nextcloud/lib/composer/composer/ClassLoader.php(428): Composer\Autoload\includeFile()
    #1 [internal function]: Composer\Autoload\ClassLoader->loadClass()
    #2 /var/www/nextcloud/apps/memories/lib/Command/Index.php(79): spl_autoload_call()
    #3 [internal function]: OCA\Memories\Command\Index->__construct()
    #4 /var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php(108): ReflectionClass->newInstanceArgs()
    #5 /var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php(116): OC\AppFramework\Utility\SimpleContainer->buildClass()
    #6 /var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php(133): OC\AppFramework\Utility\SimpleContainer->resolve()
    #7 /var/www/nextcloud/lib/private/AppFramework/DependencyInjection/DIContainer.php(465): OC\AppFramework\Utility\SimpleContainer->query()
    #8 /var/www/nextcloud/lib/private/ServerContainer.php(145): OC\AppFramework\DependencyInjection\DIContainer->queryNoFallback()
    #9 /var/www/nextcloud/lib/private/Console/Application.php(217): OC\ServerContainer->query()
    #10 /var/www/nextcloud/lib/private/Console/Application.php(128): OC\Console\Application->loadCommandsFromInfoXml()
    #11 /var/www/nextcloud/console.php(99): OC\Console\Application->loadCommands()
    #12 /var/www/nextcloud/occ(11): require_once('/var/www/nextcl...')
    #13 {main}[email protected]:/var/www/nextcloud/apps#
    

    This syntax error throws an internal server error in nextcloud which prevents all nextcloud access: image

    opened by meichthys 21
  • Error when run memories:index

    Error when run memories:index

    Following error thrown when I tried to run memories:index with www-data

    FATAL: An exception occurred while executing a query: SQLSTATE[42703]: Undefined column: 7 ERROR: column "fileid" does not exist LINE 1: SELECT "fileid", "mtime"

    Running latest Memories, Nextcloud 24.04, PHP 8.1.2, Postgresql 14.4

    opened by aerir 6
  • Possibility to reindex the pictures

    Possibility to reindex the pictures

    Hello, First of all, thanks for your work, the timeline is exactly what I was missing from the stock photo app, memories totally replaced it in my instance.

    I ran into a problem during my tests : the exif dates of some of my files were incorrect, the timeline feature make me realize that. (dates in 2036 something) I changed the dates using exiftool, and tried to re-run the occ memories:index, unfortunately it did not correct the dates in the database.

    ==========================================
    Checked 16025 files in 12.56 sec
    1488 not valid media items
    14537 skipped because unmodified
    0 (re-)processed
    ==========================================
    

    It looks like it did not even tried to re-process the files.

    I had to drop the content of the table and run occ memories:index to have a clean timeline.

    Could a command like occ memories:refresh be a thing ?

    Thanks,

    enhancement 
    opened by ThibautPlg 6
  • Error: Only variables should be passed by reference

    Error: Only variables should be passed by reference

    Hi! Thanks for the app. At least the latest 1.0.7 version throws following errors in the nc log:

    Error: Only variables should be passed by reference at /var/www/html/custom_apps/memories/lib/Controller/PageController.php#58

    Error: Only variables should be passed by reference at /var/www/html/custom_apps/memories/lib/Controller/PageController.php#77

    Error: Only variables should be passed by reference at /var/www/html/custom_apps/memories/lib/Controller/PageController.php#92

    bug 
    opened by teemue 5
  • occ memories:index scanning all files not just photos

    occ memories:index scanning all files not just photos

    Hello,

    nextcloud 24, memories 1.0.7 I've just installed memories on my dietpi nextcloud install. I'm running the following command sudo -u www-data /usr/bin/php -f /var/www/nextcloud/occ memories:index

    It is scanning all files for each user starting with file directory. I use nextcloud for more much than just photos so It would be great if it just started at each //files/Photos and scanned that folder and each subfolder. Can this be done?

    enhancement 
    opened by TheWanderer1983 5
  • Installation on yunohost nextcloud instance : memcache dependencie

    Installation on yunohost nextcloud instance : memcache dependencie

    Hi,

    I try to install but lock on an error

    [email protected]:~# sudo -u nextcloud php /var/www/nextcloud/occ memories:index
    An unhandled exception has been thrown:
    OC\HintException: [0]: Memcache \OC\Memcache\APCu not available for local cache (Is the matching PHP module installed and enabled?)
    
    

    Any other dependencie or configuration missing ? Thanks

    Nextcloud 22.2.10 Memories 1.1.6

    need details 
    opened by wadouk 4
  • Strange sql bug in latest release

    Strange sql bug in latest release

    App: memories: 1.1.4 Nextcloud: 24.0.5 Database: PostgreSQL 14.5 PHP: 8.1.9

    Got strange error in logging while opening the memories app:

    OC\DB\Exceptions\DbalException: An exception occurred while executing a query: SQLSTATE[42803]: Grouping error: 7 ERROR:
    column "f.etag" must appear in the GROUP BY clause or be used in an aggregate function LINE 1:
    SELECT "m"."fileid", "f"."etag", "m"."isvideo", "vco"."categ... ^
    

    Tried full reinstall as in https://github.com/pulsejet/memories/issues/21#issuecomment-1246634724, without any luck

    bug high priority 
    opened by vvrein 3
  • Exception: Could not read exif data

    Exception: Could not read exif data

    The memories:index command crashes after just 1 second with the following error:

    In Exif.php line 174:
                                
      [Exception]               
      Could not read exif data  
                                
    
    Exception trace:
      at /var/www/html/custom_apps/memories/lib/Exif.php:174
     OCA\Memories\Exif::processStdout() at /var/www/html/custom_apps/memories/lib/Exif.php:167
     OCA\Memories\Exif::getExifFromStream() at /var/www/html/custom_apps/memories/lib/Command/Index.php:101
     OCA\Memories\Command\Index->testExif() at /var/www/html/custom_apps/memories/lib/Command/Index.php:119
     OCA\Memories\Command\Index->execute() at /var/www/html/3rdparty/symfony/console/Command/Command.php:255
     Symfony\Component\Console\Command\Command->run() at /var/www/html/3rdparty/symfony/console/Application.php:1009
     Symfony\Component\Console\Application->doRunCommand() at /var/www/html/3rdparty/symfony/console/Application.php:273
     Symfony\Component\Console\Application->doRun() at /var/www/html/3rdparty/symfony/console/Application.php:149
     Symfony\Component\Console\Application->run() at /var/www/html/lib/private/Console/Application.php:211
     OC\Console\Application->run() at /var/www/html/console.php:100
     require_once() at /var/www/html/occ:11
    
    memories:index
    
    
    opened by escoand 3
  • Wrong datetime exif data crashes memories:index command

    Wrong datetime exif data crashes memories:index command

    
    TypeError: DateTime::createFromFormat(): Argument #2 ($datetime) must be of type string, int given in /config/www/nextcloud/apps/memories/lib/Exif.php:192
    Stack trace:
    #0 /config/www/nextcloud/apps/memories/lib/Exif.php(192): DateTime::createFromFormat()
    #1 /config/www/nextcloud/apps/memories/lib/Db/TimelineWrite.php(62): OCA\Memories\Exif::getDateTaken()
    #2 /config/www/nextcloud/apps/memories/lib/Command/Index.php(185): OCA\Memories\Db\TimelineWrite->processFile()
    #3 /config/www/nextcloud/apps/memories/lib/Command/Index.php(173): OCA\Memories\Command\Index->parseFile()
    #4 /config/www/nextcloud/apps/memories/lib/Command/Index.php(171): OCA\Memories\Command\Index->parseFolder()
    #5 /config/www/nextcloud/apps/memories/lib/Command/Index.php(171): OCA\Memories\Command\Index->parseFolder()
    #6 /config/www/nextcloud/apps/memories/lib/Command/Index.php(159): OCA\Memories\Command\Index->parseFolder()
    #7 /config/www/nextcloud/apps/memories/lib/Command/Index.php(134): OCA\Memories\Command\Index->generateUserEntries()
    #8 /config/www/nextcloud/lib/private/User/Manager.php(656): OCA\Memories\Command\Index->OCA\Memories\Command\{closure}()
    #9 /config/www/nextcloud/apps/memories/lib/Command/Index.php(135): OC\User\Manager->callForSeenUsers()
    #10 /config/www/nextcloud/3rdparty/symfony/console/Command/Command.php(255): OCA\Memories\Command\Index->execute()
    #11 /config/www/nextcloud/3rdparty/symfony/console/Application.php(1009): Symfony\Component\Console\Command\Command->run()
    #12 /config/www/nextcloud/3rdparty/symfony/console/Application.php(273): Symfony\Component\Console\Application->doRunCommand()
    #13 /config/www/nextcloud/3rdparty/symfony/console/Application.php(149): Symfony\Component\Console\Application->doRun()
    #14 /config/www/nextcloud/lib/private/Console/Application.php(211): Symfony\Component\Console\Application->run()
    #15 /config/www/nextcloud/console.php(100): OC\Console\Application->run()
    
    

    Maybe using a dafault value (0/0/00) can be used to handle the exception if possible?

    Or possibly log the path of the offending picture to manually fix it

    Currently using linuxsever.io's docker container

    opened by d1c0n 3
  • Scanning stalls every time on specific folder

    Scanning stalls every time on specific folder

    When running memories:index or memories:index --clear, the process stalls every time it's run and always on the same folder:

    ...
    Scanning folder /admin/files/Phone/Photos/2021/12
    Scanning folder /admin/files/Phone/Photos/2022
    Scanning folder /admin/files/Phone/Photos/2022/01
    

    Only a few folders remain unindexed:

    ls -l data/admin/files/Phone/Photos/2022
    total 36
    drwxr-xr-x 4 www-data www-data 4096 2022-02-26 16:31 01/
    drwxr-xr-x 4 www-data www-data 4096 2022-02-28 20:16 02/
    ...
    drwxr-xr-x 4 www-data www-data 4096 2022-09-13 18:37 09/
    

    7442 records in oc_memories.

    Setting log:manage --level 0 shows no relevant messages in the logs.

    NextCloud 24.0.5 PHP 7.4.3 (fpm) Ubuntu 20.04 Memories 1.1.4

    If further info needed, just ask. Thanks.

    bug 
    opened by RonaldBarnes 2
  • Spaces in Timeline Path

    Spaces in Timeline Path

    It appears when the 'Timeline Path' specified includes spaces, no images are displayed. If the given path does not include spaces, it has no issues displaying images, including subfolders which have spaces.

    Unfortunately my parent folder has spaces in the path, so I am unable to display any media in the Memories app.

    I have attempted to add ' and " surrounding the path, however it did not work. Let me know if there is any more information I can provide to help troubleshoot if needed.

    Ubuntu 22.04.1 LTS Memories 1.1.4 NC 24.0.5 PHP 7.4.30

    bug duplicate 
    opened by Civlac 2
  • Foo and Foobar folder are both displayed in the

    Foo and Foobar folder are both displayed in the "Foo" Timeline

    I tested this only in Nextcloud normal storage and not External Storage to not create additionnal headaches.

    Steps:

    • Create a folder named Foo
    • Create a FooBar folder
    • Put some pictures in both
    • Index
    • set "Foo" in the Timeline setting

    Result :

    • Pictures of Foo and FooBar are displayed in the Timeline

    Additionnal information:

    • Set Timeline folder as"Fo" --> Pictures of Foo and Foobar are still displayed.
    bug 
    opened by Aquariu 2
  • [Folders view] Add browsable path tree like NC Files

    [Folders view] Add browsable path tree like NC Files

    Hi there :)

    In the Folders view it seems you can't currently go back to the parent folder (no "back" button).

    I can with the buttons of my mouse, but it would be great it the view was similar to NC Files, or have a "back" button.

    enhancement 
    opened by TtuxX 0
  • l10n: Singular and plural

    l10n: Singular and plural

    Add singular and plural for the following text string: https://github.com/pulsejet/memories/blob/704eda1d2d066efc55a0ad108ec0c1b46c93edfa/src/components/Timeline.vue#L86

    bug 
    opened by Valdnet 3
  • Group folders

    Group folders

    I've all my photos in a group folder shared for every user. This share is "mounted" as Bilder in my user account. I can also see the got scanned as /<myname>/files/Bilder/.... In the filesystem they reside in .../nextcloud/data/__groupfolders/1/.... But what is the correct parameter to show all these files in the UI?

    bug high priority 
    opened by escoand 3
  • Please install exiftool (at least v12) and make sure it is in the PATH

    Please install exiftool (at least v12) and make sure it is in the PATH

    I'm getting this error when I launch occ memories:index

    Running Nextcloud on Docker macos (Macmini M1)

    I did run:

    brew install exiftool

    WARN: Failed to create stay_open exiftool process Exiftool timeout for file stream: Could not read exif data Couldn't read Exif data from test file: Could not read from Exiftool FATAL: exiftool could not be found or test failed Please install exiftool (at least v12) and make sure it is in the PATH

    opened by smailpouri 6
Releases(v1.1.6)
Owner
Varun Patil
UCLA CS PhD Candidate
Varun Patil
Yet another Value Object Library (YAVOL)

Yet Another DDD Library Value object This library is a foundation in order to implement the Value Object pattern. It helps you to introduce some DDD s

YADDDL 2 Jan 4, 2022
Jump is yet another self-hosted startpage for your server designed to be simple, stylish, fast and secure.

Jump Jump is yet another self-hosted startpage for your server designed to be simple, stylish, fast and secure. Features Fast, easy to deploy, secure

Dale Davies 273 Sep 21, 2022
๐Ÿ”– Bookmark app for Nextcloud

Nextcloud Bookmarks Bookmarks app for Nextcloud This app provides you with a web interface for collecting and organizing bookmarks to the places on th

Nextcloud 768 Sep 19, 2022
Nextcloud app to do preview generation

Preview Generator Nextcloud app that allows admins to pre-generate previews. The app listens to edit events and stores this information. Once a cron j

Nextcloud 314 Sep 14, 2022
Game Boy Camera Wifi Photo Extractor

Game Boy Camera Fast Wifi Adapter Plug in your Game Boy Camera, turn it on, and you can have the photos on your phone in under 2 minutes! Why I Made I

Matt G 70 Jul 20, 2022
Resources back-end for the Nextcloud CalDAV server

Calendar Resource Management This app enables the ??๏ธ Calendar App to work with resources and rooms Installation Place this app in nextcloud/apps/ You

Nextcloud 31 Sep 12, 2022
A plugin to make Nextcloud compatible with Solid

solid-nextcloud A plugin to make Nextcloud compatible with Solid.

PDS Interop 49 Aug 19, 2022
โ†ช๏ธ๐Ÿ”” Send notification action for Nextcloud Flow

Nextcloud Flow Notifications ?? Notification action for Nextcloud Flow ?? Configure your flow ?? Receive notifications ?? Development setup โ˜ Clone th

Nextcloud 11 Jul 13, 2022
Orangescrum is a simple yet powerful free and open source project management software that helps team to organize their tasks, projects and deliver more.

Free, open source Project Management software Introduction Orangescrum is the simple yet powerful free and open source project management software tha

Orangescrum 88 Sep 17, 2022
From the team that brought you laravel-random-command comes another gem!

?? Why require one if you can require them all? From the team that brought you laravel-random-command comes another gem! Requiring all our packages se

Spatie 45 Jul 18, 2022
A PocketMine-MP plugin that replaces a block to another block when breaks, then back to the original block after a certain time

BlockReplacer A PocketMine-MP plugin that replaces a block to another block when breaks, then back to the original block after a certain time How to I

AIPTU 11 Sep 2, 2022
Magento commands to find translations that are present in one CSV file but not in another, and to translate CSV dicts with DeepL

Hyvรค Themes - Magento translation CSV comparison command hyva-themes/magento2-i18n-csv-diff This module adds the bin/magento i18n:diff-csv and i18n:tr

Hyvรค 5 Apr 7, 2022
Another initiative where patient in need of Blood and recovered patients willing to donate Blood can come together under one platform and connect with each other.

This is yet another initiative where patient in need of Blood and recovered patients willing to donate Blood can come together under one platform and connect with each other.

Rohit Tiwari 1 May 5, 2022
A PHP wrapper around Libreoffice for converting documents from one format to another.

Document Converter A PHP wrapper around Libreoffice for converting documents from one format to another. For example: Microsoft Word to PDF OpenOffice

Lukas White 0 Jul 28, 2022
API plugin to open a dialog for choosing another player.

ChoosePlayer API plugin for choosing a player interactively. API Let player select another player This API method opens a dialog to let player $choose

Jonathan Chan Kwan Yin 4 Aug 16, 2022
A Tinder-like experience for Plex Watchlist: swipe and match with another person and find the movie you're gonna watch tonight.

Plex Finder This app's goal is to help choose a film to watch when neither you nor your SO/friend/roommate/whatever is any good at choosing anything.

Guillaume Hartemann-Piollet 3 Aug 13, 2022
Easy management of Virtualization technologies including KVM, Xen, OpenVZ, Virtuozzo, and LXC/LXD including unified commands, monitoring, template management, and many more features.

ProVirted About Easy management of Virtualization technologies including KVM, Xen, OpenVZ, Virtuozzo, and LXC/LXD including unified commands, monitori

null 2 Aug 22, 2022
Get mobile app version and other related data from Google Play Store, Apple App Store and Huawei AppGallery

Mobile App Version Get mobile app version and other related data from Google Play Store, Apple App Store and Huawei AppGallery. Installation Add to co

Omer Salaj 11 Mar 15, 2022
This is an example app demonstrating how to deploy a php app to runway.

Runway Example php App This is an example app demonstrating how to deploy a php app to runway. clone this repo, and navigate into that directory runwa

Planetary Quantum GmbH 0 Aug 9, 2022