Skip to content

Commit

Permalink
chore: enable migrate
Browse files Browse the repository at this point in the history
  • Loading branch information
katallaxie authored Sep 3, 2024
1 parent 3ac364d commit 93a1570
Showing 1 changed file with 33 additions and 1 deletion.
34 changes: 33 additions & 1 deletion cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,15 @@ import (
"log"

"github.com/kelseyhightower/envconfig"
"github.com/zeiss/fiber-goth/adapters"
"github.com/zeiss/fiber-goth/providers"
"github.com/zeiss/fiber-goth/providers/github"
reload "github.com/zeiss/fiber-reload"
seed "github.com/zeiss/gorm-seed"
"github.com/zeiss/service-lens/internal/adapters/db"
"github.com/zeiss/service-lens/internal/adapters/handlers"
"github.com/zeiss/service-lens/internal/cfg"
"github.com/zeiss/service-lens/internal/models"

"github.com/gofiber/fiber/v2"
logger "github.com/gofiber/fiber/v2/middleware/logger"
Expand Down Expand Up @@ -104,7 +106,37 @@ func (s *WebSrv) Start(ctx context.Context, ready server.ReadyFunc, run server.R
return err
}

err = store.Migrate(ctx)
err = store.Migrate(ctx,
&adapters.GothUser{},
&adapters.GothAccount{},
&adapters.GothSession{},
&adapters.GothVerificationToken{},
&models.Template{},
&models.Ownable{},
&models.Workflow{},
&models.WorkflowState{},
&models.WorkflowTransition{},
&models.Workable{},
&models.Reaction{},
&models.ProfileQuestion{},
&models.ProfileQuestionChoice{},
&models.ProfileQuestionAnswer{},
&models.Design{},
&models.DesignRevision{},
&models.DesignComment{},
&models.DesignCommentRevision{},
&models.Environment{},
&models.Profile{},
&models.Tag{},
&models.Lens{},
&models.Pillar{},
&models.Question{},
&models.Resource{},
&models.Choice{},
&models.Risk{},
&models.Workload{},
&models.WorkloadLensQuestionAnswer{},
)
if err != nil {
return err
}
Expand Down

0 comments on commit 93a1570

Please sign in to comment.