diff --git a/bun.lockb b/bun.lockb index d3e2214..d9abc98 100755 Binary files a/bun.lockb and b/bun.lockb differ diff --git a/windows-rdp/main.test.ts b/windows-rdp/main.test.ts index 24ce104..adbf323 100644 --- a/windows-rdp/main.test.ts +++ b/windows-rdp/main.test.ts @@ -9,6 +9,7 @@ import { type TestVariables = Readonly<{ agent_id: string; resource_id: string; + share?: string; admin_username?: string; admin_password?: string; }>; diff --git a/windows-rdp/main.tf b/windows-rdp/main.tf index fb09c48..10ece09 100644 --- a/windows-rdp/main.tf +++ b/windows-rdp/main.tf @@ -9,6 +9,15 @@ terraform { } } +variable "share" { + type = string + default = "owner" + validation { + condition = var.share == "owner" || var.share == "authenticated" || var.share == "public" + error_message = "Incorrect value. Please set either 'owner', 'authenticated', or 'public'." + } +} + variable "agent_id" { type = string description = "The ID of a Coder agent." @@ -53,6 +62,7 @@ resource "coder_script" "windows-rdp" { resource "coder_app" "windows-rdp" { agent_id = var.agent_id + share = var.share slug = "web-rdp" display_name = "Web RDP" url = "http://localhost:7171"