Title: Resource Metadata + Secrets · Issue #2989 · coder/coder · GitHub
Open Graph Title: Resource Metadata + Secrets · Issue #2989 · coder/coder
X Title: Resource Metadata + Secrets · Issue #2989 · coder/coder
Description: Problem statement Developers want to see additional metadata about resources in Coder. This could be an instance type, the number of cores an instance has, or a link to the cloud resource itself (say in a GCP dashboard). As a developer, ...
Open Graph Description: Problem statement Developers want to see additional metadata about resources in Coder. This could be an instance type, the number of cores an instance has, or a link to the cloud resource itself (s...
X Description: Problem statement Developers want to see additional metadata about resources in Coder. This could be an instance type, the number of cores an instance has, or a link to the cloud resource itself (s...
Opengraph URL: https://github.com/coder/coder/issues/2989
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Resource Metadata + Secrets","articleBody":"## Problem statement\r\n\r\nDevelopers want to see additional metadata about resources in Coder. This could be an instance type, the number of cores an instance has, or a link to the cloud resource itself (say in a GCP dashboard).\r\n\r\nAs a developer, I want to see information about my workspace, both information that is dynamic (e.g external IP) and the most relevant aspects of the template (no. CPUs).\r\n\r\n## Definition of done\r\n\r\nWe should add arbitrary key/value pairs that allow template authors to expose additional metadata. This should be added in our Terraform Provider, allowing customers to expose arbitrary values from existing resources that are provisioned. The key/value pairs would be available from the CLI and the dashboard. \r\n\r\n---\r\nImplementation notes (@bpmct)\r\n\r\nDashboard [(figma)](https://www.figma.com/file/YIGBkXUcnRGz2ZKNmLaJQf/Coder-v2-Design?node-id=599%3A632):\r\n\r\n\r\n\r\n\r\nTemplate:\r\n\r\n```hcl\r\nresource \"null_resource\" \"about\" {}\r\n\r\nresource \"coder_metadata\" \"about_info\" {\r\n resource_id = null_resource.about.id\r\n item {\r\n key = \"type\"\r\n value = null\r\n }\r\n item {\r\n key = \"quicklinks\"\r\n value = \"[onboarding guide](https://mywiki.com/onboarding), [troubleshooting](https://mywiki.com/troubleshooting)\"\r\n }\r\n}\r\n\r\nresource \"kubernetes_pod\" \"main-dev\" {\r\n # ...\r\n}\r\n\r\nresource \"coder_metadata\" \"dev_info\" {\r\n resource_id = kubernetes_pod.main-dev.id\r\n item {\r\n key = \"api_key\"\r\n value = \"asdfjkl\"\r\n sensitive: true\r\n }\r\n}\r\n\r\n```\r\n\r\nCLI: \r\n\r\n```sh\r\n$ coder metadata my-workspace\r\nRESOURCE_NAME KEY VALUE\r\nabout workspace-id acf2a70d-6347-4b8c\r\nabout quicklinks [onboarding guide](https://mywiki.com/onboarding), [troubleshooting](https://mywiki.com/troubleshooting)\r\nmain-dev type kubernetes_pod\r\nmain-dev api_key (hidden)\r\n\r\nSome values are sensitive. Use `coder metadata myworkspace \u003ckey>` to fetch individual values.\r\n```\r\n\r\nIn the future, perhaps `resource_id = \"global\"` or `global = true` could be used to display metadata workspace-wide in another panel if the hack is widely used.\r\n\r\n---\r\n\r\nRelated:\r\n- #1325 \r\n- #1321 ","author":{"url":"https://github.com/ammario","@type":"Person","name":"ammario"},"datePublished":"2022-07-14T16:20:48Z","url":"https://github.com/coder/coder/issues/2989"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:331dc51f-9d53-3dca-3491-770a09ab0aae |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B052:215B92:2264D73:2DC4814:6B018D42 |
| html-safe-nonce | 90df5e6b70d6b177b1ee0999ebeab5873d5f67e8fa9b549ebac88d0e03561470 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCMDUyOjIxNUI5MjoyMjY0RDczOjJEQzQ4MTQ6NkIwMThENDIiLCJ2aXNpdG9yX2lkIjoiMjg1ODQ1MDI2MTI1MjIxMTg2IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 77fec82facd3df295b0bdd5fce8a688fe14866a37f175811a5c99c8ffe0d4194 |
| hovercard-subject-tag | issue:1305012377 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/coder/coder/2989/issue_layout |
| twitter:image | https://opengraph.githubassets.com/369eabfe863ad6bdadbb6dacea0b826495f533307f2ca0cde40b4ede0ebca536/coder/coder/issues/2989 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/369eabfe863ad6bdadbb6dacea0b826495f533307f2ca0cde40b4ede0ebca536/coder/coder/issues/2989 |
| og:image:alt | Problem statement Developers want to see additional metadata about resources in Coder. This could be an instance type, the number of cores an instance has, or a link to the cloud resource itself (s... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | ammario |
| hostname | github.com |
| expected-hostname | github.com |
| None | cc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c |
| turbo-cache-control | no-preview |
| go-import | github.com/coder/coder git https://github.com/coder/coder.git |
| octolytics-dimension-user_id | 95932066 |
| octolytics-dimension-user_login | coder |
| octolytics-dimension-repository_id | 440752086 |
| octolytics-dimension-repository_nwo | coder/coder |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 440752086 |
| octolytics-dimension-repository_network_root_nwo | coder/coder |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 8c77c9e8439031ad54c75a250694842892f693e1 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width