Skip to content
This repository has been archived by the owner on Jul 25, 2023. It is now read-only.

[WIP] Add VM Networks to collected information #15

Closed
wants to merge 5 commits into from
Closed

[WIP] Add VM Networks to collected information #15

wants to merge 5 commits into from

Conversation

djberg96
Copy link
Collaborator

@djberg96 djberg96 commented Aug 28, 2017

Currently we collect logical networks, but we do not collect VM network information. This PR adds support for them by adding them to the guest_devices table.

Each VM network is associated with a lan (logical network), and so I add that relationship as well. We should then be able to get to the switch (virtual network) via the lan.

Ideally we should create a relationship between a VM and its corresponding VM networks.

Some more information here:

http://windowsitpro.com/hyper-v/understanding-hyper-v-networking-system-center-vmm-2012-r2

@miq-bot miq-bot added the wip label Aug 28, 2017
@bronaghs
Copy link

bronaghs commented Oct 5, 2017

Hi @agrare
My understanding is that the Powershell changes in this PR are final but the parser will need updated to reflect the schema changes here
It doesn't look like the inventory YML file used for specs has been updated, does this block you from taking this over while Dan is out?

@agrare
Copy link
Member

agrare commented Oct 5, 2017

@bronaghs I'll see what I can do with the scvmm provider I have access to.

@miq-bot
Copy link
Member

miq-bot commented Oct 7, 2017

Checked commits https://github.com/djberg96/manageiq-providers-scvmm/compare/8c97f1605d8fdfe7e0b78803256d9c531bb5ac17~...a6dd1a06ceaf24c8a91da95a97c8cc4422f3e61f with ruby 2.3.3, rubocop 0.47.1, and haml-lint 0.20.0
1 file checked, 2 offenses detected

app/models/manageiq/providers/microsoft/infra_manager/refresh_parser.rb

@djberg96
Copy link
Collaborator Author

djberg96 commented Oct 7, 2017

@bronaghs @agrare I've updated this WIP to reflect the changes. I think this will do the trick, but I need to update save_inventory.

@agrare
Copy link
Member

agrare commented Oct 9, 2017

Hey @djberg96 didn't know you'd be back working already :) Just for reference I started taking a crack at this here #19

Since the VMNetworks are children of a switch I think we want these to be under the switch instead of a top level collection.

I'll take care of the save_inventory side.

@djberg96
Copy link
Collaborator Author

djberg96 commented Oct 9, 2017

@agrare Maybe I'm not sure how you want to represent a VM network, but it should be a child of a logical network (lan) shouldn't it?

@agrare
Copy link
Member

agrare commented Oct 9, 2017

@djberg96 try with ManageIQ/manageiq#16153 that should save the subnets for you

@agrare
Copy link
Member

agrare commented Oct 9, 2017

Maybe I'm not sure how you want to represent a VM network, but it should be a child of a logical network (lan) shouldn't it?

Right that's why we added the parent_id to Lan, so the vm_networks will also be in switch -> lans but will have a parent_id

@agrare
Copy link
Member

agrare commented Oct 9, 2017

@djberg96 the changes to manageiq core are in to save subnets so you should be good there
I stole your subnet parser for https://github.com/ManageIQ/manageiq-providers-scvmm/pull/19/files#diff-70f4237341291be1403b3349c4fbafb7R215 so that works now, you can use it or ignore it :D up to you

I still need to do the lan parent_id saving, that'll be a little trickier.

@djberg96
Copy link
Collaborator Author

Closed in favor of #19

@djberg96 djberg96 closed this Oct 12, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants