rw_resource_util

Module runtime

source

Constants§

Functions§

  • cgroup_exists πŸ”’
    If cgroup exists or is enabled in kernel, returnb true, else false.
  • Given a certain controller, checks if it is enabled. For cgroup v1, existence of directory with controller name is checked in cgroup default root hierarchy. e.g if directory β€œ/sys/fs/cgroup”/cpuβ€œ exists then CPU controller is enabled. For cgroup v2, check the controller list path for the controller name.
  • is_linux_machine πŸ”’
  • checks if is running in a docker container by checking for docker env file, or if it is running in a kubernetes pod.