database

package
v0.0.0-...-fecfafd Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ContainerInfo

type ContainerInfo struct {
	ID            int
	ContainerID   string
	ContainerName string
	ImageName     string
	DomainName    string
	HostPort      string
	ContainerPort string
	Status        string
}

type Database

type Database struct {
	// contains filtered or unexported fields
}

func NewDatabase

func NewDatabase(dbPath string) (*Database, error)

func (*Database) AddContainer

func (d *Database) AddContainer(info ContainerInfo) error

func (*Database) Close

func (d *Database) Close() error

func (*Database) DeleteContainer

func (d *Database) DeleteContainer(containerID string) error

func (*Database) GetContainer

func (d *Database) GetContainer(containerID string) (*ContainerInfo, error)

func (*Database) GetContainersByPartialName

func (d *Database) GetContainersByPartialName(partialName string) ([]ContainerInfo, error)

func (*Database) InitSchema

func (d *Database) InitSchema() error

func (*Database) ListContainers

func (d *Database) ListContainers() ([]ContainerInfo, error)

func (*Database) UpdateContainerStatus

func (d *Database) UpdateContainerStatus(containerID, status string) error

Jump to

Keyboard shortcuts

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