Docker Setup (pi etc)

5 years 9 months ago #496 by ginnserv
Just wanted to share my code. it is not commented etc. So its not for the faint of heart.

Basically I use it for my pi that runs docker.

This enables me to easily deploy pi's or re-purpose them (no setup other than docker).

github.com/ShoGinn/opensky-docker

Summing it up, the Docker image just pulls the Debian package, installs is (sets the configuration to some trash data to begin) then when you run the docker, environmental variables are used for the opensky configuration.

Works perfect for me ;)
The following user(s) said Thank You: fuchs, strohmeier

Please Log in or Create an account to join the conversation.

5 years 9 months ago #497 by fuchs
Replied by fuchs on topic Docker Setup (pi etc)
Great idea to provide a Docker image!

It seems that this needs a running installation of dump1090, right?

Please Log in or Create an account to join the conversation.

5 years 9 months ago #498 by ginnserv
Replied by ginnserv on topic Docker Setup (pi etc)
You are correct, the container has a variable that looks for a dump1090 installation (or in my case another docker image).

github.com/ShoGinn/dump1090-docker

That image is a build of dump1090-mutability

I have seen the hp-toa version of dump1090 and might make a tag for it as well for those interested in testing it.

Thanks for looking, depending on the interest of these images I might invest more time in providing an actual readme for each of the containers ;)

Please Log in or Create an account to join the conversation.

5 years 9 months ago #501 by fuchs
Replied by fuchs on topic Docker Setup (pi etc)

You are correct, the container has a variable that looks for a dump1090 installation (or in my case another docker image).

github.com/ShoGinn/dump1090-docker

That image is a build of dump1090-mutability


Nice work! Does this run with with a simple "docker run ..." or do you need to add some special flags? I read about problems with USB devices and Docker, because containers were not allowed low-level access (see StackOverflow ).

Please Log in or Create an account to join the conversation.

5 years 9 months ago - 5 years 9 months ago #502 by ginnserv
Replied by ginnserv on topic Docker Setup (pi etc)
I have no issues running it in docker, udev has issues and I am not going to make it privileged as of right yet.(might have to if I create the hp-toa version)

I run docker-compose which makes it easy.
version: '2'
services:
  dump1090:
    image: "shoginn/raspbian-dump1090"
    restart: always
    devices:
    - "/dev/bus/usb:/dev/bus/usb"
    volumes:
    - cgroup:/sys/fs/cgroup
    ports:
      - "80:80"
      - "30003:30003"
      - "30104:30104"
      - "30005:30005"
    environment:
      - DUMP_HTTP_PORT=8080
      - DUMP_SBS_PORT=30003
      - DUMP_LAT=xx.xxxx
      - DUMP_LON=xxx.xxxx
  piaware:
    image: "shoginn/raspbian-flightaware"
    restart: always
    depends_on:
      - "gpsd"
      - "dump1090" 
    volumes:
      - cgroup:/sys/fs/cgroup
    environment:
      - PIAWARE_HOST=dump1090
      - PIAWARE_PORT=30005
      - PIAWARE_FEEDER_ID='''''''
      - "PIAWARE_GPS=tcp://gpsd:2947"
  flightradar:
    image: "shoginn/raspbian-flightradar24"
    restart: always
    hostname: fr24
    depends_on:
      - "dump1090"
    ports:
      - "8754:8754"
    volumes:
      - cgroup:/sys/fs/cgroup
    environment:
      - DUMP1090_HOST=dump1090
      - DUMP1090_PORT=30005
      - FR24_KEY='''''''
  planefinder:
    image: "shoginn/raspbian-planefinder"
    restart: always
    ports:
      - "30053:30053"
    volumes:
      - cgroup:/sys/fs/cgroup
    environment:
      - DUMP1090_HOST=dump1090
      - DUMP1090_PORT=30005
      - PF_SHARECODE=''''''''
      - LAT=xx.xxxx
      - LONG=xxx.xxxx
  adsb-exchange:
    image: "shoginn/mlat-client-docker"
    restart: always
    volumes:
      - cgroup:/sys/fs/cgroup
    environment:
      - DUMP1090_HOST=dump1090
      - ADSB_EX_USER=user
      - LAT=xx.xxxx
      - LON=xxx.xxxx
      - ALT=xxx
  gpsd:
    image: bradsjm/rpi-gpsd
    volumes:
      - cgroup:/sys/fs/cgroup
    ports:
      - "2947:2947"
    devices:
      - /dev/ttyACM0:/dev/ttyACM0
    command: /dev/ttyACM0 
    restart: always

  adsbhub:
    image: "shoginn/adsbhub-docker"
    restart: always
    volumes:
      - cgroup:/sys/fs/cgroup
    environment:
      - DUMP1090_HOST=dump1090
      - DUMP1090_PORT=30002
  opensky-feeder:
    image: "shoginn/opensky-docker"
    restart: always
    volumes:
      - cgroup:/sys/fs/cgroup
    environment:
      - DUMP1090_HOST=dump1090
      - DUMP1090_PORT=30005
      - ALT=xxx
      - LAT=xx.xxxx
      - LONG=xxx.xxxx
      - OPENSKY_USER=username
      - SERIAL=-serial

The following user(s) said Thank You: fuchs

Please Log in or Create an account to join the conversation.

5 years 9 months ago #503 by fuchs
Replied by fuchs on topic Docker Setup (pi etc)
This is what I meant:

devices:
- "/dev/bus/usb:/dev/bus/usb"


For me it wasn't obvious that you need to use this flag with the dump1090 Docker image. The docker-compose file makes it clear.

Please Log in or Create an account to join the conversation.

Powered by Kunena Forum
This website uses cookies to offer you the best experience of our services. By using this website you agree to our privacy policy!