Skip to main content

Docker specific instructions

warning

There are differences between running Docker on Linux, Mac and Windows. Linux can share the host network using --network=host Mac and Windows need port publishing using --publish HOST_PORT:CONTAINER_PORT . This makes using the ephermeral range for UDP protocols harder.

The default --shm-size for Docker is 64MB, which is barely enough to do anything for MistServer, please do not forget to set this value!

It's recommended to set a good amount of RAM depending on your hardware. We recommend using 95% if this is a dedicated server. Otherwise we would recommend at least 50% of your RAM. In the interest of keeping this quick and simple the --shm-size=### flag has been set to use 1GB of your RAM.

Set up the following values!

  • --network=host To bind MistServer to the host network, allowing others to connect
  • --publish HOST_PORT:CONTAINER_PORT As alternative to --network=host, required for Mac/Window users
  • /PATH/TO/CONFIG.JSON Host location where you want to store the MistServer configuration.
  • /FOLDER/WITH/VIDEOFILES Host location where VoD content is available
  • 1g Amount of shared memory available to the docker image
docker run --detach --mount type=bind,source=/PATH/TO/CONFIG.JSON,destination=/config.json --mount type=bind,source=/FOLDER/WITH/VIDEOFILES,destination=/video --shm-size=1G --network=host ddvtech/mistserver

For more details on which docker images are available visit our official dockerhub page Keep in mind that some of our Docker images are just the MistServer binaries, while it will make the image itself super lightweight it does not allow for adding applications or running scripts within the Docker itself. Should you need an OS we recommend grabbing one of the images with an OS included or building your own version.

info

Docker works great with MistServer, however there is one technical limitation. Docker's default network set up will significantly impact the performance of network operations. We do not recommend running intense loads on this configuration. Please use bare metal instead! If you stay within ~50% of your network capabilities you will not notice any impact however.

In the examples below we will be using the ddvtech/mistserver_alpine_minimal container, make your own adjustments accordingly.

Minimal Docker compose.yml using --network=host

services:
mistserver:
image: ddvtech/mistserver_alpine_minimal
container_name: mistserver
shm_size: '1gb'
network_mode: 'host'
restart: always

Minimal Docker compose.yml using --publish

services:
mistserver:
image: ddvtech/mistserver_alpine_minimal
container_name: mistserver
shm_size: '1gb'
ports:
- 8080:8080
- 443:443
- 4242:4242
- 8889:8889/udp
- 5554:5554
- 4200:4200
restart: always