How do I set Company and Appliance Name via API or command line?


#1

Hi See below

I wondering is it possible to script the name setting of miq appliance ?

image


#2

My one-liner:
# vmdb; source /etc/default/evm; rails r 'MiqServer.my_server.set_config(:server => {:name => "NewName", :company => "NewCompany"})'
See Persistently change server attributes in the Rails Console