maasserver.models.nodegroup

Model definition for NodeGroup which models a collection of Nodes.

Functions

generate_omapi_key() Generate a HMAC-MD5 key by calling out to the dnssec-keygen tool.
refresh_worker(nodegroup) Send worker for nodegroup a refresh message with credentials etc.

Classes

BootSource(*args, **kwargs) A source for boot resources.
BootSourceSelection(*args, **kwargs) A set of selections for a single BootSource.
CharField(*args, **kwargs)
DefaultMeta Base class for model Meta classes in the maasserver app.
ForeignKey(to[, to_field, rel_class, ...])
IntegerField([verbose_name, name, ...])
Manager()
NODEGROUPINTERFACE_MANAGEMENT The vocabulary of a NodeGroupInterface‘s possible statuses.
NODEGROUP_STATUS The vocabulary of a NodeGroup‘s possible statuses.
NodeGroup(*args, **kwargs) NodeGroup(id, created, updated, cluster_name, name, status, api_token_id, api_key, dhcp_key, uuid, maas_url)
NodeGroupInterface(*args, **kwargs) NodeGroupInterface(id, created, updated, ip, nodegroup_id, management, interface, subnet_mask, broadcast_ip, router_ip, ip_range_low, ip_range_high, foreign_dhcp_ip)
NodeGroupManager() Manager for the NodeGroup class.
TimestampedModel(*args, **kwargs) Abstract base model with creation/update timestamps.
Token(*args, **kwargs) Token(id, key, secret, verifier, token_type, timestamp, is_approved, user_id, consumer_id, callback, callback_confirmed)
class maasserver.models.nodegroup.NodeGroup(*args, **kwargs)[source]

Bases: maasserver.models.timestampedmodel.TimestampedModel

NodeGroup(id, created, updated, cluster_name, name, status, api_token_id, api_key, dhcp_key, uuid, maas_url)

accept()[source]

Accept this nodegroup’s enlistment.

reject()[source]

Reject this nodegroup’s enlistment.

get_managed_interfaces()[source]

Return the list of interfaces for which MAAS manages DHCP.

ensure_boot_source_definition()[source]

Set default boot source if none is currently defined.

manages_dns()[source]

Does this NodeGroup manage DNS on any interfaces?

This returns True when the NodeGroup is accepted, and has a NodeGroupInterface that’s set to manage both DHCP and DNS.

ensure_dhcp_key()[source]

Ensure that this nodegroup has a dhcp key.

This method persists the dhcp key without triggering the model signals (pre_save/post_save/etc) because it’s called from dhcp.configure_dhcp which, in turn, it called from the post_save signal of NodeGroup.

work_queue[source]

The name of the queue for tasks specific to this nodegroup.

import_boot_images()[source]

Import the pxe files on this cluster controller.

The files are downloaded through the proxy defined in the config setting ‘http_proxy’ if defined.

add_seamicro15k(mac, username, password, power_control=None)[source]

Add all of the specified cards the Seamicro SM15000 chassis at the specified MAC.

Parameters:
  • mac – MAC address of the card.
  • username – username for power controller
  • password – password for power controller
  • power_control – optional specify the power control method, either ipmi (default), restapi, or restapi2.
add_virsh(poweraddr, password=None)[source]

Add all of the virtual machines inside a virsh controller.

Parameters:
  • poweraddr – virsh connection string
  • password – ssh password
enlist_nodes_from_ucsm(url, username, password)[source]

Add the servers from a Cicso UCS Manager.

Parameters:
  • URL – URL of the Cisco UCS Manager HTTP-XML API.
  • username – username for UCS Manager.
  • password – password for UCS Manager.
MAAS logo

MAAS

Metal As A Service.



Related Topics

This Page