Versions in this module Expand all Collapse all v0 v0.7.6 Oct 23, 2025 v0.7.5 Jun 30, 2025 Changes in this version + const DefaultCPUPercentage + const DefaultCgroup + const DefaultJobObjectName + const DefaultMountpoint + const JOB_OBJECT_CPU_RATE_CONTROL_ENABLE — windows/amd64 + const JOB_OBJECT_CPU_RATE_CONTROL_HARD_CAP — windows/amd64 + var DefaultConfig = Config + type Config struct + CPUPercentage float64 + Cgroup string + JobName string + MemoryKB int64 + type Limits struct + func New(opts ...Option) (*Limits, error) + func (l *Limits) LimitProcess(proc execute.ProcessID) error + func (l *Limits) ListProcesses() ([]int, error) + func (l *Limits) RemoveAllLimits() error + func (l *Limits) Shutdown() error + type Option func(*Config) + func WithCPUPercentage(p float64) Option + func WithCgroup(path string) Option + func WithJobObjectName(name string) Option + func WithMemoryKB(limit int64) Option