app

package
v0.487.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 8, 2025 License: Apache-2.0 Imports: 108 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func KillBackgroundServe

func KillBackgroundServe(logger *log.Logger) error

Types

type App

type App struct {
	// contains filtered or unexported fields
}

func New

func New(ctx context.Context) (*App, error)

func (*App) Run

func (a *App) Run(ctx context.Context, args []string) error

type BuildAndDeploy

type BuildAndDeploy struct {
	Build  buildCmd  `cmd:"" help:"Build all modules found in the specified directories."`
	Deploy deployCmd `cmd:"" help:"Build and deploy all modules found in the specified directories."`
}

type CLI

type CLI struct {
	SharedCLI
	BuildAndDeploy
	LogConfig log.Config `embed:"" prefix:"log-" group:"Logging:"`

	Authenticators map[string]string `help:"Authenticators to use for FTL endpoints." mapsep:"," env:"FTL_AUTHENTICATORS" placeholder:"HOST=EXE,…"`
	Insecure       bool              `help:"Skip TLS certificate verification. Caution: susceptible to machine-in-the-middle attacks."`
	Plain          bool              `help:"Use a plain console with no color or status line." env:"FTL_PLAIN"`

	Interactive interactiveCmd            `cmd:"" help:"Interactive mode." default:""`
	Dev         devCmd                    `` /* 150-byte string literal not displayed */
	Serve       serveCmd                  `cmd:"" help:"Start the FTL server."`
	Completion  kongcompletion.Completion `cmd:"" help:"Outputs shell code for initialising tab completions."`
	Logs        logsCmd                   `cmd:"" help:"View logs from FTL modules."`

	// Specify the 1Password vault to access secrets from.
	Vault string `` /* 183-byte string literal not displayed */

	LSP lspCmd `cmd:"" help:"Start the LSP server."`
	MCP mcpCmd `cmd:"" help:"Start the MCP server."`
}

type DevModeCLI

type DevModeCLI struct {
	SharedCLI
	Logs struct {
		Level logsSetLevelCmd `cmd:"" help:"Set the current log level"`
	} `cmd:"" help:"Log commands."`
}

DevModeCLI is the embedded CLI when running in dev mode.

type InteractiveCLI

type InteractiveCLI struct {
	SharedCLI
	BuildAndDeploy
}

InteractiveCLI is the CLI that is used when running in interactive mode.

type KongContextBinder

type KongContextBinder func(ctx context.Context, kctx *kong.Context) context.Context

type SharedCLI

type SharedCLI struct {
	Version          kong.VersionFlag `help:"Show version."`
	Project          string           `` /* 179-byte string literal not displayed */
	ConfigFlag       string           `name:"config" short:"C" help:"Path to FTL project configuration file." env:"FTL_CONFIG" placeholder:"FILE"`
	TimelineEndpoint *url.URL         `help:"Timeline endpoint." env:"FTL_TIMELINE_ENDPOINT" default:"http://127.0.0.1:8892"`
	AdminEndpoint    *url.URL         `help:"Admin endpoint." env:"FTL_ENDPOINT" default:"http://127.0.0.1:8892"`
	Trace            string           `help:"File to write golang runtime/trace output to." hidden:""`

	Ping      pingCmd      `cmd:"" help:"Ping the FTL cluster."`
	Init      initCmd      `cmd:"" help:"Initialize a new FTL project."`
	Profile   profileCmd   `cmd:"" help:"Manage profiles."`
	Module    moduleCmd    `cmd:"" help:"Manage modules."`
	PS        psCmd        `cmd:"" help:"List deployments."`
	Call      callCmd      `cmd:"" help:"Call an FTL verb."`
	Changeset changesetCmd `cmd:"" help:"Work with changesets."`
	Bench     benchCmd     `cmd:"" help:"Benchmark an FTL verb."`
	Replay    replayCmd    `cmd:"" help:"Call an FTL verb with the same request body as the last invocation."`
	Update    updateCmd    `cmd:"" help:"Update a deployment."`
	Kill      killCmd      `cmd:"" help:"Kill a deployment."`
	Schema    schemaCmd    `cmd:"" help:"FTL schema commands."`
	Download  downloadCmd  `cmd:"" help:"Download a deployment."`
	Secret    secretCmd    `cmd:"" help:"Manage secrets."`
	Config    configCmd    `cmd:"" help:"Manage configuration."`
	Pubsub    pubsubCmd    `cmd:"" help:"Manage pub/sub."`
	Goose     gooseCmd     `cmd:"" help:"Run a goose command."`
	Mysql     mySQLCmd     `cmd:"" help:"Manage MySQL databases."`
	Postgres  postgresCmd  `cmd:"" help:"Manage PostgreSQL databases."`
	Edit      editCmd      `cmd:"" help:"Edit a declaration in an IDE."`
	Realm     realmCmd     `cmd:"" help:"Manage realms." hidden:""`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL