Skip to content

Commit

Permalink
Portal now has config with fewer levels
Browse files Browse the repository at this point in the history
  • Loading branch information
matskramer committed Dec 20, 2024
1 parent 3d58367 commit c594f32
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
2 changes: 1 addition & 1 deletion internal/portal/apiv1/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ func New(ctx context.Context, tracer *trace.Tracer, cfg *model.Cfg, log *logger.
}

var err error
c.datastoreClient, err = datastoreclient.New(&datastoreclient.Config{URL: cfg.Portal.Services.APIGW.BaseURL})
c.datastoreClient, err = datastoreclient.New(&datastoreclient.Config{URL: cfg.Portal.ApigwApiServer.Addr})
if err != nil {
return nil, err
}
Expand Down
8 changes: 2 additions & 6 deletions pkg/model/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -159,12 +159,8 @@ type APIGW struct {

// Portal holds the persistent storage configuration
type Portal struct {
APIServer APIServer `yaml:"api_server" validate:"required"`
Services struct {
APIGW struct {
BaseURL string `yaml:"base_url"`
} `yaml:"apigw"`
} `yaml:"services"`
APIServer APIServer `yaml:"api_server" validate:"required"`
ApigwApiServer APIServer `yaml:"apigw_api_server" validate:"required"`
}

// OTEL holds the opentelemetry configuration
Expand Down

0 comments on commit c594f32

Please sign in to comment.