mirror of
https://github.com/bluenviron/mediamtx.git
synced 2025-12-20 02:00:05 -08:00
add 'restart' option to all external commands
This commit is contained in:
parent
e511eb4ef1
commit
38b07ab68a
9 changed files with 191 additions and 115 deletions
6
main.go
6
main.go
|
|
@ -181,8 +181,9 @@ func (p *program) createResources(initial bool) error {
|
|||
|
||||
if p.clientMan == nil {
|
||||
p.clientMan = clientman.New(p.conf.ReadTimeout, p.conf.WriteTimeout,
|
||||
p.conf.RunOnConnect, p.conf.ProtocolsParsed, p.stats,
|
||||
p.serverUdpRtp, p.serverUdpRtcp, p.pathMan, p.serverTcp, p)
|
||||
p.conf.RunOnConnect, p.conf.RunOnConnectRestart,
|
||||
p.conf.ProtocolsParsed, p.stats, p.serverUdpRtp, p.serverUdpRtcp,
|
||||
p.pathMan, p.serverTcp, p)
|
||||
}
|
||||
|
||||
if p.confWatcher == nil {
|
||||
|
|
@ -295,6 +296,7 @@ func (p *program) reloadConf() error {
|
|||
conf.ReadTimeout != p.conf.ReadTimeout ||
|
||||
conf.WriteTimeout != p.conf.WriteTimeout ||
|
||||
conf.RunOnConnect != p.conf.RunOnConnect ||
|
||||
conf.RunOnConnectRestart != p.conf.RunOnConnectRestart ||
|
||||
!reflect.DeepEqual(conf.ProtocolsParsed, p.conf.ProtocolsParsed) {
|
||||
closeClientMan = true
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue