-
Notifications
You must be signed in to change notification settings - Fork 245
refactoring network stack (and static ip) #878
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
Conversation
| setNetworkSettings({ ...networkSettings, lldp_mode: value as LLDPMode }); | ||
| }; | ||
| // Build list of critical changes for display | ||
| const changes: { label: string; from: string; to: string }[] = []; |
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.
Some properties need to be confirmed in a modal.
| confirmText="Apply changes" | ||
| onConfirm={() => { | ||
| setShowCriticalSettingsConfirm(false); | ||
| if (stagedSettings) onSubmit(stagedSettings); |
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.
Once confirmed, we call the actualy onSubmit()
| } | ||
| } | ||
|
|
||
| if (resp.method === "willReboot") { |
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.
If the device sends us a willReboot message, we navigate to the root route and show the reboot overlay.
Currently, we have two flows using this:
- Click on reboot, which will send
willRebootright before actually rebooting - Given a certain network change, the backend will send this
In the future we can use this flow for the OTA.
|
|
||
| if rebootNeeded { | ||
| scopedLogger.Info().Msg("System Rebooting in 10s") | ||
|
|
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.
We can use the willReboot flow for the OTA too. Might need some tweaking, but the flow and interface should be enough.
…4Card and StaticIpv6Card components
|
Now I have to rebase the localization :) |
UI TODO:
Hostnamefield.Savebutton doesn't work (this might require fixing the Tailwind animation class).MAC Addressfield is read-only, but the style is the same. We should probably change it tospaninstead of 'input'.Apply network settingsconfirmation dialog also closes the whole settings tab instead of the confirmation dialog.subnet maskoptional for IPv4 static address, hide it if/is detected.Backend TODO:
Classless Static Route Option6rdIEEE 802.1Q VLAN ID