René's URL Explorer Experiment


Title: Add health-check for `coder_apps` · Issue #2662 · coder/coder · GitHub

Open Graph Title: Add health-check for `coder_apps` · Issue #2662 · coder/coder

X Title: Add health-check for `coder_apps` · Issue #2662 · coder/coder

Description: edited by @bpmct Problem statement Throughout Coder's documentation and examples, the startup_script is used to install web IDEs onto the workspace, such as code-server, Jetbrains Projector, JupyterLab, etc. From there, users connect via...

Open Graph Description: edited by @bpmct Problem statement Throughout Coder's documentation and examples, the startup_script is used to install web IDEs onto the workspace, such as code-server, Jetbrains Projector, Jupyte...

X Description: edited by @bpmct Problem statement Throughout Coder's documentation and examples, the startup_script is used to install web IDEs onto the workspace, such as code-server, Jetbrains Projector, Ju...

Opengraph URL: https://github.com/coder/coder/issues/2662

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Add health-check for `coder_apps`","articleBody":"edited by @bpmct \r\n\r\n## Problem statement\r\n\r\nThroughout Coder's documentation and examples, the [startup_script](https://registry.terraform.io/providers/coder/coder/latest/docs/resources/agent#startup_script) is used to [install web IDEs onto the workspace](https://coder.com/docs/coder-oss/latest/ides/configuring-web-ides), such as code-server, Jetbrains Projector, JupyterLab, etc. From there, users connect via links in the dashboard. In the template, this is defined via the [coder_app](https://registry.terraform.io/providers/coder/coder/latest/docs/resources/app) resource.\r\n\r\nWhen the workspace starts, it takes 15-60s for the IDEs to install before a user can get to the page. When they click it before the app loads, there's a 404 page: \r\n\r\n\u003cimg width=\"400\" alt=\"Screen Shot 2022-08-01 at 5 00 55 PM\" src=\"https://user-images.githubusercontent.com/22407953/182253361-4bc7c804-c99d-4cb7-baca-63c46416c9bf.png\">\r\n\r\nHowever, when you refresh 30 seconds later, it works!\r\n\r\n\u003cimg width=\"400\" alt=\"Screen Shot 2022-08-01 at 5 02 13 PM\" src=\"https://user-images.githubusercontent.com/22407953/182253481-0f6f65b3-1991-4e3a-b604-5333479e8267.png\">\r\n\r\n\r\n## Definition of done\r\n\r\nFrom the dashboard, the app cannot be opened until the health check passes, or the app is eventually deemed unhealthy.\r\n\r\n## Prior art\r\n\r\nHealth checks are implemented for [generic apps in Coder Classic](https://coder.com/docs/coder/latest/workspaces/applications#application-specification-file) with support for `exec` and `http` based health checks, but with a hardcoded interval/timeout/unhealthy threshold. There is not a loading indicator in the Ui, but when an app is clicked, the tab loads for `x` seconds until the health check passes/fails.\r\n\r\n## Ideas\r\n\r\n@bpmct: Unlike health checks in Coder Classic, I think health checks would benefit from a configurable `unhealthy threshold` since applications will often be installed during runtime, leading to longer-than-normal \"wait times.\" [GCP follows this pattern](https://cloud.google.com/load-balancing/docs/health-check-concepts)\r\n\r\n- Some apps may depend on a process starting (e.g code-server, http.server) so it can be considered unhealthy in 15 seconds\r\n- Some apps may depend on IntelliJ downloading and could take 60+ seconds\r\n\r\nAdd health check to `coder_app` resource\r\n\r\n```diff\r\nresource \"coder_app\" \"code_server\" {\r\n   # ...\r\n+  health_check {\r\n+     # actual schema TBD\r\n+     enabled = true\r\n+     unhealthy_threshold = \"60s\"\r\n+   }\r\n}\r\n```\r\n\r\nBefore the unhealthy threshold, a loading indicator could be present making it clear to users the app is still unhealthy/loading until the health check passes or times out. Perhaps the app is also unclickable\r\n\r\n\u003cimg width=\"464\" alt=\"Screen Shot 2022-08-01 at 5 27 45 PM\" src=\"https://user-images.githubusercontent.com/22407953/182256653-906947c4-6d15-41ab-8121-c5685054c073.png\">\r\n \r\nAfter the threshold is exceeded (e.g 3 mins), the app can have a red/error indicator if the health check never passes:\r\n\r\n\u003cimg width=\"475\" alt=\"Screen Shot 2022-08-01 at 5 30 55 PM\" src=\"https://user-images.githubusercontent.com/22407953/182256502-b76fc7ad-21aa-45d1-beab-6de4d93f1a04.png\">.","author":{"url":"https://github.com/sharkymark","@type":"Person","name":"sharkymark"},"datePublished":"2022-06-26T19:29:30Z","url":"https://github.com/coder/coder/issues/2662"}

react-profiling0
react-import-mapreact,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-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:bb08d4a8-51f7-4609-b954-ab98dd489af4
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idD140:842EC:219DD2A:2CCE6D7:6B018AF9
html-safe-noncea38bf54e970dd0450d4d2767a2b6837262c1aa52eb7616bc013d7670889fb406
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEMTQwOjg0MkVDOjIxOUREMkE6MkNDRTZENzo2QjAxOEFGOSIsInZpc2l0b3JfaWQiOiI1MDg1MjM2NzM2MTgzODY0MDU3IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmac20398dc2c3f427078648642244e05e66f6bc0f53be2bee850ac54699968b7e7e
hovercard-subject-tagissue:1285010333
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/coder/coder/2662/issue_layout
twitter:imagehttps://opengraph.githubassets.com/88ec86a8bc039b8c091e50c7f43b51236794ab71cef3a2eca85b165be3fb2bd0/coder/coder/issues/2662
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/88ec86a8bc039b8c091e50c7f43b51236794ab71cef3a2eca85b165be3fb2bd0/coder/coder/issues/2662
og:image:altedited by @bpmct Problem statement Throughout Coder's documentation and examples, the startup_script is used to install web IDEs onto the workspace, such as code-server, Jetbrains Projector, Jupyte...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamesharkymark
hostnamegithub.com
expected-hostnamegithub.com
Nonecc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c
turbo-cache-controlno-preview
go-importgithub.com/coder/coder git https://github.com/coder/coder.git
octolytics-dimension-user_id95932066
octolytics-dimension-user_logincoder
octolytics-dimension-repository_id440752086
octolytics-dimension-repository_nwocoder/coder
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id440752086
octolytics-dimension-repository_network_root_nwocoder/coder
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release8c77c9e8439031ad54c75a250694842892f693e1
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/coder/coder/issues/2662#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fcoder%2Fcoder%2Fissues%2F2662
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fcoder%2Fcoder%2Fissues%2F2662
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=coder%2Fcoder
Reloadhttps://github.com/coder/coder/issues/2662
Reloadhttps://github.com/coder/coder/issues/2662
Reloadhttps://github.com/coder/coder/issues/2662
coderhttps://github.com/coder
coderhttps://github.com/coder/coder
Codehttps://github.com/coder/coder
Issues320 (320)https://github.com/coder/coder/issues
Pull requests470 (470)https://github.com/coder/coder/pulls
Discussionshttps://github.com/coder/coder/discussions
Actionshttps://github.com/coder/coder/actions
Projectshttps://github.com/coder/coder/projects
Security and quality49 (49)https://github.com/coder/coder/security
Insightshttps://github.com/coder/coder/insights
https://github.com/coder/coder
New issuehttps://github.com/login?return_to=https://github.com/coder/coder/issues/2662
New issuehttps://github.com/login?return_to=https://github.com/coder/coder/issues/2662
Add health-check for coder_appshttps://github.com/coder/coder/issues/2662#top
https://github.com/f0ssel
apiArea: HTTP APIhttps://github.com/coder/coder/issues?q=state%3Aopen%20label%3A%22api%22
siteArea: frontend dashboardhttps://github.com/coder/coder/issues?q=state%3Aopen%20label%3A%22site%22
EEhttps://github.com/coder/coder/milestone/9
https://github.com/sharkymark
sharkymarkhttps://github.com/sharkymark
on Jun 26, 2022https://github.com/coder/coder/issues/2662#issue-1285010333
@bpmcthttps://github.com/bpmct
startup_scripthttps://registry.terraform.io/providers/coder/coder/latest/docs/resources/agent#startup_script
install web IDEs onto the workspacehttps://coder.com/docs/coder-oss/latest/ides/configuring-web-ides
coder_apphttps://registry.terraform.io/providers/coder/coder/latest/docs/resources/app
https://user-images.githubusercontent.com/22407953/182253361-4bc7c804-c99d-4cb7-baca-63c46416c9bf.png
https://user-images.githubusercontent.com/22407953/182253481-0f6f65b3-1991-4e3a-b604-5333479e8267.png
generic apps in Coder Classichttps://coder.com/docs/coder/latest/workspaces/applications#application-specification-file
@bpmcthttps://github.com/bpmct
GCP follows this patternhttps://cloud.google.com/load-balancing/docs/health-check-concepts
https://user-images.githubusercontent.com/22407953/182256653-906947c4-6d15-41ab-8121-c5685054c073.png
https://user-images.githubusercontent.com/22407953/182256502-b76fc7ad-21aa-45d1-beab-6de4d93f1a04.png
tjcranhttps://github.com/tjcran
bpmcthttps://github.com/bpmct
on Aug 1, 2022https://github.com/coder/coder/issues/2662#event-7103193531
bpmcthttps://github.com/bpmct
on Aug 1, 2022https://github.com/coder/coder/issues/2662#event-7105337595
https://github.com/kylecarbs
kylecarbshttps://github.com/kylecarbs
on Aug 1, 2022https://github.com/coder/coder/issues/2662#issuecomment-1201810295
https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/#define-a-liveness-http-requesthttps://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/#define-a-liveness-http-request
https://github.com/spikecurtis
spikecurtishttps://github.com/spikecurtis
on Aug 1, 2022https://github.com/coder/coder/issues/2662#issuecomment-1201825645
https://github.com/mafredri
mafredrihttps://github.com/mafredri
on Aug 2, 2022https://github.com/coder/coder/issues/2662#issuecomment-1202537995
https://github.com/bpmct
bpmcthttps://github.com/bpmct
on Aug 2, 2022https://github.com/coder/coder/issues/2662#issuecomment-1202626599
https://github.com/bpmct
bpmcthttps://github.com/bpmct
on Aug 2, 2022https://github.com/coder/coder/issues/2662#issuecomment-1202634784
https://github.com/misskniss
missknisshttps://github.com/misskniss
on Aug 2, 2022https://github.com/coder/coder/issues/2662#issuecomment-1202827410
@Emyrkhttps://github.com/Emyrk
missknisshttps://github.com/misskniss
needs groominghttps://github.com/coder/coder/issues?q=state%3Aopen%20label%3A%22needs%20grooming%22
on Aug 2, 2022https://github.com/coder/coder/issues/2662#event-7111041321
https://github.com/Emyrk
Emyrkhttps://github.com/Emyrk
on Aug 2, 2022https://github.com/coder/coder/issues/2662#issuecomment-1202850844
@missknisshttps://github.com/misskniss
https://github.com/kylecarbs
kylecarbshttps://github.com/kylecarbs
on Aug 2, 2022https://github.com/coder/coder/issues/2662#issuecomment-1202857948
@missknisshttps://github.com/misskniss
https://github.com/bpmct
bpmcthttps://github.com/bpmct
on Aug 2, 2022https://github.com/coder/coder/issues/2662#issuecomment-1202978201
#2989https://github.com/coder/coder/issues/2989
#2179https://github.com/coder/coder/issues/2179
https://github.com/misskniss
missknisshttps://github.com/misskniss
on Aug 2, 2022https://github.com/coder/coder/issues/2662#issuecomment-1203125557
@kylecarbshttps://github.com/kylecarbs
@Emyrkhttps://github.com/Emyrk
https://github.com/sreya
sreyahttps://github.com/sreya
on Aug 3, 2022https://github.com/coder/coder/issues/2662#issuecomment-1203356415
https://github.com/bpmct
bpmcthttps://github.com/bpmct
on Aug 8, 2022https://github.com/coder/coder/issues/2662#issuecomment-1208241839
@sreyahttps://github.com/sreya
https://github.com/spikecurtis
spikecurtishttps://github.com/spikecurtis
on Aug 9, 2022https://github.com/coder/coder/issues/2662#issuecomment-1209748204
@kylecarbshttps://github.com/kylecarbs
https://github.com/kylecarbs
kylecarbshttps://github.com/kylecarbs
on Aug 9, 2022https://github.com/coder/coder/issues/2662#issuecomment-1209751303
@spikecurtishttps://github.com/spikecurtis
bpmcthttps://github.com/bpmct
EEhttps://github.com/coder/coder/milestone/9
on Aug 22, 2022https://github.com/coder/coder/issues/2662#event-7233743296
kylecarbshttps://github.com/kylecarbs
featurehttps://github.com/coder/coder/issues?q=state%3Aopen%20label%3A%22feature%22
siteArea: frontend dashboardhttps://github.com/coder/coder/issues?q=state%3Aopen%20label%3A%22site%22
apiArea: HTTP APIhttps://github.com/coder/coder/issues?q=state%3Aopen%20label%3A%22api%22
needs groominghttps://github.com/coder/coder/issues?q=state%3Aopen%20label%3A%22needs%20grooming%22
on Aug 22, 2022https://github.com/coder/coder/issues/2662#event-7236649739
https://github.com/BrunoQuaresma
BrunoQuaresmahttps://github.com/BrunoQuaresma
on Aug 29, 2022https://github.com/coder/coder/issues/2662#issuecomment-1230335838
kylecarbshttps://github.com/kylecarbs
f0sselhttps://github.com/f0ssel
on Aug 31, 2022https://github.com/coder/coder/issues/2662#event-7298676482
kylecarbshttps://github.com/kylecarbs
on Sep 20, 2022https://github.com/coder/coder/issues/2662#event-7423007775
f0sselhttps://github.com/f0ssel
completedhttps://github.com/coder/coder/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
on Sep 26, 2022https://github.com/coder/coder/issues/2662#event-7459356497
Sign up for freehttps://github.com/signup?return_to=https://github.com/coder/coder/issues/2662
Sign in to commenthttps://github.com/login?return_to=https://github.com/coder/coder/issues/2662
f0sselhttps://github.com/f0ssel
apiArea: HTTP APIhttps://github.com/coder/coder/issues?q=state%3Aopen%20label%3A%22api%22
siteArea: frontend dashboardhttps://github.com/coder/coder/issues?q=state%3Aopen%20label%3A%22site%22
EEhttps://github.com/coder/coder/milestone/9
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.