diff options
Diffstat (limited to 'openspec/specs/automatic-timezone/spec.md')
| -rw-r--r-- | openspec/specs/automatic-timezone/spec.md | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/openspec/specs/automatic-timezone/spec.md b/openspec/specs/automatic-timezone/spec.md new file mode 100644 index 0000000..a14ef6a --- /dev/null +++ b/openspec/specs/automatic-timezone/spec.md | |||
| @@ -0,0 +1,25 @@ | |||
| 1 | # automatic-timezone Specification | ||
| 2 | |||
| 3 | ## Purpose | ||
| 4 | |||
| 5 | Keeps every NixOS host's system timezone in sync with its actual physical location automatically, so the system clock, GNOME's clock/calendar, and log timestamps reflect local time without any manual `timedatectl` step. | ||
| 6 | |||
| 7 | ## Requirements | ||
| 8 | |||
| 9 | ### Requirement: NixOS hosts detect and apply their timezone automatically | ||
| 10 | Every NixOS host built from this flake's shared system module SHALL determine its current timezone based on location and apply it to the system, without requiring the user to run a manual command or interactively authenticate the change. | ||
| 11 | |||
| 12 | #### Scenario: Timezone is applied after boot with network access | ||
| 13 | - **WHEN** a NixOS host built from this flake's shared system module boots with network connectivity available | ||
| 14 | - **THEN** the system's active timezone is set to the timezone matching the host's current location, without any interactive prompt | ||
| 15 | |||
| 16 | #### Scenario: No per-host opt-in required | ||
| 17 | - **WHEN** a NixOS host is built from this flake's shared system module and its own `hosts/<name>/configuration.nix` does not configure timezone detection itself | ||
| 18 | - **THEN** automatic timezone detection is still active, exactly as if it had been configured directly | ||
| 19 | |||
| 20 | ### Requirement: A host can still pin an explicit fixed timezone | ||
| 21 | A NixOS host built from this flake SHALL be able to override automatic detection with a fixed, explicitly configured timezone when that host's own configuration requires one. | ||
| 22 | |||
| 23 | #### Scenario: Host-level override takes effect | ||
| 24 | - **WHEN** a host's own `hosts/<name>/configuration.nix` sets an explicit timezone at a priority higher than the shared default | ||
| 25 | - **THEN** that host uses the explicitly configured timezone instead of an automatically detected one | ||
