cmd

package
v0.0.0-...-74aa7bb Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2024 License: EUPL-1.2 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run() error

Types

type Context

type Context struct {
	Logger         slog.Logger
	PSQLSchemaName string
}

type InitCmd

type InitCmd struct {
	PostgresDSN string `env:"MK_POSTGRES_DSN" required:"" name:"postgres-dsn" help:"Postgres Connection URL."`
}

func (*InitCmd) Run

func (opt *InitCmd) Run(ctx *Context) error

type MigrateCmd

type MigrateCmd struct {
	Up   UpCmd   `cmd:"" help:"Migrate the API."`
	Init InitCmd `cmd:"" help:"Init the API."`
}

type ServeCmd

type ServeCmd struct {
	PostgresDSN          string `env:"MK_POSTGRES_DSN" required:"" name:"postgres-dsn" help:"Postgres Connection URL."`
	BackendListenAddress string `env:"MK_BACKEND_LISTEN_ADDRESS" default:":8080" name:"backend-listen-address" help:"Address to listen  on."`

	GlobalConfig       string `env:"MK_GLOBAL_CONFIG_PATH"  default:"../config/global.yaml" name:"global-config" help:"Path to the config file."`
	OrganizationConfig string `env:"MK_CONFIG_PATH" required:"" name:"organization-config" help:"Path to the config file."`

	NotifierEndpoint     string `env:"MK_NOTIFIERDOMAIN_ENDPOINT" required:"" name:"notifier-domain-endpoint" help:"Notifier domain endpoint."`
	NotifierFscGrantHash string `env:"MK_NOTIFIERDOMAIN_FSCGRANTHASH" required:"" name:"notifier-domain-fsc-grant-hash" help:"Notifier domain fsc grant hash."`
}

func (*ServeCmd) Run

func (opt *ServeCmd) Run(ctx *Context) error

type UpCmd

type UpCmd struct {
	PostgresDSN string `env:"MK_POSTGRES_DSN" required:"" name:"postgres-dsn" help:"Postgres Connection URL."`
}

func (*UpCmd) Run

func (opt *UpCmd) Run(ctx *Context) error

Jump to

Keyboard shortcuts

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