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

api: Prevent downgrade operations to be done automatically #389

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

detsch
Copy link
Member

@detsch detsch commented Jan 31, 2025

When the latest available target has a version lower than the target that is currently running, we may or not accept it as a valid update to be performed.

Before this commit, aktualizr-lite would automatically select such target and proceed with the update operation. After this commit, the target is not longer selected by default as a valid update target.

It is possible to revert the behavior to the original one by defining ACCEPT_LOWER_VERSION at build time.


@mike-sul in order to keep original aklite-offline behavior, I had to keep the force_downgrade parameter, and add a new one in cli:: methods. Using this new parameter we can easily add a command line option for CLI commands. But in order to avoid having users rely too much on automatic downgrades, it seems better to not have those command line options for now.

When the latest available target has a version lower than the target
that is currently running, we may or not accept it as a valid update
to be performed.

Before this commit, aktualizr-lite would automatically select such
target and proceed with the update operation. After this commit, the
target is not longer selected by default as a valid update target.

It is possible to revert the behavior to the original one by defining
ACCEPT_LOWER_VERSION at build time.

Signed-off-by: Andre Detsch <[email protected]>
@detsch detsch requested a review from mike-sul January 31, 2025 18:40
@detsch detsch marked this pull request as ready for review January 31, 2025 19:44
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.

1 participant