coder / coder/terraform-provider-coder

coder_parameter of type 'number' should allow empty values in the web UI without requiring a default

Open
#462 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
Go
Stars
60
Forks
27
Avg merge
1d 21h
Merged PRs (30d)
2

Description

Version: 2.13.1

## Problem

When using Coder, if a `coder_parameter` has the type number and no default value is set, the build fails with the error `"" is not a number`.

I believe this behavior is not ideal. Ideally, the web interface should allow the parameter to be left empty and require the user to provide a value during the build, rather than requiring a default value to avoid the error.

## Example

```terraform
data "coder_parameter" "ssh_port" {
name = "ssh_port"
display_name = "SSH Port"
type = "number"
mutable = true
validation {
min = 1024
max = 65535
}
}
```

## Solution

Allow number types to be used without a default value, requiring users to provide a value when creating a workspace.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.