Open
Conversation
Author
|
Friendly ping @sharder996 in case you missed this. |
Collaborator
|
Hey @larrasket, this is on my radar to discuss with the team. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds the image hash to the output of multipass find, across all output formats (table, JSON, CSV, YAML).
without this I'm not sure if it is possible to programmatically check whether an instance is up to date without scraping internal JSON files science there is no way to compare a locally-running instance's image hash (shown in multipass info) with what multipass find returns.
Related Issue(s)
Closes #2689
Testing
Unit tests: added image_hash to 14 formatter golden files; all 28 DaemonFind and FindOutputFormatter tests pass.
Manual testing steps:
Run
multipass findverify a new "Hash" column appears in table output (12-char prefix). Test with--format json, yaml and css (replace in--format json). Compare the hash of a running instance from multipass info with the corresponding entry in multipass find output and they should match.Checklist
Additional Notes
The hash is the same id field already returned by multipass info. In table format it is truncated to 12 characters for readability (consistent with how Git displays short SHAs); JSON, YAML, and CSV show the full hash for programmatic use.