mirror of
https://github.com/caddyserver/caddy.git
synced 2025-01-24 17:46:57 +01:00
Show message when activating HTTPS
It can take a few seconds...
This commit is contained in:
parent
18e9aa4d57
commit
e56f7affc9
2 changed files with 9 additions and 5 deletions
|
@ -114,10 +114,19 @@ func loadConfigs(filename string, input io.Reader) ([]server.Config, error) {
|
||||||
// the rest of the middlewares so they have correct information regarding
|
// the rest of the middlewares so they have correct information regarding
|
||||||
// TLS configuration, if necessary. (this call is append-only, so our
|
// TLS configuration, if necessary. (this call is append-only, so our
|
||||||
// iterations below shouldn't be affected)
|
// iterations below shouldn't be affected)
|
||||||
|
if !IsRestart() && !Quiet {
|
||||||
|
fmt.Print("Activating privacy features...")
|
||||||
|
}
|
||||||
configs, err = letsencrypt.Activate(configs)
|
configs, err = letsencrypt.Activate(configs)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
if !Quiet {
|
||||||
|
fmt.Println()
|
||||||
|
}
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
if !IsRestart() && !Quiet {
|
||||||
|
fmt.Println(" done.")
|
||||||
|
}
|
||||||
|
|
||||||
// Finish setting up the rest of the directives, now that TLS is
|
// Finish setting up the rest of the directives, now that TLS is
|
||||||
// optimally configured. These loops are similar to above except
|
// optimally configured. These loops are similar to above except
|
||||||
|
|
|
@ -46,11 +46,6 @@ func Activate(configs []server.Config) ([]server.Config, error) {
|
||||||
// just in case previous caller forgot...
|
// just in case previous caller forgot...
|
||||||
Deactivate()
|
Deactivate()
|
||||||
|
|
||||||
// TODO: All the output the end user should see when running caddy is something
|
|
||||||
// simple like "Setting up HTTPS..." (and maybe 'done' at the end of the line when finished).
|
|
||||||
// In other words, hide all the other logging except for on errors. Or maybe
|
|
||||||
// have a place to put those logs.
|
|
||||||
|
|
||||||
// reset cached ocsp statuses from any previous activations
|
// reset cached ocsp statuses from any previous activations
|
||||||
ocspStatus = make(map[*[]byte]int)
|
ocspStatus = make(map[*[]byte]int)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue