Skip to content

feat: display builtin apps on workspaces table #17695

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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
May 7, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Simplify and comment select agent
  • Loading branch information
BrunoQuaresma committed May 7, 2025
commit 1270f18a6f5e733c6f409a84d786dbb19313cf1a
19 changes: 12 additions & 7 deletions site/src/pages/WorkspacesPage/WorkspacesTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -641,14 +641,19 @@ const WorkspaceApps: FC<WorkspaceAppsProps> = ({ workspace }) => {
const { data: apiKeyRes } = useQuery(apiKey());
const token = apiKeyRes?.key;

const resource = workspace.latest_build.resources
/**
* Coder is pretty flexible and allows an enormous variety of use cases, such
* as having multiple resources with many agents, but they are not common. The
* most common scenario is to have one single compute resource with one single
* agent containing all the apps. Lets test this getting the apps for the
* first resource, and first agent - they are sorted to return the compute
* resource first - and see what customers and ourselves, using dogfood, think
* about that.
*/
const agent = workspace.latest_build.resources
.filter((r) => !r.hide)
.at(0);
if (!resource) {
return null;
}

const agent = resource.agents?.at(0);
.at(0)
?.agents?.at(0);
if (!agent) {
return null;
}
Expand Down
Loading