[one-users] Opennebula template Push root password.

Jaime Melis jmelis at opennebula.org
Wed Apr 2 02:37:26 PDT 2014


Leszek,

Create a script, call it "init.sh", upload it to the Files & Kernel tab (as
a Context type). Select it under the Context -> Files section of the VM
Template.

Whatever you put inside that init.sh script will get executed.

The contents of the script depend on the distro you are using, but if
you're using CentOS 6, for instance, you might want to write something like
this:

> #!/bin/bash
> echo "root:$ROOT_PASSWORD" | passwd

And then you can specify the custom variable ROOT_PASSWORD in the VM
Template.

Please note that it's recommended to use base64 encoding for this type of
things, since otherwise it might lead to character problems.





On Wed, Apr 2, 2014 at 11:09 AM, Leszek Master <keksior at gmail.com> wrote:

> How can i push root password to a VM for example using context?
>
> _______________________________________________
> Users mailing list
> Users at lists.opennebula.org
> http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
>
>


-- 
Jaime Melis
Project Engineer
OpenNebula - Flexible Enterprise Cloud Made Simple
www.OpenNebula.org | jmelis at opennebula.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opennebula.org/pipermail/users-opennebula.org/attachments/20140402/ba0528f7/attachment-0002.htm>


More information about the Users mailing list