Backlog #4880

Allow third party components to modify deployment file or configuration

Added by Ruben S. Montero over 4 years ago. Updated about 4 years ago.

Status:PendingStart date:10/26/2016
Priority:HighDue date:
Assignee:-% Done:

0%

Category:Core & System
Target version:Release 5.6

Description

This can be done either by:

  • Generating deployment file in the driver instead of core
  • Adding support for template the deployment file

History

#1 Updated by EOLE Team over 4 years ago

+1 for the template system but I don't know a lib for that task.

We can even be crazy and imaging defining several templates and defining a new ONE template attribute to select which one to use.

For example:

  • define some templates
    • /etc/one/templates/vm-default.xml.tmpl
    • /etc/one/templates/vm-scsi.xml.tmpl
  • define some resource templates
    • VM template without any specific attribute → default to using /etc/one/templates/vm-default.xml.tmpl
    • VM template with an attribute, lets call it LIBVIRT_TEMPLATE, equal to vm-scsi → use /etc/one/templates/vm-scsi.xml.tmpl as base to generate the libvirt domain configuration

Regards.

#2 Updated by Anton Todorov over 4 years ago

+1 from me too.

I am thinking of an extra step that is called on the FE just before the deploy action on the Host. Something like:

for each file in remotes/vmm/<driver>/predeploy.d/
exec the file with VM_ID and the domain XML (base64 encoded) as arguments.
if the exit status of the script is SUCCESS the stdout of the script is the base64 encoded altered domain XML.

This way anyone can drop a script that alter in some way the domain XML. and the script will have access to all needed information to complete (acess datastores, vm,s hosts info from opennebula)

And, in a future step it could be possible to move all domain XML definition from the core to a script(s) there too.

Kind Regards,
Anton Todorov

#3 Updated by Anton Todorov over 4 years ago

Also, the previously proposed scheme should be implemented for the attach actions too - option to alter the XML that is passed on an attach action.

Or this should be a separate feature request?

Kind Regards,
Anton Todorov

#4 Updated by Ruben S. Montero about 4 years ago

  • Tracker changed from Feature to Backlog
  • Priority changed from Normal to High
  • Target version changed from Release 5.4 to Release 5.6

We can keep both in this issue. I'm moving this to next release.

Also available in: Atom PDF