cmd

package
v0.0.0-...-6a31512 Latest Latest
Warning

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

Go to latest
Published: Apr 7, 2025 License: GPL-3.0 Imports: 39 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Execute

func Execute()

func NewDockerClient

func NewDockerClient() (*client.Client, error)

func WrapCommandWithResources

func WrapCommandWithResources(fn func(cmd *cobra.Command, args []string), resourceCfg ResourceConfig) func(cmd *cobra.Command, args []string)

Types

type AppCtx

type AppCtx struct {
	Docker struct {
		Networks map[string]*network.EndpointSettings
		Client   *client.Client
	}
	Vault struct {
		Prefix string
		Client *onepassword.Client
		ID     string
	}
	Context context.Context
	Spinner *spinner.Spinner
}

func GetApp

func GetApp(cmd *cobra.Command) AppCtx

func (*AppCtx) InitializeDocker

func (ctx *AppCtx) InitializeDocker() error

func (*AppCtx) InitializeOnePass

func (ctx *AppCtx) InitializeOnePass() error

type BuildResponse

type BuildResponse struct {
	Stream string `json:"stream"`
	Error  string `json:"error"`
}

type ContextKey

type ContextKey string
var APP_CONTEXT_KEY ContextKey = "oblivion.app"

type Network

type Network int
const (
	NetworkDatabase Network = iota
	NetworkUptime
	NetworkGrafana
	NetworkLoki
)

type ResourceConfig

type ResourceConfig struct {
	Resources []ResourceType
	Networks  []Network
}

type ResourceType

type ResourceType int
const (
	ResourceDocker ResourceType = iota
	ResourceOnePassword
)

Jump to

Keyboard shortcuts

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