structures

package
v0.0.0-...-4ddc9e0 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cache

type Cache struct {
	Containers []types.Container
	Updated    time.Time
}

type Config

type Config struct {
	Version string
	HTTP    struct {
		Listen      string
		Port        int
		RateLimiter string
	}
	RateLimiter struct {
		Limit  string
		Prefix string
	}
	Redis struct {
		Address  string // takes env variable
		Username string // takes env variable
		Password string // takes env variable
		DB       int
	}
}

func (Config) HTTPAddress

func (config Config) HTTPAddress() string

type ContainerInfo

type ContainerInfo struct {
	Name    string
	Version string
	State   string
	Status  string
}

type HTTPRequest

type HTTPRequest struct {
	Gin *gin.Context
	Ctx *ParserContext
}

type ParserContext

type ParserContext struct {
	Config  *Config
	Gin     *gin.Engine
	Docker  *client.Client
	Cache   *Cache
	Crontab *crontab.Crontab
	Tasks   map[string]*Task
	Redis   *redis.Client
}

type Task

type Task struct {
	Name string
	Cron string
	Exec func(ctx *ParserContext)
}

Jump to

Keyboard shortcuts

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