[one-users] Ruby oca - change templates

Paulo A L Rego pauloalr.alu at gmail.com
Tue Nov 1 09:07:32 PDT 2011


Thanks for tips..

This "onetemplate" feature is for 3.0 version, right?
I'm using ON2.2 and was trying to add dinamically the context information
to a VM in pending state, to simplify to final user. But it seems cant be
done in this version.

I'm gonna try ON3.0.

Regards

2011/11/1 Robert Parrott <parrott at seas.harvard.edu>

> Hi Paulo,
>
> One thing that we've done is to use "onetemplate" to store a template
> " template", i.e. a template that has fields in the context that are
> placeholder tokens. Then we've wrapped the deploy command line with a
> script that will pull the contents of the template, modify it in
> place, and then feed it into the onevm create command. If you set
> "EDITOR=cat" in your shell and then do a "onetemplate update", the
> contents of the template will be written to stdout. A few well placed
> "sed" commands can customize that template dynamically for your needs
> (for example we specify a public key to add, and a local user account
> to create based on the currently login name).
>
> Rob
>
>
> On Mon, Oct 31, 2011 at 11:41 AM, Paulo A L Rego <pauloalr.alu at gmail.com>
> wrote:
> > Hi,
> > is it possible to change the virtual machine's template while the vm is
> in
> > pending state?
> >
> > We can see the template by using vm.template_str and the xml using
> > vm.to_xml.
> > Can we update the template or the xml before deploying?
> > I would like to update the name and/or include other fields at template.
> > Thanks a lot.
> > Paulo Rego
> > _______________________________________________
> > Users mailing list
> > Users at lists.opennebula.org
> > http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
> >
> >
>
>
>
> --
> Robert E. Parrott, Ph.D. (Phys. '06)
> Director, Academic Computing
> Harvard University Sch. of Eng. and App. Sci.
> Maxwell-Dworkin  211,
> 33 Oxford St.
> Cambridge, MA 02138
> (617)-496-1520
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opennebula.org/pipermail/users-opennebula.org/attachments/20111101/ed2d66c6/attachment-0003.htm>


More information about the Users mailing list