zitadel/pkg/management/management.go

22 lines
461 B
Go
Raw Normal View History

2020-03-18 14:46:41 +00:00
package management
import (
"context"
2020-03-30 16:08:54 +00:00
"github.com/caos/logging"
2020-03-18 14:46:41 +00:00
2020-03-25 06:58:58 +00:00
"github.com/caos/zitadel/internal/api/auth"
app "github.com/caos/zitadel/internal/management"
"github.com/caos/zitadel/pkg/management/api"
2020-03-18 14:46:41 +00:00
)
type Config struct {
2020-03-27 12:57:16 +00:00
App app.Config
API api.Config
2020-03-18 14:46:41 +00:00
}
2020-03-27 12:57:16 +00:00
func Start(ctx context.Context, config Config, authZ auth.Config) error {
2020-03-30 16:08:54 +00:00
err := api.Start(ctx, config.API)
logging.Log("MAIN-6dhRs").OnError(err).Panic("unable to start api")
return err
2020-03-18 14:46:41 +00:00
}