Skip to content

Commit

Permalink
fix: Admin service endpoint (#4285)
Browse files Browse the repository at this point in the history
  • Loading branch information
stuartwdouglas authored Feb 4, 2025
1 parent aad717f commit 4a451c7
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions cmd/ftl-admin/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ import (
)

var cli struct {
Version kong.VersionFlag `help:"Show version."`
ObservabilityConfig observability.Config `embed:"" prefix:"o11y-"`
LogConfig log.Config `embed:"" prefix:"log-"`
AdminConfig admin.Config `embed:"" prefix:"admin-"`
SchemaServerEndpoint *url.URL `name:"ftl-endpoint" help:"Controller endpoint." env:"FTL_ENDPOINT" default:"http://127.0.0.1:8892"`
Config string `help:"Path to FTL configuration file." env:"FTL_CONFIG" required:""`
Secrets string `help:"Path to FTL secrets file." env:"FTL_SECRETS" required:""`
Version kong.VersionFlag `help:"Show version."`
ObservabilityConfig observability.Config `embed:"" prefix:"o11y-"`
LogConfig log.Config `embed:"" prefix:"log-"`
AdminConfig admin.Config `embed:"" prefix:"admin-"`
SchemaEndpoint *url.URL `help:"Schema endpoint." env:"FTL_SCHEMA_ENDPOINT" default:"http://127.0.0.1:8897"`
Config string `help:"Path to FTL configuration file." env:"FTL_CONFIG" required:""`
Secrets string `help:"Path to FTL secrets file." env:"FTL_SECRETS" required:""`
}

func main() {
Expand Down Expand Up @@ -58,7 +58,7 @@ func main() {
sm, err := manager.New[cf.Secrets](ctx, dbSecretResolver, asmSecretProvider)
kctx.FatalIfErrorf(err)

schemaClient := rpc.Dial(ftlv1connect.NewSchemaServiceClient, cli.SchemaServerEndpoint.String(), log.Error)
schemaClient := rpc.Dial(ftlv1connect.NewSchemaServiceClient, cli.SchemaEndpoint.String(), log.Error)
eventSource := schemaeventsource.New(ctx, schemaClient)

err = admin.Start(ctx, cli.AdminConfig, cm, sm, admin.NewSchemaRetreiver(eventSource))
Expand Down

0 comments on commit 4a451c7

Please sign in to comment.