Module cpu

Source

Constantsยง

V1_CPU_PERIOD_PATH ๐Ÿ”’
V1_CPU_QUOTA_PATH ๐Ÿ”’
Default constant Cgroup paths and hierarchy.
V2_CPU_LIMIT_PATH ๐Ÿ”’

Functionsยง

get_container_cpu_limit ๐Ÿ”’
Returns the CPU limit of the container.
get_cpu_limit_v1
Returns the CPU limit when cgroup v1 is utilised.
get_cpu_limit_v2
Returns the CPU limit when cgroup v2 is utilised.
get_system_cpu
Returns the total system cpu.
total_cpu_available
Returns the total number of cpu available as a float.