Skip to content

Latest commit

 

History

History
42 lines (31 loc) · 1.34 KB

agent_instance.md

File metadata and controls

42 lines (31 loc) · 1.34 KB
page_title subcategory description
coder_agent_instance Resource - terraform-provider-coder
Use this resource to associate an instance ID with an agent for zero-trust authentication. This association is done automatically for "google_compute_instance", "aws_instance", "azurerm_linux_virtual_machine", and "azurerm_windows_virtual_machine" resources.

coder_agent_instance (Resource)

Use this resource to associate an instance ID with an agent for zero-trust authentication. This association is done automatically for "google_compute_instance", "aws_instance", "azurerm_linux_virtual_machine", and "azurerm_windows_virtual_machine" resources.

Example Usage

resource "coder_agent" "dev" {
  os   = "linux"
  arch = "amd64"
  auth = "google-instance-identity"
}

resource "google_compute_instance" "dev" {
  zone = "us-central1-a"
}

resource "coder_agent_instance" "dev" {
  agent_id    = coder_agent.dev.id
  instance_id = google_compute_instance.dev.instance_id
}

Schema

Required

  • agent_id (String) The id property of a coder_agent resource to associate with.
  • instance_id (String) The instance identifier of a provisioned resource.

Read-Only

  • id (String) The ID of this resource.