containerd/pkg/systemd
Sebastiaan van Stijn 5d31e93787
pkg/systemd: use sync.Once for systemd detection
This brings over the enhancement from a506630e57.

We don't expect the systemd state to change while containerd is running,
so we can use a `sync.Once` for this, to prevent stat'ing each time.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-09-01 12:14:56 +02:00
..
util.go pkg/systemd: use sync.Once for systemd detection 2023-09-01 12:14:56 +02:00