From c414cc5347848e2785f4d4370e0a3581ea805de6 Mon Sep 17 00:00:00 2001 From: Kyle Carberry Date: Fri, 25 Mar 2022 10:53:54 -0500 Subject: [PATCH] fix: Move "coder_workspace.username" to "coder_workspace.owner" --- docs/data-sources/workspace.md | 2 +- internal/provider/provider.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/data-sources/workspace.md b/docs/data-sources/workspace.md index 77f0e13a..1dc1ffce 100644 --- a/docs/data-sources/workspace.md +++ b/docs/data-sources/workspace.md @@ -31,7 +31,7 @@ resource "kubernetes_pod" "dev" { ### Read-Only - **name** (String) Name of the workspace. +- **owner** (String) Username of the workspace owner. - **transition** (String) Either "start" or "stop". Use this to start/stop resources with "count". -- **username** (String) Username of the workspace owner. diff --git a/internal/provider/provider.go b/internal/provider/provider.go index 65d919c4..dd0bde65 100644 --- a/internal/provider/provider.go +++ b/internal/provider/provider.go @@ -65,7 +65,7 @@ func New() *schema.Provider { transition = "start" } rd.Set("transition", transition) - rd.Set("username", os.Getenv("CODER_WORKSPACE_USERNAME")) + rd.Set("owner", os.Getenv("CODER_WORKSPACE_OWNER")) rd.Set("name", os.Getenv("CODER_WORKSPACE_NAME")) return nil }, @@ -75,7 +75,7 @@ func New() *schema.Provider { Computed: true, Description: `Either "start" or "stop". Use this to start/stop resources with "count".`, }, - "username": { + "owner": { Type: schema.TypeString, Computed: true, Description: "Username of the workspace owner.",