salt.modules.serverdensity_device

Wrapper around Server Density API

2014.7.0 新版功能.

salt.modules.serverdensity_device.create(name, **params)

Function to create device in Server Density. For more info, see the API docs.

命令行接口CLI 范例:

salt '*' serverdensity_device.create lama
salt '*' serverdensity_device.create rich_lama group=lama_band installedRAM=32768
salt.modules.serverdensity_device.delete(device_id)

Delete a device from Server Density. For more information, see the API docs.

命令行接口CLI 范例:

salt '*' serverdensity_device.delete 51f7eafcdba4bb235e000ae4
salt.modules.serverdensity_device.get_sd_auth(val, sd_auth_pillar_name='serverdensity')

Returns requested Server Density authentication value from pillar.

命令行接口CLI 范例:

salt '*' serverdensity_device.get_sd_auth <val>
salt.modules.serverdensity_device.install_agent(agent_key)

Function downloads Server Density installation agent, and installs sd-agent with agent_key.

命令行接口CLI 范例:

salt '*' serverdensity_device.install_agent c2bbdd6689ff46282bdaa07555641498
salt.modules.serverdensity_device.ls(**params)

List devices in Server Density

Results will be filtered by any params passed to this function. For more information, see the API docs on listing and searching.

命令行接口CLI 范例:

salt '*' serverdensity_device.ls
salt '*' serverdensity_device.ls name=lama
salt '*' serverdensity_device.ls name=lama group=lama_band installedRAM=32768
salt.modules.serverdensity_device.update(device_id, **params)

Updates device information in Server Density. For more information see the API docs.

命令行接口CLI 范例:

salt '*' serverdensity_device.update 51f7eafcdba4bb235e000ae4 name=lama group=lama_band
salt '*' serverdensity_device.update 51f7eafcdba4bb235e000ae4 name=better_lama group=rock_lamas swapSpace=512