Skip to content
Closed
Show file tree
Hide file tree
Changes from all 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
1 change: 1 addition & 0 deletions registry/coder-labs/modules/copilot/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -295,6 +295,7 @@ module "agentapi" {
ARG_COPILOT_CONFIG='${base64encode(local.final_copilot_config)}' \
ARG_EXTERNAL_AUTH_ID='${var.external_auth_id}' \
ARG_COPILOT_VERSION='${var.copilot_version}' \
ARG_COPILOT_MODEL='${var.copilot_model}' \
/tmp/install.sh
EOT
}
5 changes: 3 additions & 2 deletions registry/coder-labs/modules/copilot/scripts/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ ARG_MCP_CONFIG=$(echo -n "${ARG_MCP_CONFIG:-}" | base64 -d 2> /dev/null || echo
ARG_COPILOT_CONFIG=$(echo -n "${ARG_COPILOT_CONFIG:-}" | base64 -d 2> /dev/null || echo "")
ARG_EXTERNAL_AUTH_ID=${ARG_EXTERNAL_AUTH_ID:-github}
ARG_COPILOT_VERSION=${ARG_COPILOT_VERSION:-0.0.334}
ARG_COPILOT_MODEL=${ARG_COPILOT_MODEL:-claude-sonnet-4.5}

validate_prerequisites() {
if ! command_exists node; then
Expand Down Expand Up @@ -84,7 +85,7 @@ setup_copilot_configurations() {

local module_path="$HOME/.copilot-module"
mkdir -p "$module_path"
mkdir -p "$HOME/.config"
mkdir -p "$HOME/.copilot"

setup_copilot_config

Expand Down Expand Up @@ -201,7 +202,7 @@ add_custom_mcp_servers() {
}

configure_copilot_model() {
if [ -n "$ARG_COPILOT_MODEL" ] && [ "$ARG_COPILOT_MODEL" != "claude-sonnet-4.5" ]; then
if [ "$ARG_COPILOT_MODEL" != "claude-sonnet-4.5" ]; then
echo "Setting Copilot model to: $ARG_COPILOT_MODEL"
copilot config model "$ARG_COPILOT_MODEL" || {
echo "WARNING: Failed to set model via copilot config, will use environment variable fallback"
Expand Down
Loading