Thanks for the information, Kaill.<div><br></div><div>Srikanth.<br><br><div class="gmail_quote">On Wed, Oct 3, 2012 at 5:42 PM, Kiall Mac Innes <span dir="ltr"><<a href="mailto:kiall@managedit.ie" target="_blank">kiall@managedit.ie</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div>Hi Srikanth,</div><div><br></div>File Injection is not available through Horizon.<div><br></div><div>Atul is describing a different feature that can be used to achieve similar results. The contents of "User-Data" will be accessible to the instance via "<a href="http://169.254.169.254/latest/user-data" target="_blank">http://169.254.169.254/latest/user-data</a>" - Ubuntu ships with a tool called cloud-init that makes use of this data if available. </div>


<div><br></div><div>Eg One of the simple use cases for cloud-init is, if the data starts with "#!", it will assume it's a shell script and download + execute it. This can, in a roundabout way, be used to achieve similar results to the file injection feature.</div>


<div><br>Thanks,<br>Kiall<div><div class="h5"><br>
<br><br><div class="gmail_quote">On Wed, Oct 3, 2012 at 12:59 PM, Srikanth Kumar Lingala <span dir="ltr"><<a href="mailto:srikanthkumar.lingala@gmail.com" target="_blank">srikanthkumar.lingala@gmail.com</a>></span> wrote:<br>


<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<div>I am able to create an instance with the following command (along with File Injection):<br><div><b><i><br></i></b></div>


<div><b><i>#> nova boot --file /root/inject.txt=/root/inject.txt --flavor=1 --image=4671e99b-1c01-42e8-94d6-2405a59bab57 testserver1</i></b></div>
<div><b><i><br></i></b></div><div>Now, what I need is to do the same from the Horizon. I will select a file to inject from Horizon and Launch the Instance, it should inject that file.</div><div><br></div><div>Regards,</div>



<div>Srikanth.<div><div><br><br><div class="gmail_quote">On Wed, Oct 3, 2012 at 4:18 PM, Atul Jha <span dir="ltr"><<a href="mailto:Atul.Jha@csscorp.com" target="_blank">Atul.Jha@csscorp.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi,<br>
<br>
The test step followed for user-data as follows.<br>
<br>
1. Got image from <a href="http://cloud-images.ubuntu.com/precise/current/precise-server-cloudimg-i386-disk1.img" target="_blank">http://cloud-images.ubuntu.com/precise/current/precise-server-cloudimg-i386-disk1.img</a><br>




<br>
2. Booted it from Horizon and passed the script in the file<br>
<br>
#!/bin/sh<br>
mkdir /home/ubuntu/testdir<br>
<br>
3. Logged in to the machine with<br>
<br>
ssh -i <mykey.pub> ubuntu@IP<br>
<br>
And i can see the directory created.<br>
<br>
<br>
File injection via Horizon uses cloud-init and i have tested it on Ubuntu 12.04 i have no idea about other distributions.<br>
<br>
You can file more about cloud-init here :- <a href="https://help.ubuntu.com/community/CloudInit" target="_blank">https://help.ubuntu.com/community/CloudInit</a><br>
<br>
And thanks, i will add this in the doc somewhere. :)<br>
<br>
Hope it helps.<br>
<br>
<br>
Atul jha<br>
<br>
________________________________________<br>
From: Shake Chen [<a href="mailto:shake.chen@gmail.com" target="_blank">shake.chen@gmail.com</a>]<br>
Sent: Wednesday, October 03, 2012 2:28 PM<br>
To: Srikanth Kumar Lingala<br>
Cc: Atul Jha; <a href="mailto:openstack@lists.launchpad.net" target="_blank">openstack@lists.launchpad.net</a><br>
Subject: Re: [Openstack] File Injection through Horizon<br>
<div><br>
I also have same question.<br>
<br>
can you give us example. how to injection throuth Horizon?<br>
<br>
<br>
<br>
</div><div>On Wed, Oct 3, 2012 at 3:24 PM, Srikanth Kumar Lingala <<a href="mailto:srikanthkumar.lingala@gmail.com" target="_blank">srikanthkumar.lingala@gmail.com</a><mailto:<a href="mailto:srikanthkumar.lingala@gmail.com" target="_blank">srikanthkumar.lingala@gmail.com</a>>> wrote:<br>




Hi Atul,<br>
Can you please guide me how to do File Injection through Horizon?<br>
<br>
Regards,<br>
Srikanth.<br>
<br>
</div><div>On Wed, Oct 3, 2012 at 12:41 PM, Atul Jha <<a href="mailto:Atul.Jha@csscorp.com" target="_blank">Atul.Jha@csscorp.com</a><mailto:<a href="mailto:Atul.Jha@csscorp.com" target="_blank">Atul.Jha@csscorp.com</a>>> wrote:<br>




Hi,<br>
<snip><br>
I have some doubts regarding File Injection.<br>
Can File Injection can be done through Horizon, while creating an Instance?<br>
While creating an Instance from Horizon, a field called 'User Data' [text area] is there. Is that field is related to File Injection? Can anyone tell me, the values we need to give for 'User Data'?<br>
</snip><br>
Yes.<br>
<br>
<br>
Cheers!!<br>
<br>
Atul Jha<br>
<a href="http://www.csscorp.com/common/email-disclaimer.php" target="_blank">http://www.csscorp.com/common/email-disclaimer.php</a><br>
<br>
<br>
_______________________________________________<br>
Mailing list: <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~openstack</a><br>
</div>Post to     : <a href="mailto:openstack@lists.launchpad.net" target="_blank">openstack@lists.launchpad.net</a><mailto:<a href="mailto:openstack@lists.launchpad.net" target="_blank">openstack@lists.launchpad.net</a>><br>



<div>Unsubscribe : <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~openstack</a><br>
More help   : <a href="https://help.launchpad.net/ListHelp" target="_blank">https://help.launchpad.net/ListHelp</a><br>
<br>
<br>
<br>
<br>
--<br>
Shake Chen<br>
<br>
</div><a href="http://www.csscorp.com/common/email-disclaimer.php" target="_blank">http://www.csscorp.com/common/email-disclaimer.php</a><br>
</blockquote></div><br><br>
</div></div></div></div>
<br>_______________________________________________<br>
Mailing list: <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~openstack</a><br>
Post to     : <a href="mailto:openstack@lists.launchpad.net" target="_blank">openstack@lists.launchpad.net</a><br>
Unsubscribe : <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~openstack</a><br>
More help   : <a href="https://help.launchpad.net/ListHelp" target="_blank">https://help.launchpad.net/ListHelp</a><br>
<br></blockquote></div><br></div></div></div>
</blockquote></div><br><br>
</div>