Restructure database config (#1700)

This commit is contained in:
Kristoffer Dalby 2024-02-09 07:27:00 +01:00 committed by GitHub
parent 00e7550e76
commit 94b30abf56
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
11 changed files with 180 additions and 114 deletions

View file

@ -41,8 +41,12 @@ func (s *Suite) ResetDB(c *check.C) {
}
cfg := types.Config{
NoisePrivateKeyPath: tmpDir + "/noise_private.key",
DBtype: "sqlite3",
DBpath: tmpDir + "/headscale_test.db",
Database: types.DatabaseConfig{
Type: "sqlite3",
Sqlite: types.SqliteConfig{
Path: tmpDir + "/headscale_test.db",
},
},
IPPrefixes: []netip.Prefix{
netip.MustParsePrefix("10.27.0.0/23"),
},