Skip to content
This repository was archived by the owner on May 15, 2025. It is now read-only.
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion code-server/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ terraform {
required_providers {
coder = {
source = "coder/coder"
version = ">= 0.17"
version = ">= 2.1"
}
}
}
Expand Down Expand Up @@ -122,6 +122,16 @@ variable "subdomain" {
default = false
}

variable "open_in" {
type = string
description = <<-EOT
Determines where the app will be opened. Valid values are `"tab"` and `"slim-window" (default)`.
`"tab"` opens in a new tab in the same browser window.
`"slim-window"` opens a new browser window without navigation controls.
EOT
default = "slim-window"
}

resource "coder_script" "code-server" {
agent_id = var.agent_id
display_name = "code-server"
Expand Down Expand Up @@ -166,6 +176,7 @@ resource "coder_app" "code-server" {
subdomain = var.subdomain
share = var.share
order = var.order
open_in = var.open_in

healthcheck {
url = "http://localhost:${var.port}/healthz"
Expand Down