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

Fix smartos_imgadm doesn't handle orphan images #55137

Merged
merged 3 commits into from Dec 9, 2019
Merged

Conversation

sjorge
Copy link
Contributor

@sjorge sjorge commented Oct 26, 2019

What does this PR do?

Update _parse_image_meta so that it handles orphan images.
Additionally we also pull in the changes from #51563 to master as those are also needed.

What issues does this PR fix or reference?

#55136

Previous Behavior

_parse_image_meta would not handle orphan image data e.g.

{
  "manifest": {
    "uuid": "07f360fd-12d5-e624-a279-eb8a15b630f6"
  },
  "zpool": "zones",
  "cloneNames": [],
  "clones": 0
}

New Behavior

_parse_image_meta will now check if the 'name' field is present.

Tests written?

Yes, there were no tests for smartos_imgadm yet. Tests for _parse_image_meta were added that feed is various kinds of image data. Currently those are 'orphan', 'native', 'lx', and 'zvol'.

Those cover the currently available image types available in SmartOS

Commits signed with GPG?

No

@sjorge sjorge requested a review from as a code owner Oct 26, 2019
@ghost ghost requested a review from DmitryKuzmenko Oct 26, 2019
@sjorge
Copy link
Contributor Author

@sjorge sjorge commented Oct 31, 2019

I'm not sure how to fix the ci/py3 failures?

@sjorge
Copy link
Contributor Author

@sjorge sjorge commented Nov 18, 2019

@Ch3LL aside from a rebase, anything blocking this? CI seems to always fail for a bunch of distros but it are just unit tests which is weird as they work fine locally and on some targets?

@sjorge
Copy link
Contributor Author

@sjorge sjorge commented Dec 3, 2019

@Ch3LL bump

dwoz
dwoz approved these changes Dec 9, 2019
@dwoz dwoz merged commit a643496 into saltstack:master Dec 9, 2019
46 checks passed
@sjorge sjorge deleted the 55136 branch Dec 10, 2019
@sjorge
Copy link
Contributor Author

@sjorge sjorge commented Dec 10, 2019

Thanks for merging!

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.

None yet

2 participants