Skip to content
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

web: display notifications for actions that can only be done on commandline #75

Merged
merged 4 commits into from
Aug 7, 2024

Conversation

hnez
Copy link
Member

@hnez hnez commented Aug 2, 2024

There are two things in the web interface that look like they can be used to change a piece of configuration but actually can't:

  • The "Enabled" checkboxes in the RAUC update channel list.
  • The active slot display, also in the RAUC section.

As @a3f (I think) rightfully stated this is a bit confusing to the user,
but actually implementing such actions (in a somewhat safe way) would be quite a lot of work and performing these actions is not something a user would do regularly.

Instead display a notification when one of the actions is requested that looks something like this:

cli-notification

@hnez hnez requested a review from KarlK90 August 2, 2024 12:38
@SmithChart
Copy link
Member

Totally agree here. For something that is probably done only once for a device it should be OK to ask the user to complete it on the command line - especially since SSH access is part of the onboarding process.

Copy link
Member

@KarlK90 KarlK90 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@hnez after playing around with several other ideas that didn't really work I approve the change.

This will allow us to add e.g. React `useState`'s that are used by the
whole application in the future.

Signed-off-by: Leonard Göhrs <[email protected]>
The App.test.tsx file was created by create-react-app when initially setting
up the project. It has not been updated or used since then though.

If the parameters of the `App` function ever where to change (foreshadowing)
the build would break, requiring changes to App.test.tsx.

Since the file is unused it can just be removed instead.

Signed-off-by: Leonard Göhrs <[email protected]>
Implementing active rauc slot chaning safely would be quite difficult
and it is also not something users would do regularly.

Display a notification at the top of the screen instead.
The notifications contains the correct command line to perform the desired
change.

Signed-off-by: Leonard Göhrs <[email protected]>
Implementing the update channel actication/deactivation safely would
be somewhat involved.

Display a notification on the commandline instead that shows how to do
the change.

Signed-off-by: Leonard Göhrs <[email protected]>
@hnez hnez merged commit a5faf76 into linux-automation:main Aug 7, 2024
5 checks passed
@hnez hnez deleted the cmdline-notifications branch August 7, 2024 05:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants