-
Notifications
You must be signed in to change notification settings - Fork 273
Custom NTP Configuration UI #1102
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: dev
Are you sure you want to change the base?
Conversation
…to available values.
…for IP or hostname.
adamshiervani
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for implementing the time sync configuration and also all your other PRs!!
The functionality is solid, but I think the UI needs a remodel. The current design reflects our internal data model rather than what users actually need.
Usually there are two groups with a 95/5 ratio:
- "Just work" - Automatic time sync, don't care how
- "Use my servers" - Enterprise/air-gapped environments with specific NTP servers
Proposed Simplification
Two modes: Automatic | Custom
Time Synchronization
└─ [Automatic ▼]
When "Custom":
┌────────────────────────────────────────────────────────┐
│ Your NTP Servers │
│ [ntp.internal.corp.com ] [×] │
│ [+ Add Server] │
│ │
│ Your HTTP URLs (optional) │
│ [http://time.internal.corp.com ] [×] │
│ [+ Add URL] │
│ │
│ ☑ Fall back to built-in servers if yours fail │
│ ☐ Also try NTP servers from DHCP (for isolated networks)│
└────────────────────────────────────────────────────────┘
Backend Mapping
| UI State | Backend Values |
|---|---|
| Automatic | time_sync_mode: "ntp_and_http", default ordering |
| Custom + fallback | mode: "custom", ordering: [user_ntp, user_http, ntp, http], disable_fallback: false |
| Custom + fallback + DHCP | Same but ordering includes ntp_dhcp after user sources |
| Custom, no fallback | ordering: [user_ntp, user_http], disable_fallback: true |
|
Hi there! I agree with your comments, and that's what I thought of doing. I implemented this as a first-pass.... just to basically understand what the model was behind the scenes. At least this gives power-users access to the advanced features. From here, yeah, I agree. Things like "Disable Fallback" shouldn't be possible with no specified NTP/HTTP URLs.... A lot of the things should be "automatic" unless specified. Then even the "specified" things should only be the servers / URLs. As long as things behind the scenes only hit the servers specified, I think offline users / air-gaped users would be satisfied. I might get around to simplifying this over the next couple of weeks....but not being a React / TS dev...this makes it a bit of a struggle :P |
As a network engineer, I would expect DHCP to be honored first |
Closes #516, #645, #59
Summary
Checklist
make test_e2elocally and passedCloses #<issue-number>)