ERROR>> 2372016#2372016: *795438 lua tcp socket connect timed out, when connecting to
CONF:
init_by_lua_block {
auto_ssl = (require "resty.auto-ssl").new()
auto_ssl:set("storage_adapter", "resty.auto-ssl.storage_adapters.redis")
auto_ssl:set("redis", {
host = "localhost",
port = "6379",
db = "0",
prefix = "admin_ssl"
})
auto_ssl:set("renew_check_interval", 86400)
auto_ssl:set("allow_domain", function(domain, auto_ssl, ssl_options, renewal)
if domain == "admin..app" then
return true
end
local http = require("resty.http")
local httpc = http.new()
httpc:set_timeout(10000)
local uri = "
https://api.app/tenant/validate?k-tenant=" .. domain
local res, err = httpc:request_uri(uri, {
ssl_verify = false,
method = "GET"
})
if not res then
return false
end
if res.status == 200 then
return true
end
if res.status == 404 then
return false
end
end)
auto_ssl:init()
}