db

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Oct 17, 2026 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func TestConnection

func TestConnection(p config.Profile) error

Types

type DBConnection

type DBConnection struct {
	DB        *sql.DB
	SSHClient *ssh.Client
	Profile   config.Profile
	Mode      string // "direct" or "tunnel"
}

DBConnection represents a PostgreSQL connection, possibly via SSH.

func Connect

func Connect(p config.Profile) (*DBConnection, error)

Connect returns a PostgreSQL connection (direct or via SSH tunnel).

func (*DBConnection) Close

func (c *DBConnection) Close()

Jump to

Keyboard shortcuts

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