⚠️ Experimental — Replaces agent and app attachments on a remote runner.
Calls Guild PUT /api/v1/remote-runners/{id}/attachments without rewriting agent personas. Use this when the runner already exists (lookup / imported) or when attach should be managed independently of sg_remote_runner registration — same pattern as sg_remote_runner_secrets.
Prefer attached_apps = ["sre"] for StackGen SRE Copilot catalog investigators. Do not also set attached_agents / attached_apps on the same runner via sg_remote_runner in the same root — pick one owner to avoid thrash.
# Attach an existing remote runner to SRE catalog agents without persona rewrite.
resource "sg_remote_runner_attachments" "sre" {
runner_id = "guild-dogfood"
attached_apps = ["sre"]
attached_agents = ["stackgen-sre-investigator"]
}
Import an existing sg_remote_runner_attachments using its runner UUID:
terraform import sg_remote_runner_attachments.example '123e4567-e89b-12d3-a456-426614174000'
runner_id (String) Remote runner identifier (same as sg_remote_runner.name / runner_id). Changing forces replacement.attached_agents (List of String) Agent names explicitly allowed to use this runner. Empty list detaches all directly attached agents.attached_apps (List of String) App catalog slugs attached to this runner (e.g. sre). Empty list detaches all attached apps. Prefer for catalog agents to avoid sg_agent persona rewrite.