Migrate DB: rename namespace, automigrate user
@@ -187,7 +187,9 @@ func (h *Headscale) initDB() error {
return err
}
- err = db.AutoMigrate(&Namespace{})
+ _ = db.Migrator().RenameTable("Namespace", "User")
+
+ err = db.AutoMigrate(&User{})
if err != nil {
return err
}
