Controlling / Configuring MistServer
Once installed & running
MistServer has several methods of control, the main method is through our API (either directly or through our interface. Other methods would be through configuration editing and using the MistServer binaries through the Command Line Interface.
API / Interface
The API is the first and most complete method of controlling MistServer, the interface is build as an example implementation of using the API and perhaps the easiest starting point to begin with MistServer. At default settings you can find the MistServer API at port 4242 and connect to it using a browser to http://mistserveraddress:4242.
When MistServer is running on the same device as your browser you can use http://localhost:4242, however pay extra attention when copying over any input urls, they will contain localhost as well.
The first time you boot MistServer you will be prompted to make an account, this is either through the terminal or upon first time accessing the API. This account will then need to be used to authorize API commands later on.
Should you ever wish to reset this log in or add additional logins you can do so by booting MistController with the -a account:password flag, any existing account would be overwritten.
If you wish to know more about the API or interface please visit their dedicated pages for more information.
Configuration edit
MistServers configurations are stored in a config.json file within the folder you're running MistController from, or at /etc/mistserver.conf if ran as a system service. By default MistServer will monitor the configuration file and if edited apply the changes to the current live configuration.
You can change this by setting a boot parameter. --configrw or -C with either r, w or rw:
- 'r', read configuration changes from disk.
- 'w', writes them to disk after 60 seconds of no changes.
- 'rw', does both (default). In all other cases does neither.
While MistServer stores everything as a single line json it does not matter whether you're saving it as a single line or not, as long as it's valid json. If you'd like more information about how to control MistServer through editing the configuration file please look at their dedicated pages.
Command Line Interface
Starting the MistController would boot up MistServer and allows you to instruct it through the APi/interface and configuration file. However almost all MistServer binaries can also be ran individually for several results as well. This could be debugging purposes, reconstructing live only or segmented streams or simply testing out a different configuration.
If you wish to know more about what you can do with the MistServer binaries we recommend running them with the -j (json format) or -h (human readable in terminal) flag for more information or opening the dedicated Command Line Interface pages.
Each binary within MistServer has its dedicated task, which you can usually guess once you understand the naming scheme.
MistController: The main controlling binary that can open/close the other ones.MistIn*: Stream/file inputs for creating streams within MistServer, file and pull input.MistOut*: Streams with outgoing connections, this means viewers and live inputs.MistProc*: Process binaries made to manipulate/change streaming data.MistUtil*: Utility processes, helps with setup or debugging.MistAnalyser*: Analysers, analyse stream validity or reconstruct live streams to easier to use files.MistSession: Starts a session within MistServer, generally ran by other processes to keep an accurate count of inputs, outputs and viewers.
Want to know more about a specific control/configuration topic?
📄️ API
Using the API
📄️ Interface
Using the API
📄️ Command Line Interface
Using the CLI
📄️ Config editing
Directly editing config