<div dir="ltr"><div>Leszek,</div><div><br></div>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.<div>

<br></div><div>Whatever you put inside that init.sh script will get executed. </div><div><br></div><div>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:</div>

<div><br></div><div>> #!/bin/bash</div><div>> echo "root:$ROOT_PASSWORD" | passwd<br></div><div><br></div><div>And then you can specify the custom variable ROOT_PASSWORD in the VM Template.</div><div><br>
</div>
<div>Please note that it's recommended to use base64 encoding for this type of things, since otherwise it might lead to character problems.</div><div><br></div><div><br></div><div><br></div></div><div class="gmail_extra">

<br><br><div class="gmail_quote">On Wed, Apr 2, 2014 at 11:09 AM, Leszek Master <span dir="ltr"><<a href="mailto:keksior@gmail.com" target="_blank">keksior@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div dir="ltr">How can i push root password to a VM for example using context?</div>
<br>_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.opennebula.org">Users@lists.opennebula.org</a><br>
<a href="http://lists.opennebula.org/listinfo.cgi/users-opennebula.org" target="_blank">http://lists.opennebula.org/listinfo.cgi/users-opennebula.org</a><br>
<br></blockquote></div><br></div><br clear="all"><div><br></div>-- <br><div dir="ltr"><div>Jaime Melis<br>Project Engineer<br>OpenNebula - Flexible Enterprise Cloud Made Simple<br><a href="http://www.OpenNebula.org" target="_blank">www.OpenNebula.org</a> | <a href="mailto:jmelis@opennebula.org" target="_blank">jmelis@opennebula.org</a></div>

</div>