Sign inSign up

glowf1sh/srtla-receiver

By glowf1sh

•Updated about 2 years ago

SRTLA/SRT Receiver with latest NOALBS+SLS+SRTLA+LUStatsBot / For RIST->glowf1sh/srtla_rist-receiver

Image
Operating systems
26

2.7K

glowf1sh/srtla-receiver repository overview

This Docker container is distributed under the Creative Commons Attribution-NonCommercial (CC BY-NC) license. You are free to use, copy, distribute, and display the container for non-commercial purposes only. If you modify or build upon this container, you may distribute the resulting work only under the same license. For more information about the CC BY-NC license, please visit: https://creativecommons.org/licenses/by-nc/4.0/⁠

For RIST SUPPORT read this If you want to use the new RIST streaming protocol please have a look at my (still experimental but stable) SRT/LA+RIST All-in-one Receiver⁠**

IMPORTANT NOTE for INTEL/AMD or ARM users: Please use the correct Tag / Image for your hardware architecture that your docker host is running on. If you have Intel/AMD please use -amd64 and if you have some ARM Processor please use the -arm64 image instead. Otherwise you would get an "unsupported platform" error on starting your container. It´s important to always run the right image on the according hardware architecture you are having. Most synology NAS systems have Intel Atom or AMD processors. However some also have ARM processors. Please be aware and choose the right image to fully enjoy my container :)

SRTLA/SRT Receiver with NOALBS+SLS+SRTLA+LUStatsBot built-in v1.9-amd64 (Alpine small footprint build)

[Update 12.09.24] Released v1.9 - Updated all packages / especially NOALBS from 2.11.1 to 2.11.2 to fix broken KICK Chat (thanks for reporting @stealinx)

[Update 08.07.24] Released v1.8 - Updated all packages / especially NOALBS from 2.10.0 to 2.11.1

[Update 04.05.24] Released v1.7 - Updated NOALBS to 2.10.0

[Update 23.03.24] Released v1.6 with alot of error fixes and better comfort for all users.

*This is an actual forked version of the Belabox-Receiver Docker Container made by @Sherazarde and brought to more recent versions. Also this docker is modified and comes with several fixes currently no other container has.

This container comes with:

All parts can be DEACTIVATED or ACTIVATED as you need it! This container offers all you need and you can disable the parts you dont need via Docker Environment (ENV) Flags.

The default ENV Flags are:

NOALBS_STARTUP=true
SRTLA_REC_STARTUP=true
SLS_STARTUP=true
LUSTATSBOT_STARTUP=true

If you want to disable for example NOALBS you can set the ENV Flag: NOALBS_STARTUP=false

Environment/Mountpoints:

NOALBS

Please create a mountpoint to /apps/noalbs/config.json for your local settings outside of the docker container. There are online generators to create a working config.json (See IRLKit´s NOALBS Config Generator). Alternatively you can use the example config.json at the end of this description.

Please also create a mountpoint to /apps/noalbs/.env to a local file named .env containing your Twitch (Streamer/Bot) Account Name and the OAUTH Token for that account.

Once signed in to your Twitch Account you can get the twitch OAUTH token here: https://twitchapps.com/tmi⁠

The .env File should look like this:

TWITCH_BOT_USERNAME=yourBotname (or your Streamer Name in case you dont have an extra Bot Account)
TWITCH_BOT_OAUTH=oauth:xxxxxxxxxxxxxxxxxxxxx

LiveU StatsBot

Please create a mountpoint to /apps/lustatsbot/config.json and edit it accordingly to your account and credentials. See notes down below for an example config.json. Then restart the docker container once. Please dont forget to open Ports 8181/tcp (SLS Status for NOALBS), 8282/UDP SRT and/or 8383/UDP for SRTLA in your Router in case you want to access the SRT(LA) Relay from outside, for example with a LiveU Field Unit.

To use this docker with a LiveU edit your Streaming Destination on solo.liveu.tv:

Profile: SRT-Out solo h265 1080p50/60 (yes! you can use H.265 with this SRT Build)
URL and Port: srt://yourserversIPorName:8282
Stream ID: publish/live/feed1

In your OBS you can pull the stream as a media source with the URL:
srt://yourserversIPorName:8282?streamid=play/live/feed1

To use this docker on a streaming Box (orangePi5+ or Jetson Nano) or with your Smartphone (iOS Moblin or Android IRLPRO App):

SRT (only one Modem/Connection):
Encoder Settings: h265 / HDMI 1080p50/60 (yes! you can use H.265 with this SRT Build)
SRT receiver address / URL(IP) and Port: srt://yourserversIPorName:8282
Stream ID: publish/live/feed1

SRTLA (multiple modems/connections = Channel Bonding = Link Aggregation):
Same settings as above but:
For streaming Boxes use SRTLA receiver address / URL(IP) and Port: srt://yourserversIPorName:8383
For Android IRLPRO synthetic bonding/SRTLA use SRTLA receiver address / URL(IP) and Port: srtla://yourserversIPorName:8282

In your OBS you can pull the stream as a media source with the URL:
srt://yourserversIPorName:8282?streamid=play/live/feed1

Additional OBS Media Source Settings for retrieving your stream:

- Local File = deactivated (unticked)
- Restart playback when source becomes active = activated (ticked)
- Network Buffering = 0 MB (if Docker is run on the same machine as your OBS or 1-3 MB if you run it on a different computer - try to reduce to 0 if possible)
- Input: See above
- Input Format - will be autofilled by OBS after saving the media source. Should be mpegts
- Reconnect Delay - Move slider to 1s if running OBS and Docker on the same computer - Move slider to 3-10s if you run this docker elsewhere - experiment a little on this setting)
- Use hardware decoding when available - activated (ticked) - unticking this gave horrible grey pictures and artifacts on my Intel i9-13900KS with an NVIDIA RTX 4090 and OBS 29.1.3 - 30.1.1. Seems there is a bug or with software decoding (at least for me). So try to enable hardware decoding on the source to prevent horrible images.
- Show nothing when playback ends - activated (ticked)
- Close file when inactive - active (ticked)
- YUV Color Range - Auto
- Alpha in linear range: - deactivated (unticked)
- Searchable - deactivated (unticked)
EXPERIMENTAL - FFmpeg-Options - probesize=32 - Set probing size in bytes, i.e. the size of the data to analyze to get stream information. A higher value will enable detecting more information in case it is dispersed into the stream, but will increase latency. Must be an integer not lesser than 32. It is 5000000 by default. I have set it to 32 and had amazing good streams. However it should be more research on that - maybe having a higher value can get a better image quality with less artifacts. However it would increase the latency of your stream. So experiment on your own or leave this parameter out and live with the high latencey.

To instantly and easily install this docker container use either of these single line commands.

For Intel/AMD64 Processors

Example 1 (for most people! - run container with all 4 Services (NOALBS, LiveU Stats Bot, SRTLA Receiver and SLS Server):

docker run -d --restart=always --name srtla-receiver -p 8181:8181/tcp -p 8282:8282/udp -p 8383:8383/udp glowf1sh/srtla-receiver:v1.9-amd64

Example 2: (run container with NOALBS and LiveU Stats Bot DISABLED):

docker run -d --restart=always --name srtla-receiver -e NOALBS_STARTUP=false -e LUSTATSBOT_STARTUP=false -p 8181:8181/tcp -p 8282:8282/udp -p 8383:8383/udp glowf1sh/srtla-receiver:v1.9-amd64

For ARM Processors

Example 1 (for most people! - run container with all 4 Services (NOALBS, LiveU Stats Bot, SRTLA Receiver and SLS Server):

docker run -d --restart=always --name srtla-receiver -p 8181:8181/tcp -p 8282:8282/udp -p 8383:8383/udp glowf1sh/srtla-receiver:v1.9-arm64

Example 2: (run container with NOALBS and LiveU Stats Bot DISABLED):

docker run -d --restart=always --name srtla-receiver -e NOALBS_STARTUP=false -e LUSTATSBOT_STARTUP=false -p 8181:8181/tcp -p 8282:8282/udp -p 8383:8383/udp glowf1sh/srtla-receiver:v1.9-arm64

Usage instructions for liveU Stats Bot:

LiveU Stats bot is a bit tricky to run, especially since the config file format changes during updates from time to time. In case LUStatsbot does not work or run (check ps afux or process list in your docker) you can manually run it. Enter a shell (for example /bin/bash. You will find yourself in /apps. Now run liveU Stats bot with the command: /apps/lustatsbot/liveu_stats_bot

The Bot will now run a little setup wizard. Please answer all the questions and it will create the correct config.json file for you. For this build you can also use this template - please modify with your credentials etc.:

{  
"liveu": {
    "email": "YOUR EMAIL",
    "password": "YOUR PASSWORD",
    "id": null,
    "monitor": {
      "battery": true,
      "batteryCharging": true,
      "batteryNotification": [
        99,
        50,
        10,
        5,
        1
      ],
      "batteryInterval": 10,
      "modems": true,
      "modemsInterval": 10
    }
  },
  "twitch": {
    "botUsername": "YOUR BOT",
    "botOauth": "YOUR TWITCH OAUTH",
    "channel": "YOUR TWITCH CHANNEL NAME",
    "adminUsers": ["yourowntwitchname", "yourfirstmod", "yoursecondmod", "othermodetc."],
    "modOnly": true
  },
  "commands": {
    "cooldown": 5,
    "stats": [
      "!lustats",
      "!liveustats",
      "!lus"
    ],
    "battery": [
      "!battery",
      "!liveubattery",
      "!lub"
    ],
    "start": "!lustart",
    "stop": "!lustop",
    "restart": "!lurestart",
    "reboot": "!lureboot",
    "delay": "!ludelay"
  },
  "rtmp": {
    "url": "http://localhost:8181/stats",
    "application": "publish",
    "key": "live"
  },
  "customPortNames": {
    "ethernet": "ETH",
    "wifi": "WiFi",
    "usb1": "USB1",
    "usb2": "USB2",
    "sim1": "SIM1",
    "sim2": "SIM2",
    "sim3": "SIM3"
  }
} 

Example Config for NOALBS:

If you are using NOALBS, you can use this config.json template. It provides the scene switching for two SRT Feeds at once. So you could have a main Video Stream from a streamingbox and a picture in picture from your smartphone for example and the scene switcher will only switch if both connections are not available. Please look for "feed1" and "feed2" and update it with your correct stream ID name. Please also add your correct OBS Scene Names, Twitch Names and the name of your MODs to this config example and update it accordingly or the NOALBS will not start or work. Please check out the NOALBS documentation on Github if you have questions.

{
  "user": {
    "id": null,
    "name": "your Twitch Username",
    "passwordHash": null
  },
  "switcher": {
    "bitrateSwitcherEnabled": false,
    "onlySwitchWhenStreaming": true,
    "instantlySwitchOnRecover": false,
    "autoSwitchNotification": true,
    "retryAttempts": 3,
    "triggers": {
      "low": 400,
      "rtt": 1800,
      "offline": null,
      "rttOffline": null
    },
    "switchingScenes": {
      "normal": "OBS Normal Scene Name",
      "low": "OBS Low Bitrate Scene Name",
      "offline": "OBS Stream has no signal Scene Name"
    },
    "streamServers": [
      {
        "streamServer": {
          "type": "SrtLiveServer",
          "statsUrl": "http://127.0.0.1:8181/stats",
          "publisher": "publish/live/feed1"
        },
        "name": "Feed1",
        "priority": 0,
        "overrideScenes": null,
        "dependsOn": null,
        "enabled": true
      },
      {
        "streamServer": {
          "type": "SrtLiveServer",
          "statsUrl": "http://127.0.0.1:8181/stats",
          "publisher": "publish/live/Feed2"
        },
        "name": "Feed2",
        "priority": 0,
        "overrideScenes": null,
        "dependsOn": null,
        "enabled": true
      }
    ]
  },
  "software": {
    "type": "Obs",
    "host": "IP or Hostname of your OBS Computer",
    "password": "Your OBS Websocket 5 Password",
    "port": 4455
  },
  "chat": {
    "platform": "Twitch",
    "username": "Your Twitch Username",
    "admins": [
      "Your Twitch Username",
      "Your Bot Name",
      "Your first Mod",
      "Your second Mod",
      "Your other Mod",
      "Your other Mod",
      "Your other Mod",
      "Your other Mod",
      "Your other Mod"
    ],
    "language": "DE",
    "prefix": "!",
    "enablePublicCommands": true,
    "enableModCommands": true,
    "enableAutoStopStreamOnHostOrRaid": true,
    "announceRaidOnAutoStop": true,
    "commands": {
      "Switch": {
        "permission": "Mod",
        "alias": [
          "ss"
        ]
      },
      "Fix": {
        "permission": "Mod",
        "alias": [
          "f"
        ]
      },
      "Sourceinfo": {
        "permission": "Mod",
        "alias": null
      },
      "Refresh": {
        "permission": "Mod",
        "alias": [
          "r"
        ]
      },
      "Bitrate": {
        "permission": "Public",
        "alias": [
          "b"
        ]
      },
      "Trigger": {
        "permission": "Mod",
        "alias": null
      }
    }
  },
  "optionalScenes": {
    "starting": "OBS Your Stream starting soon Scene",
    "ending": "OBS Your Stream has ended Scene",
    "privacy": "OBS Your Stream Privacy Scene (Bio Break e.g.)",
    "refresh": "OBS Your offline or Low Bitrate Scene Name"
  },
  "optionalOptions": {
    "twitchTranscodingCheck": true,
    "twitchTranscodingRetries": 5,
    "twitchTranscodingDelaySeconds": 15,
    "offlineTimeout": null,
    "recordWhileStreaming": false
  }
}

Tag summary

Content type

Image

Digest

sha256:e15530df7…

Size

48.9 MB

Last updated

about 2 years ago

docker pull glowf1sh/srtla-receiver:v1.9-arm64