Skip to content

Commit

Permalink
docs/systemd: describe device rules
Browse files Browse the repository at this point in the history
Signed-off-by: Kir Kolyshkin <[email protected]>
  • Loading branch information
kolyshkin committed Apr 26, 2023
1 parent 81f0439 commit 64b9f6b
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions docs/systemd.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,25 @@ The following tables summarize which properties are translated.
For documentation on systemd unit resource properties, see
`systemd.resource-control(5)` man page.

### Device access rules

Runc translates device access rules from the runtime spec to systemd properties
(`DevicePolicy` and `DeviceAllow`). Not all rules and rulesets are supported.
For example, the following can not be translated:
- blacklist-style rulesets;
- major-wildcard rules (meaning "all devices with the given minor number").

NOTE that systemd v240 or later is highly recommended, since older versions
have limited ways to interpret `DeviceAllow` rules. When using systemd older
than v240, the following limitations exist:

- it is not possible to add a rule for a device that does not have an
equivalent `/dev/{char,block}/<MAJOR>:<minor>` file on the host
(for example, this is the case for NVidia devices);
- adding a wildcard rule with the set major number and the unset minor number
(meaning "all devices with the given major number") results in adding a set
of individual rules for existing devices with the given major number.

### Auxiliary properties

Auxiliary properties of a systemd unit (as shown by `systemctl show
Expand Down

0 comments on commit 64b9f6b

Please sign in to comment.