Photo Management with Lychee
When I first build my NAS one of the first things I did was create an SMB share for photos and migrate all of the family photos from their various hard drives, SD cards and misc locations.
In had initially planned to organise and sort all of the photos, but very quickly the share became full of duplicates and misc folders with no organisation in sight. The other problem was accessibility. While a network share worked for me, it wasn’t really ideal for the less technically inclined in my family.
To this end I decided that I really needed a web frontend and after spending some time googling I stumbled across Lychee.
Lychee is a free photo-management tool, which runs on your server or web-space. Installing is a matter of seconds. Upload, manage and share photos like from a native application. Lychee comes with everything you need and all your photos are stored securely.
To host Lychee I created a new Ubuntu 16.04 LXC container in Proxmox and to start assigned it 1vCPU, 512MB of RAM and 50GB of disk space.
The Lychee installation instructions here only deal with the installation of Lychee itself, although all that is required for Lychee to run is PHP5 or later, a web server and MySQL.
I installed Nginx, MySQL and PHP7 with the required extensions:
sudo apt-get install mysql-{server,client} nginx php-{fpm,sql,imagick} php7.0-{gd,zip,mbstring} imagemagick git
In /etc/php/7.0/fpm/php.ini
I set the following options:
I then ran mysql_secure_installation
to secure my MySQL installation then created a new SQL service account and database for Lychee.
I then created a new Nginx site: sudo vim /etc/nginx/sites-available/lychee
And enabled it: sudo ln -s /etc/nginx/sites-{available,enabled}/lychee
I then pulled the latest release of Lychee and set the required permissions: (I strongly dislike 777 permissions and have since adjusted these to more appropriate values).
I then restarted the required services:
And checked for the presence of the required PHP extensions:
After configuring DNS I was then able to navigate to the URL of my new Lychee installation to do the initial configuration and start uploading.
I have now been using Lychee for several months and it hasn’t had any problems.
The upgrade procedure is also very simple:
All in all I’m very happy with Lychee. There are quite a few available plugins which I have yet to explore and dropbox sync is also a feature that I need to look into.
However, for the time being I’m busy uploading and sorting all my photos.