Skip to content

Commit b90094b

Browse files
feat: implement automated version documentation system
Implements a maintainable system for documenting minimum Coder version requirements for each resource and data source. Changes: - Add resource_versions.go with version registry that developers must update - Modify docsgen to automatically inject version information into docs - Add version compatibility matrix to provider index page - Add developer documentation for maintaining version requirements - All resources now show their minimum required Coder version This ensures users can easily identify version requirements and prevents compatibility issues. Co-authored-by: matifali <[email protected]>
1 parent dacc296 commit b90094b

19 files changed

+239
-1
lines changed

docs/data-sources/external_auth.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ description: |-
1010

1111
Use this data source to require users to authenticate with an external service prior to workspace creation. This can be used to [pre-authenticate external services](https://coder.com/docs/admin/external-auth) in a workspace. (e.g. Google Cloud, Github, Docker, etc.)
1212

13+
~> **Note:** This data source requires [Coder v2.18.0](https://github.com/coder/coder/releases/tag/v2.18.0) or later.
14+
1315
## Example Usage
1416

1517
```terraform

docs/data-sources/parameter.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ description: |-
1010

1111
Use this data source to configure editable options for workspaces.
1212

13+
~> **Note:** This data source requires [Coder v2.18.0](https://github.com/coder/coder/releases/tag/v2.18.0) or later.
14+
1315
## Example Usage
1416

1517
```terraform

docs/data-sources/provisioner.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ description: |-
1010

1111
Use this data source to get information about the Coder provisioner.
1212

13+
~> **Note:** This data source requires [Coder v2.18.0](https://github.com/coder/coder/releases/tag/v2.18.0) or later.
14+
1315
## Example Usage
1416

1517
```terraform

docs/data-sources/workspace.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ description: |-
1010

1111
Use this data source to get information for the active workspace build.
1212

13+
~> **Note:** This data source requires [Coder v2.18.0](https://github.com/coder/coder/releases/tag/v2.18.0) or later.
14+
1315
## Example Usage
1416

1517
```terraform

docs/data-sources/workspace_owner.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ description: |-
1010

1111
Use this data source to fetch information about the workspace owner.
1212

13+
~> **Note:** This data source requires [Coder v2.18.0](https://github.com/coder/coder/releases/tag/v2.18.0) or later.
14+
1315
## Example Usage
1416

1517
```terraform

docs/data-sources/workspace_preset.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ description: |-
1010

1111
Use this data source to predefine common configurations for coder workspaces. Users will have the option to select a defined preset, which will automatically apply the selected configuration. Any parameters defined in the preset will be applied to the workspace. Parameters that are defined by the template but not defined by the preset will still be configurable when creating a workspace.
1212

13+
~> **Note:** This data source requires [Coder v2.18.0](https://github.com/coder/coder/releases/tag/v2.18.0) or later.
14+
1315
## Example Usage
1416

1517
```terraform

docs/data-sources/workspace_tags.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ description: |-
1010

1111
Use this data source to configure workspace tags to select provisioners.
1212

13+
~> **Note:** This data source requires [Coder v2.18.0](https://github.com/coder/coder/releases/tag/v2.18.0) or later.
14+
1315
## Example Usage
1416

1517
```terraform

docs/index.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,20 @@ Terraform provider for managing Coder [templates](https://coder.com/docs/admin/t
1414

1515
!> [`coder_git_auth`](https://registry.terraform.io/providers/coder/coder/1.0.4/docs/data-sources/git_auth) and owner related fields of [`coder_workspace`](https://registry.terraform.io/providers/coder/coder/1.0.4/docs/data-sources/workspace) data source have been removed. Follow the [Version 2 Upgrade Guide](https://registry.terraform.io/providers/coder/coder/latest/docs/guides/version-2-upgrade) to update your code.
1616

17+
## Version Compatibility
18+
19+
The following table shows the minimum Coder version required for each terraform-provider-coder release:
20+
21+
| Provider Version | Minimum Coder Version | Key Features |
22+
|------------------|-----------------------|--------------|
23+
| v2.8.0+ | [v2.18.0](https://github.com/coder/coder/releases/tag/v2.18.0) | Default preset support |
24+
| v2.7.0+ | [v2.24.0](https://github.com/coder/coder/releases/tag/v2.24.0) | AI task resource |
25+
| v2.6.0+ | [v2.18.0](https://github.com/coder/coder/releases/tag/v2.18.0) | Scheduling configuration for prebuilds |
26+
| v2.5.0+ | [v2.21.0](https://github.com/coder/coder/releases/tag/v2.21.0) | Devcontainer support |
27+
| v2.0.0+ | [v2.18.0](https://github.com/coder/coder/releases/tag/v2.18.0) | Base requirement for v2 provider |
28+
29+
~> **Note:** Individual resources may have higher version requirements. Check the documentation for each resource to see its specific minimum Coder version.
30+
1731
## Example
1832

1933
```terraform

docs/resources/agent.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ description: |-
1010

1111
Use this resource to associate an agent.
1212

13+
~> **Note:** This resource requires [Coder v2.18.0](https://github.com/coder/coder/releases/tag/v2.18.0) or later.
14+
1315
## Example Usage
1416

1517
```terraform

docs/resources/agent_instance.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ description: |-
1010

1111
Use this resource to associate an instance ID with an agent for zero-trust authentication. This association is done automatically for `"google_compute_instance"`, `"aws_instance"`, `"azurerm_linux_virtual_machine"`, and `"azurerm_windows_virtual_machine"` resources.
1212

13+
~> **Note:** This resource requires [Coder v2.18.0](https://github.com/coder/coder/releases/tag/v2.18.0) or later.
14+
1315
## Example Usage
1416

1517
```terraform

0 commit comments

Comments
 (0)