[one-users] Random password on CONTEXT
André Monteiro
andre.monteir at gmail.com
Mon Aug 20 01:33:25 PDT 2012
Hi Ricardo,
Try to use variables in context section, for example you can bind a
pseudo-random password using several context variables:
CONTEXT = [
files = "/service/init.sh /service/resolv.conf"
hostname = "$NAME-$VMID",
ip_private = "$NIC[IP, NETWORK=\"public net\"]",
user = oneadmin,
user_pw= "MyPass-$NAME-$VMID"
]
Hope it helps,
--
André Monteiro
On Sat, Aug 18, 2012 at 12:01 PM, Ricardo Duarte <rjtd21 at hotmail.com> wrote:
> Hi there,
>
> I would like to generate a random password for each instance, but it
> should be readable/available under Sunstone.
> The plan is to slightly modify the virtual machine data table, and add a
> new column named "Service Password", or in alternative, users may look for
> it under the "Image Template" tab.
> What I am missing is how to make the password available to both Sunstone
> and the instance, and how to generate it before the machine boots. Looks
> like the easier way would be to auto-generate it and add it to CONTEXT.
> But how can I do it? Is there any hook I can use to generate a variable
> and add them to context, before the machine boots? Or do I have to modify
> the OpenNebula C core?
>
> Thanks.
>
>
>
> _______________________________________________
> Users mailing list
> Users at lists.opennebula.org
> http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opennebula.org/pipermail/users-opennebula.org/attachments/20120820/04e53cf2/attachment-0003.htm>
More information about the Users
mailing list