mirror of
https://github.com/caddyserver/caddy.git
synced 2025-01-13 22:51:08 -05:00
Don't change port when TLS is managed manually
This commit is contained in:
parent
345ece3850
commit
5a45719227
1 changed files with 1 additions and 1 deletions
|
@ -138,7 +138,7 @@ func (h *httpContext) MakeServers() ([]caddy.Server, error) {
|
|||
// is incorrect for this site.
|
||||
cfg.Addr.Scheme = "https"
|
||||
}
|
||||
if cfg.Addr.Port == "" {
|
||||
if cfg.Addr.Port == "" && (!cfg.TLS.Manual || cfg.TLS.OnDemand) {
|
||||
// this is vital, otherwise the function call below that
|
||||
// sets the listener address will use the default port
|
||||
// instead of 443 because it doesn't know about TLS.
|
||||
|
|
Loading…
Reference in a new issue