Revert "Change variable name to default"

This reverts commit 4893f172c3.
pull/224/head
austin 1 year ago
parent 4893f172c3
commit 8b78673cad

@ -28,6 +28,6 @@ module "dotfiles" {
source = "registry.coder.com/modules/dotfiles/coder"
version = "1.0.12"
agent_id = coder_agent.example.id
default = "https://github.com/coder/dotfiles"
default_dotfiles_repo = "https://github.com/coder/dotfiles"
}
```

@ -20,11 +20,11 @@ describe("dotfiles", async () => {
});
it("set a default dotfiles_uri", async () => {
const default = "foo";
const default_dotfiles_uri = "foo";
const state = await runTerraformApply(import.meta.dir, {
agent_id: "foo",
default,
default_dotfiles_uri,
});
expect(state.outputs.dotfiles_uri.value).toBe(default);
expect(state.outputs.dotfiles_uri.value).toBe(default_dotfiles_uri);
});
});

@ -14,7 +14,7 @@ variable "agent_id" {
description = "The ID of a Coder agent."
}
variable "default" {
variable "default_dotfiles_uri" {
type = string
description = "The default dotfiles URI if the workspace user does not provide one."
default = ""
@ -24,7 +24,7 @@ data "coder_parameter" "dotfiles_uri" {
type = "string"
name = "dotfiles_uri"
display_name = "Dotfiles URL (optional)"
default = var.default
default = var.default_dotfiles_uri
description = "Enter a URL for a [dotfiles repository](https://dotfiles.github.io) to personalize your workspace"
mutable = true
icon = "/icon/dotfiles.svg"
@ -50,5 +50,5 @@ output "dotfiles_uri" {
output "dotfiles_default_uri" {
description = "Dotfiles Default URI"
value = var.default
value = var.default_dotfiles_uri
}
Loading…
Cancel
Save