How to Install Photonix on Debian Latest

Photonix is an open-source, modern image viewer and organizer. In this tutorial, we will guide you through the steps of installing Photonix on Debian Latest.

Requirements

Before we begin, you need to have the following requirements:

Step 1 – Update System Packages

Before installing any new software, it is essential to update the system packages to their latest versions. You can do this by running the following commands:

sudo apt update
sudo apt upgrade

Step 2 – Install Required Packages

Photonix requires some packages to be installed on the system before it can be installed. Run the following command to install these packages:

sudo apt install wget git imagemagick nodejs npm

Step 3 – Install NVM

Since Photonix is a Node.js application, we need to install NVM to manage multiple Node.js versions. Run the following commands to install NVM:

wget -qO- https://raw.githubusercontent.com/nvm-sh/nvm/v0.38.0/install.sh | bash
source ~/.bashrc

Step 4 – Install Photonix

To install the Photonix application, clone the source code from the Github repository using the following command:

git clone https://github.com/deluan/photonix.git

Now, navigate to the application directory:

cd photonix/

Next, install the required packages using the following command:

npm install

Photonix is now installed on your system.

Step 5 – Start Photonix

You can now start Photonix by running the following command in the application directory:

npm start

After starting Photonix, you can access it by visiting http://localhost:3333 in your web browser.

Step 6 – Set up Systemd Service

To make Photonix run as a service, follow these steps:

  1. Create a new file in the /etc/systemd/system/ directory with the name photonix.service using a text editor such as Nano:
sudo nano /etc/systemd/system/photonix.service
  1. Add the following content to the file:
[Unit]
Description=Photonix Image Viewer
After=network.target

[Service]
User=<USERNAME>
ExecStart=/path/to/photonix/directory/npm start
Restart=always
RestartSec=10
WorkingDirectory=/path/to/photonix/directory/

[Install]
WantedBy=multi-user.target

Replace <USERNAME> and /path/to/photonix/directory/ with your username and the directory where you installed Photonix, respectively.

  1. Save and close the file.

  2. Reload the systemd daemons:

sudo systemctl daemon-reload
  1. Start the Photonix systemd service:
sudo systemctl start photonix

You can check the status of the service using the following command:

sudo systemctl status photonix

This will ensure that Photonix starts automatically whenever the system is rebooted.

Conclusion

In this tutorial, we have successfully installed Photonix on Debian Latest. You can now start organizing and viewing your images in Photonix. If you face any issues during the installation process, kindly refer to the official documentation of the application.

If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!

Alternatively, for the best virtual desktop, try Shells!