Hi,
I created a new OS using hammer cli -
hammer os create --architecture-ids=1 --config-template-ids="30"
–family="Redhat" --major="6" --minor="5" --ptable-ids="6" --name="RH6_5"
The os got created but the finish template was not set. I verified this by
checking in the UI-the finish template field was not set to the correct
tempmlat, though the drop down showed the template.
The info command shows the template as associated with the os
[root@provisionserver3 ~]# hammer os info --id=4
Id: 4
Name: RH6_5 6.5
Release name:
Family: Redhat
Installation media:
Architectures: x86_64
Partition tables: Kickstart default
Config templates: RHEL Finish
Parameters:
The template command shows the os id
[root@provisionserver3 ~]# hammer template info --id=30
Id: 30
Name: RHEL Finish
Type: finish
OS ids: 1, 4, 2
Yet the finish template is not set.
Can somebody please tell how can this be achieved using cli? Have I missed
anything obvious?
Best regards,
Abhijeet
Hello Abhijeet
Workflow in the CLI is the same as in the UI. By associating OSs with
templates you're saying which combinations are valid to use together.
Then you can select OS's default template from this subset. This is the
select boxes on the operating system's template tab in the UI. CLI
equivalent is hammer os set-default-template
. Unfortunately this
command didn't make it to 0.1.0 but you can use our nightly repos.
Regards
Tomas
···
On 04/16/2014 02:12 PM, Abhijeet Joshi wrote:
> Hi,
>
> I created a new OS using hammer cli -
> hammer os create --architecture-ids=1 --config-template-ids="30"
> --family="Redhat" --major="6" --minor="5" --ptable-ids="6" --name="RH6_5"
>
> The os got created but the finish template was not set. I verified this
> by checking in the UI-the finish template field was not set to the
> correct tempmlat, though the drop down showed the template.
>
> The info command shows the template as associated with the os
> [root@provisionserver3 ~]# hammer os info --id=4
> Id: 4
> Name: RH6_5 6.5
> Release name:
> Family: Redhat
> Installation media:
> Architectures: x86_64
> Partition tables: Kickstart default
> Config templates: RHEL Finish
> Parameters:
>
> The template command shows the os id
> [root@provisionserver3 ~]# hammer template info --id=30
> Id: 30
> Name: RHEL Finish
> Type: finish
> OS ids: 1, 4, 2
>
> Yet the finish template is not set.
>
> Can somebody please tell how can this be achieved using cli? Have I
> missed anything obvious?
>
> Best regards,
> Abhijeet
>
>
Ok I will try this. Thanks.