16:00:32 <akasurde> #startmeeting Ansible VMware Working Group Meeting
16:00:32 <zodbot> Meeting started Mon Sep 18 16:00:32 2017 UTC.  The chair is akasurde. Information about MeetBot at http://wiki.debian.org/MeetBot.
16:00:32 <zodbot> Useful Commands: #action #agreed #halp #info #idea #link #topic.
16:00:32 <zodbot> The meeting name has been set to 'ansible_vmware_working_group_meeting'
16:02:07 <tomscanlan> #halp
16:02:15 <akasurde> #chair tomscanlan
16:02:15 <zodbot> Current chairs: akasurde tomscanlan
16:02:20 <akasurde> hi tomscanlan
16:02:32 <dericcrago> ooh, fancy, no need to hop over to ansible-meeting
16:02:48 <akasurde> #chair dericcrago
16:02:48 <zodbot> Current chairs: akasurde dericcrago tomscanlan
16:03:08 <akasurde> yep we have our own zodbot now :)
16:04:24 <akasurde> #topic New module progress
16:04:29 <tomscanlan> Hi.  I've missed all the meetings :)  vmware guy here working with ansible to install SDDC
16:05:13 <akasurde> nice
16:05:18 <akasurde> what is SDDC btw
16:05:29 <tomscanlan> software defined datacenter
16:06:12 <akasurde> Cool we need help in various things
16:06:33 <tomscanlan> indeed ;)  me too.
16:07:04 <tomscanlan> I'm happy to pitch in.  time is limited lately, but definitly want to help
16:07:06 <jtanner> hi
16:07:36 <jtanner> what is sddc?
16:07:40 <balexander> I'm new as well. vmware AirWatch guy using ansible on AirWatch automation (VM creation, app install, patching, etc)
16:07:46 <akasurde> #chair jtanner
16:07:46 <zodbot> Current chairs: akasurde dericcrago jtanner tomscanlan
16:07:49 <akasurde> #chair balexander
16:07:49 <zodbot> Current chairs: akasurde balexander dericcrago jtanner tomscanlan
16:08:07 <akasurde> sddc is Software defined datacenter
16:08:17 <akasurde> hi balexander, welcome
16:08:36 <tomscanlan> hey balexander... we need to talk.
16:08:52 <tomscanlan> are you in atlanta?
16:09:01 <balexander> I am indeed in Atlanta
16:10:16 <tomscanlan> I was just there end of last week.  maybe I'll catch you next time.  I've got some desire to get liota and fire/ice projects that leverage airwatch installed.  I could use some airwatch experts
16:10:52 <akasurde> Does anyone have any update on new module ?
16:11:12 <jtanner> not me
16:11:19 <akasurde> I have submitted a new module related to vmware_guest powerstate to simplify powerstate management
16:11:31 <akasurde> comments and review are most welcome
16:12:48 <jtanner> link
16:13:08 <akasurde> #link https://github.com/ansible/ansible/pull/30505
16:13:34 <akasurde> jtanner, I moved some code out of vmware guest to vmware module_utils
16:14:31 <jtanner> PyVmomiHelper should also go into the module util
16:15:39 <akasurde> Ok
16:19:16 <akasurde> Does anyone have any other module to discuss ?
16:20:29 <akasurde> #topic general discussion
16:22:16 <tomscanlan> akasurde, I'll put some discussion on that PR.  just looked and do have a Q right off.
16:22:33 <akasurde> tomscanlan, Sure thanks
16:23:08 <akasurde> balexander, Do you use Ansible to manage Airwatch ?
16:25:08 <akasurde> any links to repo will be helpful
16:25:57 <balexander> currently we are using powercli vis powershell
16:26:25 <akasurde> oh
16:26:43 <balexander> when it was developed the modules were not present to do the customization we needed (was before my employment so I don't have the details), but long term we do want to migrate to the vmware modules
16:27:22 <akasurde> Cool thats nice. We can work together then :)
16:29:59 <balexander> I look forward to it.
16:31:04 <jtanner> anyone here work in the vcenter api team?
16:31:23 <jtanner> or have deep exertise with searchindex.findbyinventorypath?
16:31:34 <jtanner> expertise*
16:31:59 <tomscanlan> I don't but could dig if you need it.
16:32:25 <jtanner> the api doesn't seem to be well documented on how to assemble the input
16:32:55 <jtanner> in some cases, the datacenter name needs to be the first position, other times it should not
16:33:01 <tomscanlan> ok.  I'll poke around and see if I can find a good person
16:33:24 <tomscanlan> I'll ping you back once I've got them
16:33:38 <jtanner> 99% of our issues with vmware_guest right now are in get_vm/getvm and primarily due to findbyinventorypath not being able to locate a folder
16:34:18 <jtanner> and we get people trying to fix in the "wrong" way https://github.com/ansible/ansible/pull/30510/files
16:34:21 <akasurde> tomscanlan, also if there is any reliable "magic" method to find Virtual Machine in infra
16:34:26 <tomscanlan> that is significant :)  I'll help
16:34:58 <tomscanlan> I don't think there is a magic method, but I'll sic someone on it
16:35:01 <jtanner> i'm starting to get a handle on what is "correct" with vmware_walk.py
16:36:11 <akasurde> we also need a method where it can find virtual machine inside a resource pool
16:36:18 <dericcrago> jtanner - I've been using searchIndex.FindByInventoryPath('{}/vm/{}'.format('datacenter/path/relative/to/vcenter', 'vm/path/relative/to/datacenter'))
16:37:17 <jtanner> something about your environment makes that valid
16:37:23 <jtanner> in other environments, it is not valid
16:37:24 <jtanner> https://github.com/ansible/ansible/issues/29043#issuecomment-329805170
16:40:07 <akasurde> dericcrago, jtanner does datacenter.vmFolder always has the virtual machine folder ?
16:40:24 <jtanner> no idea
16:40:35 <jtanner> vmware_walk checks it though
16:41:52 <akasurde> I have seen code where people safetly depend upon that
16:42:03 <dericcrago> yes, it's guaranteed
16:42:05 <dericcrago> https://code.vmware.com/apis/196/vsphere#/doc/vim.Datacenter.html
16:43:25 <akasurde> Cool
16:43:34 <akasurde> need to explore that avenue as well
16:44:18 <jtanner> based on 29043, i think this block of code has issues https://github.com/ansible/ansible/blob/devel/lib/ansible/modules/cloud/vmware/vmware_guest.py#L1189-L1201
16:46:35 <akasurde> jtanner, agreed
16:46:46 <pdellaert> o/ sorry being so late, traffic issues
16:48:34 <akasurde> #chair pdellaert
16:48:34 <zodbot> Current chairs: akasurde balexander dericcrago jtanner pdellaert tomscanlan
16:48:58 <akasurde> we are discussing about a method to find VM using findinventorypath
16:50:30 <tomscanlan> and I'm volunteering to find an expert in that part, or to become one.
16:50:48 <jtanner> this may be the problem https://github.com/ansible/ansible/blob/devel/lib/ansible/module_utils/vmware.py#L227-L242
16:51:40 <dericcrago> yeah, I was looking at the section righ tnow
16:54:41 <akasurde> #action tomscanlan Find expert/s to help with findinventorybypath
16:55:21 <akasurde> jtanner, this code works as expected I think
16:59:12 <akasurde> what is we pass datacenter.vmFolder directly to findbyinventory method ?
17:01:41 <akasurde> like
17:02:36 <akasurde> get datacenter.vmFolder from datacenter and find vm till find it inside each folder
17:03:31 <dericcrago> akasurde - do you mean just iterating and matching?
17:03:40 <akasurde> yes
17:03:58 <akasurde> I know it will be slow but assured
17:04:05 <dericcrago> you certainly could, I had something like that until I discovered FindByInventoryPath
17:06:14 <akasurde> dericcrago, how do you handle folders inside vmFolder
17:06:50 <dericcrago> it was recursive as long as the path kept matching
17:07:46 <akasurde> I am thinking on same lines
17:10:45 <jtanner> i had it working fine, until the community revolted and claimed it was too slow
17:10:46 <jtanner> https://github.com/ansible/ansible/pull/19937/files
17:12:53 <akasurde> ohk
17:13:17 <jtanner> now it's AMAZINGLY FAST! (and broken)
17:14:12 <jtanner> gonna have to figure out if the scenario in 29043 is possible with vcsim
17:14:59 <akasurde> I am not able to re-create nested folder line 29043
17:15:02 <akasurde> using vcsim
17:15:39 <akasurde> we can close the meeting and take this discussion on
17:15:44 <akasurde> #endmeeting