Cloud¶
Overview¶
Cloud machine creation in DRP describes the architecture by which virtual machines are provisioned in cloud providers — AWS, Azure, GCP, and others — and then registered as managed Machine objects within DRP. Unlike bare-metal discovery, which relies on PXE boot and the physical network, cloud-create begins with an API call to a cloud provider and ends with a fully registered, agent-connected machine ready to receive workflow tasks.
Resource Brokers¶
The central architectural element for cloud provisioning is the Resource Broker (RSB). A Resource Broker is a DRP object that represents a pool of cloud resources — an account, region, and instance type — from which virtual machines can be requested. When a workflow task requests a cloud machine, it creates a request against a Resource Broker. The broker translates that abstract request into provider-specific API calls (for example, AWS RunInstances or Azure VM creation) and tracks the resulting instance.
Resource Brokers decouple the workflow from provider-specific details. A workflow written against the Resource Broker abstraction can create VMs in any supported cloud without modification. The broker also manages the lifecycle of the instance, including tracking its state, handling errors, and tearing it down when the machine is decommissioned.
Cloud Create Workflow¶
The cloud-create flow proceeds through the following phases:
-
Request submission. A DRP workflow task (typically within a universal-application or cluster workflow) creates a ResourceBroker allocation request. The request specifies the instance type, image, networking parameters, and user-data script to be embedded in the VM at launch.
-
VM provisioning. DRP's Resource Broker plugin calls the target cloud provider's API to create the virtual machine. The user-data script bundled into the instance includes the DRP endpoint address, a join-up token, and instructions for the machine agent to bootstrap itself on first boot.
-
Agent startup and join-up. Once the VM is running, cloud-init (or equivalent) executes the user-data script. This script downloads the DRP machine agent, collects basic inventory (cloud provider metadata, instance ID, IP addresses), and calls the DRP endpoint to either create a new Machine object or match an existing one. This mirrors the join-up process used in bare-metal discovery but does not require PXE or Sledgehammer.
-
Machine registration. DRP receives the join-up request and registers the VM as a Machine object in its database, assigning an API token and recording the hardware addresses and cloud-specific identifiers. At this point the machine is visible in the DRP portal and API.
-
Workflow execution. With the machine registered and the agent connected, DRP drives the machine through its assigned workflow — application installation, configuration, or any other pipeline — exactly as it would for a bare-metal system. The cloud origin of the machine is transparent to workflow tasks.
Differences from PXE-Based Discovery¶
PXE discovery is initiated by the physical system itself: it boots, contacts the DRP DHCP/TFTP service, loads Sledgehammer, and then runs join-up. Cloud create reverses this order: DRP (via the Resource Broker) creates the machine first, then the VM calls home. This means cloud-create machines do not require DRP to be on the same Layer 2 network segment, and they do not require DHCP provisioning from DRP. They do require network reachability from the cloud VM to the DRP endpoint over HTTPS.
Another key difference is that cloud VMs carry cloud-provider-supplied identity (instance ID, cloud metadata) which DRP records alongside the standard hardware inventory. This identity is used by the Resource Broker to correlate the VM back to its allocation request and to manage teardown later.