| 284 | } |
| 285 | |
| 286 | func (c *Manager) SetType(cgType CgroupType) error { |
| 287 | // NOTE: We could abort if cgType != Threaded here as currently |
| 288 | // it's not possible to revert back to domain, but not sure |
| 289 | // it's worth being that opinionated, especially if that may |
| 290 | // ever change. |
| 291 | v := Value{ |
| 292 | filename: typeFile, |
| 293 | value: string(cgType), |
| 294 | } |
| 295 | return writeValues(c.path, []Value{v}) |
| 296 | } |
| 297 | |
| 298 | func (c *Manager) RootControllers() ([]string, error) { |
| 299 | b, err := os.ReadFile(filepath.Join(c.unifiedMountpoint, controllersFile)) |