lapicidae/vdr-server

By lapicidae

Updated 2 days ago

VDR based on Arch Linux

Image
Web Servers

10K+

vdr

The Video Disk Recorder (VDR) is a free (open source), non-commercial project from Klaus Schmidinger to create a digital video recorder using standard PC components. It is possible to receive, record and playback digital TV broadcasts compatible with the DVB standard.

lapicidae/vdr-server

GitHub Repo starsDocker PullsDocker StarsGitHub Workflow Status

Image based on Arch Linux, VDR4Arch and s6-overlay.

Features

Note

The image is automatically rebuilt when any of the following sources receive an update:

Getting Started

Usage

Here are some example snippets to help you get started creating a container.

WARNING: The first start might be slow.
The first start can take longer, as non-integrated plugins are built from the AUR.

docker-compose (recommended)

Compatible with docker-compose v2 schemas.

version: "2.1"
services:
  vdr-server:
    image: lapicidae/vdr-server
    container_name: vdr-server
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=Europe/London
      - PLUGINS=epgsearch live streamdev-server vnsiserver #optional
    volumes:
      - /path/to/system:/vdr/system
      - /path/to/config:/vdr/config
      - /path/to/recordings:/vdr/recordings
      - /path/to/cache:/vdr/cache
      - /path/to/channellogos:/vdr/channellogos #optional
      - /path/to/log:/vdr/log #optional
      - /path/to/timeshift:/vdr/timeshift #optional
      - /path/to/pkgbuild:/vdr/pkgbuild #optional
    ports:
      - 8008:8008
      - 6419:6419 #optional
      - 6419:6419/udp #optional
      - 34890:34890 #optional
      - 8099:8099 #optional
    devices:
      - /dev/dvb:/dev/dvb #optional
    cap_add:
      - SYS_TIME #optional: read hint!
    restart: unless-stopped
    stop_grace_period: 60s #important

docker cli

docker run -d \
  --name=vdr-server \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Europe/London \
  -e PLUGINS=epgsearch live streamdev-server vnsiserver `#optional` \
  -p 8008:8008 \
  -p 6419:6419 `#optional` \
  -p 6419:6419/udp `#optional` \
  -p 34890:34890 `#optional` \
  -p 8099:8099 `#optional`
  -v /path/to/system:/vdr/system \
  -v /path/to/config:/vdr/config \
  -v /path/to/recordings:/vdr/recordings \
  -v /path/to/cache:/vdr/cache \
  -v /path/to/channellogos:/vdr/channellogos `#optional` \
  -v /path/to/log:/vdr/log `#optional` \
  -v /path/to/timeshift:/vdr/timeshift `#optional` \
  -v /path/to/pkgbuild:/vdr/pkgbuild `#optional` \
  --device /dev/dvb:/dev/dvb `#optional` \
  --restart unless-stopped \
  --cap-add=SYS_TIME `#optional: read hint!` \
  --stop-timeout 60 `#important` \
  lapicidae/vdr-server
Parameters

Container images are configured using parameters passed at runtime.
These parameters are separated by a colon and indicate <external>:<internal> respectively.
For example, -p 8080:80 would expose port 80 from inside the container to be accessible from the host's IP on port 8080 outside the container.

ParameterFunction
-p 8008Http VDR-Live plugin.
-p 3000Streamdev Server (HTTP Streaming) 1
-p 8009Optional - Https VDR-Live plugin (you need to set up your own certificate)
-p 6419Optional - Simple VDR Protocol (SVDRP)
-p 6419/udpOptional - SVDRP Peering
-p 2004Optional - Streamdev Server (VDR-to-VDR Streaming)
-p 34890Optional - Kodi VDR-Network-Streaming-Interface (VNSI)
-p 8099Optional - Image Server for e.g. roboTV (must be enabled) 2
-e PUID=1000for UserID - see below for explanation
-e PGID=1000for GroupID - see below for explanation
-e TZ=Europe/LondonSpecify a timezone to use (e.g. Europe/London)
-e LANG=en_US.UTF-8Default locale; see list (e.g. en_US.UTF-8)
-e PLUGINS=epgsearch live streamdev-server vnsiserverOptional - Space separated list of VDR Plugins (default: epgsearch live streamdev-server vnsiserver)
-e START_NALUDUMP=trueOptional - Start naludump every day at 4 am (via cron) 3
-e START_NALUDUMP_AT=0 4 * * *Optional - Crontab schedule for the start of naludump (examples)
-e START_IMAGESERVER=trueOptional - Image Server: provision of station logos and epg images via http
-e LOG2FILE=trueOptional - Write log to file in /vdr/log
-e PROTECT_CAMDATA=trueOptional - Write protect cam.data to avoid unwanted changes
-e DISABLE_WEBINTERFACE=trueOptional - Disable web interface (live plugin)
-e LOGO_COPY=falseOptional - Use your own station logos in /vdr/channellogos
-v /vdr/systemStart parameters, recording hooks and msmtprc config
-v /vdr/configConfig files (e.g. setup.conf or channels.conf)
-v /vdr/recordingsRecording directory (aka video directory)
-v /vdr/cacheCache files (e.g. epgimages or cam.data)
-v /vdr/channellogosTV and radio station logos
-v /vdr/logLogfiles if LOG2FILE=true
-v /vdr/timeshiftVNSI Time-Shift buffer directory
-v /vdr/pkgbuildBuild packages: README
--device /dev/dvbOnly needed if you want to pass through a DVB card to the container

Hint

If you want to use VDRs "SetSystemTime = 1" use parameter "--cap-add=SYS_TIME"(untested)

User / Group Identifiers

When using volumes (-v flags) permissions issues can arise between the host OS and the container, we avoid this issue by allowing you to specify the user PUID and group PGID.

Ensure any volume directories on the host are owned by the same user you specify and any permissions issues will vanish like magic.

In this instance PUID=1234 and PGID=4321, to find yours use id user as below:

  $ id username
    uid=1234(dockeruser) gid=4321(dockergroup) groups=4321(dockergroup)

VDR Configuration

Directory Structure

Standard paths and their Container counterpart.

  • /etc/vdr -> /vdr/system
  • /var/lib/vdr -> /vdr/config
  • /srv/vdr/video -> /vdr/recordings
  • /var/cache/vdr -> /vdr/cache
  • /usr/share/vdr/channel-logos -> /vdr/channellogos
Application Setup

Please read the VDR Wiki.

Command line parameters can be changed in vdr/system/conf.d/00-vdr.conf and
configuration files are located in vdr/config/.

Webui (live plugin) can be found at http://<your-ip>:8008.
Most VDR settings can be edited via the webui remote.

Plugins

First, see if there is anything to adjust in the Webui / Remote section.

Parameters are passed via the corresponding file in vdr/system/conf.d/.
Most other files related to plugins are located in vdr/config/plugins/.

eMail Notification

For example, the VDR plugin epgsearch can send a notification by e-mail (sendmail).
To provide sendmail functionality msmtp is used and the configuration is done in vdr/system/eMail.conf.
Please refer to the msmtp documentation for configuration instructions.

Bonus

Channel IDs

A list of VDR channel IDs is automatically created when the container is stopped and can be found in vdr/cache/channelids.conf.

Recording Error Check

Scan the recordings before 'VDR 2.6.0' for errors (continuity counter), e.g. to display them in the web interface.
Just put an empty file named checkrec into the main directory of your recordings (vdr/recordings).
The process is executed at container start and runs until everything is checked.
The check is done via vdr-checkts by eTobi and the basic script comes from MarkusE.

Thanks

Footnotes

  1. Simple interface is avalable at http://<your-ip>:3000

  2. When the server is running instructions available at: http://<your-ip>:8099

  3. WARNING: The whole process has been designed to be as safe as possible! Nevertheless, there is no guarantee that the recordings will not be damaged during the cleanup.

Docker Pull Command

docker pull lapicidae/vdr-server