jackw01 / led-control

Advanced WS2812/SK6812 RGB/RGBW LED controller with on-the-fly Python animation programming, web code editor/control interface, 1D, 2D, and 3D display support, and E1.31 sACN support
https://jackw01.github.io/led-control/
MIT License
162 stars 35 forks source link

Docker Image? #8

Open nils opened 3 years ago

nils commented 3 years ago

Hi Jack,

first of all: this is a brilliant application!

I really enjoy everything about it, like the simple installation, the well-designed CLI interface, and the equally well designed web interface.

However, I still have a low priority suggestion that I'd like to discuss with you.

How about provisioning of a Docker image containing an installation of led-control and an example docker-compose.yaml file ? I have built my own Dockerfile for this purpose, and that is not exactly hard to do. If one of us would provide that it could even further reduce the entry barrier because users would only need a docker-enabled distribution like HypriotOS on their RPi and not care about any additional dependencies.

Dockerfile:

FROM python:3-buster

WORKDIR /usr/src/app

RUN apt-get update && apt-get install -y scons swig git
RUN git clone --recurse-submodules https://github.com/jackw01/led-control.git && \
 cd led-control && \
 python3 setup.py develop
ENTRYPOINT ["ledcontrol"]

docker-compose.yml:

version: '3'
services:
  ledcontrol:
    build: .
    ports:
      - "80:80"
    privileged: true
    restart: always
    command: --led_count 150 --led_pixel_order GRBW # 150 LEDs of type SK6812
    volumes:
      - ./ledcontrol.json:/etc/ledcontrol.json

What do you think about this? And how should we tackle it from your perspective? Add another repository under your github user so that others can find it? Add the files to this repo? Do you have a Docker Hub account?

I can also do this under my own name, but then it would be harder to find for interested users. Maybe you could then link the Docker Hub page?

I'd prefer it if we could include the files in this repo, because then we could also automatically trigger a Docker image rebuild as soon as this repository is updated.

Best Regards, Nils

@jackw01