cli: add option to server streams externally without a player #699
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Add an option to the CLI name --player-external-http, to start an HTTP
server like --player-continuous-http, but without starting a
corresponding player, and streaming to all available interfaces instead
of just the loopback.
This can be useful to stream to devices like smartphones or streaming
boxes, while making use of the better compatibility and performance of
livestreamer.
An accompanying --player-external-http-port option was added to allow
people behind firewalls to add their exceptions only once.
When starting livestreamer in this mode, URLs for the server will be
printed instead of a player being started. Those are detected based
on the IPv4 addresses returned by calling
socket.getaddrinfo(socket.gethostname(), ...), which will work for sure
on UNIX platforms, and should on Windows as well (actual testing
pending), in addition to 127.0.0.1.