Infoscreen/HTPC with webinterface
Go to file
2019-03-13 11:25:39 +01:00
dist Whoops, fixed the xorg service file 2019-03-09 21:27:12 +01:00
grzegorz Allow unlisted playlists 2019-03-13 11:25:39 +01:00
res Add readme and dist setup 2018-03-04 18:29:08 +01:00
.gitignore Move config.py to default_config.py and make deplay.bash not delete config.py on the remote 2018-04-12 19:03:36 +02:00
default_config.py Move config.py to default_config.py and make deplay.bash not delete config.py on the remote 2018-04-12 19:03:36 +02:00
deploy.bash Move config.py to default_config.py and make deplay.bash not delete config.py on the remote 2018-04-12 19:03:36 +02:00
main.py Move config.py to default_config.py and make deplay.bash not delete config.py on the remote 2018-04-12 19:03:36 +02:00
README.md Fix typo in readme 2019-03-13 11:23:17 +01:00
requirements.txt Make __init__ produce a sanic app object instead of simply blocking as main() 2018-02-25 00:18:05 +01:00

Grzegorz API

Grzegorz is simple REST API for managing an instance of MPV. Why the name Grzegorz? We have a bad taste in humor!

When Grzegorz starts, it launches an instance of MPV and maintains it. It is designed to be used as an info screen or HTPC, and supports multiple users to push changes to the MPV instance.

The API is described and can be tested at http:/localhost:8080/swagger while the server is running. All API endpoints are available under /api

How to run it

First of we need to install any needed dependencies. If you want to, you may do so in a virtual environment.

To install the needed dependencies, run this with sufficient rights (as root?):

pip install -r requirements.txt

Gregorz manages a MPV process, meaning you need MPV installed on your system. Look for it in your package manager.

When finished, you may run the server with:

python3 main.py

The server should now be available at http://localhost:8080/. You may change the address and port in the file named config.py which is copied from default_config.py when running main.py the first time

Making Grzegorz run on boot

When setting up a info screen or HTPC using Grzegors, you may configure it to run automatically on startup.

We recommend installing a headless linux, and create a user for Grzegorz to run as. (We named ours grzegorz, obviously) Clone this repo into the home directory. Then make systemd automatically spin up a X session to run Grzegorz in: Copy the files in the folder dist into the folder $HOME/.config/systemd/user and run the following commands as your user:

$ systemctl --user enable grzegorz@0.service
$ systemctl --user start grzegorz@0.service