reorg modules

This commit is contained in:
moicen
2022-06-28 23:46:51 +08:00
committed by 木逸辰
parent f06c818f4a
commit 2357fa3d7e
8 changed files with 28 additions and 16 deletions
+2
View File
@@ -5,8 +5,10 @@ package.path = package.path .. ';<SCRIPT_PATH>/?.lua';
local upload = require "resty.upload"
local uuid = require "resty.jit-uuid"
local http = require "resty.http"
local cjson = require "cjson"
local verify = require('lib.jwt_verify')
local create_task = require("lib.create_task")
local TaskTypes = require 'lib.task_type'
local httpc = http:new()
local authHeader = ngx.req.get_headers().Authorization
local sudoerToken = ngx.req.get_headers().HtySudoerToken
+8
View File
@@ -0,0 +1,8 @@
local TaskTypes = {
NOOP = 'NOOP',
UPLOAD_PICTURE = 'UPLOAD_PICTURE',
CONVERT_AUDIO_FILE = 'CONVERT_AUDIO_FILE',
AI_RATE = 'AI_RATE'
}
return TaskTypes
+1 -4
View File
@@ -2,10 +2,7 @@ package.path = package.path .. ';<SCRIPT_PATH>/?.lua';
local cjson = require "cjson"
local http = require "resty.http"
local create_task = require "lib.create_task"
local TaskTypes = {
NOOP = 'NOOP',
CONVERT_AUDIO_FILE = "CONVERT_AUDIO_FILE"
}
local TaskTypes = require 'lib.task_type'
local httpc = http.new()
ngx.req.read_body()
+1
View File
@@ -7,6 +7,7 @@ local http = require 'resty.http'
local get_wx_media = require("wx_download")
local create_task = require("lib.create_task")
local verify = require('lib.jwt_verify')
local TaskTypes = require 'lib.task_type'
local httpc = http:new()