Mercurial > prosody-hg
comparison util/prosodyctl/cert.lua @ 12219:0a44def211fa
util.prosodyctl.cert: Look for certs matching 'http_host'
This should ensure any certificate needed for HTTP services will also be
included in the certificate import.
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Thu, 27 Jan 2022 16:23:26 +0100 |
| parents | 0f5d04c3092f |
| children | 05c250fa335a |
comparison
equal
deleted
inserted
replaced
| 12218:0795e1ccf3d8 | 12219:0a44def211fa |
|---|---|
| 199 end | 199 end |
| 200 else | 200 else |
| 201 for host in pairs(prosody.hosts) do | 201 for host in pairs(prosody.hosts) do |
| 202 if host ~= "*" and configmanager.get(host, "enabled") ~= false then | 202 if host ~= "*" and configmanager.get(host, "enabled") ~= false then |
| 203 table.insert(hostnames, host); | 203 table.insert(hostnames, host); |
| 204 local http_host = configmanager.get(host, "http_host") or host; | |
| 205 if http_host ~= host then | |
| 206 table.insert(hostnames, http_host); | |
| 207 end | |
| 204 end | 208 end |
| 205 end | 209 end |
| 206 end | 210 end |
| 207 end | 211 end |
| 208 if not arg[1] or arg[1] == "--help" then -- Probably forgot the path | 212 if not arg[1] or arg[1] == "--help" then -- Probably forgot the path |
