DefaultTLSKey returns the path to the default TLS key file that is used (creating if necessary) when TLS is specified without the key file.
()
| 308 | // file that is used (creating if necessary) when TLS is specified |
| 309 | // without the key file. |
| 310 | func DefaultTLSKey() string { |
| 311 | dir, err := PerkeepConfigDir() |
| 312 | if err != nil { |
| 313 | log.Fatalf("Could not compute DefaultTLSKey: %v", err) |
| 314 | } |
| 315 | return filepath.Join(dir, "tls.key") |
| 316 | } |
| 317 | |
| 318 | // RegisterLetsEncryptCacheFunc registers a func f to return the path to the |
| 319 | // default Let's Encrypt cache. |
no test coverage detected