top of page

locast2plex in docker

We have other interests besides AWS and Flow Logs.

Recently, we found a cool way to get local TV stations streamed to our Plex machine. It lets us watch local TV, legally, without a cable subscription, and stream it to any Plex-compatible device.


This page does a great job of explaining the process:


However, when building this in docker container on a Synology NAS DS218+, we kept hitting errors and not being able to find a resolution.


locast2plex    | Getting user location...
locast2plex    | Getting location via IP Address.
locast2plex    | Error in function get_ip_location: [Errno -3] Try again
locast2plex    | Could not acertain location.  Exiting...
locast2plex exited with code 1

The solution is to switch to "host" mode networking.

  1. Edit your docker-compose.yml file in your preferred text editor

  2. add a line network_mode: "host"

  3. remove the ports section

  4. sudo docker-compose up

Here is the complete docker-compose.yml file that finally worked:


version: '2'
services:
  locast2plex:
    network_mode: "host"
    image: tgorg/locast2plex
    container_name: locast2plex
    restart: unless-stopped
    environment:
      - username=email@yahoo.com
      - 'password=abcdefg'
      - external_addy=192.168.1.999
      - external_port=6077
      - debug=yes
    volumes:
      - ./config.ini:/app/config/config.ini

bottom of page