jclouds-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ignasi Barrera <n...@apache.org>
Subject Re: ec2 image for jclouds
Date Mon, 01 Dec 2014 23:35:45 GMT
Something like this should work:

TemplateOptions options = compute.templateOptions();
Template template = compute.templateBuilder()
   .options(options.overrideLoginUser("user")
                            .overrideLoginPassword("password"))
   (...)
   .build();


On 2 December 2014 at 00:13, liang cheng <liang.cheng@gmail.com> wrote:
> Hi Ignasi,
>
> Thanks for the reply. Can you please provide some code snippet from a
> working example how to use overrideLoginCredentials to overwrite the
> password for the root ?
>
> Thanks,
> -Liang
>
>
>
> On Mon, Dec 1, 2014 at 1:28 PM, Ignasi Barrera <nacx@apache.org> wrote:
>>
>> Hi Liang,
>>
>> The AWS api does not provide a way to get the default username of the
>> AMIs, so jclouds can only do its best to guess them. We also provide
>> the usernames for AMIs from well-known owners, but if you are using a
>> custom AMI, jclouds will probably try to login as "root".
>>
>> You can provide the right credentials by using the
>> "overrideLoginCredentials" in the TemplateOptions object.
>>
>> Let us know if this helps!
>>
>> I.
>>
>> On 1 December 2014 at 21:06, liang cheng <liang.cheng@gmail.com> wrote:
>> > Hi,
>> >
>> > I'm experimenting the jclouds ec2 example:
>> >
>> > https://github.com/jclouds/jclouds-examples/tree/master/compute-basics
>> >
>> > I works perfectly fine with the AWS EC2 default ami like ami-4b6f650e.
>> >
>> > However, it has ssl issue with my own ami. It can create ami but can't
>> > do
>> > the bootstrap script injection.
>> >
>> > Now my question is what conditions I need to satisfy for my own ami to
>> > work
>> > with jclouds on ec2 ? Do I need to have a default user name like
>> > ec2-user ?
>> >
>> > Thanks,
>> > -Liang
>
>

Mime
View raw message