cli

package
v2.4.18 Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2026 License: MIT Imports: 42 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Version = "dev"

Version is set by main at startup from the ldflags-injected value.

Functions

func Run

func Run(args []string, stdout, stderr io.Writer) int

Run dispatches Cortex CLI commands.

func SetDeepDBOpener added in v2.4.18

func SetDeepDBOpener(opener DeepDBOpener)

SetDeepDBOpener wires the PostgreSQL probe seam. Called by cmd/cortex (the sole server-composition bridge) before command dispatch; harmless if called repeatedly with the same opener.

Types

type DeepDBOpener added in v2.4.18

type DeepDBOpener func(ctx context.Context, dsn string) (*sql.DB, error)

DeepDBOpener opens a database/sql connection pool over a registered PostgreSQL driver and verifies connectivity with a ping before returning. The driver name is deliberately absent from the signature: the injector owns the driver registration (pgx stdlib in the server composition).

Jump to

Keyboard shortcuts

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