添加项目文件。

This commit is contained in:
xx
2024-05-26 23:38:57 +08:00
parent fce628f794
commit e1f3bc9e17
522 changed files with 122908 additions and 0 deletions

19
scripts/init.lua Normal file
View File

@@ -0,0 +1,19 @@
require "website"
-- MYSQL数据库池
function initMysql()
local pool = mysql_pool.new()
if pool:start("127.0.0.1","test","123456","test","utf8mb4",3306,10) == false then
print("start mysql pool failed")
return false
end
global_regist("mysql",pool:self())
return true
end
if initMysql() == false then
return false
end
return true