Skip to content

Conversation

johnstcn
Copy link
Member

@johnstcn johnstcn commented May 10, 2023

Fixes #28

  • No longer fails when trying to copy outer container quota to inner container.
    Warns in buildlog instead.
  • Adds logic to determine current cgroup from /proc/self/cgroup
  • Adds logic to read cpu.max from /sys/fs/cgroup//cpu.max
  • Adds logic to write cpu.max to /sys/fs/cgroup/docker//init.scope/cpu.max
  • Adds more unit tests around all of the above for both cgroupv1 and cgroupv2

Tested on:

  • Rocky 9.1, kernel 5.14.0-162.23.1.el9_1.x86_64
  • k3s v1.26.4
  • Coder v0.23.2

Tested with both systemd.unified_cgroup_hierarchy=1 and systemd.unified_cgroup_hierarchy=0.

You can test yourself with the envbox image gcr.io/coder-dev-1/coder-cian/envboxv2:pr34

Screenshot 2023-05-10 at 12 09 16

Screenshot 2023-05-10 at 12 06 58

@johnstcn johnstcn self-assigned this May 10, 2023
@johnstcn johnstcn requested a review from sreya May 10, 2023 11:18
@johnstcn johnstcn merged commit b0b58d6 into main May 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

bug: envbox fails to start if CGroupV2 is enabled
2 participants