Giter Site home page Giter Site logo

mrtam / relay Goto Github PK

View Code? Open in Web Editor NEW
7.0 1.0 2.0 1.63 MB

HDHomeRun Emulator

License: GNU General Public License v3.0

Dockerfile 0.74% C# 68.76% HTML 3.18% CSS 0.58% JavaScript 26.74%
relay tvheadend channels-dvr plexmediaserver plex hdhomerun

relay's Introduction

Relay

CircleCI Cloudsmith

Relay is a software emulator for the Silicondust HD HomeRun series of network tuners. It has been designed to work out of the box with Plex DVR, and Channels DVR. Other services which are HDHR capable will likely work too - however these are untested.

OK cool. How does this differ to tvhProxy / Antennas / etc?

Relay is a modular full application built using the ASP.NET Core 2.2 Framework, with Entity Framework (EF) utilised for persistence. Channel lineups are persisted to a SQLite database, with support for channel favorites just like a real HD HomeRun.

A basic frontend is in place in addition to the regular REST framework. This frontend allows for browsing and marking channels as favourites, and manually invoking a guide update.

Relay has been designed to be completely modular - with the notion of supporting multiple provider backends. Right now there is currently support for Tvheadend - however within the project scope is to extend this to other platforms, such as IPTV playlists.

Finally, this application fully supports the UDP discovery protocol. Several DVR systems such as Channels DVR make use of this protocol to discover devices on the network. Without this in place, these apps cannot make use of the tuner.

Configuration

Configuration is set using environment variables:

Parameter Default Description
relay_address 127.0.0.1 The address used in the BaseURL given out to all REST/UDP calls. Must be a valid address.
relay_tunercount 2 The number of tuners to broadcast in discovery calls.
relay_tunerdeviceid 1337 The device ID provided to discovery calls.
relay_updateintervalseconds 3600 The interval in seconds between guide updates.
relay_databasepath . The path to where the database should be stored.

Provider Configuration

Tvheadend has separate configuration.

NB: It is recommended to configure a user with streaming credentials and provide these to Relay here. Channels DVR can run into difficulty using the Tvheadend provider if credentials are not set, as the default noauth implementation uses a token based system that is not compatible with this DVR.

Parameter Default Description
relay_tvheadend__url http://127.0.0.1:9981 The location of where Tvheadend is running.
relay_tvheadend__username - Username for login
relay_tvheadend__password - Password for login

Running

Relay can be run directly on any Windows / Mac / Linux machine, but requires .NET Core 2.2 to be installed prior.

cd relay
dotnet run

Docker

Docker is the preferred method of deployment. Docker images are hosted on the Cloudsmith platform.

docker run --rm -it \
    -e relay_address=192.168.1.2 \
    -e relay_tvheadend__url=http://192.168.1.1:9981 \
    -e relay_tvheadend__username=foobar \
    -e relay_tvheadend_password=wibble \
    -e relay_tunercount=4 \
    -e relay_databasepath=/config \
    -v /some/path/to/config:/config \
    docker.cloudsmith.io/mrtam/relay/relay:latest

When using Docker, it is important that the relay_databasepath parameter is set to /config. The Dockerfile creates this folder, and is a safe place for mounting locally to persist the database following container destruction.

Finally ...

This is very much a WIP project, and as such I welcome pull requests and comments. I created this project mostly out of need and dissatisfaction with the existing solutions, and welcome contributions to make Relay the best it can be.

Please fork, update, and PR!!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.