dotfiles/nixos/system/timezone.nix
Noah Masur d021baa1bb split nixos from darwin
required because they don't share all attributes
2022-12-21 17:07:58 -07:00

20 lines
544 B
Nix

{ config, pkgs, lib, ... }: {
config = lib.mkIf pkgs.stdenv.isLinux {
# Service to determine location for time zone
services.geoclue2.enable = true;
services.geoclue2.enableWifi = false; # Breaks when it can't connect
location = { provider = "geoclue2"; };
# Enable local time based on time zone
services.localtimed.enable = true;
# Required to get localtimed to talk to geoclue2
services.geoclue2.appConfig.localtimed.isSystem = true;
services.geoclue2.appConfig.localtimed.isAllowed = true;
};
}