Export and share photos with digiKam
Exporting Photos to Remote Hosts
The KioExportImport plugin allows digiKam to access files, websites, and remote hosts using KDE's KIO library (Figure 4). In practical terms, this plugin can be used to export photos directly from digiKam to remote machines via supported protocols (FISH, FTP, SFTP, SMB, and many others). This functionality can come in handy not only for off-site backup but also for publishing photos with web applications that are not directly supported by digiKam.
For example, if you happen to use Mejiro [2], cobbled together by yours truly, you can use the KioExportImport plugin to upload photos to the application. To do this, select the photos you want to upload and choose Export | Export to remote computer (Figure 4). Enter the URL to the remote destination directory, which should look something like the following (replace 127.0.0.1 with the actual domain name or IP address of the machine running Mejiro):
fish://127.0.0.1/var/www/mejiro/photos
To transfer the selected photos now, hit the Start export button.
digikamWebUi
As a desktop application, digiKam doesn't provide functionality for accessing the entire photo library via the web. The digikamWebUi [3] software fills this void by adding a web interface that allows you to view and manage photos in digiKam albums using nothing but a browser.
Although digikamWebUi is easy to use, deploying the application requires some manual work. The following installation instructions assume that you're deploying digikamWebUi on the same machine running digiKam, where all photos and digiKam databases are stored in the /home/user/photos
directory. The machine itself runs Debian or Ubuntu (or any of their derivatives).
digikamWebUi runs on the Apache/PHP/SQLite stack, so the first step is to install the required components:
sudo install apache2 php5 php5-sqlite sqlite3 git
The next step is to install and configure the CakePHP framework that powers digikamWebUi. Switch to the /var/www
directory and download the current release of CakePHP using the following commands, replacing x.x.x.tar.gz with the actual version number of the latest CakePHP release. You can check the latest version number at https://github.com/cakephp/cakephp/releases:
cd /var/www sudo wget https://github.com/cakephp/cakephp/archive/x.x.x.tar.gz
Unpack the downloaded archive and rename the resulting directory cakephp
:
sudo tar xzvf x.x.x.tar.gz sudo mv x.x.x cakephp
Make cakephp
writable by the server using the sudo chown -R www-data cakephp/
command, open the /var/www/cakephp/app/Config/core.php
file for editing, and change the default value of the Security.salt
parameter to a string consisting of 63 random alphanumeric characters (you can use the https://www.grc.com/passwords.htm page to generate a random string). Next, set the Security.cipherSeed
parameter to a different 29-number random value.
Now open the default file with sudo nano /etc/apache2/sites-enabled/000-default
for editing and locate the following fragment:
<Directory /var/www/> Options Indexes FollowSymLinks MultiViews AllowOverride None Order allow,deny allow from all </Directory>
Change the AllowOverride None
command to AllowOverride All
and save the file; then, enable the mod_rewrite
Apache module:
sudo a2enmod rewrite sudo /etc/init.d/apache2 restart
Now you are ready to install digikamWebUi. Make sure that you are still in the /var/www
directory and clone the project's repository:
sudo git clone https://github.com/mehdilauters/digikamWebUi.git digikamwebui
Open the database file for editing with sudo nano digikamwebui/app/Config/database.php
and add the database connection profiles shown in Listing 1.
Listing 1
Database Connection Profiles
Next, switch to the /home/user/photos
directory and create the digikamWebUi.db
SQLite database using the supplied digikamWebUi.sql
file:
cd ~/photos sqlite3 digikamWebUi.db < /var/www/digikamwebui/app/Config/Schema/digikamWebUi.sql
It's important that the created database has the same permissions as the /photos
directory, so use the chmod 777 -R ~/photos
command to apply the same permissions to the directory and all the files in it.
Finally, open the /var/www/digikamwebui/app/Config/core.php
file for editing and change Configure::write('debug', 2);
to Configure::write('debug', 0);
to disable debugging messages.
Point the browser to http://127.0.0.1/digikamwebui/users/add and add a new user. Once you've done that, go to http://127.0.0.1/digikamwebui/users/login, log in using the specified credentials, and you should see digikamWebUi in all its beauty (Figure 5).
digikamWebUi's interface is divided into three columns. The Albums column to the left shows a hierarchical list of all albums in digiKam, and you can switch to a specific album by clicking on its name. When processing the digiKam library, digikamWebUi parses tags found in photos and lists them in the Tags column to the right. As you would expect, clicking on a tag shows all photos containing the tag. The middle column shows thumbnails of photos in the currently selected album or photos containing a specific tag. To view a larger version of a photo, click on its thumbnail.
Commands under each photo can be used to perform common operations, such as deleting, rotating, and rating the photo. Choosing Edit opens the photo editing page. Here, you can edit the photo's name, assign tags, and move the photo to a different album. Using digikamWebUi, you can display photos as a slideshow and view them on the map (Figure 6). The latter feature can be used not only to show photo thumbnails on the map but also to travel in time using the timeline slider at the top.
When using digikamWebUi, keep in mind that it needs to cache files when it accesses digiKam albums for the first time. That means it can be pretty slow in the beginning. digikamWebUi is still rough around the edges, but if you need to access and manage your digiKam albums via the web, this is the tool you need.
Final Word
Although digiKam is first and foremost a desktop application, it features export capabilities that can be used to push photos to a variety of popular photo-sharing and file storage services. Additionally, if you need to access your digiKam library via the web, digikamWebUi has you covered.
Infos
- Wikimedia Commons: http://commons.wikimedia.org
- Mejiro: http://dmpop.github.io/mejiro
- digikamWebUi: http://github.com/mehdilauters/digikamWebUi
« Previous 1 2
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.
News
-
Firefox 134 Offers Improvements for Linux Version
Fans of Linux and Firefox rejoice, as there's a new version available that includes some handy updates.
-
Serpent OS Arrives with a New Alpha Release
After months of silence, Ikey Doherty has released a new alpha for his Serpent OS.
-
HashiCorp Cofounder Unveils Ghostty, a Linux Terminal App
Ghostty is a new Linux terminal app that's fast, feature-rich, and offers a platform-native GUI while remaining cross-platform.
-
Fedora Asahi Remix 41 Available for Apple Silicon
If you have an Apple Silicon Mac and you're hoping to install Fedora, you're in luck because the latest release supports the M1 and M2 chips.
-
Systemd Fixes Bug While Facing New Challenger in GNU Shepherd
The systemd developers have fixed a really nasty bug amid the release of the new GNU Shepherd init system.
-
AlmaLinux 10.0 Beta Released
The AlmaLinux OS Foundation has announced the availability of AlmaLinux 10.0 Beta ("Purple Lion") for all supported devices with significant changes.
-
Gnome 47.2 Now Available
Gnome 47.2 is now available for general use but don't expect much in the way of newness, as this is all about improvements and bug fixes.
-
Latest Cinnamon Desktop Releases with a Bold New Look
Just in time for the holidays, the developer of the Cinnamon desktop has shipped a new release to help spice up your eggnog with new features and a new look.
-
Armbian 24.11 Released with Expanded Hardware Support
If you've been waiting for Armbian to support OrangePi 5 Max and Radxa ROCK 5B+, the wait is over.
-
SUSE Renames Several Products for Better Name Recognition
SUSE has been a very powerful player in the European market, but it knows it must branch out to gain serious traction. Will a name change do the trick?