Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: replace example that requires TFC #114

Merged
merged 1 commit into from
Oct 18, 2024
Merged
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
8 changes: 4 additions & 4 deletions docs/resources/template.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ When importing, the ID supplied can be either a template UUID retrieved via the
// Provider populated from environment variables
provider "coderd" {}

// Get the commit SHA of the configuration's git repository
variable "TFC_CONFIGURATION_VERSION_GIT_COMMIT_SHA" {
// Can be populated using an environment variable, or an external datasource script
variable "COMMIT_SHA" {
type = string
}

Expand All @@ -38,12 +38,12 @@ resource "coderd_template" "ubuntu-main" {
description = "The main template for developing on Ubuntu."
versions = [
{
name = "stable-${var.TFC_CONFIGURATION_VERSION_GIT_COMMIT_SHA}"
name = "stable-${var.COMMIT_SHA}"
description = "The stable version of the template."
directory = "./stable-template"
},
{
name = "staging-${var.TFC_CONFIGURATION_VERSION_GIT_COMMIT_SHA}"
name = "staging-${var.COMMIT_SHA}"
description = "The staging version of the template."
directory = "./staging-template"
}
Expand Down
8 changes: 4 additions & 4 deletions examples/resources/coderd_template/resource.tf
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
// Provider populated from environment variables
provider "coderd" {}

// Get the commit SHA of the configuration's git repository
variable "TFC_CONFIGURATION_VERSION_GIT_COMMIT_SHA" {
// Can be populated using an environment variable, or an external datasource script
variable "COMMIT_SHA" {
type = string
}

Expand All @@ -17,12 +17,12 @@ resource "coderd_template" "ubuntu-main" {
description = "The main template for developing on Ubuntu."
versions = [
{
name = "stable-${var.TFC_CONFIGURATION_VERSION_GIT_COMMIT_SHA}"
name = "stable-${var.COMMIT_SHA}"
description = "The stable version of the template."
directory = "./stable-template"
},
{
name = "staging-${var.TFC_CONFIGURATION_VERSION_GIT_COMMIT_SHA}"
name = "staging-${var.COMMIT_SHA}"
description = "The staging version of the template."
directory = "./staging-template"
}
Expand Down
Loading