Marcin Tojek
a2d4b9984e
fix: hide app icon if not found ( #16684 )
...
Fixes: https://github.com/coder/coder/issues/14759
2025-02-25 10:30:17 +00:00
Hugo Dutka
c8abf58e29
chore: reduce prominence of Scratch starter and emphasize Docker in UI ( #16665 )
2025-02-24 20:59:21 +01:00
Steven Masley
658825cad2
feat: add sourcing secondary claims from access_token ( #16517 )
...
Niche edge case, assumes access_token is jwt.
Some `access_token`s are JWT's with potential useful claims.
These claims would be nearly equivalent to `user_info` claims.
This is not apart of the oauth spec, so this feature should not be
loudly advertised. If using this feature, alternate solutions are preferred.
2025-02-24 13:38:20 -06:00
Steven Masley
e005e4e51d
chore: merge provisioner key and provisioner permissions ( #16628 )
...
Provisioner key permissions were never any different than provisioners.
Merging them for a cleaner permission story until they are required (if
ever) to be seperate.
This removed `ResourceProvisionerKey` from RBAC and just uses the
existing `ResourceProvisioner`.
2025-02-24 13:31:11 -06:00
546a549dcf
feat: enable soft delete for organizations ( #16584 )
...
- Add deleted column to organizations table
- Add trigger to check for existing workspaces, templates, groups and
members in a org before allowing the soft delete
---------
Co-authored-by: Steven Masley <stevenmasley@gmail.com >
Co-authored-by: Steven Masley <Emyrk@users.noreply.github.com >
2025-02-24 12:59:41 -05:00
Hugo Dutka
ac88c9ba17
fix: ensure the web UI doesn't break when license telemetry required check fails ( #16667 )
...
Addresses https://github.com/coder/coder/issues/16455 .
## Changes
- Initialize default entitlements in a Set to include all features
- Initialize entitlements' `Warnings` and `Errors` fields to arrays
rather than `nil`s.
- Minor changes in formatting on the frontend
## Reasoning
I had to change how entitlements are initialized to match the `codersdk`
[generated
types](https://github.com/coder/coder/blob/33d62619225702257fa2542f40ecc26bfd0d1fa6/site/src/api/typesGenerated.ts#L727 ),
which the frontend assumes are correct, and doesn't run additional
checks on.
- `features: Record<FeatureName, Feature>`: this type signifies that
every `FeatureName` is present in the record, but on `main`, that's not
true if there's a telemetry required error
- `warnings: readonly string[];` and `errors: readonly string[];`: these
types mean that the fields are not `null`, but that's not always true
With a valid license, the [`LicensesEntitlements`
function](https://github.com/coder/coder/blob/33d62619225702257fa2542f40ecc26bfd0d1fa6/enterprise/coderd/license/license.go#L92 )
ensures that all features are present in the entitlements. It's called
by the [`Entitlements`
function](https://github.com/coder/coder/blob/33d62619225702257fa2542f40ecc26bfd0d1fa6/enterprise/coderd/license/license.go#L42 ),
which is called by
[`api.updateEnittlements`](https://github.com/coder/coder/blob/33d62619225702257fa2542f40ecc26bfd0d1fa6/enterprise/coderd/coderd.go#L687 ).
However, when a license requires telemetry and telemetry is disabled,
the entitlements with all features [are
discarded](https://github.com/coder/coder/blob/33d62619225702257fa2542f40ecc26bfd0d1fa6/enterprise/coderd/coderd.go#L704 )
in an early exit from the same function. By initializing entitlements
with all the features from the get go, we avoid this problem.
## License issue banner after the changes
<img width="1512" alt="Screenshot 2025-02-23 at 20 25 42"
src="https://github.com/user-attachments/assets/ee0134b3-f745-45d9-8333-bfa1661e33d2 "
/>
2025-02-24 16:02:33 +01:00
Marcin Tojek
ab5c9f7e0c
fix: display notification on schedule update ( #16672 )
...
Fixes: https://github.com/coder/coder/issues/15214
2025-02-24 13:27:16 +00:00
brettkolodny
39f42bc11d
feat: show dialog with a redirect if permissions are required ( #16661 )
...
Closes [this
issue](https://github.com/coder/internal/issues/385#issuecomment-2667061358 )
## New behavior
When a user ends up on a page they don't have permission to view instead
of being redirected back to _/workspaces_ they'll be met with the
un-closeable dialog below with a link to _/workspaces_.
This is similar to [this PR](https://github.com/coder/coder/pull/16644 )
but IMO we should be making sure we are using `<RequirePermissions />`
wherever applicable and only relying on `<ErrorAlert />` as a fallback
in case there is some page we missed or endpoint we're accidentally
using.

2025-02-21 17:43:32 -05:00
brettkolodny
ce49ce4f41
fix: redirect users lacking create permissions to /workspaces ( #16659 )
...
Closes [this issue](https://github.com/coder/internal/issues/394 ).
At the moment this behavior can be a bit confusing, but after [this
issue is
closed](https://github.com/coder/internal/issues/385#issuecomment-2667061358 )
it should be more obvious what's going on here.
2025-02-21 16:33:54 -05:00
ケイラ
a85a220816
chore: clean up built-in role permissions ( #16645 )
2025-02-21 14:33:34 -07:00
brettkolodny
a376e8dbfe
fix: include a link and more useful error details for 403 response codes ( #16644 )
...
Currently if a user gets to a page they don't have permission to view
they're greeted with a vague error alert and no actionable items. This
PR adds a link back to _/workspaces_ within the alert as well as more
helpful error details.
Before:

After:

2025-02-21 16:26:07 -05:00
Hugo Dutka
8c5e7007cd
feat: support the OAuth2 device flow with GitHub for signing in ( #16585 )
...
First PR in a series to address
https://github.com/coder/coder/issues/16230 .
Introduces support for logging in via the [GitHub OAuth2 Device
Flow](https://docs.github.com/en/apps/oauth-apps/building-oauth-apps/authorizing-oauth-apps#device-flow ).
It's previously been possible to configure external auth with the device
flow, but it's not been possible to use it for logging in. This PR
builds on the existing support we had to extend it to sign ins.
When a user clicks "sign in with GitHub" when device auth is configured,
they are redirected to the new `/login/device` page, which makes the
flow possible from the client's side. The recording below shows the full
flow.
https://github.com/user-attachments/assets/90c06f1f-e42f-43e9-a128-462270c80fdd
I've also manually tested that it works for converting from
password-based auth to oauth.
Device auth can be enabled by a deployment's admin by setting the
`CODER_OAUTH2_GITHUB_DEVICE_FLOW` env variable or a corresponding config
setting.
2025-02-21 18:42:16 +01:00
Marcin Tojek
e8a7b7e8cb
feat: add notifications troubleshooting tab ( #16650 )
2025-02-21 14:34:48 +01:00
brettkolodny
54b09d9878
fix: show an error banner if the user does not have permission to view the audit page ( #16637 )
2025-02-20 09:56:57 -05:00
Marcin Tojek
f670559a5d
fix: change validation error for workspace name ( #16643 )
...
Fixes: https://github.com/coder/coder/issues/14824
2025-02-20 14:34:31 +01:00
brettkolodny
570e42b7f7
fix: rearrange render logic ( #16631 )
...
Change the render logic so that we always show an error message if the
error is available
2025-02-19 15:09:37 -05:00
ケイラ
deadac0b91
fix: fix loading states and permissions checks in organization settings ( #16465 )
2025-02-19 11:48:13 -07:00
Marcin Tojek
e59c54a539
fix: center proxy spinner ( #16621 )
...
Fixes: https://github.com/coder/coder/issues/16615
2025-02-19 19:07:10 +01:00
brettkolodny
4732f08588
fix: show an error when a user doesn't have permission to view the health page ( #16580 )
2025-02-19 10:54:35 -05:00
Kira Pilot and Jaayden Halko
2c6df5a9ae
fix: sort orgs alphabetically in dropdown ( #16583 )
...
resolves https://github.com/coder/internal/issues/352
<img width="312" alt="Screenshot 2025-02-18 at 12 16 09 PM"
src="https://github.com/user-attachments/assets/c7863bfd-c7cc-4fa6-be88-68a03cd19c1f "
/>
---------
Co-authored-by: Jaayden Halko <jaayden.halko@gmail.com >
2025-02-19 10:20:14 -05:00
Marcin Tojek
22fa71d15c
fix: open link with search params ( #16617 )
...
Fixes: https://github.com/coder/coder/issues/16501
2025-02-19 12:55:55 +01:00
Bruno Quaresma
0f3858ecc9
feat: display provisioner jobs and daemons for an organization ( #16532 )
...
**Jobs:**
<img width="1624" alt="Screenshot 2025-02-13 at 09 26 31"
src="https://github.com/user-attachments/assets/dc1f24de-48e8-4f91-b128-8e4f3b109328 "
/>
[Figma
Link](https://www.figma.com/design/JYW69pbgOMr21fCMiQsPXg/Provisioners?node-id=10-2005&m=dev )
**Daemons:**
<img width="1624" alt="Screenshot 2025-02-13 at 09 26 53"
src="https://github.com/user-attachments/assets/429d77ee-2b4f-45d1-924f-796145901fd8 "
/>
[Figma
Link](https://www.figma.com/design/JYW69pbgOMr21fCMiQsPXg/Provisioners?node-id=26-4038&m=dev )
Close https://github.com/coder/coder/issues/15192 and
https://github.com/coder/coder/issues/15193
2025-02-18 11:27:51 -03:00
Sas Swart
a17cf03980
feat(site): add support for presets to the create workspace page ( #16567 )
...
This pull request adds support for presets to the create workspace page.
This behaviour can be seen in the storybook. This will not be visible in
dogfood until we merge support for presets in the provisioners.
There is more frontend work to be done before this is ready for a
general release, but this should be sufficient for dogfood testing
2025-02-18 15:26:55 +02:00
Danielle Maywood
d6b9806098
chore: implement oom/ood processing component ( #16436 )
...
Implements the processing logic as set out in the OOM/OOD RFC.
2025-02-17 16:56:52 +00:00
Mathias Fredriksson
b5329ae1cd
feat: add workspace agent connect and app open audit types ( #16493 )
...
This commit adds new audit resource types for workspace agents and
workspace apps, as well as connect/disconnect and open/close actions.
The idea is that we will log new audit events for connecting to the
agent via SSH/editor.
Likewise, we will log openings of `coder_app`s.
This change also introduces support for filtering by `request_id`.
Updates #15139
2025-02-17 13:02:30 +00:00
Marcin Tojek
42f6b716f2
fix: add link to troubleshooting ( #16592 )
...
Fixes: https://github.com/coder/coder/issues/14933
2025-02-17 14:00:51 +01:00
brettkolodny
1ce4dfe058
fix: stop text from overflowing on delete org button ( #16549 )
...
Closes #16433
I also took the opportunity to convert the components to tailwind. Since
there aren't designs for this piece of UI yet I tried to match it as
closely as possible using the existing tailwind config

2025-02-14 11:13:28 -05:00
Mathias Fredriksson
77306f3de1
feat(coderd): add filters and fix template for provisioner daemons ( #16558 )
...
This change adds provisioner daemon ID filter to the provisioner daemons
endpoint, and also implements the limiting to 50 results.
Test coverage is greatly improved and template information for jobs
associated to the daemon was also fixed.
Updates #15084
Updates #15192
Related #16532
2025-02-14 17:26:46 +02:00
Marcin Tojek
5ce4cc07de
fix: switch engagement chart to linear ( #16576 )
...
Fixes: https://github.com/coder/internal/issues/363
2025-02-14 13:13:32 +00:00
Marcin Tojek
1c5a0425c5
fix: include origin in support link ( #16572 )
...
Fixes: https://github.com/coder/coder/issues/15542
2025-02-14 13:07:59 +00:00
M Atif Ali
b1d53b091c
feat(site): add Keycloak icon ( #16569 )
...
https://www.keycloak.org/
2025-02-14 09:37:12 +00:00
brettkolodny
b23e3f9132
fix: change resource icon colors in the delete modal based on the set theme ( #16550 )
2025-02-13 17:41:02 -05:00
Jaayden Halko
00e76b881f
chore: migrate to tailwind ( #16543 )
...
Moving styles to Tailwind
2025-02-13 14:45:38 -05:00
Mathias Fredriksson
e38bd27183
feat(coderd): add support for provisioner job id and tag filter ( #16556 )
...
This change adds to new filters to the provisionerjobs endpoint, id
(array) and tags (map).
Updates #15084
Updates #15192
Related #16532
2025-02-13 18:24:27 +02:00
Jaayden Halko
ea1358ce76
chore: update table component and styles ( #16541 )
...
- migrate styles to tailwind
- migrate to new Table component
2025-02-12 14:59:18 -05:00
brettkolodny
f1c26050b1
fix: add correct size to storybook icon buttons ( #16539 )
...
Jaayden and I noticed that the icon button in storybooks didn't look
correct. This PR fixes that by adding the correct size argument.
2025-02-12 14:28:15 -05:00
Marcin Tojek
d7614a4b02
fix: display error on deleted workspace build ( #16536 )
...
Fixes: https://github.com/coder/coder/issues/15058
2025-02-12 16:43:05 +01:00
Sas Swart
71cbf735e5
feat(coderd): add support for presets to the coder API ( #16526 )
...
This pull request builds on the existing migrations and queries to add
support for presets to the coder API.
2025-02-12 14:41:14 +02:00
Bruno Quaresma
e85da8b02b
chore: return template data for provisioner daemons ( #16514 )
...
Return template data in provisioner jobs to be displayed in the
provisioners page.
2025-02-11 14:22:34 -03:00
Bruno Quaresma
e9b3561677
refactor: return template_icon and make metadata required ( #16496 )
2025-02-10 10:00:34 -03:00
Cian Johnston
31b1ff7d3b
feat(agent): add container list handler ( #16346 )
...
Fixes https://github.com/coder/coder/issues/16268
- Adds `/api/v2/workspaceagents/:id/containers` coderd endpoint that allows listing containers
visible to the agent. Optional filtering by labels is supported.
- Adds go tools to the `coder-dylib` CI step so we can generate mocks if needed
2025-02-10 11:29:30 +00:00
Jaayden Halko
7076c4e4ab
feat: add combobox for selecting claim field value for group/role idp sync ( #16459 )
...
contributes to coder/internal#330
This is a followup to coder/coder#16335
This adds a combobox that swaps with the input for the idp group and idp
role names when the sync field returns claim values from the claim field
values endpoint. If no claim field values are returned then the input
remains instead of the combobox.
<img width="806" alt="Screenshot 2025-02-05 at 20 50 48"
src="https://github.com/user-attachments/assets/bff839f5-1a2f-4cc1-8933-73fde942bc75 "
/>
<img width="803" alt="Screenshot 2025-02-05 at 20 51 00"
src="https://github.com/user-attachments/assets/e9c7ca33-136a-4962-b924-770a64658dc8 "
/>
2025-02-07 16:31:02 -05:00
ケイラ
323559ba82
feat: show warning on unrecognized idp group and role mapping claims ( #16485 )
2025-02-07 11:41:22 -07:00
Bruno Quaresma
8a3a79f527
refactor: match StatusIndicator component with the new designs ( #16458 )
...
Reference:
https://www.figma.com/design/WfqIgsTFXN2BscBSSyXWF8/Coder-kit?node-id=489-4278&m=dev
2025-02-07 15:11:56 -03:00
Bruno Quaresma
de70ff3206
fix: display SVG emojis in the picker ( #16492 )
...
Fix https://github.com/coder/coder/issues/16263
2025-02-07 11:48:01 -03:00
ケイラ
bcfeb726d6
feat: show warning on unrecognized idp org mapping claims ( #16478 )
2025-02-06 16:45:03 -07:00
Mathias Fredriksson
b04d883348
feat: add provisioner job metadata ( #16454 )
...
This change adds metadata to provisioner jobs to help with rendering
related tempaltes and workspaces in the UI.
Updates #15084
2025-02-06 16:19:20 +02:00
Bruno Quaresma
f45277a2eb
chore: add Tooltip component ( #16444 )
...
Based on
https://www.figma.com/design/WfqIgsTFXN2BscBSSyXWF8/Coder-kit?node-id=489-4332&m=dev
<img width="110" alt="Screenshot 2025-02-05 at 10 45 27"
src="https://github.com/user-attachments/assets/8fb9cda8-fdca-49ba-8f11-a40058570d1a "
/>
2025-02-05 16:53:45 -03:00
ケイラ
b13cac9f0a
chore: remove beta badges from organizations ( #16411 )
2025-02-05 09:21:17 -07:00
Jaayden Halko
497abe902d
chore: add storybook stories for combobox component ( #16451 )
2025-02-05 10:58:04 -05:00