Provisioning non-vm objects through CFME


We have a usecase where the client wants to manage his non-vm services through CFME.
The Client is a service provider. He provides services to his clients. non-vm Services are like - Network switch, Network racks, Storage space on SAS/SATA, etc.

Now in CFME, he wants below things:

  1. The end user should be able to see the different types of non-vm services the client is providing. We can add separate Service Catalogues for Switches, Racks, etc.
  2. Then he will be selecting the type and number of services he wants.
  3. Once he submits the request, the approval process will be started. On getting approvals, the request will be then sent to their IT Support team. This team will then manually launch the services and will close the request.

This is what I am thinking about the approach. Request you all to please correct me.

  1. We need to create Catalogs and Dialogs for separate Non-VM services.
  2. In the Service Dialogues, we will create the parameters as per client requirement.
  3. I am not sure how this thing should be configured in StateMachines part, as these services are not an actual VM.

The client basically wants a single pane of glass for managing all his infra.
He has his infra on VMware, AWS and Azure.
They own their own DataCenter and rent the services like network ports, rack space, etc. to their clients.

Can you please help me guide on the approach which needs to be followed.

Pushkar Mahakal
Mobile: +91 9673417089

One way I can think of is to create Generic type of services for each type and store the configuration/status in custom attributes. Here is an example to create custom attributes for a service from an automation method (value read from dialog). For provisioning/retirement workflows you can clone the default Service state machines, but you’ll need to extend them with custom methods implementing the actual actions on your managed infrastructure.

Another way is to use Dymanic Resource Objects (DRO) - also called Generic Objects. This is a new feature and rather undocumented yet but looks a better fit for your usecase. Here is an old presentation of the design:
Generic Objects - Bill Wei - ManageIQ Design Summit 2016

I’m just exploring its capabilities and plan to share my findings but this topic is new to me as well.

Regarding the lack of documentation on Generic Objects, I just came accross this appendix to Mastering Cloudforms Automation, which has a whole chapter about Generic Objects, in another thread. It is still work in progress, but I can confirm that everything works as described so far.

Just one thing that is missing, if you want to test the methods on a generic object from the rails console, you have to set a user-context like this:

mydro = dro_definition.create_object(name: 'my_first_dro', attributes: {:foo => 'bar', :foobar => 'baz'})
# mydro = $evm.vmdb('generic_object').where(generic_object_definition_id:
mydro.instance_variable_set(:@ae_user, User.first) # User.first is usually Administrator
User.current_user = User.first #IRB user