Add HTTPS support for the web endpoint with manually configured

certificate/key files.
This commit is contained in:
Ward Vandewege 2021-04-23 16:54:35 -04:00
parent c5a3d0b01c
commit 252c68c50a
3 changed files with 23 additions and 2 deletions

View file

@ -311,7 +311,11 @@ func getHeadscaleApp() (*headscale.Headscale, error) {
DBname: viper.GetString("db_name"),
DBuser: viper.GetString("db_user"),
DBpass: viper.GetString("db_pass"),
TLSCertPath: absPath(viper.GetString("tls_cert_path")),
TLSKeyPath: absPath(viper.GetString("tls_key_path")),
}
h, err := headscale.NewHeadscale(cfg)
if err != nil {
return nil, err