Skip to content

Conversation

@ianroberts
Copy link

Add a flag to the migrator command to allow the user to specify a key prefix that they want to back up, rather than hard coding to always back up the entire database. This is useful in several situations, including:

  • when a user wants to back up only specific object types, e.g. to back up just their secrets they could specify --prefix /registry/secrets
  • when they have an older dqlite database created by microk8s v1.26 or earlier, and are unable to back up at all due to issue k8s-dqlite migrator exits immediately with code 0, no backup created #341 - in this case passing --prefix /registry will allow the backup to proceed correctly.

If the new flag is not supplied, the default behaviour matches the current hard-coded behaviour for backwards compatibility - an empty prefix "" for backup-etcd and the prefix "/" for backup-dqlite.

Thank you for making K8s-dqlite better

Verify you have:

Add a flag to the `migrator` command to allow the user to specify a key prefix that they want to back up, rather than hard coding to always back up the entire database.
@ianroberts ianroberts requested a review from a team as a code owner December 9, 2025 11:26
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