debian/control, postinst, prerm, postrm — standard dpkg package lifecycle debian/files/opt/dupfinder/dupfinder-setup.sh — interactive setup: checks Docker, detects NVIDIA GPU, prompts for photos/data paths, writes docker-compose.override.yml with GPU reservation if present, pulls image from registry (builds from source as fallback) debian/files/usr/local/bin/dupfinder — CLI wrapper: setup / start / stop / restart / status / logs / open / update debian/files/etc/systemd/system/dupfinder.service — systemd unit, guards against starting before setup has run debian/build-deb.sh — builds .deb and uploads to Gitea package registry; prints the exact apt sources.list line on success Install on any Debian/Ubuntu machine: echo "deb [trusted=yes] http://192.168.1.64:3000/api/packages/tocmo0nlord/debian bookworm main" \ | sudo tee /etc/apt/sources.list.d/dupfinder.list sudo apt update && sudo apt install dupfinder sudo dupfinder setup Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
28 lines
1.5 KiB
Bash
28 lines
1.5 KiB
Bash
#!/bin/bash
|
|
set -e
|
|
|
|
# Create data directory with correct permissions
|
|
mkdir -p /var/lib/dupfinder/data
|
|
chmod 755 /var/lib/dupfinder
|
|
|
|
# Reload systemd and enable service (don't start yet — needs user config first)
|
|
systemctl daemon-reload
|
|
systemctl enable dupfinder.service 2>/dev/null || true
|
|
|
|
echo ""
|
|
echo "╔══════════════════════════════════════════════════╗"
|
|
echo "║ DupFinder installed successfully! ║"
|
|
echo "╠══════════════════════════════════════════════════╣"
|
|
echo "║ ║"
|
|
echo "║ Run setup to configure your photos path: ║"
|
|
echo "║ ║"
|
|
echo "║ sudo dupfinder setup ║"
|
|
echo "║ ║"
|
|
echo "║ After setup, manage with: ║"
|
|
echo "║ sudo systemctl start dupfinder ║"
|
|
echo "║ sudo systemctl stop dupfinder ║"
|
|
echo "║ dupfinder status ║"
|
|
echo "║ ║"
|
|
echo "╚══════════════════════════════════════════════════╝"
|
|
echo ""
|