Merged in feature/permit-integration-1 (pull request #172)
Permit integration - part 1 * WIP permit integration * slim down build * Merge branch 'main' of bitbucket.org:aarete/query-orchestration into feature/permit-integration-1 * omit swagger from auth * clean build * comment * part 1 completed this is the initial permitio parts and tests without integration. Also testing.md since we have a new test target `task test:permitio` * feature flag for no jwt validation * permit integration * fix ci unit tests * ci fix * build fix * fix home handler * fix redirect * test fix * update docs for auth
This commit is contained in:
@@ -20,6 +20,7 @@ import (
|
||||
"os"
|
||||
|
||||
"queryorchestration/internal/client"
|
||||
"queryorchestration/internal/cognitoauth"
|
||||
"queryorchestration/internal/collector"
|
||||
"queryorchestration/internal/document"
|
||||
"queryorchestration/internal/export"
|
||||
@@ -95,7 +96,7 @@ func main() {
|
||||
DocumentUpload: docup,
|
||||
}
|
||||
|
||||
cons := queryapi.NewControllers(services)
|
||||
cons := queryapi.NewControllers(services, cfg)
|
||||
|
||||
queryapi.RegisterHandlers(cfg.Router, cons)
|
||||
|
||||
@@ -128,6 +129,12 @@ func main() {
|
||||
os.Exit(1)
|
||||
}
|
||||
|
||||
// Validate Permit.io configuration before starting server
|
||||
if err := cognitoauth.ValidatePermitIOConfiguration(); err != nil {
|
||||
slog.Error("Permit.io configuration validation failed", "error", err)
|
||||
os.Exit(1)
|
||||
}
|
||||
|
||||
server, err := api.New(ctx, cfg)
|
||||
if err != nil {
|
||||
slog.Error(err.Error())
|
||||
|
||||
Reference in New Issue
Block a user