package models import ( "gorm.io/gorm" "gorm.io/driver/sqlite" ) var ( DB *gorm.DB ) func InitDB() { DB, _ = gorm.Open(sqlite.Open("data/colossus.db"), &gorm.Config{}) // Migrate the schema DB.AutoMigrate(&Component{}) }