quickstart: for -existing-webserver, also tls key/cert placeholder for mail.$domain

unless mail.$domain is the mx hostname.

after question about which tls certs are needed from robbo5000 on matrix
This commit is contained in:
Mechiel Lukkien 2024-12-08 10:18:57 +01:00
parent 2255ebcf11
commit 5320ec1c5b
No known key found for this signature in database

View file

@ -744,6 +744,7 @@ many authentication failures).
hostbase := filepath.FromSlash("path/to/" + dnshostname.Name()) hostbase := filepath.FromSlash("path/to/" + dnshostname.Name())
mtastsbase := filepath.FromSlash("path/to/mta-sts." + domain.Name()) mtastsbase := filepath.FromSlash("path/to/mta-sts." + domain.Name())
autoconfigbase := filepath.FromSlash("path/to/autoconfig." + domain.Name()) autoconfigbase := filepath.FromSlash("path/to/autoconfig." + domain.Name())
mailbase := filepath.FromSlash("path/to/mail." + domain.Name())
public.TLS = &config.TLS{ public.TLS = &config.TLS{
KeyCerts: []config.KeyCert{ KeyCerts: []config.KeyCert{
{CertFile: hostbase + "-chain.crt.pem", KeyFile: hostbase + ".key.pem"}, {CertFile: hostbase + "-chain.crt.pem", KeyFile: hostbase + ".key.pem"},
@ -751,6 +752,9 @@ many authentication failures).
{CertFile: autoconfigbase + "-chain.crt.pem", KeyFile: autoconfigbase + ".key.pem"}, {CertFile: autoconfigbase + "-chain.crt.pem", KeyFile: autoconfigbase + ".key.pem"},
}, },
} }
if mailbase != hostbase {
public.TLS.KeyCerts = append(public.TLS.KeyCerts, config.KeyCert{CertFile: mailbase + "-chain.crt.pem", KeyFile: mailbase + ".key.pem"})
}
fmt.Println( fmt.Println(
`Placeholder paths to TLS certificates to be provided by the existing webserver `Placeholder paths to TLS certificates to be provided by the existing webserver