Today, I am taking Techno Dad Life (TDL) challenge. I am going to attempt to install Piwigo an open source photo management server on
So here we go now!
I just want to address the PUID and PGID. Please see this post https://www.networkshinobi.com:443/docker-containers-puid-and-pgid/ regarding PUID and PGID.
SSH to the OMV server and create two directories. One for Piwigo and the other for mkdir -p
will make the directories that have not existed along the path
root@openmediavault:~# mkdir -p /sharedfolders/appdata/piwigo root@openmediavault:~# mkdir -p /sharedfolders/appdata/mariadb-photo root@openmediavault:~# cd /sharedfolders/appdata root@openmediavault:/sharedfolders/appdata# ls -lh total 8.0K drwxr-xr-x 2 root root 4.0K Jun 6 20:16 mariadb-photo drwxr-xr-x 2 root root 4.0K Jun 6 20:16 piwigo root@openmediavault:/sharedfolders/appdata#
- Assuming you already installed the Docker UI on your OMV, navigate to Services > Docker
- Search for piwigo in the search box. If there are multiple ones, select the one from Linuxserver repository
Click Start to pull the Piwigo image from Docker Hub. Once the Close button is clickable, click the Close button.
The time it would take to pull an image depends on its size and your Internet speed.
Search for
Again, click on Start to pull the mariaDB Docker image. Click Close, when it is done downloading.
Verify the Docker images by clicking the Refresh button
Now we need to configure the Docker containers. We are going to start with mariaDB. Click on mariadb image then click on Run Image.
Under the General Settings section, fill out the following fields as shown in the table below. See Figure 7 for reference.
Container name | mariadb-photo |
Restart Policy | always |
Under the Networking, Port forwarding section, enter the following as shown in table below. Make sure click on the + sign to add the config. See Figure 7 for reference.
Host IP | Host Port | Exposed Port |
0.0.0.0 | 3307 | 3306/tcp |
Under the Environment variables section, add the following as shown in the table below. Check this link for
Adjust the TZ to meet your own Timezone. Timezone is very sensitive; if this doesn’t match your other containers, you are going to have a bad day. also, for PUID and PGID value, you can use your admin or whoever managing your Docker containers.
For example: in the terminal, type in – id <your-username>
Name | Value |
TZ | America/New_York |
MYSQL_ROOT_PASSWORD | StrongPasswordHere |
PUID | 99 |
PGID | 100 |
Under the Volumes and Bind mounts section, locate the directory
Under the Volumes and Bind mounts section, the Host path and Container path should look like as shown in the table below. Click Save to start the
Host path | Container path |
/sharefolders/appdata/mariadb-photo | /config |
If you disconnected your SSH session earlier, you will need to SSH again to your OMV server. We are going to configure the mariadb and create a database for Piwigo.
# We need to bash-in mariadb container root@openmediavault:~# docker container exec -it mariadb-photo bash root@06b18968d2fe:/# # As you can see above, the prompt changed from root@openmediavault to # root@06b18968d2fe. This tells us that we are inside of the container. # # We are going to create the piwigo database. Please replace the username # 'piwigo' with your desired username. Same with the database 'piwigo'. # Also, generate a better password than what I have in this example. mysql -u root -p # You will get prompted with the mariadb password we set-up in the web UI # Create a user 'piwigo' with a password of 'StrongDatabasePassword' CREATE USER 'piwigo' IDENTIFIED by 'StrongDatabasePassword'; # Create a database for piwigo CREATE DATABASE IF NOT EXISTS piwigo; # Grant all privileges GRANT ALL PRIVILEGES ON piwigo.* TO 'piwigo' IDENTIFIED BY 'StrongDatabasePassword'; # Exit mariadb quit # Exit mariadb container exit
Back to OMV web UI. Navigate back to Services > Docker > Docker images. we are going to run the Piwigo image that we pulled earlier. Click on Piwigo Docker image then click on Run image
Under the General section, fill out the following fields:
Container name | piwigo |
Restart Policy | Always |
Under the Networking section, and fill out the following fields. Don’t forget to click on the + plus sign. When done, scroll down for more settings.
OMV uses port 80/tcp. Thefore, the Host Port has to be changed. You can choose any port you desired for Host Port. However, choose the port that doesn’t overlap with your other containers’ Host Port.
Host IP | Host Port | Exposed Port |
0.0.0.0 | 82 | 80/tcp |
Under the Environment variables, add the following information as shown in the table below. See Figure 12 for reference.
Note: Adjust the value based on your own use case
Name | Value |
TZ | America/New_York |
PUID | 99 |
PGID | 100 |
Under the Volumes and Bind mounts, fill out the following. Do not forget to click on the + sign. Click Save to start the Piwigo container. See Figure 12 for reference.
The second line /config/www/gallery/upload/
is optional. I only did this so that my photos are located outside of the appdata. Therefore, if I decided to switch to a different platform. I have my photos outside of Piwigo.
Host path | Container path |
/sharefolders/appdata/piwigo | /config |
/sharefolders/Photos/piwigo | /config/www/gallery/upload/ |
Open a new browser tab and navigate to http://omv-ip-addr:82. You will be greeted by the Piwigo installation page.
Basic Configuration | |
Default gallery language | English [US] |
Database configuration | |
Host | 10.0.7.123:3307 |
User | piwigo |
Password | StrongDatabasePassword |
Database name | piwigo |
Administration configuration | |
Username | karlo |
Password | web-ui-admin-password |
Confirm Password | web-ui-admin-password |
Email address | your-email-address |
If everything is configured correctly, you should get the page similar to Figure 14.
You can either Start the tour or skip it. It is your choice and choose wisely 🙂
This is it. This is the admin gallery page. You can start configuring your instance of Piwigo.
Cheers!
Thank you for useful tutorial.
One question, please: In which folder are pictures: /sharefolders/Photos/piwigo or
config/www/gallery/upload/ ?
P.S.
Did Techno Dad send you a sticker? 🙂