nixos/docker-rootless: disable for root

This commit is contained in:
Nikolay Amiantov 2022-02-05 14:37:11 +03:00
parent 1ce6ed1917
commit cb18e6cd01

View file

@ -76,7 +76,11 @@ in
# needs newuidmap from pkgs.shadow
path = [ "/run/wrappers" ];
environment = proxy_env;
unitConfig.StartLimitInterval = "60s";
unitConfig = {
# docker-rootless doesn't support running as root.
ConditionUser = "!root";
StartLimitInterval = "60s";
};
serviceConfig = {
Type = "notify";
ExecStart = "${cfg.package}/bin/dockerd-rootless --config-file=${daemonSettingsFile}";