mirror of
https://github.com/micromdm/micromdm/
synced 2026-08-14 17:41:43 +08:00
assign workflows
This commit is contained in:
32
main.go
32
main.go
@@ -78,6 +78,22 @@ func main() {
|
||||
os.Exit(1)
|
||||
}
|
||||
|
||||
//profileDB must exist before workflowDB
|
||||
// TODO this is getting messy and migrations should be handled by a separate thing
|
||||
profileDB := profile.NewDB(
|
||||
"postgres",
|
||||
*flPGconn,
|
||||
profile.Logger(logger),
|
||||
profile.Debug(),
|
||||
)
|
||||
|
||||
workflowDB := workflow.NewDB(
|
||||
"postgres",
|
||||
*flPGconn,
|
||||
workflow.Logger(logger),
|
||||
workflow.Debug(),
|
||||
)
|
||||
|
||||
deviceDB := device.NewDB(
|
||||
"postgres",
|
||||
*flPGconn,
|
||||
@@ -119,22 +135,6 @@ func main() {
|
||||
)
|
||||
connectHandler := connect.ServiceHandler(ctx, connectSvc)
|
||||
|
||||
//profileDB must exist before workflowDB
|
||||
// TODO this is getting messy and migrations should be handled by a separate thing
|
||||
profileDB := profile.NewDB(
|
||||
"postgres",
|
||||
*flPGconn,
|
||||
profile.Logger(logger),
|
||||
profile.Debug(),
|
||||
)
|
||||
|
||||
workflowDB := workflow.NewDB(
|
||||
"postgres",
|
||||
*flPGconn,
|
||||
workflow.Logger(logger),
|
||||
workflow.Debug(),
|
||||
)
|
||||
|
||||
workflowSvc := workflow.NewService(workflow.DB(workflowDB))
|
||||
workflowHandler := workflow.ServiceHandler(ctx, workflowSvc)
|
||||
// profiles
|
||||
|
||||
Reference in New Issue
Block a user