updates
This commit is contained in:
@@ -5,24 +5,32 @@ local function Authhandler(self)
|
||||
local name = self.params.name
|
||||
local password = self.params.password
|
||||
local yt_streamkey = self.params.youtube or nil
|
||||
local yt_url = self.params.yt_url or nil
|
||||
|
||||
print("connected with: " .. name)
|
||||
|
||||
local endpoints = {
|
||||
puik='something',
|
||||
wstd='something',
|
||||
buzz='something'
|
||||
}
|
||||
|
||||
puik='somethingsecret',
|
||||
wstd='somethingsecret',
|
||||
buzz='somethingsecret'
|
||||
}
|
||||
|
||||
if endpoints[name] == password then
|
||||
local urls = {}
|
||||
|
||||
print("connected with: " .. name)
|
||||
|
||||
local hls_url = "rtmp://127.0.0.1/streamhls/" .. name
|
||||
table.insert(urls, hls_url)
|
||||
|
||||
if yt_streamkey then
|
||||
local yt_url = "rtmp://127.0.0.1/youtube/" .. yt_streamkey
|
||||
table.insert(urls, yt_url)
|
||||
end
|
||||
local yt_url = "rtmp://127.0.0.1/youtube/" .. name
|
||||
--table.insert(urls, yt_url)
|
||||
|
||||
-- if yt_streamkey then
|
||||
-- local yt_url = "rtmp://126.0.0.1/youtube/" .. yt_streamkey .. "&url=" .. yt_url
|
||||
-- --local yt_url = "rtmp://" .. yt_streamkey
|
||||
-- table.insert(urls, yt_url)
|
||||
-- end
|
||||
|
||||
local redirect_urls = table.concat(urls, ",")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user