forked from baron/baron-sso
테넌트 등록 방식을 결정
This commit is contained in:
@@ -17,6 +17,11 @@ func Run(db *gorm.DB) error {
|
||||
return fmt.Errorf("migration failed: %w", err)
|
||||
}
|
||||
|
||||
// 2. Seed Tenants
|
||||
if err := SeedTenants(db); err != nil {
|
||||
return fmt.Errorf("tenant seeding failed: %w", err)
|
||||
}
|
||||
|
||||
slog.Info("[Bootstrap] User seed skipped (Kratos is SoT)")
|
||||
slog.Info("[Bootstrap] Bootstrap completed successfully.")
|
||||
return nil
|
||||
@@ -27,6 +32,8 @@ func migrateSchemas(db *gorm.DB) error {
|
||||
// Add all domain models here
|
||||
return db.AutoMigrate(
|
||||
&domain.Tenant{},
|
||||
&domain.TenantDomain{},
|
||||
&domain.User{},
|
||||
&domain.ApiKey{},
|
||||
&domain.IdentityProviderConfig{},
|
||||
// &domain.RelyingParty{}, // TODO: Uncomment when model is ready
|
||||
|
||||
Reference in New Issue
Block a user