boot

package
v0.0.0-...-6530c03 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Up

func Up(env Env) error

Up is called in main.go to boot up and run Finch.

Types

type CommandLine

type CommandLine struct {
	Options
	Args []string `arg:"positional"`
}

func ParseCommandLine

func ParseCommandLine(args []string) (CommandLine, error)

type Env

type Env struct {
	Args []string
	Env  []string
}

Env is the startup environment: command line args and environment variables. This is mostly used for testing to override the defaults.

type Options

type Options struct {
	Client     string `arg:"env:FINCH_CLIENT"`
	CPUProfile string `arg:"--cpu-profile,env:FINCH_CPU_PROFILE"`
	Database   string `arg:"-D,--database,env:FINCH_DB"`
	Debug      bool   `arg:"env:FINCH_DEBUG"`
	DSN        string `arg:"env:FINCH_DSN"`
	Help       bool
	Params     []string `arg:"-p,--param,separate"`
	Server     string   `arg:"env:FINCH_SERVER"`
	Test       bool     `arg:"env:FINCH_TEST"`
	Version    bool
}

Options represents the command line options

Jump to

Keyboard shortcuts

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