Skip to content

Conversation

@matifali
Copy link
Member

@matifali matifali commented Jul 3, 2024

The owner-related fields (owner, owner_email, owner_id, owner_name, owner_oidc_access_token, owner_groups, owner_session_token) in the workspace data source have been deprecated. This commit removes these fields from the codebase.

We should have done this before https://github.com/coder/terraform-provider-coder/releases/tag/v1.0.0

contributes to #250

…urce

The owner-related fields (`owner`, `owner_email`, `owner_id`, `owner_name`, `owner_oidc_access_token`, `owner_groups`, `owner_session_token`) in the workspace data source have been deprecated. This commit removes these fields from the codebase.
@matifali matifali self-assigned this Jul 3, 2024
Copy link
Member Author

@matifali matifali left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

self review.


## Example Usage

```terraform
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Elaborated example usage. If its too much happy to simply it.

resource "coder_env" "git_author_email" {
agent_id = var.agent_id
agent_id = coder_agent.dev.id
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there was no var defined so used the already defined agent.

Comment on lines -81 to -87
"workspace.owner": `testing`,
"workspace.owner_email": `testing@coder\.com`,
"workspace.owner_groups": `\[\]`,
"workspace.owner_id": `[a-zA-Z0-9]+`,
"workspace.owner_name": `default`,
"workspace.owner_oidc_access_token": `^$`, // TODO: need a test OIDC integration
"workspace.owner_session_token": `[a-zA-Z0-9-]+`,
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed all owner related items from the integration test. We already have a separate integration test for coder_workspace_owner.

@matifali matifali requested review from johnstcn and mtojek July 4, 2024 13:07
@johnstcn
Copy link
Member

johnstcn commented Jul 4, 2024

We will need to bump the major version after this change.

@matifali matifali merged commit 7ed088d into main Jul 5, 2024
@matifali matifali deleted the matifali/coder_workspace branch July 5, 2024 08:40
@github-actions github-actions bot locked and limited conversation to collaborators Jul 5, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants