Kutt is a modern URL shortener application. It is written in Node.js and uses MySQL or MariaDB database. In this tutorial, we will go through the steps to install Kutt on Fedora Server.
Before we start installing Kutt on Fedora Server, make sure you have the following prerequisites:
First, update your Fedora server to ensure that all packages are up to date. Run the following command to update your system:
sudo dnf update -y
Kutt is a Node.js based application, so we need to install Node.js on the server. First, add the Node.js repository to your system with the following command:
sudo dnf module install nodejs:14 -y
After adding the repository, install Node.js and npm with the following command:
sudo dnf install nodejs
Kutt requires either MySQL or MariaDB database to store data. You can choose either one of them. If you haven't installed any of the databases, then you can install MariaDB with the following command:
sudo dnf install mariadb-server
After installing MariaDB, start the database service and enable it to start at boot time with the following command:
sudo systemctl start mariadb
sudo systemctl enable mariadb
Then, run the mysql_secure_installation command to set the password for the root user of the database.
Next, log in to the MariaDB or MySQL shell with the following command:
sudo mysql -u root -p
Then, create a new database and user for Kutt with the following commands:
CREATE DATABASE kutt;
CREATE USER 'kuttuser'@'localhost' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON kutt.* TO 'kuttuser'@'localhost';
FLUSH PRIVILEGES;
Remember to replace 'password' with a strong password.
Clone the Kutt repository to your server with git:
git clone https://github.com/thedevs-network/kutt.git
Then, install the dependencies with npm:
cd kutt
npm install
Kutt has a configuration file located in the .env
file. Copy the .env.example
file and rename it to .env
with the following command:
cp .env.example .env
Then, open the .env
file and modify the following lines with your MariaDB or MySQL database connection details.
DB_HOST=localhost
DB_USER=kuttuser
DB_PASS=password
DB_NAME=kutt
Finally, start the Kutt application with the following command:
npm start
This will start the Kutt application on http://localhost:3000. You can use a process manager like PM2 to run Kutt in the background and automatically restart in case of crashes.
Congratulations! You have successfully installed Kutt on Fedora Server. You can now start using this modern URL shortener 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!