# Assigning passwords to VMs

**URL:** https://discourse.chef.io/t/assigning-passwords-to-vms/3826
**Category:** Chef Infra (archive)
**Created:** [April 2, 2013, 10:42pm UTC](https://discourse.chef.io/t/assigning-passwords-to-vms/3826 "2013-04-02T22:42:43Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![Alex\_Abraham](https://avatars.discourse-cdn.com/v4/letter/a/958977/32.png) [@Alex\_Abraham](https://discourse.chef.io/u/Alex_Abraham)
#### Post date: [April 2, 2013, 10:42pm UTC](https://discourse.chef.io/t/assigning-passwords-to-vms/3826/1 "2013-04-02T22:42:43Z")

</div>

Hello,

We want to allow users to enter a password to assign to a VM as they create  
that VM. How would we go about doing this?

We are using Chef for Provisioning and Configuration.  
We have our compute node on Ubuntu/KVM

Any help would be highly appreciated.

Thanks in advance…

Regards,  
Alex.

---

<div class="post-metadata">

### Author: ![Brian\_Akins](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/brian_akins/32/298_2.png) [@Brian\_Akins](https://discourse.chef.io/u/Brian_Akins)
#### Post date: [April 2, 2013, 10:46pm UTC](https://discourse.chef.io/t/assigning-passwords-to-vms/3826/2 "2013-04-02T22:46:28Z")

</div>

So, you use chef to provision vm’s via KVM?

---

<div class="post-metadata">

### Author: ![Alex\_Abraham](https://avatars.discourse-cdn.com/v4/letter/a/958977/32.png) [@Alex\_Abraham](https://discourse.chef.io/u/Alex_Abraham)
#### Post date: [April 3, 2013, 5:09pm UTC](https://discourse.chef.io/t/assigning-passwords-to-vms/3826/3 "2013-04-03T17:09:01Z")

</div>

Yes, Brian.

So, what we want to do is to have the user go thru chef to provision and configure VMs.

So, as the users do this, we want the user to have the ability to enter a password that will be assigned to the VM they are creating. No idea how to do this. If we can at least get an approach to how to go about doing this, that will be a good start.

Regards,  
Alex.

— On Tue, 4/2/13, Brian Akins [brian@akins.org](mailto:brian@akins.org) wrote:

From: Brian Akins [brian@akins.org](mailto:brian@akins.org)  
Subject: [chef] Re: Assigning passwords to VMs  
To: “chef” [chef@lists.opscode.com](mailto:chef@lists.opscode.com)  
Date: Tuesday, April 2, 2013, 5:46 PM

So, you use chef to provision vm’s via KVM?

---

<div class="post-metadata">

### Author: ![AJ\_Christensen](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/aj_christensen/32/525_2.png) [@AJ\_Christensen](https://discourse.chef.io/u/AJ_Christensen)
#### Post date: [April 3, 2013, 8:04pm UTC](https://discourse.chef.io/t/assigning-passwords-to-vms/3826/4 "2013-04-03T20:04:37Z")

</div>

Put it in json or a data-bag and use that during convergence. Write a  
script to update said file.

Cheers,

AJ

On 4 April 2013 06:09, Alex Abraham [abraham0508@yahoo.com](mailto:abraham0508@yahoo.com) wrote:

> Yes, Brian.
> 
> So, what we want to do is to have the user go thru chef to provision and  
> configure VMs.
> 
> So, as the users do this, we want the user to have the ability to enter a  
> password that will be assigned to the VM they are creating. No idea how to  
> do this. If we can at least get an approach to how to go about doing this,  
> that will be a good start.
> 
> Regards,  
> Alex.
> 
> --- On _Tue, 4/2/13, Brian Akins [brian@akins.org](mailto:brian@akins.org)_ wrote:
> 
> From: Brian Akins [brian@akins.org](mailto:brian@akins.org)  
> Subject: [chef] Re: Assigning passwords to VMs  
> To: "chef" [chef@lists.opscode.com](mailto:chef@lists.opscode.com)  
> Date: Tuesday, April 2, 2013, 5:46 PM
> 
> So, you use chef to provision vm's via KVM?

---

<div class="post-metadata">

### Author: ![Alex\_Abraham](https://avatars.discourse-cdn.com/v4/letter/a/958977/32.png) [@Alex\_Abraham](https://discourse.chef.io/u/Alex_Abraham)
#### Post date: [April 3, 2013, 8:06pm UTC](https://discourse.chef.io/t/assigning-passwords-to-vms/3826/5 "2013-04-03T20:06:09Z")

</div>

Ok, thanks, AJ…

— On Wed, 4/3/13, AJ Christensen [aj@junglist.gen.nz](mailto:aj@junglist.gen.nz) wrote:

From: AJ Christensen [aj@junglist.gen.nz](mailto:aj@junglist.gen.nz)  
Subject: [chef] Re: Re: Re: Assigning passwords to VMs  
To: “chef” [chef@lists.opscode.com](mailto:chef@lists.opscode.com)  
Date: Wednesday, April 3, 2013, 3:04 PM

Put it in json or a data-bag and use that during convergence. Write a script to update said file.

Cheers,

AJ

On 4 April 2013 06:09, Alex Abraham [abraham0508@yahoo.com](mailto:abraham0508@yahoo.com) wrote:

Yes, Brian.

So, what we want to do is to have the user go thru chef to provision and configure VMs.

So, as the users do this, we want the user to have the ability to enter a password that will be assigned to the VM they are creating. No idea how to do this. If we can at least get an approach to how to go about doing this, that will be a good start.

Regards,  
Alex.

— On Tue, 4/2/13, Brian Akins [brian@akins.org](mailto:brian@akins.org) wrote:

From: Brian Akins [brian@akins.org](mailto:brian@akins.org)  
Subject: [chef] Re: Assigning passwords to VMs  
To: “chef” [chef@lists.opscode.com](mailto:chef@lists.opscode.com)  
Date: Tuesday, April 2, 2013, 5:46 PM

So, you use chef to provision vm’s via KVM?
