fix(dogfood): fix startup script looping (#11972)

Seems to be on account of the quotes interpreting a ~ literally.  We do
replace it with /home/coder but only if it matches ~/, not ~ alone.
This commit is contained in:
Asher 2024-01-31 21:33:02 -09:00 committed by GitHub
parent 3ace7982aa
commit e748312193
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -31,7 +31,7 @@ locals {
"sa-saopaulo" = "tcp://oberstein-sao-cdr-dev.tailscale.svc.cluster.local:2375"
}
repo_base_dir = replace(data.coder_parameter.repo_base_dir.value, "/^~\\//", "/home/coder/")
repo_base_dir = data.coder_parameter.repo_base_dir.value == "~" ? "/home/coder" : replace(data.coder_parameter.repo_base_dir.value, "/^~\\//", "/home/coder/")
repo_dir = module.git-clone.repo_dir
container_name = "coder-${data.coder_workspace.me.owner}-${lower(data.coder_workspace.me.name)}"
jfrog_host = replace(var.jfrog_url, "https://", "")