Title: [Feat]: Leverage "proxy-domain" in the "Ports" panel · Issue #5458 · coder/code-server · GitHub
Open Graph Title: [Feat]: Leverage "proxy-domain" in the "Ports" panel · Issue #5458 · coder/code-server
X Title: [Feat]: Leverage "proxy-domain" in the "Ports" panel · Issue #5458 · coder/code-server
Description: What is your suggestion? VS Code Remote, Gitpod, and Codespaces have a lovely panel to detect and access ports via "Ports." Demonstration: Screen.Recording.2022-08-09.at.1.41.40.PM.mov code-server has a lesser-known "proxy-domain" featur...
Open Graph Description: What is your suggestion? VS Code Remote, Gitpod, and Codespaces have a lovely panel to detect and access ports via "Ports." Demonstration: Screen.Recording.2022-08-09.at.1.41.40.PM.mov code-server ...
X Description: What is your suggestion? VS Code Remote, Gitpod, and Codespaces have a lovely panel to detect and access ports via "Ports." Demonstration: Screen.Recording.2022-08-09.at.1.41.40.PM.mov co...
Opengraph URL: https://github.com/coder/code-server/issues/5458
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"[Feat]: Leverage \"proxy-domain\" in the \"Ports\" panel","articleBody":"## What is your suggestion?\r\n\r\nVS Code Remote, Gitpod, and Codespaces have a lovely panel to detect and access ports via \"Ports.\" Demonstration:\r\n\r\nhttps://user-images.githubusercontent.com/22407953/184697035-7a75ac07-4130-4ec2-936b-ecfb719dcc4c.mov\r\n\r\ncode-server has a lesser-known [\"proxy-domain\" feature](https://coder.com/docs/code-server/latest/guide#using-a-subdomain) which also allows you to access running ports running on the code-server host via a subdomain pointed to code-server (e.g. `https://8080.subdomain.coder.com`). \r\n\r\nWhat if when a user runs an app on port 3000, code-server detects it and adds to \"Ports\". Also, what if you clicked \"localhost:3000\" from the code-server terminal, it actually goes to the proper feature.\r\n\r\n## Why do you want this feature?\r\n\r\nFeature parity with SaaS solutions. Also, with a minor change, this would work pretty well with [Coder](https://github.com/coder/coder) once [coder/coder#1624](https://github.com/coder/coder/issues/1624) is completed.\r\n\r\nAlthough code-servers proxy wouldn't be directly used, Coder's proxy be and it would \"just work.\" Right now, however, the proxy domain expects the port to be the only part of the subdomain. (e.g `8080.the-rest` vs. `8080-other-stuff.the-rest`)\r\n\r\n```hcl\r\n# inside a Coder template\r\n# see https://coder.com/docs/coder-oss/latest/templates/\r\nresource \"coder_agent\" \"main\" {\r\n arch = \"amd64\"\r\n os = \"linux\"\r\n startup_script = \u003c\u003cEOF\r\n #!/bin/sh\r\n # install and start code-server\r\n curl -fsSL https://code-server.dev/install.sh | sh\r\n # set proxy-domain to the URL to access a port from a workpace inside Coder itself\r\n code-server --auth none --port 13337 --proxy-domain=[PORT]-main-${data.coder_workspace.me.name}-${data.coder_workspace.me.owner}.coder.example.com\r\n EOF\r\n}\r\n```\r\n\r\n## Are there any workarounds to get this functionality today?\r\n\r\nNavigating to the URL directly.\r\n\r\n## Are you interested in submitting a PR for this?\r\n\r\nI wouldn't know where to start :(","author":{"url":"https://github.com/bpmct","@type":"Person","name":"bpmct"},"datePublished":"2022-08-15T18:57:21Z","url":"https://github.com/coder/code-server/issues/5458"}
| 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:48aad1e6-56ff-83e8-6990-fc94589027e9 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | CBF0:19AA62:274BFB6:31EA054:6B0196BC |
| html-safe-nonce | 3357b47afb37cd657d164cc4eae6a66a9dd77f28ac20d486f62d396943b96f92 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDQkYwOjE5QUE2MjoyNzRCRkI2OjMxRUEwNTQ6NkIwMTk2QkMiLCJ2aXNpdG9yX2lkIjoiODQwNzc0MTU4MTg2MDI2Njg0IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | cc998ee2dd01e5ab5a06ac0ee81dd1601f7e9633490edfccd8d9ad5b0a519765 |
| hovercard-subject-tag | issue:1339366443 |
| 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/code-server/5458/issue_layout |
| twitter:image | https://opengraph.githubassets.com/c91b02bdbf9625dc3e93cf25bdab22d4fea6d53e5aa26be7bf69003b3a07cfba/coder/code-server/issues/5458 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/c91b02bdbf9625dc3e93cf25bdab22d4fea6d53e5aa26be7bf69003b3a07cfba/coder/code-server/issues/5458 |
| og:image:alt | What is your suggestion? VS Code Remote, Gitpod, and Codespaces have a lovely panel to detect and access ports via "Ports." Demonstration: Screen.Recording.2022-08-09.at.1.41.40.PM.mov code-server ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | bpmct |
| hostname | github.com |
| expected-hostname | github.com |
| None | cc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c |
| turbo-cache-control | no-preview |
| go-import | github.com/coder/code-server git https://github.com/coder/code-server.git |
| octolytics-dimension-user_id | 95932066 |
| octolytics-dimension-user_login | coder |
| octolytics-dimension-repository_id | 172953845 |
| octolytics-dimension-repository_nwo | coder/code-server |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 172953845 |
| octolytics-dimension-repository_network_root_nwo | coder/code-server |
| 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