tzupdate: initial service switch from static timezone
Signed-off-by: Myned <dev@bjork.tech>
This commit is contained in:
parent
d948aac059
commit
5b5a6d823b
3 changed files with 16 additions and 3 deletions
|
@ -10,6 +10,7 @@ with lib; {
|
||||||
#// agenix.enable = true;
|
#// agenix.enable = true;
|
||||||
#// netbird.enable = true;
|
#// netbird.enable = true;
|
||||||
tailscale.enable = true;
|
tailscale.enable = true;
|
||||||
|
tzupdate.enable = true;
|
||||||
})
|
})
|
||||||
|
|
||||||
(mkIf config.custom.minimal {
|
(mkIf config.custom.minimal {
|
||||||
|
|
15
options/custom/services/tzupdate.nix
Normal file
15
options/custom/services/tzupdate.nix
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
with lib; let
|
||||||
|
cfg = config.custom.services.tzupdate;
|
||||||
|
in {
|
||||||
|
options.custom.services.tzupdate.enable = mkOption {default = false;};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable {
|
||||||
|
# https://github.com/cdown/tzupdate
|
||||||
|
services.tzupdate.enable = true;
|
||||||
|
};
|
||||||
|
}
|
|
@ -9,13 +9,10 @@ in {
|
||||||
options.custom.settings.environment = {
|
options.custom.settings.environment = {
|
||||||
enable = mkOption {default = false;};
|
enable = mkOption {default = false;};
|
||||||
builder = mkOption {default = config.custom.full;};
|
builder = mkOption {default = config.custom.full;};
|
||||||
timezone = mkOption {default = "America/Chicago";};
|
|
||||||
wayland = mkOption {default = config.custom.minimal;};
|
wayland = mkOption {default = config.custom.minimal;};
|
||||||
};
|
};
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
time.timeZone = cfg.timezone;
|
|
||||||
|
|
||||||
# https://wiki.nixos.org/wiki/Cross_Compiling
|
# https://wiki.nixos.org/wiki/Cross_Compiling
|
||||||
boot.binfmt.emulatedSystems = mkIf cfg.builder ["aarch64-linux"]; # Emulate architecture
|
boot.binfmt.emulatedSystems = mkIf cfg.builder ["aarch64-linux"]; # Emulate architecture
|
||||||
#// nixpkgs.buildPlatform = "x86_64-linux"; # Binary caches often not available
|
#// nixpkgs.buildPlatform = "x86_64-linux"; # Binary caches often not available
|
||||||
|
|
Loading…
Reference in a new issue