diff --git a/vscode-server/main.tf b/vscode-server/main.tf index 2953f25..aeabcb9 100644 --- a/vscode-server/main.tf +++ b/vscode-server/main.tf @@ -57,12 +57,6 @@ variable "accept_license" { } } -variable "custom_version" { - type = string - description = "The version of VS Code to install." - default = "latest" -} - resource "coder_script" "vscode-server" { agent_id = var.agent_id display_name = "vscode-server" @@ -70,8 +64,8 @@ resource "coder_script" "vscode-server" { script = templatefile("${path.module}/run.sh", { PORT : var.port, LOG_PATH : var.log_path, - VERSION : var.custom_version, INSTALL_DIR : var.install_dir, + TELEMETRY : var.telemetry, }) run_on_start = true } diff --git a/vscode-server/run.sh b/vscode-server/run.sh index 04a6368..aa551f5 100644 --- a/vscode-server/run.sh +++ b/vscode-server/run.sh @@ -14,4 +14,4 @@ printf "🥳 vscode-server has been installed.\n\n" echo "👷 Running ${INSTALL_DIR}/bin/code serve-web --port ${PORT} --without-connection-token --accept-server-license-terms in the background..." echo "Check logs at ${LOG_PATH}!" -${INSTALL_DIR}/bin/code-server serve-local --port ${PORT} --without-connection-token --accept-server-license-terms >${LOG_PATH} 2>&1 & +${INSTALL_DIR}/bin/code-server serve-local --port ${PORT} --without-connection-token --accept-server-license-terms --telemetry-level ${TELEMETRY} >${LOG_PATH} 2>&1 &