Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat: storecoder_workspace_tags in the database#13294

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
mtojek merged 27 commits intomainfrom13218-workspace-tags
May 20, 2024
Merged

Conversation

mtojek
Copy link
Member

@mtojekmtojek commentedMay 16, 2024
edited
Loading

Fixes:#13218
Follow-up:#13219

Note: I know this PR is relatively large, but there are chunks of generated code.

Changes:

  • add database tabletemplate_version_workspace_tags to store tags extracted from the template in the database (will be used in the follow up PR)
  • add logic to insert/query workspace tags from the database
  • update dependency onterraform-provider-coder
  • terraform runner can parse and extract workspace tags from a template

Terraform preview:

[API] 2024-05-17 10:56:18.081 [info]  terraform: unpacking template source archive  session_id=5c2d05eb-8b1b-476b-9f4b-7c8bf804a2fa  size_bytes=44544[API] 2024-05-17 10:56:18.087 [info]  terraform: workspace tag found  key=cluster  value="\"developers\""[API] 2024-05-17 10:56:18.087 [info]  terraform: workspace tag found  key=os  value=data.coder_parameter.os_selector.value[API] 2024-05-17 10:56:18.087 [info]  terraform: workspace tag found  key=debug  value="\"${data.coder_parameter.feature_debug_enabled.value}+12345\""[API] 2024-05-17 10:56:18.087 [info]  terraform: workspace tag found  key=cache  value="data.coder_parameter.feature_cache_enabled.value == \"true\" ? \"nix-with-cache\" : \"no-cache\""

Database preview:

select * from template_version_workspace_tags;         template_version_id          |   key   |                                           value--------------------------------------+---------+-------------------------------------------------------------------------------------------- c7da54e8-37a3-4374-b103-bb76f9bd189b | cluster | "developers" c7da54e8-37a3-4374-b103-bb76f9bd189b | os      | data.coder_parameter.os_selector.value c7da54e8-37a3-4374-b103-bb76f9bd189b | debug   | "${data.coder_parameter.feature_debug_enabled.value}+12345" c7da54e8-37a3-4374-b103-bb76f9bd189b | cache   | data.coder_parameter.feature_cache_enabled.value == "true" ? "nix-with-cache" : "no-cache"(4 rows)

@mtojekmtojek self-assigned thisMay 16, 2024
@mtojekmtojekforce-pushed the13218-workspace-tags branch from8556888 to849ad82CompareMay 17, 2024 10:06
@mtojekmtojek marked this pull request as ready for reviewMay 17, 2024 12:24
@mtojekmtojekenabled auto-merge (squash)May 20, 2024 13:30
@mtojekmtojek merged commitb8b80fe intomainMay 20, 2024
32 checks passed
@mtojekmtojek deleted the 13218-workspace-tags branchMay 20, 2024 13:30
@github-actionsgithub-actionsbot locked and limited conversation to collaboratorsMay 20, 2024
Sign up for freeto subscribe to this conversation on GitHub. Already have an account?Sign in.
Reviewers

@johnstcnjohnstcnjohnstcn approved these changes

@mafredrimafredriAwaiting requested review from mafredri

Assignees

@mtojekmtojek

Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

coderd: implementcoder_workspace_tags
2 participants
@mtojek@johnstcn

[8]ページ先頭

©2009-2025 Movatter.jp