container

package
v0.0.31 Latest Latest
Warning

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

Go to latest
Published: May 6, 2025 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package container provides utilities for managing containers, including creating, starting, stopping, and monitoring containers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetOrGenerateContainerName

func GetOrGenerateContainerName(containerName, image string) (string, string)

GetOrGenerateContainerName generates a container name if not provided. It returns both the container name and the base name. If containerName is not empty, it will be used as both the container name and base name. If containerName is empty, a name will be generated based on the image.

func NewMonitor

func NewMonitor(rt runtime.Runtime, containerID, containerName string) runtime.Monitor

NewMonitor creates a new container monitor

Types

type Factory

type Factory struct{}

Factory creates container runtimes

func NewFactory

func NewFactory() *Factory

NewFactory creates a new container factory

func (*Factory) Create

func (*Factory) Create(ctx context.Context) (runtime.Runtime, error)

Create creates a container runtime

Directories

Path Synopsis
Package docker provides Docker-specific implementation of container runtime, including creating, starting, stopping, and monitoring containers.
Package docker provides Docker-specific implementation of container runtime, including creating, starting, stopping, and monitoring containers.
Package kubernetes provides a client for the Kubernetes runtime including creating, starting, stopping, and retrieving container information.
Package kubernetes provides a client for the Kubernetes runtime including creating, starting, stopping, and retrieving container information.
Package runtime provides interfaces and types for container runtimes, including creating, starting, stopping, and monitoring containers.
Package runtime provides interfaces and types for container runtimes, including creating, starting, stopping, and monitoring containers.
Package templates provides utilities for generating Dockerfile templates based on different transport types (uvx, npx).
Package templates provides utilities for generating Dockerfile templates based on different transport types (uvx, npx).

Jump to

Keyboard shortcuts

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