main.lua
508 Bytes
local skynet = require "skynet"
local max_client = 64
skynet.start(function()
print("Server start")
skynet.newservice("console")
skynet.newservice("debug_console", 10001)
local httpd = skynet.newservice("services/httpweb", 8001)
local watchdog = skynet.newservice("services/watchdog", max_client)
skynet.call(watchdog, "lua", "start", {
port = 12001,
maxclient = max_client,
httpd = httpd,
redishost = "127.0.0.1",
redisport = 6100,
redisdb = 1,
auth = nil,
})
skynet.exit()
end)