8914f4dce9
- Created `TV_SHOWS_SQL_QUERY_PATTERNS.md` to document SQL query patterns for TV shows, including performance issues and missing indexes. - Added `README.md` for Linux package building, detailing steps for creating Debian and Red Hat packages. - Implemented build scripts for Debian and Red Hat, including service files and post-installation hooks. - Added necessary scripts for managing Jellyfin service lifecycle on both Debian and Red Hat systems. - Included package specifications and installation instructions for both distributions.
2.6 KiB
2.6 KiB
Linux Package Build Quick Reference
One-Command Build
cd ~/projects/pgsql-jellyfin && chmod +x build-linux-packages.sh && ./build-linux-packages.sh
Prerequisites
# Debian/Ubuntu
sudo apt-get install ruby-dev && sudo gem install fpm
# Red Hat/CentOS/Fedora
sudo dnf install ruby-devel && sudo gem install fpm
Build Variations
# Both Debian and Red Hat
./build-linux-packages.sh
# Debian only
./build-linux-packages.sh --deb-only
# Red Hat only
./build-linux-packages.sh --rpm-only
# Custom version
./build-linux-packages.sh --version 12.0.0
Installation
# Debian
sudo dpkg -i build/packages/jellyfin-11.0.0-amd64.deb
sudo apt-get install -f # Fix deps if needed
# Red Hat
sudo dnf install build/packages/jellyfin-11.0.0-1.x86_64.rpm
Verification
# Check status
sudo systemctl status jellyfin
# View logs
sudo journalctl -u jellyfin -f
# List files in package
dpkg -L jellyfin # Debian
rpm -ql jellyfin # Red Hat
Key Directories
| Purpose | Location |
|---|---|
| Application | /opt/jellyfin |
| Configuration | /etc/jellyfin |
| Data/Library | /var/lib/jellyfin |
| Logs | /var/log/jellyfin |
| Cache | /var/cache/jellyfin |
Publishing Parameters
- Runtime:
linux-x64(64-bit) - Configuration:
Release(optimized) - Self-contained:
true(.NET included) - Both Debian and Red Hat use identical parameters
Systemd Commands
sudo systemctl start jellyfin # Start service
sudo systemctl stop jellyfin # Stop service
sudo systemctl status jellyfin # Check status
sudo systemctl restart jellyfin # Restart service
sudo systemctl enable jellyfin # Auto-start on boot
sudo systemctl disable jellyfin # Disable auto-start
Troubleshooting
| Issue | Solution |
|---|---|
| Permission denied | chmod +x build-linux-packages.sh |
| FPM not found | Install ruby-dev/ruby-devel and gem install fpm |
| Missing dependencies | sudo apt-get install -f (Debian) or dnf resolves automatically |
| Service won't start | Check logs: sudo journalctl -u jellyfin -n 50 |
Output
Packages created in: ./build/packages/
jellyfin-VERSION-amd64.deb(Debian)jellyfin-VERSION-1.x86_64.rpm(Red Hat)
Scripts Location
scripts/
├── build-linux-packages.sh # Main build script
├── jellyfin.spec # Red Hat SPEC template
├── debian/ # Debian hooks
└── redhat/ # Red Hat hooks
Full Documentation
See LINUX_PACKAGE_BUILD_GUIDE.md for complete details