Skip to content
This repository was archived by the owner on May 1, 2025. It is now read-only.
This repository was archived by the owner on May 1, 2025. It is now read-only.

Allow limiting system resource usage #9

@GrumpyBear57

Description

@GrumpyBear57

I'd like to be able to limit how many system resources the KT runner is allowed to consume. Something like MAX_CPU and MAX_MEM where mem accepts a percent or a unit. I also would like a system variant (MAX_SYS_CPU and MAX_SYS_MEM) that prevents the runner from starting new containers if the system wide utilization would exceed those values.
The runner should also probably default to some sane values (i.e. 50% for runner specific, and 80% for system wide)and check to ensure that there is enough to run a single container (i.e. > 5% CPU, > 500MB memory).

A network utilization limit may also be nice for other people hosting the runner on slower connections, but this is probably lower priority since the network utilization seems rather low anyways.

example:

MAX_CPU=60%
MAX_SYS_CPU=90%
MAX_MEM=50%
MAX_SYS_MEM=80%

or

MAX_MEM=8192MB
MAX_SYS_MEM=80%

or

MAX_MEM=8GB
MAX_SYS_MEM=16GB

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions