Install LinkDing on Ubuntu 24.04

Install docker
$sudo apt update
$sudo apt install curl apt-transport-https ca-certificates software-properties-common
$curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg

$echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null

$sudo apt update
$sudo apt install docker-ce -y

check if docker is running
$sudo systemctl status docker

Add current user to docker group
$sudo usermod -aG docker $USER
$newgrp

Install linkding
$sudo -i
$sudo mkdir /var/linkding
$docker run --name linkding -p 9090:9090 -v /var/linkding:/etc/linkding/data -d sissbruecker/linkding:latest

Create new user
$docker exec -it linkding python manage.py createsuperuser --username=joe --email=joe@example.com

Server is running at localhost:9090


Set up nginx reverse proxy
$sudo apt install nginx
$sudo nano /etc/nginx/sites-available/your_domain

server {
    listen 80;
    listen [::]:80;

    server_name your_domain www.your_domain;
        
    location / {
        proxy_pass http://localhost:9090;
        include proxy_params;
    }
}

Update docker to start automatically every time system is rebooted
$docker stop linkding
$docker update --restart unless-stopped linkding
$docker start linkding