@@ -67,16 +67,15 @@ struct HTTPDInterface {
Usage
-----
-Currently streams can be supplied as a stream through stdin or any ffmpeg-
-compatible URI, e.g. files or network locations. Examples:
+To use ffserver, a config file has to be created that defines what streams to
+read and where to serve them. A sample config is supplied as sample_config.lua.
+This sample config defines two servers with a total of three streams. The first
+server serves two streams on all interfaces on port 8080, while the second
+server serves one stream on 127.0.0.1. The streams can be received by
+requesting the configured stream name as the GET parameter in the HTTP request.
+In the sample config, this would be "http://<server_address>:8080/default_stream"
+for the first stream.
-cat somefile.mkv | ./ffserver
-
-./ffserver somefile.mkv
-
-./ffserver http://somehost/somefile.mkv
-
-This will start reading the file and open port 8080 for HTTP client connections.
The stream is read in real time from whatever resource it is retrieved.
Currently a maximum of 16 clients is implemented.
new file mode 100644
@@ -0,0 +1,28 @@
+-- Sample configuration file for ffserver
+-- Contains all settings
+settings = {
+ -- A server instance
+ default_server = {
+ -- Server settings
+ bind_address = "0.0.0.0",
+ port = 8080,
+ -- Stream settings
+ default_stream = {
+ input = "default.mkv",
+ formats = { "mkv" }, -- later possible: { "mkv", "hls", "dash" }
+ },
+ other_stream = {
+ input = "other_file.mkv",
+ formats = { "mkv" }
+ }
+ },
+ -- Another server instance
+ other_server = {
+ bind_address = "127.0.0.1",
+ port = 8081,
+ default_restream = {
+ input = "yet_another_file.mkv",
+ formats = { "mkv" }
+ }
+ }
+}
Signed-off-by: Stephan Holljes <klaxa1337@googlemail.com> --- Documentation.txt | 17 ++++++++--------- sample_config.lua | 28 ++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+), 9 deletions(-) create mode 100644 sample_config.lua