ibmcloud_python_sdk.cis.baremetal package

Submodules

ibmcloud_python_sdk.cis.baremetal.hardware module

class ibmcloud_python_sdk.cis.baremetal.hardware.Hardware[source]

Bases: object

get_baremetal(baremetal)[source]

Retrieve specific baremetal

Parameters

baremetal (str) – Baremetal name or ID

Returns

Baremetal server information

Return type

dict

get_baremetal_by_id(id)[source]

Retrieve specific baremetal by ID

Parameters

id (str) – Baremetal ID

Returns

Baremetal server information

Return type

dict

get_baremetal_by_name(name)[source]

Retrieve specific baremetal by name

Parameters

name (str) – Baremetal name

Returns

Baremetal server information

Return type

dict

get_baremetal_power_state(baremetal)[source]

Retrieve baremetal power state

Parameters

baremetal (str) – Baremetal name or ID

Returns

Baremetal power state

Return type

dict

get_baremetals()[source]

Retrieve baremetal list

Returns

List of baremetal servers

Return type

dict

reload_os(**kwargs)[source]

Reload operating system and configuration

Parameters
  • baremetal (str) – Baremetal name or ID

  • spare_pool (str, optional) – Server will be moved into the spare pool after an sperating system reload

  • script (str, optional) – Will be used to download and execute a customer defined script on the host at the end of provisioning

  • retention (str) – Primary drive will be converted to a portable storage volume during an operating system reload

  • erase_drives (bool, optional) – All data will be erased from drives during an sperating system reload

  • hard_drives – The hard drive partitions that a server can be partitioned with

  • image_template_id (str, optional) – An image template ID that will be deployed to the host. If provided no item prices are required

  • item_prices (list, optional) – Item prices that the server can be configured with

  • enable_lvm (bool, optional) – The provision should use LVM for all logical drives

  • reset_ipmi_password (bool, optional) – The remote management cards password will be reset

  • ssh_keys (list, optional) – SSH keys to add to the server for authentication. SSH Keys will not be added to servers with Microsoft Windows

  • upgrade_bios (bool, optional) – BIOS will be updated when installing the operating system.

  • upgrade_firmware (bool, optional) – Firmware on all hard drives will be updated when installing the operating system

Returns

Reload status

Return type

dict

set_baremetal_power_state(**kwargs)[source]

Set baremetal power state

Parameters

baremetal (str) – Baremetal name or ID

Parem power_state

Target power state

Returns

Power state

Return type

dict

ibmcloud_python_sdk.cis.baremetal.order module

class ibmcloud_python_sdk.cis.baremetal.order.Order[source]

Bases: object

get_locations()[source]

Retrieve all datacenter locations

Returns

List of datacenter location

Return type

dict

get_operating_system(image, package=None)[source]

Retrieve specific baremetal operating system

Parameters
  • image (str) – Image name

  • package (str, optional) – Package name, defaults to BARE_METAL_SERVER

Returns

Baremetal operating system

Return type

dict

get_operating_systems(package=None)[source]

Retrieve baremetal operating system list

Parameters

package (str, optional) – Package name, defaults to BARE_METAL_SERVER

Returns

Baremetal operating system list

Return type

dict

get_package_items(package=None, **kwargs)[source]

Retrieve package item list

Parameters
  • package (str, optional) – Package name, defaults to BARE_METAL_SERVER

  • category (str, optional) – Filter by category

  • mask (str, optional) – Mask fields

Returns

Baremetal operating systems

Return type

dict

get_package_presets(package=None)[source]

Retrieve baremetal package presets

Parameters

package (str, optional) – Package name, defaults to BARE_METAL_SERVER

Returns

Baremetal presets from package

Return type

dict

place(**kwargs)[source]

Place an order

Parameters
  • package (str) – The package being ordered

  • location (str) – The datacenter location string for ordering

  • items (list) – The list of item keyname strings to order

  • complex_type (str) – The complex type to send with the order

  • hourly (bool, optional) – If true, uses hourly billing, defaults to True

  • preset (str, optional) – Specifies a preset to use for that package

  • extras (dict) – The extra data for the order in dictionary format

  • quantity (int, optional) – The number of resources to order, default to 1

Returns

The placed order

Return type

dict

verify(**kwargs)[source]

Verify an order

Parameters
  • package (str) – The package being ordered

  • location (str) – The datacenter location string for ordering

  • items (list) – The list of item keyname strings to order

  • complex_type (str) – The complex type to send with the order

  • hourly (bool, optional) – If true, uses hourly billing, defaults to True

  • preset (str, optional) – Specifies a preset to use for that package

  • extras (dict) – The extra data for the order in dictionary format

  • quantity (int, optional) – The number of resources to order, default to 1

Returns

The verified order

Return type

dict

Module contents