Compare commits

..

583 Commits

Author SHA1 Message Date
Steven Masley db9274f8aa feat: purge expired api keys in dbpurge (#20863) (#21040)
Backport of https://github.com/coder/coder/pull/20863
2025-12-01 15:25:58 -06:00
Danny Kopping a75205a559 fix: remove a sensitive field from an agent log line (#20968) (#20970)
Backport of #20968

Co-authored-by: Sas Swart <sas.swart.cdk@gmail.com>
2025-11-27 17:35:00 +02:00
Cian Johnston 41dfbc7f1d chore: update Go to 1.24.10 (#20684) (#20707)
(cherry picked from commit 81c3375670)

Signed-off-by: Danny Kopping <danny@coder.com>
Co-authored-by: Danny Kopping <danny@coder.com>
2025-11-10 10:54:57 -06:00
Dean Sheather ee8e8cb805 fix: initialize pseudo console with default size for SSH sessions [2.26] (#20491)
> Resolved an invalid parameter error (-2147024809) during PTY creation
on Windows 11 22H2 (but not only) when connecting via JetBrains Toolbox
which spawns the native SSH client with `-tt` forcing PTY allocation
even though there is no "terminal" on the client side to query its size.
>
> CreatePseudoConsole doesn't accept a 0x0 (zero width and zero height)
console size and unfortunately, there is NO explicit documentation in
the official Microsoft documentation that states the minimum valid
values or explicitly prohibits 0x0.
>
> Looking at real-world implementations in the search results, all
examples use reasonable non-zero values.
>
> I tested this with a local Windows VM registered to dev.coder.com i.e.
externally managed workspace.

Relates to #20468

Co-authored-by: Faur Ioan-Aurel <fioan89@gmail.com>
2025-10-28 22:47:03 +11:00
Danielle Maywood 4793806569 chore: upgrade coder/clistat to v1.1.1 (#20322) (#20324)
coder/clistat has received a handful of bug fixes so we're back-porting
these bug fixes to 2.26

---

Cherry-picked from 9bef5de30d
2025-10-16 15:29:05 +01:00
Dean Sheather 03440f6ae2 fix: avoid connection logging crashes in agent [2.26] (#20306)
# For release 2.26

- Ignore errors when reporting a connection from the server, just log
them instead
- Translate connection log IP `localhost` to `127.0.0.1` on both the
server and the agent
- Temporary fix: convert invalid IPs to `127.0.0.1` since the database
forbids NULL

Relates to #20194
2025-10-16 01:28:10 +11:00
Cian Johnston 7afe6c813b fix(coderd): ensure agent WebSocket conn is cleaned up (#19711) (#20094)
Co-authored-by: Danielle Maywood <danielle@themaywoods.com>
2025-10-01 15:37:56 -05:00
Kacper Sawicki 536920459d [2.26 backport] perf(enterprise): remove expensive GetWorkspaces query from entitlements (#19747) (#19756)
This PR addresses the significant database load issue where the
GetWorkspaces query was causing performance problems in the license
entitlements code.

cherry picked from commit 3074547
2025-09-11 09:48:32 +02:00
Kacper Sawicki c0f1b9d73e [2.26 backport] fix: pin pg_dump version when generating schema (#19696) (#19765)
This is required by #19756 

The latest release of all `pg_dump` major versions, going back to 13,
started inserting `\restrict` `\unrestrict` keywords into dumps. This
currently breaks sqlc in `gen/dump` and our check migration script. Full
details of the postgres change are available here:
https://git.postgresql.org/gitweb/?p=postgresql.git;a=commitdiff;h=575f54d4c

To fix, we'll always use the `pg_dump` in our postgres 13.21 docker
image for schema dumps, instead of what's on the runner/local machine.

Coder doesn't restore from postgres dumps, so we're not vulnerable to
attacks that would be patched by the latest postgres version.
Regardless, we'll unpin ASAP.

Once sqlc is updated to handle these keywords, we need to start
stripping them when comparing the schema in the migration check script,
and then we can unpin the pg_dump version. This is being tracked at
https://github.com/coder/internal/issues/965

Co-authored-by: Ethan <39577870+ethanndickson@users.noreply.github.com>
2025-09-11 09:32:58 +02:00
Stephen Kirby a056cb6577 chore: add last commit from cherry-pick list for release (#19679)
Co-authored-by: Spike Curtis <spike@coder.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-02 19:19:04 -05:00
Stephen Kirby 0a73f842b3 fix: merge cherry-picked items for v2.26.0 (#19678)
Co-authored-by: Cian Johnston <cian@coder.com>
Co-authored-by: Mathias Fredriksson <mafredri@gmail.com>
Co-authored-by: Hugo Dutka <hugo@coder.com>
Co-authored-by: Kacper Sawicki <kacper@coder.com>
Co-authored-by: Atif Ali <atif@coder.com>
Co-authored-by: Danielle Maywood <danielle@themaywoods.com>
Co-authored-by: Susana Ferreira <susana@coder.com>
Co-authored-by: Brett Kolodny <brettkolodny@gmail.com>
Co-authored-by: Dean Sheather <dean@deansheather.com>
Co-authored-by: Steven Masley <Emyrk@users.noreply.github.com>
2025-09-02 16:19:17 -05:00
Cian Johnston 8083d9d5c8 fix(cli): attach org option to task create (#19554)
Attaches the org context options to the exp task create cmd
2025-08-26 19:42:02 +01:00
Callum Styan f0cf0adcc8 feat: log additional known non-sensitive query param fields in the httpmw logger (#19532)
Blink helped here but it's suggestion was to have a set map of sensitive
fields based on predefined constants in various files, such as the api
token string names. For now we'll add additional query param logging for fields we know are safe/that we want to log, such as query pagination/limit fields and ID list counts which may help identify P99 DB query latencies.

---------

Signed-off-by: Callum Styan <callumstyan@gmail.com>
2025-08-26 11:14:53 -07:00
Brett Kolodny d274f832b3 chore: improve scroll behavior of DashboardLayout wrapped pages (#19396)
Updates the the `DashboardLayout` to create a singular scroll area
between the top nav bar and the deployment banner on the bottom. Also
improves the scroll behavior of the org settings pages.

<img width="2122" height="1413" alt="CleanShot 2025-08-18 at 13 53 01"
src="https://github.com/user-attachments/assets/a9920509-69e7-471d-ac0d-853cb212fcae"
/>




https://github.com/user-attachments/assets/128be43d-433f-4a0f-af5b-bbfb7d646345
2025-08-26 14:14:44 -04:00
Bruno Quaresma 59525f879b feat: display startup script logs while agent is starting (#19530)
Closes https://github.com/coder/coder/issues/19363

**Screenshot:**

<img width="1318" height="753" alt="Screenshot 2025-08-25 at 11 02 25"
src="https://github.com/user-attachments/assets/6fa1d4c7-dddb-4db9-a9f0-86986b3628d8"
/>

**Demo:**


https://github.com/user-attachments/assets/07a68e30-b776-44f9-b4ca-e2dd8d124281
2025-08-26 12:45:07 -03:00
Bruno Quaresma a1546b5414 refactor: replace task prompt by workspace name in the topbar (#19531)
Fixes https://github.com/coder/coder/issues/19524

**Screenshot:**

<img width="1512" height="773" alt="Screenshot 2025-08-25 at 14 59 11"
src="https://github.com/user-attachments/assets/5d958302-04b3-4cd6-8e59-41a3048798be"
/>

**Demo:**


https://github.com/user-attachments/assets/040490ea-b276-48d7-9f3a-d8261d982bb5

**Changes:**
- Change "View workspace" button to icon + "Workspace"
- Updated the title to use the workspace name instead of the prompt
- Added a prompt button, so the user can see what is the prompt that is
running + copy it easily
2025-08-26 12:24:52 -03:00
Cian Johnston 5baaf2747d feat(cli): implement exp task status command (#19533)
Closes https://github.com/coder/internal/issues/900

- Implements `coder exp task status`
- Adds `testutil.MustURL` helper
2025-08-26 16:01:35 +01:00
Danielle Maywood c19f430f35 fix(cli): display workspace created at time instead of current time (#19553)
Applying a suggestion from
https://github.com/coder/coder/pull/19492#discussion_r2301175791
2025-08-26 15:57:44 +01:00
Steven Masley ef0d74fb75 chore: improve performance of 'GetLatestWorkspaceBuildsByWorkspaceIDs' (#19452)
Closes https://github.com/coder/internal/issues/716

This prevents a scan over the entire `workspace_build` table by removing
a `join`. This is still imperfect as we are still scanning over the
number of builds for the workspaces in the arguments. Ideally we would
have some index or something precomputed. Then we could skip scanning
over the builds for the correct workspaces that are not the latest.
2025-08-26 09:26:11 -05:00
Danielle Maywood 63c1325ad5 feat(cli): add exp task create command (#19492)
Partially implements https://github.com/coder/internal/issues/893

This isn't the full implementation of `coder exp tasks create` as
defined in the issue, but it is the minimum required to create a task.
2025-08-26 15:24:42 +01:00
dependabot[bot] 73544a1cc8 chore: bump github.com/mark3labs/mcp-go from 0.37.0 to 0.38.0 (#19544)
Bumps [github.com/mark3labs/mcp-go](https://github.com/mark3labs/mcp-go)
from 0.37.0 to 0.38.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/mark3labs/mcp-go/releases">github.com/mark3labs/mcp-go's
releases</a>.</em></p>
<blockquote>
<h2>Release v0.38.0</h2>
<h2>What's Changed</h2>
<ul>
<li>fix: resolve stdio transport race condition for concurrent tool
calls by <a href="https://github.com/ezynda3"><code>@​ezynda3</code></a>
in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/529">mark3labs/mcp-go#529</a></li>
<li>fix CallToolResult json marshaling and unmarshaling: need
structuredC… by <a
href="https://github.com/sunfuze"><code>@​sunfuze</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/523">mark3labs/mcp-go#523</a></li>
<li>feat: refactor constants for resource content types by <a
href="https://github.com/CocaineCong"><code>@​CocaineCong</code></a> in
<a
href="https://redirect.github.com/mark3labs/mcp-go/pull/489">mark3labs/mcp-go#489</a></li>
<li>feat: add missing SetPrompts, DeleteResources, and SetResources
methods by <a
href="https://github.com/vasayxtx"><code>@​vasayxtx</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/445">mark3labs/mcp-go#445</a></li>
<li>feat: support creating tools using go-struct-style input schema by
<a href="https://github.com/Grivn"><code>@​Grivn</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/534">mark3labs/mcp-go#534</a></li>
<li>fix: remove duplicate methods server.SetPrompts &amp;
server.SetResources by <a
href="https://github.com/matthisholleville"><code>@​matthisholleville</code></a>
in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/542">mark3labs/mcp-go#542</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/sunfuze"><code>@​sunfuze</code></a> made
their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/523">mark3labs/mcp-go#523</a></li>
<li><a href="https://github.com/Grivn"><code>@​Grivn</code></a> made
their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/534">mark3labs/mcp-go#534</a></li>
<li><a
href="https://github.com/matthisholleville"><code>@​matthisholleville</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/542">mark3labs/mcp-go#542</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/mark3labs/mcp-go/compare/v0.37.0...v0.38.0">https://github.com/mark3labs/mcp-go/compare/v0.37.0...v0.38.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/35ebaa54ae30076f93c4beb1f7269004cf0e90be"><code>35ebaa5</code></a>
Add releases notification</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/9f16336f83e17d0659fc49798f233f9dcd910da0"><code>9f16336</code></a>
fix: remove duplicate methods server.SetPrompts &amp;
server.SetResources (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/542">#542</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/8a18f594dd9ec9df1daa382aa611d83eba8f809c"><code>8a18f59</code></a>
feat: support creating tools using go-struct-style input schema (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/534">#534</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/a3d34d980b9a6bfbbaa78cfc0cfb9c78d9b6f7da"><code>a3d34d9</code></a>
feat: add missing SetPrompts, DeleteResources, and SetResources methods
(<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/445">#445</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/8a88d013b3bf38cc37f0ef7fa0b4d7b957b8a6fc"><code>8a88d01</code></a>
feat:add constants for resource content types (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/489">#489</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/9c5d30312932f87f51257af2575936976d1c1622"><code>9c5d303</code></a>
fix CallToolResult json marshaling and unmarshaling: need structuredC…
(<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/523">#523</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/93935261086dda133e3e4b6447304e24deb56a21"><code>9393526</code></a>
fix: resolve stdio transport race condition for concurrent tool calls
(<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/529">#529</a>)</li>
<li>See full diff in <a
href="https://github.com/mark3labs/mcp-go/compare/v0.37.0...v0.38.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/mark3labs/mcp-go&package-manager=go_modules&previous-version=0.37.0&new-version=0.38.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-25 22:36:38 +00:00
dependabot[bot] 7b0a2dc2a0 chore: bump github.com/valyala/fasthttp from 1.64.0 to 1.65.0 (#19539)
Bumps [github.com/valyala/fasthttp](https://github.com/valyala/fasthttp)
from 1.64.0 to 1.65.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/valyala/fasthttp/releases">github.com/valyala/fasthttp's
releases</a>.</em></p>
<blockquote>
<h2>v1.65.0</h2>
<h2>‼️ ⚠️ backwards incompatibility! ⚠️ ‼️</h2>
<p>In this version of fasthttp, headers delimited by just
<code>\n</code> (instead of <code>\r\n</code>) are no longer
supported!</p>
<h2>What's Changed</h2>
<ul>
<li>Rewrite header parsing to improve spec compliance by <a
href="https://github.com/erikdubbelboer"><code>@​erikdubbelboer</code></a>
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2030">valyala/fasthttp#2030</a></li>
<li>Simplify Client.Do function and lock usage by <a
href="https://github.com/byte0o"><code>@​byte0o</code></a> in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2038">valyala/fasthttp#2038</a></li>
<li>chore(deps): bump securego/gosec from 2.22.5 to 2.22.7 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2039">valyala/fasthttp#2039</a></li>
<li>Fix trailer security by <a
href="https://github.com/erikdubbelboer"><code>@​erikdubbelboer</code></a>
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2043">valyala/fasthttp#2043</a></li>
<li>Fix RequestHeader.ContentLength() if disableSpecialHeader is true by
<a
href="https://github.com/erikdubbelboer"><code>@​erikdubbelboer</code></a>
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2042">valyala/fasthttp#2042</a></li>
<li>Add reuseport support for Solaris by <a
href="https://github.com/jwntree"><code>@​jwntree</code></a> in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2046">valyala/fasthttp#2046</a></li>
<li>test: replace atomic operations with atomic types by <a
href="https://github.com/alexandear"><code>@​alexandear</code></a> in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2048">valyala/fasthttp#2048</a></li>
<li>chore(deps): bump golang.org/x/net from 0.42.0 to 0.43.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2049">valyala/fasthttp#2049</a></li>
<li>Optimize fs to have 0 allocations by <a
href="https://github.com/erikdubbelboer"><code>@​erikdubbelboer</code></a>
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2052">valyala/fasthttp#2052</a></li>
<li>chore(deps): bump actions/checkout from 4 to 5 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2055">valyala/fasthttp#2055</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/jwntree"><code>@​jwntree</code></a> made
their first contribution in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2046">valyala/fasthttp#2046</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/valyala/fasthttp/compare/v1.64.0...v1.65.0">https://github.com/valyala/fasthttp/compare/v1.64.0...v1.65.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/valyala/fasthttp/commit/f9d84d7c5242423b3ddac7ce6c671ff817274296"><code>f9d84d7</code></a>
Rewrite header parsing to improve spec compliance (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2030">#2030</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/89010cb2c614d1b0454440ffd4fe54e9d08505b4"><code>89010cb</code></a>
chore(deps): bump actions/checkout from 4 to 5 (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2055">#2055</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/1828bd4eee29b489a516b8c01446e621b3a6953e"><code>1828bd4</code></a>
Optimize fs to have 0 allocations (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2052">#2052</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/81ebee8c79ae193cb2e30ed2b326ece3681278a8"><code>81ebee8</code></a>
Fix PeekKeys()</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/c20414a496d520c50299276aab29b43261e54d7c"><code>c20414a</code></a>
Remove BenchmarkCoarseTimeNow</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/3f641c3246225546dc80ffbdffaafb7ac38e4b82"><code>3f641c3</code></a>
chore(deps): bump golang.org/x/net from 0.42.0 to 0.43.0 (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2049">#2049</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/51b494732003f551d59bf466e3927d9986f96eae"><code>51b4947</code></a>
test: replace atomic operations with atomic types (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2048">#2048</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/1d8fe19359b6f308806a2773713bfde7f13ddf29"><code>1d8fe19</code></a>
Add reuseport support for Solaris (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2046">#2046</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/01d533ad1561d9f2b8878f14e2267e12fc37db1a"><code>01d533a</code></a>
Fix RequestHeader.ContentLength() if disableSpecialHeader is true (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2042">#2042</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/a1c842f19eda39be4b4a60b9d5989aa41e0ba166"><code>a1c842f</code></a>
Fix trailer security (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2043">#2043</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/valyala/fasthttp/compare/v1.64.0...v1.65.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/valyala/fasthttp&package-manager=go_modules&previous-version=1.64.0&new-version=1.65.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-25 22:14:41 +00:00
dependabot[bot] 2c1406ffe2 chore: bump github.com/brianvoe/gofakeit/v7 from 7.3.0 to 7.4.0 (#19537)
Bumps
[github.com/brianvoe/gofakeit/v7](https://github.com/brianvoe/gofakeit)
from 7.3.0 to 7.4.0.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/brianvoe/gofakeit/commit/e2348ee0ad38880e92a28467eefeea73e83bea49"><code>e2348ee</code></a>
address - added unit</li>
<li><a
href="https://github.com/brianvoe/gofakeit/commit/4f7e2ec5cb004701c50b8552eb7a2f7ac4f8453e"><code>4f7e2ec</code></a>
Merge pull request <a
href="https://redirect.github.com/brianvoe/gofakeit/issues/384">#384</a>
from Kzamirtay/fix-iso4217</li>
<li><a
href="https://github.com/brianvoe/gofakeit/commit/de10081cdaf64c754743d8e16356e8ab49697059"><code>de10081</code></a>
fix wrong codes data currency by iso 4217</li>
<li><a
href="https://github.com/brianvoe/gofakeit/commit/08d115b2b7886c80aa1024449e6f8f915964f6d0"><code>08d115b</code></a>
readme - added merch link</li>
<li><a
href="https://github.com/brianvoe/gofakeit/commit/13e15a3392936b0c3f94d408f95562dd991c7577"><code>13e15a3</code></a>
image - merch image</li>
<li><a
href="https://github.com/brianvoe/gofakeit/commit/6b938f8ba0fd43d6f76a4340889c4a3f6ec2b66c"><code>6b938f8</code></a>
readme - added isbn</li>
<li>See full diff in <a
href="https://github.com/brianvoe/gofakeit/compare/v7.3.0...v7.4.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/brianvoe/gofakeit/v7&package-manager=go_modules&previous-version=7.3.0&new-version=7.4.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-25 22:10:15 +00:00
dependabot[bot] 8416882ebb chore: bump go.uber.org/mock from 0.5.0 to 0.6.0 (#19538)
Bumps [go.uber.org/mock](https://github.com/uber/mock) from 0.5.0 to
0.6.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/uber/mock/releases">go.uber.org/mock's
releases</a>.</em></p>
<blockquote>
<h2>v0.6.0</h2>
<h2>0.6.0 (18 Aug 2025)</h2>
<h3>Added</h3>
<ul>
<li><a
href="https://redirect.github.com/uber/mock/issues/258">#258</a>[]:
Archive mode: a new mockgen mode that generates mocks out of archive
files.</li>
</ul>
<h3>Fixed</h3>
<ul>
<li><a
href="https://redirect.github.com/uber/mock/issues/276">#276</a>[]:
Fixed mockgen errors with go1.25 due to outdated golang.org/x/tools
dependency.</li>
</ul>
<p><a href="https://redirect.github.com/uber/mock/issues/258">#258</a>:
<a
href="https://redirect.github.com/uber-go/mock/pull/258">uber-go/mock#258</a>
<a href="https://redirect.github.com/uber/mock/issues/276">#276</a>: <a
href="https://redirect.github.com/uber-go/mock/pull/276">uber-go/mock#276</a></p>
<h2>v0.5.2</h2>
<h2>0.5.2 (28 Apr 2025)</h2>
<h3>Fixed</h3>
<ul>
<li><a
href="https://redirect.github.com/uber/mock/issues/248">#248</a>[]:
Fixed an issue with type aliases not being included in generated code
correctly.</li>
</ul>
<p><a href="https://redirect.github.com/uber/mock/issues/248">#248</a>:
<a
href="https://redirect.github.com/uber-go/mock/pull/248">uber-go/mock#248</a></p>
<h2>v0.5.1</h2>
<h2>0.5.1 (7 Apr 2025)</h2>
<h3>Fixed</h3>
<ul>
<li><a
href="https://redirect.github.com/uber/mock/issues/220">#220</a>[]:
Package mode will now generate code that uses aliases of types
when they are used in the source.</li>
<li><a
href="https://redirect.github.com/uber/mock/issues/219">#219</a>[]:
Fixed a collision between function argument names and package names
in generated code.</li>
<li><a
href="https://redirect.github.com/uber/mock/issues/165">#165</a>[]:
Fixed an issue where aliases specified by <code>-imports</code> were not
being
respected in generated code.</li>
</ul>
<p><a href="https://redirect.github.com/uber/mock/issues/220">#220</a>:
<a
href="https://redirect.github.com/uber-go/mock/pull/220">uber-go/mock#220</a>
<a href="https://redirect.github.com/uber/mock/issues/219">#219</a>: <a
href="https://redirect.github.com/uber-go/mock/pull/219">uber-go/mock#219</a>
<a href="https://redirect.github.com/uber/mock/issues/165">#165</a>: <a
href="https://redirect.github.com/uber-go/mock/pull/165">uber-go/mock#165</a></p>
<p>Thanks to <a
href="https://github.com/mtoader"><code>@​mtoader</code></a> and <a
href="https://github.com/bstncartwright"><code>@​bstncartwright</code></a>
for their contributions to this release.</p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/uber-go/mock/blob/main/CHANGELOG.md">go.uber.org/mock's
changelog</a>.</em></p>
<blockquote>
<h2>0.6.0 (18 Aug 2025)</h2>
<h3>Added</h3>
<ul>
<li><a
href="https://redirect.github.com/uber/mock/issues/258">#258</a>[]:
Archive mode: a new mockgen mode that generates mocks out of archive
files.</li>
<li><a
href="https://redirect.github.com/uber/mock/issues/262">#262</a>[]:
Support for specifying mock names when using the
<code>_gomock_archive</code> bazel rule.</li>
</ul>
<h3>Fixed</h3>
<ul>
<li><a
href="https://redirect.github.com/uber/mock/issues/276">#276</a>[]:
Fixed mockgen errors with go1.25 due to outdated golang.org/x/tools
dependency.</li>
</ul>
<p><a href="https://redirect.github.com/uber/mock/issues/258">#258</a>:
<a
href="https://redirect.github.com/uber-go/mock/pull/258">uber-go/mock#258</a>
<a href="https://redirect.github.com/uber/mock/issues/262">#262</a>: <a
href="https://redirect.github.com/uber-go/mock/pull/262">uber-go/mock#262</a>
<a href="https://redirect.github.com/uber/mock/issues/276">#276</a>: <a
href="https://redirect.github.com/uber-go/mock/pull/276">uber-go/mock#276</a></p>
<h2>0.5.2 (28 Apr 2025)</h2>
<h3>Fixed</h3>
<ul>
<li><a
href="https://redirect.github.com/uber/mock/issues/248">#248</a>[]:
Fixed an issue with type aliases not being included in generated code
correctly.</li>
</ul>
<p><a href="https://redirect.github.com/uber/mock/issues/248">#248</a>:
<a
href="https://redirect.github.com/uber-go/mock/pull/248">uber-go/mock#248</a></p>
<h2>0.5.1 (7 Apr 2025)</h2>
<h3>Fixed</h3>
<ul>
<li><a
href="https://redirect.github.com/uber/mock/issues/220">#220</a>[]:
Package mode will now generate code that uses aliases of types
when they are used in the source.</li>
<li><a
href="https://redirect.github.com/uber/mock/issues/219">#219</a>[]:
Fixed a collision between function argument names and package names
in generated code.</li>
<li><a
href="https://redirect.github.com/uber/mock/issues/165">#165</a>[]:
Fixed an issue where aliases specified by <code>-imports</code> were not
being
respected in generated code.</li>
</ul>
<p><a href="https://redirect.github.com/uber/mock/issues/220">#220</a>:
<a
href="https://redirect.github.com/uber-go/mock/pull/220">uber-go/mock#220</a>
<a href="https://redirect.github.com/uber/mock/issues/219">#219</a>: <a
href="https://redirect.github.com/uber-go/mock/pull/219">uber-go/mock#219</a>
<a href="https://redirect.github.com/uber/mock/issues/165">#165</a>: <a
href="https://redirect.github.com/uber-go/mock/pull/165">uber-go/mock#165</a></p>
<p>Thanks to <a
href="https://github.com/mtoader"><code>@​mtoader</code></a> and <a
href="https://github.com/bstncartwright"><code>@​bstncartwright</code></a>
for their contributions to this release.</p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/uber-go/mock/commit/2d1c58167e30f380cf78e44a43b100a14767e817"><code>2d1c581</code></a>
Prepare release v0.6.0 (<a
href="https://redirect.github.com/uber/mock/issues/278">#278</a>)</li>
<li><a
href="https://github.com/uber-go/mock/commit/c65419553997ae71c1542dc7733358c020d03880"><code>c654195</code></a>
Update CI to run 1.24/1.25 (<a
href="https://redirect.github.com/uber/mock/issues/277">#277</a>)</li>
<li><a
href="https://github.com/uber-go/mock/commit/5900c74f02ff1a28eeb59f3e2a0ef6c27e217148"><code>5900c74</code></a>
update golang.org/x/tools to v0.36.0 (<a
href="https://redirect.github.com/uber/mock/issues/276">#276</a>)</li>
<li><a
href="https://github.com/uber-go/mock/commit/6a0445c87f2d82e304033c553dadd34d2a1a8120"><code>6a0445c</code></a>
feat(bazel): mock_names flag support in archive mode (<a
href="https://redirect.github.com/uber/mock/issues/262">#262</a>)</li>
<li><a
href="https://github.com/uber-go/mock/commit/aa11bfcd02f7339576f4cef5b8c697f980f607d2"><code>aa11bfc</code></a>
feat(bazel): support archive mode (<a
href="https://redirect.github.com/uber/mock/issues/259">#259</a>)</li>
<li><a
href="https://github.com/uber-go/mock/commit/359202c7b2fe16fad86eae73a0ff732f8cb363b9"><code>359202c</code></a>
Support for archive mode (<a
href="https://redirect.github.com/uber/mock/issues/258">#258</a>)</li>
<li><a
href="https://github.com/uber-go/mock/commit/871d86bb6f8b22d0c4d250ebca1f9d674f6e6d1e"><code>871d86b</code></a>
Back to development (<a
href="https://redirect.github.com/uber/mock/issues/251">#251</a>)</li>
<li><a
href="https://github.com/uber-go/mock/commit/0b8095f698fe3b6414a8d1321e990100ba8ce5bc"><code>0b8095f</code></a>
Prepare release v0.5.2 (<a
href="https://redirect.github.com/uber/mock/issues/250">#250</a>)</li>
<li><a
href="https://github.com/uber-go/mock/commit/8ce01ac54df4c2f4443bbe7de345188289af8c4e"><code>8ce01ac</code></a>
Bump go.mod to 1.23 and remove alias replacements (<a
href="https://redirect.github.com/uber/mock/issues/248">#248</a>)</li>
<li><a
href="https://github.com/uber-go/mock/commit/6568d888c79f7c03d45c396af40b608782fae4df"><code>6568d88</code></a>
Back to development. (<a
href="https://redirect.github.com/uber/mock/issues/242">#242</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/uber/mock/compare/v0.5.0...v0.6.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=go.uber.org/mock&package-manager=go_modules&previous-version=0.5.0&new-version=0.6.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-25 22:09:46 +00:00
dependabot[bot] df28da677a chore: bump github.com/aws/aws-sdk-go-v2 from 1.37.2 to 1.38.1 (#19536)
Bumps
[github.com/aws/aws-sdk-go-v2](https://github.com/aws/aws-sdk-go-v2)
from 1.37.2 to 1.38.1.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/ba4ee4da236306b260326a7a913f61cb19355110"><code>ba4ee4d</code></a>
Release 2025-08-21</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/40e3d871f1507d7b7a10b101dd65c5c85ec183c2"><code>40e3d87</code></a>
Regenerated Clients</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/b2be01902dbbdbdec11e3fe7a9ca56aa45c9edcd"><code>b2be019</code></a>
Update partitions file</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/dece4e78c3752a54cc2393bf375672ca7b66b260"><code>dece4e7</code></a>
Update endpoints model</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/294af1979f20160f82f273fd00790466bc8f7daa"><code>294af19</code></a>
Update API model</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/0df860a876d097b792f61fd35caea13c86247d46"><code>0df860a</code></a>
changelog</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/df2bca243bed6101bdee10478def6146a7f7e647"><code>df2bca2</code></a>
feature(s3/manager): add option to control default checksums (<a
href="https://redirect.github.com/aws/aws-sdk-go-v2/issues/3151">#3151</a>)</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/315de9ca18b06a3bc807313c9f79b56e2956009a"><code>315de9c</code></a>
Release 2025-08-20</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/1a9d79d3c8d2dcf70265875f2ed6a8af678454d5"><code>1a9d79d</code></a>
Regenerated Clients</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/79594120103fbf7a5aa836f8c640b9c255453835"><code>7959412</code></a>
Update endpoints model</li>
<li>Additional commits viewable in <a
href="https://github.com/aws/aws-sdk-go-v2/compare/v1.37.2...v1.38.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/aws/aws-sdk-go-v2&package-manager=go_modules&previous-version=1.37.2&new-version=1.38.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-25 22:02:36 +00:00
dependabot[bot] f008b599f9 chore: bump google.golang.org/grpc from 1.74.2 to 1.75.0 (#19535)
Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from
1.74.2 to 1.75.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/grpc/grpc-go/releases">google.golang.org/grpc's
releases</a>.</em></p>
<blockquote>
<h2>Release 1.75.0</h2>
<h1>Behavior Changes</h1>
<ul>
<li>xds: Remove support for GRPC_EXPERIMENTAL_XDS_FALLBACK environment
variable. Fallback support can no longer be disabled. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8482">#8482</a>)</li>
<li>stats: Introduce <code>DelayedPickComplete</code> event, a type
alias of <code>PickerUpdated</code>. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8465">#8465</a>)
<ul>
<li>This (combined) event will now be emitted only once per call, when a
transport is successfully selected for the attempt.</li>
<li>OpenTelemetry metrics will no longer have multiple &quot;Delayed LB
pick complete&quot; events in Go, matching other gRPC languages.</li>
<li>A future release will delete the <code>PickerUpdated</code>
symbol.</li>
</ul>
</li>
<li>credentials: Properly apply <code>grpc.WithAuthority</code> as the
highest-priority option for setting authority, above the setting in the
credentials themselves. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8488">#8488</a>)
<ul>
<li>Now that this <code>WithAuthority</code> is available, the
credentials should not be used to override the authority.</li>
</ul>
</li>
<li>round_robin: Randomize the order in which addresses are connected to
in order to spread out initial RPC load between clients. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8438">#8438</a>)</li>
<li>server: Return status code INTERNAL when a client sends more than
one request in unary and server streaming RPC. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8385">#8385</a>)
<ul>
<li>This is a behavior change but also a bug fix to bring gRPC-Go in
line with the gRPC spec.</li>
</ul>
</li>
</ul>
<h1>New Features</h1>
<ul>
<li>dns: Add an environment variable
(<code>GRPC_ENABLE_TXT_SERVICE_CONFIG</code>) to provide a way to
disable TXT lookups in the DNS resolver (by setting it to
<code>false</code>). By default, TXT lookups are enabled, as they were
previously. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8377">#8377</a>)</li>
</ul>
<h1>Bug Fixes</h1>
<ul>
<li>xds: Fix regression preventing empty node IDs in xDS bootstrap
configuration. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8476">#8476</a>)
<ul>
<li>Special Thanks: <a
href="https://github.com/davinci26"><code>@​davinci26</code></a></li>
</ul>
</li>
<li>xds: Fix possible panic when certain invalid resources are
encountered. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8412">#8412</a>)
<ul>
<li>Special Thanks: <a
href="https://github.com/wooffie"><code>@​wooffie</code></a></li>
</ul>
</li>
<li>xdsclient: Fix a rare panic caused by processing a response from a
closed server. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8389">#8389</a>)</li>
<li>stats: Fix metric unit formatting by enclosing non-standard units
like <code>call</code> and <code>endpoint</code> in curly braces to
comply with UCUM and gRPC OpenTelemetry guidelines. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8481">#8481</a>)</li>
<li>xds: Fix possible panic when clusters are removed from the xds
configuration. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8428">#8428</a>)</li>
<li>xdsclient: Fix a race causing &quot;resource doesn not exist&quot;
when rapidly subscribing and unsubscribing to the same resource. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8369">#8369</a>)</li>
<li>client: When determining the authority, properly percent-encode (if
needed, which is unlikely) when the target string omits the hostname and
only specifies a port
(<code>grpc.NewClient(&quot;:&lt;port-number-or-name&gt;&quot;)</code>).
(<a
href="https://redirect.github.com/grpc/grpc-go/issues/8488">#8488</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/grpc/grpc-go/commit/b9788ef265596eda98a4391079c70c3992ed47cb"><code>b9788ef</code></a>
Change version to 1.75.0 (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8493">#8493</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/2bd74b28f5a7d464de4ed6927aef4b69abc0d3af"><code>2bd74b2</code></a>
credentials: fix behavior of grpc.WithAuthority and credential handshake
prec...</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/9fa3267859958a7fa0141a8180102850f3d5842c"><code>9fa3267</code></a>
xds: remove xds client fallback environment variable (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8482">#8482</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/62ec29fd9b3f9ea3cea6dc08a31e837aa92678b7"><code>62ec29f</code></a>
grpc: Fix cardinality violations in non-client streaming RPCs. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8385">#8385</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/85240a5b02defe7b653ccba66866b4370c982b6a"><code>85240a5</code></a>
stats: change non-standard units to annotations (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8481">#8481</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/ac13172781fae5593fd97ce07c3019c4044a71cd"><code>ac13172</code></a>
update deps (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8478">#8478</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/0a895bc971a89c68c00070f792a28cc533846780"><code>0a895bc</code></a>
examples/opentelemetry: use experimental metrics in example (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8441">#8441</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/8b61e8f7b8fe9b0a4217336f6a4a31731338c3b2"><code>8b61e8f</code></a>
xdsclient: do not process updates from closed server channels (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8389">#8389</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/7238ab1822875fdc2864e06fb224236dc7cbf3bf"><code>7238ab1</code></a>
Allow empty nodeID (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8476">#8476</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/9186ebd774370e3b3232d1b202914ff8fc2c56d6"><code>9186ebd</code></a>
cleanup: use slices.Equal to simplify code (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8472">#8472</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/grpc/grpc-go/compare/v1.74.2...v1.75.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=google.golang.org/grpc&package-manager=go_modules&previous-version=1.74.2&new-version=1.75.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-25 21:20:40 +00:00
blink-so[bot] 9b7d41dbea chore: update terraform to 1.13.0 (#19509)
Co-authored-by: Jon Ayers <jon@coder.com>
2025-08-25 10:06:06 -07:00
Bruno Quaresma e7591aa453 chore: preload inter and ibm mono fonts in storybook (#19455)
This aims to solve font rendering issues in Storybook like the
inconsistent snapshot below.

**Inconsistent snapshot:**
<img width="3022" height="1552" alt="image"
src="https://github.com/user-attachments/assets/ad0e1060-89cc-4255-b601-97ed59286080"
/>


**References:**
-
https://www.chromatic.com/docs/troubleshooting-snapshots/#why-are-fonts-in-my-graph-component-rendering-inconsistently
- https://fontsource.org/docs/getting-started/preload
2025-08-25 10:41:16 -03:00
Mathias Fredriksson 836324e641 feat(cli): add coder exp tasks list (#19496)
Fixes coder/internal#892
Fixes coder/internal#896

Example output:

```
❯ coder exp task list
ID                                    NAME                         STATUS   STATE  STATE CHANGED  MESSAGE
a7a27450-ca16-4553-a6c5-9d6f04808569  task-hardcore-herschel-bd08  running  idle   5h22m3s ago    Listed root directory contents, working directory reset
50f92138-f463-4f2b-abad-1816264b065f  task-musing-dewdney-f058     running  idle   6h3m8s ago     Completed arithmetic calculation
```
2025-08-25 13:03:32 +00:00
Ethan cef2904108 chore(scaletest): use random deployment password (#19516)
Closes https://github.com/coder/internal/issues/932
2025-08-25 22:31:54 +10:00
ケイラ d7ee1019c0 feat: add endpoint for retrieving workspace acl (#19375)
Implements `/acl [get]` for workspaces, with tests.
Blocked by experiment enablement
2025-08-25 07:11:18 -05:00
ケイラ 86e401d85a chore: remove kirby button (#19501) 2025-08-25 07:09:55 -05:00
Ethan fe8ca2a440 chore(scaletest): add deployment name to all metrics (#19479)
If multiple of `alpha`, `bravo` or `charlie` are running simultaneously, we'll have trouble differentiating the metrics. To fix this, we'll add that name to all metrics. 
<img width="1051" height="113" alt="image" src="https://github.com/user-attachments/assets/618c0105-0668-46ba-af3f-13cce3d5d512" />
2025-08-25 12:45:31 +10:00
Ethan 6132cd5eba refactor(scaletest): use vpc for networking infrastructure (#19464)
This PR refactors the scaletest infrastructure to use a dedicated VPC for each deployment (i.e. alpha, bravo, charlie). It then peers that VPC with the observability VPC, and the Cloud SQL database. It also sets up subnetting for and within each deployment.

With this deployed, I was able to get the scaletest running with metrics flowing into `scaletest.cdr.dev`.

Co-authored-by: Dean Sheather <dean@deansheather.com>
2025-08-25 12:35:32 +10:00
Ethan 5145cd002d chore(scaletest): add tls to infrastructure (#19412)
Closes https://github.com/coder/internal/issues/850

This PR has the scaletest infrastructure retrieve and use TLS certificates from the persistent observability cluster.

To support creating multiple instances of the infrastructure simultaneously, `var.name` can be set to `alpha`, `bravo` or `charlie`, which retrieves the corresponding certificates.

Also:
- Adds support for wildcard apps.
- Retrieves the Cloudflare token from GCP secrets.
2025-08-25 12:25:09 +10:00
dependabot[bot] 236844e5cc chore: bump coder/cursor/coder from 1.3.0 to 1.3.1 in /dogfood/coder (#19514)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/cursor/coder&package-manager=terraform&previous-version=1.3.0&new-version=1.3.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-25 01:33:01 +00:00
dependabot[bot] 3fadf1ae6e chore: bump coder/vscode-web/coder from 1.3.1 to 1.4.1 in /dogfood/coder (#19513)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/vscode-web/coder&package-manager=terraform&previous-version=1.3.1&new-version=1.4.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-25 01:31:29 +00:00
dependabot[bot] 7977fa87aa chore: bump coder/claude-code/coder from 2.0.7 to 2.1.0 in /dogfood/coder (#19512)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/claude-code/coder&package-manager=terraform&previous-version=2.0.7&new-version=2.1.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-25 01:30:33 +00:00
Atif Ali 2b3ae549ca chore: rename docker-compose.yaml to compose.yaml (#19480)
Docker recommends using a `compose.yaml` file.
2025-08-23 11:32:14 +05:00
ケイラ 3b6c85a3f9 chore: add @Parkreiner as site/ CODEOWNER (#19502) 2025-08-22 13:40:24 -06:00
Bruno Quaresma cde5b624f4 feat: display the number of idle tasks in the navbar (#19471)
Depends on: https://github.com/coder/coder/pull/19377

Closes https://github.com/coder/coder/issues/19323

**Screenshot:**

<img width="1511" height="777" alt="Screenshot 2025-08-21 at 11 52 21"
src="https://github.com/user-attachments/assets/be04e507-bf04-47d0-8748-2f71b93b5685"
/>

**Screen recording:**


https://github.com/user-attachments/assets/f70b34fe-952b-427b-9bc9-71961ca23201



<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
- Added a Tasks navigation item showing a badge with the number of idle
tasks and a tooltip: “You have X tasks waiting for input.”

- Improvements
  - Fetches per-user tasks with periodic refresh for up-to-date counts.
- Updated active styling for the Tasks link for clearer navigation
state.
  - User menu now always appears on medium+ screens.

- Tests
- Expanded Storybook with preloaded, user-filtered task scenarios to
showcase idle/task states.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-22 15:24:32 -03:00
DevCats 6fbe777317 chore: add auggie icon (#19500)
add auggie icon
2025-08-22 12:53:33 -05:00
ケイラ 7e23081c2f chore: fix vite types (#19477) 2025-08-22 09:00:03 -06:00
Mathias Fredriksson 427b23f49a feat(coderd): add tasks list and get endpoints (#19468)
Fixes coder/internal#899

Example API response:

```json
{
  "tasks": [
    {
      "id": "a7a27450-ca16-4553-a6c5-9d6f04808569",
      "organization_id": "241e869f-1a61-42c9-ae1e-9d46df874058",
      "owner_id": "9e9b9475-0fc0-47b2-9170-a5b7b9a075ee",
      "name": "task-hardcore-herschel-bd08",
      "template_id": "accab607-bbda-4794-89ac-da3926a8b71c",
      "workspace_id": "a7a27450-ca16-4553-a6c5-9d6f04808569",
      "initial_prompt": "What directory are you in?",
      "status": "running",
      "current_state": {
        "timestamp": "2025-08-22T10:03:27.837842Z",
        "state": "working",
        "message": "Listed root directory contents, working directory reset",
        "uri": ""
      },
      "created_at": "2025-08-22T09:21:39.697094Z",
      "updated_at": "2025-08-22T09:21:39.697094Z"
    },
    {
      "id": "50f92138-f463-4f2b-abad-1816264b065f",
      "organization_id": "241e869f-1a61-42c9-ae1e-9d46df874058",
      "owner_id": "9e9b9475-0fc0-47b2-9170-a5b7b9a075ee",
      "name": "task-musing-dewdney-f058",
      "template_id": "accab607-bbda-4794-89ac-da3926a8b71c",
      "workspace_id": "50f92138-f463-4f2b-abad-1816264b065f",
      "initial_prompt": "What is 1 + 1?",
      "status": "running",
      "current_state": {
        "timestamp": "2025-08-22T09:22:33.810707Z",
        "state": "idle",
        "message": "Completed arithmetic calculation",
        "uri": ""
      },
      "created_at": "2025-08-22T09:18:28.027378Z",
      "updated_at": "2025-08-22T09:18:28.027378Z"
    }
  ],
  "count": 2
}
```
2025-08-22 17:11:31 +03:00
Cian Johnston fe36e9c120 fix(dogfood/coder): allow mutable ai_prompt parameter (#19493) 2025-08-22 15:08:42 +01:00
Edward Angert 49f32d14eb docs: add dev containers and scheduling to prebuilt workspaces known issues (#18816)
closes #18806 

- [x] scheduling limitation
- [x] dev containers limitation
- [x] edit intro


[preview](https://coder.com/docs/@18806-prebuilds-known-limits/admin/templates/extending-templates/prebuilt-workspaces)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Documentation**
* Clarified the introduction and administrator responsibilities for
prebuilt workspaces.
* Integrated compatibility information about DevContainers and workspace
scheduling more contextually.
* Added explicit notes on limitations with dev containers integration
and workspace autostart/autostop features.
* Improved configuration examples and clarified scheduling instructions.
* Enhanced explanations of scheduling behavior and lifecycle steps for
better understanding.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
Co-authored-by: Sas Swart <sas.swart.cdk@gmail.com>
Co-authored-by: Susana Ferreira <susana@coder.com>
2025-08-22 15:54:28 +02:00
Cian Johnston 5e49d8c569 chore: reduce execution time of TestProvisionerJobs (#19475)
Note: this commit was partially authored by AI.

- Replaces coderdtest.CreateTemplate/TemplateVersion() with direct dbgen
calls. We do not need a fully functional template for these tests.
- Removes provisioner daemon creation/cleanup. We do not need a running
provisioner daemon here; this functionality is tested elsewhere.
  - Simplifies provisioner job creation test helpers.

This reduces the test runtime by over 50%:

Old:
```
time go test -count=100 ./cli -test.run=TestProvisionerJobs
ok      github.com/coder/coder/v2/cli   50.149s
```

New:
```
time go test -count=100 ./cli -test.run=TestProvisionerJobs
ok      github.com/coder/coder/v2/cli   21.898
```
2025-08-22 13:40:06 +01:00
Danny Kopping 4970da433c chore: remove coderabbit (#19491) 2025-08-22 13:28:40 +02:00
Danny Kopping e549084b7f chore: add pull request template for AI guidelines (#19487) 2025-08-22 12:07:01 +02:00
Cian Johnston 213fffbfa6 chore: add git-config module to dogfood template (#19489)
As a developer, I want to be immediately able to run `git commit` in a
fresh workspace.
2025-08-22 09:37:48 +01:00
Dean Sheather 82f2e15974 chore: add unknown usage event type error (#19436)
- Adds `usagetypes.UnknownEventTypeError` type, which is returned by
`ParseEventWithType`
- Changes `ParseEvent` to not be a generic function since it doesn't
really need it
- Adds `User-Agent` to tallyman requests
2025-08-22 16:32:35 +10:00
Spike Curtis b90bc7c398 feat: use cloud secret for DNS token in scaletest TF (#19466)
Removes the requirement to obtain a Cloudflare DNS token from our scaletest/terraform/action builds. Instead, by default, we pull the token from Google Secrets Manager and use the `scaletest.dev` DNS domain.

Removes cloudflare_email as this was unneeded.  
  
Removes the cloudflare_zone_id and instead pulls it from a data source via the Cloudflare API.  
  
closes https://github.com/coder/internal/issues/839
2025-08-22 07:41:49 +02:00
Ethan a71e5cc8b0 test: add increasing integer to GetRandomNameHyphenated (#19481)
Fixes flakes like the following:
```
workspaces_test.go:4938: 
	Error Trace:	/home/runner/work/coder/coder/coderd/coderdtest/coderdtest.go:1279
											/home/runner/work/coder/coder/coderd/workspaces_test.go:4938
											/home/runner/work/coder/coder/coderd/workspaces_test.go:5044
	Error:      	Received unexpected error:
								POST http://127.0.0.1:42597/api/v2/users/me/workspaces: unexpected status code 409: Workspace "romantic-mcclintock" already exists.
									name: This value is already in use and should be unique.
	Test:       	TestWorkspaceCreateWithImplicitPreset/SinglePresetWithParameters
```

https://github.com/coder/coder/actions/runs/17142665868/job/48633017007?pr=19464
 
Which are caused by insufficient randomness when creating multiple
workspaces with random names. Two words is not enough to avoid flakes.
We have a `testutil.GetRandomName` function that appends a monotonically
increasing integer, but this alternative function that uses hyphens
doesn't add that integer. This PR fixes that by just
`testutil.GetRandomName`
2025-08-22 12:20:03 +10:00
Andrew Aquino 9a872f903e feat: show workspace health error alert above agents in WorkspacePage (#19400)
closes #19338 

<img width="1840" height="1191" alt="image"
src="https://github.com/user-attachments/assets/eeefda13-88d1-4a26-ba57-9749abda3f17"
/>
2025-08-21 17:22:25 -07:00
Rafael Rodriguez ad5e6785f4 feat: add filtering options to provisioners list (#19378)
## Summary

In this pull request we're adding support for additional filtering
options to the `provisioners list` CLI command and the
`/provisionerdaemons` API endpoint.

Resolves: https://github.com/coder/coder/issues/18783

### Changes

#### Added CLI Options

- `--show-offline`: When this option is provided, all provisioner
daemons will be returned. This means that when `--show-offline` is not
provided only `idle` and `busy` provisioner daemons will be returned.
- `--status=<list_of_statuses>`: When this option is provided with a
comma-separated list of valid statuses (`idle`, `busy`, or `offline`)
only provisioner daemons that have these statuses will be returned.
- `--max-age=<duration>`: When this option is provided with a valid
duration value (e.g., `24h`, `30s`) only provisioner daemons with a
`last_seen_at` timestamp within the provided max age will be returned.

#### Query Params

- `?offline=true`: Include offline provisioner daemons in the results.
Offline provisioner daemons will be excluded if `?offline=false` or if
offline is not provided.
- `?status=<list_of_statuses>`: Include provisioner daemons with the
specified statuses.
- `?max_age=<duration>`: Include provisioner daemons with a
`last_seen_at` timestamp within the max age duration.

#### Frontend

- Since offline provisioners will not be returned by default anymore
(`--show-offline` has to be provided to see them), a checkbox was added
to the provisioners list page to allow for offline provisioners to be
displayed
- A revamp of the provisioners page will be done in:
https://github.com/coder/coder/issues/17156, this checkbox change was
just added to maintain currently functionality with the backend updates

Current provisioners page (without checkbox)

<img width="1329" height="574" alt="Screenshot 2025-08-20 at 10 51
00 AM"
src="https://github.com/user-attachments/assets/77b73650-0b62-44f0-a77f-acbe5710809f"
/>

Provisioners page with checkbox (unchecked)

<img width="1314" height="626" alt="Screenshot 2025-08-20 at 10 48
40 AM"
src="https://github.com/user-attachments/assets/7ba164ad-6d3f-417b-bd39-338c0161b145"
/>

Provisioner page with checkbox (checked) and URL updated with query
parameters

<img width="1306" height="597" alt="Screenshot 2025-08-20 at 10 50
14 AM"
src="https://github.com/user-attachments/assets/e78d0986-bbf8-491b-9d56-b682973237a0"
/>

### Show Offline vs Offline Status

To list offline provisioner daemons, users can either:

1. Include the `--show-offline` option

OR

2. Include `offline` in the list of values provided to the `--status`
option
2025-08-21 16:03:34 -04:00
Bruno Quaresma d77c3d0226 feat: filter tasks that are waiting for user input (#19377)
Closes https://github.com/coder/coder/issues/19324

<img width="1624" height="974" alt="Screenshot 2025-08-15 at 14 45 39"
src="https://github.com/user-attachments/assets/a738d9af-f548-413b-a0e7-3f311cb997ee"
/>

---------

Co-authored-by: ケイラ <mckayla@hey.com>
2025-08-21 15:06:11 -03:00
Callum Styan 014a2d5b0f perf: don't call GetUserByID unnecessarily for Agents metrics loops (#19395)
At the moment, the loop which retrieves and updates the values of the
agents metrics excessively calls `GetUserByID` (a DB query). First it
retrieves a list of all workspaces, filtering out inactive agents (not
entirely clear to me whether this is non-running workspaces, or just
dead agents), and then iterates over those workspaces to get the rest of
the relevant data for the metrics. The next call is `GetUserByID` for
`workspace.OwnerID`. This is unnecessary because the `workspaces_visible` view we pull workspaces from has already been joined with the users table to get the username/name/etc.

This should at least partially resolve
https://github.com/coder/internal/issues/726 
---------

Signed-off-by: Callum Styan <callumstyan@gmail.com>
2025-08-21 11:01:32 -07:00
Bruno Quaresma 8aafbcb3be feat: show workspace build logs during tasks creation (#19413)
This is part of https://github.com/coder/coder/issues/19363

**Screenshot:**
<img width="1610" height="974" alt="Screenshot 2025-08-19 at 12 32 54"
src="https://github.com/user-attachments/assets/c7435b67-49ac-4b88-ae2d-014787cea5f2"
/>


**Video demo:**


https://github.com/user-attachments/assets/2249affd-3d51-4ff0-8a5f-a0358a90d659
2025-08-21 15:01:03 -03:00
Bruno Quaresma 54440af953 fix: fix workspaces pagination (#19448)
Fixes #18707 

**Before:**


https://github.com/user-attachments/assets/6d4fba3e-0f24-4f60-adb6-d48d73b720ff

**After:**


https://github.com/user-attachments/assets/483dad99-3095-4647-990d-8386dd0c4d75
2025-08-21 14:59:37 -03:00
Cian Johnston 86f9bed608 chore: fix TestCheckInactiveUsers flake (#19469)
THIS CODE WAS NOT WRITTEN BY A HUMAN.
Use a fixed time interval to avoid timing flakes.
2025-08-21 16:35:31 +01:00
dependabot[bot] fe289e8824 chore: bump github.com/go-viper/mapstructure/v2 from 2.3.0 to 2.4.0 (#19470)
Bumps
[github.com/go-viper/mapstructure/v2](https://github.com/go-viper/mapstructure)
from 2.3.0 to 2.4.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/go-viper/mapstructure/releases">github.com/go-viper/mapstructure/v2's
releases</a>.</em></p>
<blockquote>
<h2>v2.4.0</h2>
<h2>What's Changed</h2>
<ul>
<li>refactor: replace interface{} with any by <a
href="https://github.com/sagikazarmark"><code>@​sagikazarmark</code></a>
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/115">go-viper/mapstructure#115</a></li>
<li>build(deps): bump github/codeql-action from 3.29.0 to 3.29.2 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/114">go-viper/mapstructure#114</a></li>
<li>Generic tests by <a
href="https://github.com/sagikazarmark"><code>@​sagikazarmark</code></a>
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/118">go-viper/mapstructure#118</a></li>
<li>Fix godoc reference link in README.md by <a
href="https://github.com/peczenyj"><code>@​peczenyj</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/107">go-viper/mapstructure#107</a></li>
<li>feat: add StringToTimeLocationHookFunc to convert strings to
*time.Location by <a
href="https://github.com/ErfanMomeniii"><code>@​ErfanMomeniii</code></a>
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/117">go-viper/mapstructure#117</a></li>
<li>feat: add back previous StringToSlice as a weak function by <a
href="https://github.com/sagikazarmark"><code>@​sagikazarmark</code></a>
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/119">go-viper/mapstructure#119</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/ErfanMomeniii"><code>@​ErfanMomeniii</code></a>
made their first contribution in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/117">go-viper/mapstructure#117</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/go-viper/mapstructure/compare/v2.3.0...v2.4.0">https://github.com/go-viper/mapstructure/compare/v2.3.0...v2.4.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/go-viper/mapstructure/commit/b9794a5f0e73d425210d6614ed833067029155f5"><code>b9794a5</code></a>
Merge pull request <a
href="https://redirect.github.com/go-viper/mapstructure/issues/119">#119</a>
from go-viper/string-to-weak-slice</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/17cdcb0741054e2a33938adf6bd1f2a5c0aa8f30"><code>17cdcb0</code></a>
feat: add back previous StringToSlice as a weak function</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/3caca3614c3ab2c5b5d359c44fdcd72058887b19"><code>3caca36</code></a>
Merge pull request <a
href="https://redirect.github.com/go-viper/mapstructure/issues/117">#117</a>
from ErfanMomeniii/main</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/9a861bc115f2b54ed4e494662f29c172d9ef046a"><code>9a861bc</code></a>
Merge pull request <a
href="https://redirect.github.com/go-viper/mapstructure/issues/107">#107</a>
from peczenyj/patch-2</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/86ed5b59da0615fb8c3a413f401cdf0231f1234c"><code>86ed5b5</code></a>
refactor: update</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/ace5b4e8b3dec99468ffa9498e42fb09d177b0a6"><code>ace5b4e</code></a>
chore: add interface any linter</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/1a4f1aef38bfa8549762aaf42c7c18a5d268e76e"><code>1a4f1ae</code></a>
Merge pull request <a
href="https://redirect.github.com/go-viper/mapstructure/issues/118">#118</a>
from go-viper/generic-tests</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/a2689090ed4348033c36724d866faf1f911a9f63"><code>a268909</code></a>
fix: lint</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/17f1fd44eb7606b109c9bb017c0a1c6d3e93b5cd"><code>17f1fd4</code></a>
test: add more comments</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/b48c8566836bf291bfee2b217d51fc36e8e61f6f"><code>b48c856</code></a>
test: expand tests</li>
<li>Additional commits viewable in <a
href="https://github.com/go-viper/mapstructure/compare/v2.3.0...v2.4.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/go-viper/mapstructure/v2&package-manager=go_modules&previous-version=2.3.0&new-version=2.4.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts page](https://github.com/coder/coder/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-21 15:08:50 +00:00
Callum Styan bcdade7d8c fix: add database constraint to enforce minimum username length (#19453)
Username length and format, via regex, are already enforced at the
application layer, but we have some code paths with database queries
where we could optimize away many of the DB query calls if we could be
sure at the database level that the username is never an empty string.

For example: https://github.com/coder/coder/pull/19395

---------

Signed-off-by: Callum Styan <callumstyan@gmail.com>
2025-08-21 07:56:41 -07:00
Spike Curtis 72f58c0483 fix: limit test parallelism in make test (#19465)
In order to get `make test` to reliably pass again on our dogfood
workspaces, we're having to resort to setting parallelism.

It also reworks our CI to call the `make test` target, instead of
rolling a different command.

Behavior changes:
 * sets 8 packages x 8 tests in parallel by default on `make test`
* by default, removes the `-short` flag. In my testing it makes only a
few seconds difference on ~200s, or 1-2%
* by default, removes the `-count=1` flag that busts Go's test cache.
With a fresh cache and no code changes, `make test` executes in ~15
seconds.

Signed-off-by: Spike Curtis <spike@coder.com>
2025-08-21 16:37:31 +04:00
Dean Sheather 8d0bc485df chore: add actionlint and zizmor linters (#19459) 2025-08-21 22:14:43 +10:00
Danny Kopping 338e8b5161 fix: use new http transport for webhook handler (#19462) 2025-08-21 12:08:32 +02:00
Danielle Maywood 2521e732be refactor: generate task name fallback on coderd (#19447)
Instead of generating the fallback task name on the website, we instead
generate it on coderd.
2025-08-21 11:06:30 +01:00
Atif Ali 62fa731b34 chore(dogfood): add IDE selection parameter (#19194)
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-08-21 13:32:45 +05:00
Ethan 444874d9db ci: add check-build job to require make build to pass on prs (#19460)
We've had `build` fail on main one or two times, and it's easily
preventable by just running `make build` on PRs.

I didn't add `build` to required as it's already pretty complex, and
we'd be making it more complex by skipping half of it when not on
coder/coder main.
2025-08-21 17:59:18 +10:00
Spike Curtis 229d05193d fix: speed up GetTailnetTunnelPeerBindings query (#19444)
relates to: https://github.com/coder/internal/issues/718

Optimizes the GetTailnetTunnelPeerBindings query to reduce its execution time.

Before: https://explain.dalibo.com/plan/c2fd53f913aah21c

After: https://explain.dalibo.com/plan/6bc67d323g7afh61

At a high level, we first assemble the total list of peer IDs needed by the query, and only then go into the `tailnet_peers` table to extract their info. This saves us some time instead of hashing the entire `tailnet_peers` table.
2025-08-21 07:53:56 +02:00
Ethan 51d8a05301 test: disable direct connections for a deterministic reachable peers metric (#19458)
closes https://github.com/coder/internal/issues/921

Not sure what I was thinking when I wrote this test case, but it was
relying on the connection being p2p on every ping, which is technically
and evidently not always the case. Instead we'll require a DERP peer,
and block direct connections.
2025-08-21 11:46:56 +10:00
Dean Sheather bfd392b0bf fix: use int64 in publisher delay (#19457) 2025-08-21 11:23:50 +10:00
Rowan Smith baf30679e0 chore: fix typo in clientNetcheckSummary for support bundle command (#19441)
This PR fixes a typo in the original support bundle implementation for
the `clientNetcheckSummary` var.
2025-08-21 10:08:51 +10:00
Brett Kolodny ee789dac9a fix: redirect users to /login if their oauth token is invalid (#19429)
[As mentioned in the
issue](https://github.com/coder/coder/issues/12056#issuecomment-3206975879)
the problem here is the fact this endpoint is returning a 401 instead of
a 200 in this specific case.

Since we actually have enough information before performing this
mutation to know that it'll fail in the case of a bad auth token we'd
ideally re-work the code not to call the mutation on logout and just
perform the local clean up. Unfortunately it seems like the interactions
that this mutation is having with React Query at large is necessary for
our code to work as intended and thus it's not currently possible to
move the local clean up (the code inside of the `onSuccess`) outside of
the mutation. Shout out to @Parkreiner for helping me confirm this.

So until we can re-work the `AuthProvider` to be less brittle this PR
changes `onSuccess` to `onSettled` so that while the mutation still
fails with a 401, the local clean up still runs.

Closes #12056
2025-08-20 15:04:57 -04:00
Benjamin Peinhardt 02fc173df4 fix: fix flake due to two time.Now() calls (#19450)
fixes https://github.com/coder/internal/issues/559

This test is looking to see that after calling `coder schedule extend
<workspace> 10h`, the scheduled stop time of the workspace is updated
appropriately (or at least that the information printed to the terminal
indicates that).

By using two `time.Now()` calls for the current time and the expected
time, there was the possibility that the second call just barely crossed
over the hour mark. This is shown in the error message when the test
would flake: `wanted "2025-04-07T22:"; got " 2025-04-07T23:00:00+05:30
\r\n"` (the 00:00 letting us know we just barely crossed the hour).

Using the same time object to construct the expected time should fix the
issue.
2025-08-20 12:12:02 -05:00
Cian Johnston 9ad124d489 feat(coderd/telemetry): track AI task usage (#19418)
Relates to https://github.com/coder/internal/issues/868
2025-08-20 17:59:09 +01:00
Rafael Rodriguez 5b1e809862 fix: support oidc group allowlist in oss (#19430)
## Summary

In this pull request we're adding support for OIDC allowed groups in the
OSS version as part of work for
https://github.com/coder/coder/issues/17027.

### Changes

- Restored support for parsing group allow list in OSS code

### Testing

- Added tests for OSS code
- Tested allowed/prohibited group OIDC flows in premium and OSS
2025-08-20 10:09:13 -05:00
Steven Masley a19dfa9a0a docs: add generative ai contribution guidelines (#19427)
Initial language that gives us something to point to if needed.
2025-08-20 09:13:40 -05:00
Hugo Dutka d536b91bfc chore(coderd/database/dbauthz): migrate more tests to mocked db (#19300)
Related to https://github.com/coder/internal/issues/869

---------

Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: Steven Masley <stevenmasley@gmail.com>
2025-08-20 14:10:18 +00:00
Jakub Domeracki fc7f53ffce chore: update monaco-editor to resolve DOMPurify CVEs #19445 (#19446)
https://github.com/coder/coder/issues/19445
2025-08-20 16:00:10 +02:00
Susana Ferreira 5b08f8b4a0 fix: change createWorkspace to use dbtime.Time (#19414)
The `createWorkspace` function was updated to use an injected Clock,
which makes it possible to mock time in tests:
https://github.com/coder/coder/pull/19264/files#diff-46f90baab52ea3ad914acbde30d656dbc8e46f5918d19bc056c445a1dc502482R1130
For database operations, however, it is recommended to use `dbtime.Time`
since it rounds to the microsecond, the smallest unit of precision
supported by Postgres.
2025-08-20 14:58:00 +01:00
Dean Sheather 1a601c30ad chore: move usage types to new package (#19103) 2025-08-20 23:48:38 +10:00
Dean Sheather 6eb02d1c2a chore: wire up usage tracking for managed agents (#19096)
Wires up the usage collector and publisher to coderd.

Relates to coder/internal#814
2025-08-20 23:38:09 +10:00
Garrett Delfosse dd867bd743 fix: fix jetbrains toolbox connection tracking (#19348)
Fixes https://github.com/coder/coder/issues/18350

I attempted the route of relying on just the session env vars, in hopes
that this issue was fixed in Toolbox and the process name matching was
no longer need, but it was not a fruitful endeavor and it seems to be
using the same connection logic as it did in gateway, just with new
binary and flag names.
2025-08-20 08:39:08 -04:00
Susana Ferreira 560cf84251 fix: prevent activity bump for prebuilt workspaces (#19263)
## Description

This PR ensures that activity-based deadline extensions ("activity
bumping") are not applied to prebuilt workspaces. Prebuilds are managed
by the reconciliation loop and must not have `deadline` or
`max_deadline` values set or extended, as they are not part of the
regular lifecycle executor path.

## Changes

- Update `ActivityBumpWorkspace` SQL query to discard prebuilt
workspaces
- Update application layer to avoid calling activity bump logic on
prebuilt workspaces

Related with: 
* Issue: https://github.com/coder/coder/issues/18898
* PR: https://github.com/coder/coder/pull/19252
2025-08-20 12:19:14 +01:00
Kacper Sawicki cd1faffeff docs: re-add missing Templates and Modules entries to manifest.json (#19442) 2025-08-20 09:14:41 +00:00
Sas Swart f9a6adc704 feat: claim prebuilds based on workspace parameters instead of preset id (#19279)
Closes https://github.com/coder/coder/issues/18356.

This change finds and selects a matching preset if one was not chosen
during workspace creation. This solidifies the relationship between
presets and parameters.

When a workspace is created without in explicitly chosen preset, it will
now still be eligible to claim a prebuilt workspace if one is available.
2025-08-20 11:02:53 +02:00
Danielle Maywood 5e84d257b7 refactor: convert workspacesdk.AgentConn to an interface (#19392)
Fixes https://github.com/coder/internal/issues/907

We convert `workspacesdk.AgentConn` to an interface and generate a mock
for it. This allows writing `coderd` tests that rely on the agent's HTTP
api to not have to set up an entire tailnet networking stack.
2025-08-20 10:00:44 +01:00
Danielle Maywood 23c494f36b fix(agent/agentcontainers): resolve symlink in tests (#19440)
Fixes https://github.com/coder/internal/issues/917
2025-08-20 09:32:28 +01:00
Dean Sheather 67da780ce4 fix: avoid error when AI usage is zero (#19388)
Fixes a bug that prevents the managed AI agent usage from showing in the
licenses page of the dashboard when the usage is zero. Adds a story with
this case as well.
2025-08-20 07:22:42 +00:00
Ethan c310a3202b ci: ping blink on slack on ci failures (#19435)
im experimenting with getting blink to track flakes for us in
coder/internal, it worked when kyle and I pinged it by hand, so let's
try this too.
2025-08-20 06:19:29 +00:00
dependabot[bot] 60d611fc78 chore: bump github.com/hashicorp/go-getter from 1.7.8 to 1.7.9 (#19433)
Bumps
[github.com/hashicorp/go-getter](https://github.com/hashicorp/go-getter)
from 1.7.8 to 1.7.9.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/hashicorp/go-getter/releases">github.com/hashicorp/go-getter's
releases</a>.</em></p>
<blockquote>
<h2>v1.7.9</h2>
<h2>What's Changed</h2>
<ul>
<li>Speed up XZ decompression by 5x with bufio wrapper by <a
href="https://github.com/vsarunas"><code>@​vsarunas</code></a> in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/520">hashicorp/go-getter#520</a></li>
<li>Fix CI Workflow by <a
href="https://github.com/mohanmanikanta2299"><code>@​mohanmanikanta2299</code></a>
in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/522">hashicorp/go-getter#522</a></li>
<li>test: Remove use of &quot;mitchellh/go-testing-interface&quot; for
stdlib by <a
href="https://github.com/jrasell"><code>@​jrasell</code></a> in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/523">hashicorp/go-getter#523</a></li>
<li>fix: url redact of multiple sshkey by <a
href="https://github.com/dduzgun-security"><code>@​dduzgun-security</code></a>
in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/528">hashicorp/go-getter#528</a></li>
<li>Publish arm binaries by <a
href="https://github.com/sethvargo"><code>@​sethvargo</code></a> in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/525">hashicorp/go-getter#525</a></li>
<li>fix errcheck lint errors and run it as part of pr checks by <a
href="https://github.com/abhijeetviswa"><code>@​abhijeetviswa</code></a>
in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/530">hashicorp/go-getter#530</a></li>
<li>fix additional lint errors and increase linter scope by <a
href="https://github.com/abhijeetviswa"><code>@​abhijeetviswa</code></a>
in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/531">hashicorp/go-getter#531</a></li>
<li>IND-3728 enabling dependabot by <a
href="https://github.com/KaushikiAnand"><code>@​KaushikiAnand</code></a>
in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/529">hashicorp/go-getter#529</a></li>
<li>fix: go-getter subdir paths by <a
href="https://github.com/dduzgun-security"><code>@​dduzgun-security</code></a>
in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/540">hashicorp/go-getter#540</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/vsarunas"><code>@​vsarunas</code></a>
made their first contribution in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/520">hashicorp/go-getter#520</a></li>
<li><a href="https://github.com/jrasell"><code>@​jrasell</code></a> made
their first contribution in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/523">hashicorp/go-getter#523</a></li>
<li><a href="https://github.com/sethvargo"><code>@​sethvargo</code></a>
made their first contribution in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/525">hashicorp/go-getter#525</a></li>
<li><a
href="https://github.com/abhijeetviswa"><code>@​abhijeetviswa</code></a>
made their first contribution in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/530">hashicorp/go-getter#530</a></li>
<li><a
href="https://github.com/KaushikiAnand"><code>@​KaushikiAnand</code></a>
made their first contribution in <a
href="https://redirect.github.com/hashicorp/go-getter/pull/529">hashicorp/go-getter#529</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/hashicorp/go-getter/compare/v1.7.8...v1.7.9">https://github.com/hashicorp/go-getter/compare/v1.7.8...v1.7.9</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/hashicorp/go-getter/commit/e70221100018573cdc74411c95c19b2a372f6728"><code>e702211</code></a>
Merge pull request <a
href="https://redirect.github.com/hashicorp/go-getter/issues/532">#532</a>
from hashicorp/dependabot/github_actions/actions-8948...</li>
<li><a
href="https://github.com/hashicorp/go-getter/commit/df0a14fa67f2921eabff8fbdb51445ac03daeb87"><code>df0a14f</code></a>
[chore] : Bump the actions group with 8 updates</li>
<li><a
href="https://github.com/hashicorp/go-getter/commit/87541b2501c00df5eaedea6acc61a2a4a4efa5b7"><code>87541b2</code></a>
fix: go-getter subdir paths (<a
href="https://redirect.github.com/hashicorp/go-getter/issues/540">#540</a>)</li>
<li><a
href="https://github.com/hashicorp/go-getter/commit/37130302313c9294df898ac96e2565a65369ec68"><code>3713030</code></a>
[Compliance] - PR Template Changes Required</li>
<li><a
href="https://github.com/hashicorp/go-getter/commit/af2dd3ca2764281bf6b7468e05028a8b114c63a7"><code>af2dd3c</code></a>
Merge pull request <a
href="https://redirect.github.com/hashicorp/go-getter/issues/529">#529</a>
from hashicorp/dependabot-intge</li>
<li><a
href="https://github.com/hashicorp/go-getter/commit/bf526297fa4cd429fcf31da9e4a6bf6a0b512026"><code>bf52629</code></a>
updating dependabot.yml</li>
<li><a
href="https://github.com/hashicorp/go-getter/commit/1f63e10d3b421544473bf52103b41eb423e2c897"><code>1f63e10</code></a>
changelog added, updated dependabot.yaml</li>
<li><a
href="https://github.com/hashicorp/go-getter/commit/45af45918c6958be58f87d1576ac4a0b32f7eb4b"><code>45af459</code></a>
fix additional lint errors and increase linter scope</li>
<li><a
href="https://github.com/hashicorp/go-getter/commit/c8c6aba0f7ad4e3937ef7cfcb50627520e498252"><code>c8c6aba</code></a>
fix errcheck lint errors and run it as part of pr checks</li>
<li><a
href="https://github.com/hashicorp/go-getter/commit/9b76f983e594375fdef9e231822c805c82ec9ed7"><code>9b76f98</code></a>
copywrite header added</li>
<li>Additional commits viewable in <a
href="https://github.com/hashicorp/go-getter/compare/v1.7.8...v1.7.9">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/hashicorp/go-getter&package-manager=go_modules&previous-version=1.7.8&new-version=1.7.9)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts page](https://github.com/coder/coder/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-20 03:11:11 +00:00
Bruno Quaresma c70a786e07 chore: ignore dynamic expiration date on story (#19425)
Fixes https://github.com/coder/coder/issues/19410
2025-08-19 16:09:07 -03:00
DevCats 7bcbb83c7c feat: add amp logo sourced from presskit (#19421)
Added logo sourcegraph-amp.svg to site/static/icon
Add icon to icons.json

Logo is sourced from: https://ampcode.com/press-kit
2025-08-19 13:58:17 -05:00
Cian Johnston c978ab99b5 fix(scripts/check_unstaged.sh): modify shebang (#19419) 2025-08-19 19:24:20 +01:00
Callum Styan f2ee89c36a fix: fix more TestWorkspaceAutobuild flakes (#19417)
made these commits yesterday but apparently I forgot to push so they got
missed in https://github.com/coder/coder/pull/19398

---------

Signed-off-by: Callum Styan <callumstyan@gmail.com>
2025-08-19 10:24:40 -07:00
Callum Styan 9e5c83ae0d fix: fix flakes in TestWorkspaceAutobuild due to incorrect tick time (#19398)
we missed these in the previous PR, we find `tickTime2`
and pass it to the `tickCh`, but we were incorrectly passing `tickTime`
to `UpdateProvisionerLastSeenAt` in some places

Signed-off-by: Callum Styan <callumstyan@gmail.com>
2025-08-19 09:24:40 -07:00
Phorcys b6abcba942 chore: correct template API docs (#19228) 2025-08-19 15:14:25 +00:00
Danielle Maywood 655377165b feat(coderd): generate task names based on their prompt (#19335)
Closes https://github.com/coder/coder/issues/18159

If an Anthropic API key is available, we call out to Claude to generate
a task name based on the user-provided prompt instead of our random name
generator.
2025-08-19 14:56:37 +01:00
Kacper Sawicki c4290201c3 fix(enterprise): update external agent instructions in cli (#19411)
### Description

The command for agent instructions was incorrectly displayed in the CLI.
2025-08-19 13:54:42 +00:00
Susana Ferreira d79a7797c2 fix: exclude prebuilt workspaces from template-level lifecycle updates (#19265)
## Description

This PR ensures that lifecycle-related changes made via template
schedule updates do **not affect prebuilt workspaces**. Since prebuilds
are managed by the reconciliation loop and do not participate in the
regular lifecycle executor flow, they must be excluded from any updates
triggered by template configuration changes.

This includes changes to TTL, dormant-deletion scheduling, deadline and
autostart scheduling.

## Changes

- Updated SQL query `UpdateWorkspacesTTLByTemplateID` to exclude
prebuilt workspaces
- Updated SQL query `UpdateWorkspacesDormantDeletingAtByTemplateID` to
exclude prebuilt workspaces
- Updated application-layer logic to skip any updates to lifecycle
parameters if a workspace is a prebuild
- Preserved all existing update behavior for regular user workspaces

This change guarantees that only lifecycle-managed workspaces are
affected when template-level configurations are modified, preserving
strict boundaries between prebuild and user workspace lifecycles.

Related with: 
* Issue: https://github.com/coder/coder/issues/18898
* PR: https://github.com/coder/coder/pull/19252
2025-08-19 13:08:01 +01:00
Danielle Maywood e8795269e4 fix: resolve TestAPI/Error/DuringInjection flake (#19407)
Resolves https://github.com/coder/internal/issues/905
2025-08-19 12:23:37 +01:00
Kacper Sawicki c7cfa65961 fix(enterprise): correct order for external agent init cmd (#19408)
### Description

`CODER_AGENT_TOKEN` env variable was incorrectly being passed to the
curl command instead of the executed script during agent initialization.

Fixed the command order to ensure `CODER_AGENT_TOKEN` is properly passed
to the script execution context rather than the download command.
2025-08-19 11:00:40 +00:00
Kacper Sawicki 7f7206770b feat(site): add support for external agents in the UI and extend CodeExample (#19288)
This pull request introduces support for external workspace management, allowing users to register and manage workspaces that are provisioned and managed outside of the Coder.

* Added a new component AgentExternal which shows instructions for connecting external agents.
* Added redacted fields to CodeExample so you can now hide specific parts of the code instead of the full line
* Hides workspace actions if workspace is using external agent.

<img width="1719" height="646" alt="image" src="https://github.com/user-attachments/assets/45b7bfae-7006-461f-a96d-e61f97084819" />
2025-08-19 11:00:32 +02:00
Kacper Sawicki 7b1dcd9846 feat(cli): add enterprise external-workspaces CLI command (#19287)
This pull request introduces support for external workspace management, allowing users to register and manage workspaces that are provisioned and managed outside of the Coder.

* coder external-workspaces create - Creates a new external workspace (this command extends coder create)
  * Example: coder external-workspaces create ext-workspace --template=externally-managed-workspace -y
  * Checks if template has coder_external_agent resource before creating a workspace
* coder external-workspaces list - Lists all external workspaces
* coder external-workspaces agent-instructions <workspace name> <agent name> - Retrieves agent connection instruction
  * Example: coder external-workspaces agent-instructions ext-workspace main --output=json
2025-08-19 10:52:31 +02:00
Kacper Sawicki 9edceef0bf feat(coderd): add support for external agents to API's and provisioner (#19286)
This pull request introduces support for external workspace management, allowing users to register and manage workspaces that are provisioned and managed outside of the Coder.

Depends on: https://github.com/coder/terraform-provider-coder/pull/424

* GET /api/v2/init-script - Gets the agent initialization script
  * By default, it returns a script for Linux (amd64), but with query parameters (os and arch) you can get the init script for different platforms
* GET /api/v2/workspaces/{workspace}/external-agent/{agent}/credentials - Gets credentials for an external agent **(enterprise)**
* Updated queries to filter workspaces/templates by the has_external_agent field
2025-08-19 10:41:33 +02:00
Cian Johnston f085c37af3 fix(dogfood/coder): fix env var for exp mcp configure claude-code (#19404)
`coder exp mcp configure claude-code` will read the API key for
claude-code from the environment variable `CLAUDE_API_KEY`. Claude will
also happily read `ANTHROPIC_API_KEY` but will ask you to confirm first,
which is problematic in an automated setup.

Also bumps claude-code module.
2025-08-19 09:40:49 +01:00
Kacper Sawicki 5e4aa79a9d feat(coderd): add has_external_agent flag to template_versions and workspace_builds (#19285)
This pull request introduces support for external workspace management, allowing users to register and manage workspaces that are provisioned and managed outside of the Coder.

* Added has_external_agent field to workspace builds and template versions
2025-08-19 10:29:51 +02:00
ケイラ e67f0f6f52 chore: convert emotion styles to tailwind (#19347) 2025-08-18 16:16:21 -06:00
Steven Masley 42c4792f24 test: add sub claim field to static id claims in testidp (#19399) 2025-08-18 15:20:10 -05:00
Brett Kolodny 95388f7576 chore: convert emotion styles to tailwind (#19357) 2025-08-18 15:00:58 -04:00
Cian Johnston 3e7c8c9052 feat(scripts): add fixtures.sh to add license to dev deployment (#19374)
Adds `scripts/fixtures.sh` with initial support for adding license.
Future improvements may involve adding + breaking out:
- User creation
- Template creation/import
- Org creation
2025-08-18 17:32:53 +01:00
Dean Sheather c6c8b00b07 chore: require nolint for testutil.RunRetry (#19394) 2025-08-19 00:48:10 +10:00
Dean Sheather e2ba9e7d62 chore: retry TestAgent_Dial subtests (#19387)
Closes https://github.com/coder/internal/issues/595
2025-08-18 13:51:19 +00:00
Danielle Maywood a8c89a120f fix: increase timeout for watch workspace agent devcontainers test (#19390)
Relates to https://github.com/coder/internal/issues/907

The test can take around 10s when it is the only one running, so in a
constrained environment like CI it makes sense that it still hits the 25
second timeout. For now we up the limit to 60 seconds until the test is
rewritten to greatly reduce the time taken.
2025-08-18 09:56:39 +01:00
Ethan fdc9dfae89 test(coderd/database/dbpurge): use mock db in TestPurge (#19386)
Closes https://github.com/coder/internal/issues/906

This test was using dbmem until we removed it. The test just makes sure the background job runs at all, so a mock db continues to be fine here.

No other tests in this package used dbmem, so this is the only test I've changed.
2025-08-18 15:25:52 +10:00
Rowan Smith 0a815029e9 chore: fix incorrect ordering of OS options in docs (#19384)
On https://coder.com/docs/install/uninstall at present we order the top
OS listing as "Linux | macOS | Windows", while in the `Coder settings,
cache, and the optional built-in PostgreSQL database` paragraph towards
the bottom of the page we change to using "macOS | Linux | Windows" for
some reason. This PR moves Linux to be listed first instead of macOS in
the bottom paragraph to match the ordering of the top section.
2025-08-18 14:31:06 +10:00
Dean Sheather 8f9f0cda11 chore: avoid DNS lookups for DERP in tests (#19385)
Closes https://github.com/coder/internal/issues/886
2025-08-18 03:44:37 +00:00
Rowan Smith 93279dff24 chore: change format of key from uuid to string to fix swagger issue (#19380)
ref: https://codercom.slack.com/archives/C014JH42DBJ/p1755192759211289

this change allows api keys to be deleted via swagger
2025-08-18 12:37:51 +10:00
dependabot[bot] 4da0cfbe83 chore: bump coder/jetbrains/coder from 1.0.2 to 1.0.3 in /dogfood/coder (#19383)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/jetbrains/coder&package-manager=terraform&previous-version=1.0.2&new-version=1.0.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-18 01:05:32 +00:00
dependabot[bot] 95db8d437b chore: bump coder/cursor/coder from 1.2.1 to 1.3.0 in /dogfood/coder (#19382)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/cursor/coder&package-manager=terraform&previous-version=1.2.1&new-version=1.3.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-18 01:05:01 +00:00
dependabot[bot] 29479c28d7 chore: bump coder/zed/coder from 1.0.1 to 1.1.0 in /dogfood/coder (#19381)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/zed/coder&package-manager=terraform&previous-version=1.0.1&new-version=1.1.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-18 01:04:46 +00:00
Bruno Quaresma bed4e12b93 chore: fix storybook flakes (#19366)
Close https://github.com/coder/coder/issues/19365
2025-08-15 16:07:33 -03:00
Danielle Maywood 4ca69af867 fix: increase timeout for watch workspace agent devcontainers test (#19376) 2025-08-15 19:11:19 +01:00
Cian Johnston 2ea807fde1 feat(dogfood/coder): integrate tasks support into "Write Coder on Coder" template (#19320)
Updates https://github.com/coder/internal/issues/836

- Adds an optional AI prompt parameter
- Conditionally adds the following resources if "AI Prompt" is provided:
  - `claude-code` module if AI prompt is provided
  - auto-restarting instance of `develop.sh` running in screen
  - a "preview" app that shows the local development server
2025-08-15 17:47:31 +01:00
Callum Styan 6c902a7410 fix: don't create autostart workspace builds with no available provisioners (#19067)
This should fix https://github.com/coder/coder/issues/17941 by introducing a check for whether there are any valid (non-stale provisioners for a job in the autobuild executor code path.

---------

Signed-off-by: Callum Styan <callumstyan@gmail.com>
2025-08-15 08:50:51 -07:00
Dean Sheather a25d85631b chore: add usage tracking package (#19095)
Not used in coderd yet, see stack.

Adds two new packages:
- `coderd/usage`: provides an interface for the "Collector" as well as a stub implementation for AGPL
- `enterprise/coderd/usage`: provides an interface for the "Publisher" as well as a Tallyman implementation

Relates to https://github.com/coder/internal/issues/814
2025-08-16 01:31:00 +10:00
Steven Masley e92af2b050 chore: set editorconfig to use tabs instead of spaces for sql files (#19344) 2025-08-15 08:02:32 -05:00
Danielle Maywood 205eb29e60 fix: stop reading closed channel for /watch devcontainers endpoint (#19373)
Fixes https://github.com/coder/coder/issues/19372

We increase the read limit to 4MiB (we use this limit elsewhere). We
also make sure to stop sending messages when `containersCh` becomes
closed.
2025-08-15 12:32:33 +01:00
Sas Swart a9f607afd8 test: add an ergonomic way to access the test database for debugging (#19371)
Accessing the database during debugging currently requires either
spinning up a separate PostgreSQL instance or inspecting memory to
retrieve the DSN—both of which add unnecessary friction. While the test
suite already provisions a database by default, connecting to it for
manual inspection or debugging is not straightforward.

This change introduces a clearer and more accessible way to surface the
DSN during debugging sessions, allowing developers to connect to the
test database directly without relying on external infrastructure or ad
hoc methods.

Expected Usage:
1. Debug using dlv or the IDE.
2. Step through line by line and determine that a query isn't doing what
you'd expect
3. No further insight to be gained at the Go level
4. The next place to test is to connect directly to the database while
it is in the exact state that the test has produced just before running
the query
5. Rerun the test with this option enabled and your breakpoint set right
before the questionable query runs
6. Connect to the database and inspect or troubleshoot as you need to
2025-08-15 11:25:20 +02:00
Ethan d7bdb3cdef ci: add paralleltestctx to lint/go (#19369)
Closes https://github.com/coder/internal/issues/884

We're adding this as a `go run` in `lint/go` for now, since adding it to
golangci-lint ourselves involves recompiling golangci-lint and then
running that new binary. I'll look into proposing it being added to the
public golangci-lint linters.

Doesn't appear to cause the lint ci job to take any longer, which is
nice.
2025-08-15 16:16:18 +10:00
Bruno Quaresma 1d1a16ea01 chore: update storybook config to use TS (#19343) 2025-08-14 17:05:16 -06:00
ケイラ ac40c4b828 chore: fix biome when running locally (#19367) 2025-08-14 16:42:45 -06:00
ケイラ bb0e407660 chore: remove some usage of useClassName (#19346) 2025-08-14 15:53:29 -06:00
Bruno Quaresma accdcb8b77 chore: upgrade biome to v2 (#19362)
Guide for migration: https://biomejs.dev/guides/upgrade-to-biome-v2/
2025-08-14 18:25:15 -03:00
ケイラ 167522e5ae fix: fix storybook when using coder desktop (#19364) 2025-08-14 14:13:10 -06:00
Brett Kolodny 362c78a705 fix: ensure deployment banner is always on the bottom (#19361) 2025-08-14 15:35:42 -04:00
Bruno Quaresma 9cde6e6608 chore: remove turbosnap plugin (#19341)
Turbosnap plugin is included by default in Storybook 8, so we can remove
it from our configuration.

> Found 'rollup-plugin-turbosnap' which is now included by default in
Storybook 8.
Removing from your plugins list. Ensure you pass `--stats-json` to
generate stats.

> For more information, see
https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#turbosnap-vite-plugin-is-no-longer-needed
2025-08-14 12:39:13 -03:00
Steven Masley 4926410146 feat: keep original token refresh error in external auth (#19339)
External auth refresh errors lose the original error thrown on the first
refresh. This PR saves that error to the database to be raised on
subsequent refresh attempts
2025-08-14 09:50:31 -05:00
Brett Kolodny 5b5fbbed33 fix: implement proper overflow behavior for workspace history (#19340)
Before:


https://github.com/user-attachments/assets/2f1ff75c-4916-4d0a-a657-004d46691ea0


After:


https://github.com/user-attachments/assets/a8e575b5-84f9-4eea-b318-93d2a3d60aa5

Also converts a lot of emotion components to tailwind
2025-08-14 09:26:20 -04:00
Susana Ferreira 734299de71 fix: disallow lifecycle endpoints for prebuilt workspaces (#19264)
## Description

This PR updates the API to prevent lifecycle configuration endpoints
from being used on prebuilt workspaces. Since prebuilds are managed by
the reconciliation loop and do not participate in the regular workspace
lifecycle, they must not support per-workspace overrides for fields like
deadline, TTL, autostart, or dormancy.

Attempting to use these endpoints on a prebuilt workspace will now
return a clear validation error (`409 Conflict`) with an appropriate
explanation. This prevents accidental misconfiguration and preserves the
lifecycle separation between prebuilds and regular workspaces.

## Changes

The following endpoints now return an error if the target workspace is a
prebuild:

* `PUT /workspaces/{workspace}/extend`
* `PUT /workspaces/{workspace}/ttl`
* `PUT /workspaces/{workspace}/autostart`
* `PUT /workspaces/{workspace}/dormant`

Update endpoints logic to use the API clock in order to allow time
mocking in tests.

Related with: 
* Issue: https://github.com/coder/coder/issues/18898
* PR: https://github.com/coder/coder/pull/19252
2025-08-14 11:30:19 +01:00
Hugo Dutka af97b78e76 chore(coderd/database/dbauthz): migrate TestTemplate to use mocked DB (#19304)
Related to https://github.com/coder/internal/issues/869

---------

Co-authored-by: Steven Masley <stevenmasley@gmail.com>
2025-08-14 11:32:53 +02:00
Ethan b2b3edf0f1 test(codersdk/toolsdk): skip coder_workspace_bash tool test on windows (#19351)
Fixes flakes on the nightly-gauntlet like:
https://github.com/coder/coder/actions/runs/16955654896
since there's no `bash` on windows...
```
=== Failed
=== FAIL: codersdk/toolsdk  (0.00s)
PASS
The following tools were not tested:
 - coder_workspace_bash
Please ensure that all tools are tested using testTool().
If you just added a new tool, please add a test for it.
NOTE: if you just ran an individual test, this is expected.
FAIL	github.com/coder/coder/v2/codersdk/toolsdk	4.185s
```
2025-08-14 15:49:48 +10:00
Ethan c6d62e2de1 docs: update coder desktop + corporate vpn issue (#19353)
I missed this in my first PR 😮‍💨. We already include the
version requirements for the VPN fix in the `Known Issues` section.
2025-08-14 15:06:41 +10:00
Michael Smith 0c203b0cf8 fix: correct markup for Abbr component (#19317)
Fixes some accidental styling issues introduced in #19242

## Changes made
- Updated styles
- Added support for `className` prop so that we can override the styles
as needed
- Removed the aria-label in favor of injecting the main text directly

## Notes
- This feels like a case where the changes in the previous PR were
actually *correct overall*, but something with our MUI+Tailwind setup
created conflicting styles, and we accidentally introduced an underline
style that shouldn't be there
- Removed the Aria label because I've realized in the past year that
Aria is really easy to misuse, and it's best just to do things with the
base HTML features as much as possible. There's a risk that the old code
had compliance issues with certain types of screen readers (even though
it worked fine when I did manual testing back in 2023). These changes
hopefully remove those risks completely
2025-08-14 00:20:00 -04:00
Ethan 1ffc5a0e97 docs: update status of coder desktop + corporate vpn issue (#19350)
A customer read this on the docs and thought the issue was still
unresolved.
2025-08-14 04:17:25 +00:00
Michael Smith 193c7ce91b fix(site): tighten interface design for various frontend utility functions (#18894)
Precursor to https://github.com/coder/coder/pull/18895
Splitting this off so that the changes are easier to review.

## Changes made
- Improve type-safety for the `withQuery` Storybook decorator
- Centralized almost all queries that deal with template versions to use
a shared, exported query key prefix
- Updated `useFilter` and `usePagination` to have much more strict
return types, and decoupled them from React Router at the interface
level
- Also added some extra input validation and performance optimizations
to `useFilter` and `usePagination`
- Removed a stale data when working with checked workspaces for the
`/workspaces` page
- Removed hacky `useEffect` call for syncing URL state to checked
workspaces, in favor of explicit state syncs
- Did some extra cleanup and removed unused values

## Notes
- Many of the changes here were in service of the main PR. I'll try to
highlight notable areas, but if there's anything that's not clear, feel
free to post a comment in this PR. Ideally you shouldn't really have to
look at the other PR to understand this one, so if something's
confusing, that's a sign that something's wrong

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Refactor**
* Improved handling of URL search parameters and state synchronization
in filter and pagination features across multiple pages.
* Centralized and clarified state management for workspace selection and
batch actions on the Workspaces page.
* Enhanced type safety and naming consistency in batch actions and
filter components.
* Updated filter and pagination hooks to accept explicit parameters and
callbacks for better maintainability.
* Streamlined prop naming and menu handling in workspace filter
components for clarity.

* **Bug Fixes**
* Prevented unnecessary state updates when filter values remain
unchanged.

* **Tests**
  * Updated tests for improved type safety and more precise assertions.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-14 00:06:15 -04:00
ケイラ 2180d17f7d chore: upgrade to pnpm 10 (#19327)
pnpm 9 yells pretty loudly about being out of date. also, pnpm 10 no
longer runs untrusted `postinstall`/`prepare` scripts by default, which,
_finally_.
2025-08-13 15:39:10 -04:00
Susana Ferreira 92d505c52b feat(cli): prevent coder schedule command on prebuilt workspaces (#19259)
## Description

This PR adds CLI-side validation to prevent the use of the `coder
schedule` command (including both `start` and `stop` subcommands) on
prebuilt workspaces.

Prebuilt workspaces are scheduled independently by the reconciliation
loop, based on template and preset-level configuration. They do not
participate in the regular user workspace lifecycle, and cannot be
configured via the `coder schedule` CLI command. This change ensures
that attempting to configure scheduling on a prebuilt workspace results
in a clear CLI error.

## Changes

- `coder schedule start` — now returns an error if the target workspace
is a prebuild
- `coder schedule stop` — now returns an error if the target workspace
is a prebuild

Related with: 
* Issue: https://github.com/coder/coder/issues/18898
* **Depends on PR**: https://github.com/coder/coder/pull/19252
2025-08-13 18:15:53 +01:00
Hugo Dutka e10f29c481 chore(coderd/database/dbauthz): migrate File, Group, APIKey, AuditLogs, and ConnectionLogs tests to mocked db (#19299)
Related to https://github.com/coder/internal/issues/869

---------

Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: Steven Masley <stevenmasley@gmail.com>
2025-08-13 09:30:48 -05:00
Jash Ambaliya a556324c93 chore(site): add postgres icon (#19210)
added pgadmin logo as mentioned in review:
<img width="1200" height="394" alt="image"
src="https://github.com/user-attachments/assets/4f536037-e496-4048-b70f-7c915dc82afc"
/>

I have read the CLA Document and I hereby sign the CLA

---------

Co-authored-by: DevCats <christofer@coder.com>
Co-authored-by: ケイラ <mckayla@hey.com>
2025-08-13 09:22:56 -05:00
Susana Ferreira 8567ecbe52 fix: set prebuilds lifecycle parameters on creation and claim (#19252)
## Description

This PR ensures that prebuilt workspaces are properly excluded from the
lifecycle executor and treated as a separate class of workspaces, fully
managed by the prebuild reconciliation loop.

It introduces two lifecycle guarantees:
* When a prebuilt workspace is created (i.e., when the workspace build
completes), all lifecycle-related fields are unset, ensuring the
workspace does not participate in TTL, autostop, autostart, dormancy, or
auto-deletion logic.
* When a prebuilt workspace is claimed, it transitions into a regular
user workspace. At this point, all lifecycle fields are correctly
populated according to template-level configurations, allowing the
workspace to be managed by the lifecycle executor as expected.

## Changes

* Prebuilt workspaces now have all lifecycle-relevant fields unset
during creation
* When a prebuild is claimed:
* Lifecycle fields are set based on template and workspace level
configurations. This ensures a clean transition into the standard
workspace lifecycle flow.
* Updated lifecycle-related SQL update queries to explicitly exclude
prebuilt workspaces.

## Relates 

Related issue: https://github.com/coder/coder/issues/18898

To reduce the scope of this PR and make the review process more
manageable, the original implementation has been split into the
following focused PRs:
* https://github.com/coder/coder/pull/19259
* https://github.com/coder/coder/pull/19263
* https://github.com/coder/coder/pull/19264
* https://github.com/coder/coder/pull/19265

These PRs should be considered in conjunction with this one to
understand the complete set of lifecycle separation changes for prebuilt
workspaces.
2025-08-13 12:45:46 +01:00
Cian Johnston f17ab92798 chore: improve message when running develop.sh multiple times (#19333)
`develop.sh` checks for existing processes listening on port 3000 or
8080.
We can check if it's the development server to avoid confusion.

---------

Co-authored-by: Mathias Fredriksson <mafredri@gmail.com>
2025-08-13 11:49:00 +01:00
Ethan 791d39c261 test(coderd/database): use seperate context for subtests to fix flake (#19330)
Fixes flakes like
https://github.com/coder/coder/actions/runs/16927282256/job/47965470039

https://coder.com/blog/go-testing-contexts-and-t-parallel

...I'm going to take a stab at turning this into a lint rule. I think
it's possible by just reading the AST?
2025-08-13 14:45:35 +10:00
Rowan Smith 117fa05063 chore: update docs to mention debug logging config explicitly (#19329)
From https://coder.com/docs/admin/monitoring/logs#coderd-logs

It wasn't overly clear what was needed to get debug logs, this PR adds a
mention explaining it.
2025-08-13 14:26:45 +10:00
Jon Ayers e99c33e0d1 chore: restrict who can make releases (#19326)
This PR confines who can run the `Release` action to members with
`maintain` or above
2025-08-12 23:43:28 -04:00
ケイラ 17fa1a4e22 refactor(site): migrate ActiveUserChart from emotion to tailwind styling (#19244) 2025-08-12 15:20:43 -06:00
DevCats ea7025b562 docs(admin/users): add google provider-specific guide (#19309)
## Summary
- Add a provider-specific guide for configuring Google as an OIDC
provider
- Document refresh token setup via CODER_OIDC_AUTH_URL_PARAMS
- Add page to docs navigation under Users → OIDC Authentication

## Test plan
- Docs site builds: `docs/admin/users/oidc-auth/google.md` renders
- Nav shows 'Google' under OIDC Authentication
- Links to OIDC overview and refresh tokens work

Fixes #13508

---------

Co-authored-by: Atif Ali <atif@coder.com>
2025-08-12 13:02:40 -05:00
Steven Masley f4f4e52173 docs: remove beta badge from docs about dynamic parameters (#19325) 2025-08-12 17:59:47 +00:00
Rafael Rodriguez aab2ccdb38 fix!: support empty or default fields when updating templates (#19256)
Breaking change: Field types in `codersdk.UpdateTemplateMeta` for
`Icon`, `Description`, and `DisplayName` moved to `*string`

## Summary

In this pull request we're updating the `UpdateTemplateMeta` struct to
allow `DisplayName`, `Description`, and `Icon` to be set as empty `""`
or default to the value from the template if not provided in an update
call.

Fixes https://github.com/coder/coder/issues/19036

### The bug

The reported bug occurred when clients were attempting to update a
metadata field in a template via an edit call. When the request was
decoded into an `UpdateTemplateMeta` struct the default values for
fields in the struct were used to update the template even if they
weren't provided. This led to fields like `Icon` being set to `""` (the
default value).

### Changes

To allow for specific fields to be set to `""` these fields were updated
to be `*string` as opposed to `string`. This allows for clients to set
these fields as `""` in an update request or they will default to the
template value if they are not provided in the update request (will be
`nil`).

Added tests to confirm empty and nil values and updated other tests that
use these fields.
2025-08-12 11:37:44 -05:00
Jon Ayers 064436a300 chore: fix formdata for apidocgen (#19319) 2025-08-12 12:30:09 -04:00
Danny Kopping 67e1567b47 chore: specify packageManager explicitly to match pinned version in Dockerfile (#19311) 2025-08-12 16:55:59 +02:00
Ethan fb8036a154 ci: fix gcp service accounts (#19312)
Service accounts got deleted, oops
2025-08-12 22:02:56 +10:00
ケイラ 64f0aaa2b4 chore: skip flaking classic parameters test (#19308)
Causing test-js failures on main
2025-08-12 14:38:20 +04:00
Danielle Maywood f349edcc3c refactor: create tasks in coderd instead of frontend (#19280)
Instead of creating tasks with a specialized call to `CreateWorkspace`
on the frontend, we instead lift this to the backend and allow the
frontend to simply call `CreateAITask`.
2025-08-12 11:23:55 +01:00
Hugo Dutka cda1a3a593 chore(coderd/database/dbauthz): migrate TestUser to mocked db (#19305)
Related to https://github.com/coder/internal/issues/869

---------

Co-authored-by: Steven Masley <stevenmasley@gmail.com>
2025-08-12 09:20:12 +00:00
Jaayden Halko 0bfe0d63ae feat: add tests for dynamic parameters (#18679)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Added support for a new testing attribute to the multi-select combobox
component, improving testability.
* Expanded mock data for dynamic parameters, covering a wider range of
input types and validation scenarios.

* **Bug Fixes**
* Improved loader and error handling on the experimental workspace
creation page to better display WebSocket errors.

* **Tests**
* Introduced comprehensive tests for the experimental workspace creation
page, including dynamic parameter updates, error handling, and form
submission scenarios.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: Michael Smith <throwawayclover@gmail.com>
2025-08-11 15:43:50 -04:00
Andrew Aquino b8c9192d0b fix: generalize password invalid message (#19307)
fixes #19044 

password over 64 characters means it's _too_ strong; now the error
message is applicable to this case
2025-08-11 12:20:02 -07:00
Michael Suchacz 94bf1e3ae2 chore: symlink CLAUDE.md to AGENTS.md for Codex usage (#19298) 2025-08-11 20:32:17 +02:00
dependabot[bot] 4238b38c4c chore: bump github.com/coder/terraform-provider-coder/v2 from 2.9.0 to 2.10.0 (#19296)
Bumps
[github.com/coder/terraform-provider-coder/v2](https://github.com/coder/terraform-provider-coder)
from 2.9.0 to 2.10.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/coder/terraform-provider-coder/releases">github.com/coder/terraform-provider-coder/v2's
releases</a>.</em></p>
<blockquote>
<h2>v2.10.0</h2>
<h2>What's Changed</h2>
<ul>
<li>feat(coder-attach): add coder_external_agent resource by <a
href="https://github.com/kacpersaw"><code>@​kacpersaw</code></a> in <a
href="https://redirect.github.com/coder/terraform-provider-coder/pull/424">coder/terraform-provider-coder#424</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/kacpersaw"><code>@​kacpersaw</code></a>
made their first contribution in <a
href="https://redirect.github.com/coder/terraform-provider-coder/pull/424">coder/terraform-provider-coder#424</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/coder/terraform-provider-coder/compare/v2.9.0...v2.10.0">https://github.com/coder/terraform-provider-coder/compare/v2.9.0...v2.10.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/coder/terraform-provider-coder/commit/e04ea9c09cae938ca568a14aadc5e65e1ac97026"><code>e04ea9c</code></a>
feat(coder-attach): add coder_external_agent resource (<a
href="https://redirect.github.com/coder/terraform-provider-coder/issues/424">#424</a>)</li>
<li>See full diff in <a
href="https://github.com/coder/terraform-provider-coder/compare/v2.9.0...v2.10.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/coder/terraform-provider-coder/v2&package-manager=go_modules&previous-version=2.9.0&new-version=2.10.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 16:58:46 +00:00
dependabot[bot] 8008c08893 chore: bump cloud.google.com/go/compute/metadata from 0.7.0 to 0.8.0 (#19297)
Bumps
[cloud.google.com/go/compute/metadata](https://github.com/googleapis/google-cloud-go)
from 0.7.0 to 0.8.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/googleapis/google-cloud-go/releases">cloud.google.com/go/compute/metadata's
releases</a>.</em></p>
<blockquote>
<h2>compute/metadata: v0.8.0</h2>
<h2><a
href="https://github.com/googleapis/google-cloud-go/compare/compute/metadata/v0.7.0...compute/metadata/v0.8.0">0.8.0</a>
(2025-08-06)</h2>
<h3>Features</h3>
<ul>
<li><strong>compute/metadata:</strong> Add Options.UseDefaultClient (<a
href="https://redirect.github.com/googleapis/google-cloud-go/issues/12657">#12657</a>)
(<a
href="https://github.com/googleapis/google-cloud-go/commit/1a8820900f20e038291c4bb2c5284a449196e81f">1a88209</a>),
refs <a
href="https://redirect.github.com/googleapis/google-cloud-go/issues/11078">#11078</a></li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/googleapis/google-cloud-go/blob/main/CHANGES.md">cloud.google.com/go/compute/metadata's
changelog</a>.</em></p>
<blockquote>
<h2>v0.8.0</h2>
<ul>
<li>profiler package added.</li>
<li>storage:
<ul>
<li>Retry Objects.Insert call.</li>
<li>Add ProgressFunc to WRiter.</li>
</ul>
</li>
<li>pubsub: breaking changes:
<ul>
<li>Publish is now asynchronous (<a
href="https://groups.google.com/d/topic/google-api-go-announce/aaqRDIQ3rvU/discussion">announcement</a>).</li>
<li>Subscription.Pull replaced by Subscription.Receive, which takes a
callback (<a
href="https://groups.google.com/d/topic/google-api-go-announce/8pt6oetAdKc/discussion">announcement</a>).</li>
<li>Message.Done replaced with Message.Ack and Message.Nack.</li>
</ul>
</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/googleapis/google-cloud-go/commit/e11d9d1a1722e191d3d017c08077f2c15189769a"><code>e11d9d1</code></a>
rpcreplay: file format and I/O</li>
<li><a
href="https://github.com/googleapis/google-cloud-go/commit/f5c3fe2352c8d679cfc47d2f102449571022c323"><code>f5c3fe2</code></a>
profiler: Add Cloud Profiler runtime agent for Go.</li>
<li><a
href="https://github.com/googleapis/google-cloud-go/commit/87cc1d286587530f709063127a1faef4ed8431c5"><code>87cc1d2</code></a>
rpcreplay: package doc</li>
<li><a
href="https://github.com/googleapis/google-cloud-go/commit/b4e9a381a01e953e880e6d2cf7fd02d412977cae"><code>b4e9a38</code></a>
storage: retry Objects.Insert call</li>
<li><a
href="https://github.com/googleapis/google-cloud-go/commit/9a04fc8dc5de830157ea2887ab5565f964c311a7"><code>9a04fc8</code></a>
trace: respond with trace context to report the sampling options</li>
<li><a
href="https://github.com/googleapis/google-cloud-go/commit/e8b5f2cc58266b603c1d7dc9f6ac0f254d1670df"><code>e8b5f2c</code></a>
spanner: Increased the maximum allowed sending and recieving msg size to
100 MB</li>
<li><a
href="https://github.com/googleapis/google-cloud-go/commit/dd88571a2747f25e093c425b9a598db5bec04e57"><code>dd88571</code></a>
bigtable: Fix documentation for timestamp range filters</li>
<li><a
href="https://github.com/googleapis/google-cloud-go/commit/c60d02f3cdeb4bf91d4810e9e505800cad03ce9f"><code>c60d02f</code></a>
pubsub: clarify that Topic is goroutine-safe</li>
<li><a
href="https://github.com/googleapis/google-cloud-go/commit/69931d826ffbbcb4f8451b42d5cf7fc2ac6c7443"><code>69931d8</code></a>
bigquery: get streaming buffer info</li>
<li><a
href="https://github.com/googleapis/google-cloud-go/commit/7d132fead24899d37a2aef0112d06b9d5b891d19"><code>7d132fe</code></a>
bigtable: Fix GCRuleToString when GcRule is nil</li>
<li>Additional commits viewable in <a
href="https://github.com/googleapis/google-cloud-go/compare/v0.7.0...v0.8.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=cloud.google.com/go/compute/metadata&package-manager=go_modules&previous-version=0.7.0&new-version=0.8.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 16:58:19 +00:00
dependabot[bot] cbcdda25dc ci: bump the github-actions group with 8 updates (#19293)
Bumps the github-actions group with 8 updates:

| Package | From | To |
| --- | --- | --- |
| [actions/checkout](https://github.com/actions/checkout) | `4.2.2` |
`4.3.0` |
| [actions/cache](https://github.com/actions/cache) | `4.2.3` | `4.2.4`
|
| [crate-ci/typos](https://github.com/crate-ci/typos) | `1.34.0` |
`1.35.3` |
| [docker/login-action](https://github.com/docker/login-action) |
`3.4.0` | `3.5.0` |
|
[google-github-actions/setup-gcloud](https://github.com/google-github-actions/setup-gcloud)
| `2.1.5` | `2.2.0` |
|
[actions/download-artifact](https://github.com/actions/download-artifact)
| `4.3.0` | `5.0.0` |
|
[tj-actions/changed-files](https://github.com/tj-actions/changed-files)
| `c2ca2493190021783138cb8aac49bcee14b4bb89` |
`f963b3f3562b00b6d2dd25efc390eb04e51ef6c6` |
| [github/codeql-action](https://github.com/github/codeql-action) |
`3.29.7` | `3.29.8` |

Updates `actions/checkout` from 4.2.2 to 4.3.0
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/actions/checkout/releases">actions/checkout's
releases</a>.</em></p>
<blockquote>
<h2>v4.3.0</h2>
<h2>What's Changed</h2>
<ul>
<li>docs: update README.md by <a
href="https://github.com/motss"><code>@​motss</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1971">actions/checkout#1971</a></li>
<li>Add internal repos for checking out multiple repositories by <a
href="https://github.com/mouismail"><code>@​mouismail</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1977">actions/checkout#1977</a></li>
<li>Documentation update - add recommended permissions to Readme by <a
href="https://github.com/benwells"><code>@​benwells</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/2043">actions/checkout#2043</a></li>
<li>Adjust positioning of user email note and permissions heading by <a
href="https://github.com/joshmgross"><code>@​joshmgross</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/2044">actions/checkout#2044</a></li>
<li>Update README.md by <a
href="https://github.com/nebuk89"><code>@​nebuk89</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/2194">actions/checkout#2194</a></li>
<li>Update CODEOWNERS for actions by <a
href="https://github.com/TingluoHuang"><code>@​TingluoHuang</code></a>
in <a
href="https://redirect.github.com/actions/checkout/pull/2224">actions/checkout#2224</a></li>
<li>Update package dependencies by <a
href="https://github.com/salmanmkc"><code>@​salmanmkc</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/2236">actions/checkout#2236</a></li>
<li>Prepare release v4.3.0 by <a
href="https://github.com/salmanmkc"><code>@​salmanmkc</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/2237">actions/checkout#2237</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/motss"><code>@​motss</code></a> made
their first contribution in <a
href="https://redirect.github.com/actions/checkout/pull/1971">actions/checkout#1971</a></li>
<li><a href="https://github.com/mouismail"><code>@​mouismail</code></a>
made their first contribution in <a
href="https://redirect.github.com/actions/checkout/pull/1977">actions/checkout#1977</a></li>
<li><a href="https://github.com/benwells"><code>@​benwells</code></a>
made their first contribution in <a
href="https://redirect.github.com/actions/checkout/pull/2043">actions/checkout#2043</a></li>
<li><a href="https://github.com/nebuk89"><code>@​nebuk89</code></a> made
their first contribution in <a
href="https://redirect.github.com/actions/checkout/pull/2194">actions/checkout#2194</a></li>
<li><a href="https://github.com/salmanmkc"><code>@​salmanmkc</code></a>
made their first contribution in <a
href="https://redirect.github.com/actions/checkout/pull/2236">actions/checkout#2236</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/actions/checkout/compare/v4...v4.3.0">https://github.com/actions/checkout/compare/v4...v4.3.0</a></p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/actions/checkout/blob/main/CHANGELOG.md">actions/checkout's
changelog</a>.</em></p>
<blockquote>
<h1>Changelog</h1>
<h2>V4.3.0</h2>
<ul>
<li>docs: update README.md by <a
href="https://github.com/motss"><code>@​motss</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1971">actions/checkout#1971</a></li>
<li>Add internal repos for checking out multiple repositories by <a
href="https://github.com/mouismail"><code>@​mouismail</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1977">actions/checkout#1977</a></li>
<li>Documentation update - add recommended permissions to Readme by <a
href="https://github.com/benwells"><code>@​benwells</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/2043">actions/checkout#2043</a></li>
<li>Adjust positioning of user email note and permissions heading by <a
href="https://github.com/joshmgross"><code>@​joshmgross</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/2044">actions/checkout#2044</a></li>
<li>Update README.md by <a
href="https://github.com/nebuk89"><code>@​nebuk89</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/2194">actions/checkout#2194</a></li>
<li>Update CODEOWNERS for actions by <a
href="https://github.com/TingluoHuang"><code>@​TingluoHuang</code></a>
in <a
href="https://redirect.github.com/actions/checkout/pull/2224">actions/checkout#2224</a></li>
<li>Update package dependencies by <a
href="https://github.com/salmanmkc"><code>@​salmanmkc</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/2236">actions/checkout#2236</a></li>
</ul>
<h2>v4.2.2</h2>
<ul>
<li><code>url-helper.ts</code> now leverages well-known environment
variables by <a href="https://github.com/jww3"><code>@​jww3</code></a>
in <a
href="https://redirect.github.com/actions/checkout/pull/1941">actions/checkout#1941</a></li>
<li>Expand unit test coverage for <code>isGhes</code> by <a
href="https://github.com/jww3"><code>@​jww3</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1946">actions/checkout#1946</a></li>
</ul>
<h2>v4.2.1</h2>
<ul>
<li>Check out other refs/* by commit if provided, fall back to ref by <a
href="https://github.com/orhantoy"><code>@​orhantoy</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1924">actions/checkout#1924</a></li>
</ul>
<h2>v4.2.0</h2>
<ul>
<li>Add Ref and Commit outputs by <a
href="https://github.com/lucacome"><code>@​lucacome</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1180">actions/checkout#1180</a></li>
<li>Dependency updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>- <a
href="https://redirect.github.com/actions/checkout/pull/1777">actions/checkout#1777</a>,
<a
href="https://redirect.github.com/actions/checkout/pull/1872">actions/checkout#1872</a></li>
</ul>
<h2>v4.1.7</h2>
<ul>
<li>Bump the minor-npm-dependencies group across 1 directory with 4
updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1739">actions/checkout#1739</a></li>
<li>Bump actions/checkout from 3 to 4 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1697">actions/checkout#1697</a></li>
<li>Check out other refs/* by commit by <a
href="https://github.com/orhantoy"><code>@​orhantoy</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1774">actions/checkout#1774</a></li>
<li>Pin actions/checkout's own workflows to a known, good, stable
version. by <a href="https://github.com/jww3"><code>@​jww3</code></a> in
<a
href="https://redirect.github.com/actions/checkout/pull/1776">actions/checkout#1776</a></li>
</ul>
<h2>v4.1.6</h2>
<ul>
<li>Check platform to set archive extension appropriately by <a
href="https://github.com/cory-miller"><code>@​cory-miller</code></a> in
<a
href="https://redirect.github.com/actions/checkout/pull/1732">actions/checkout#1732</a></li>
</ul>
<h2>v4.1.5</h2>
<ul>
<li>Update NPM dependencies by <a
href="https://github.com/cory-miller"><code>@​cory-miller</code></a> in
<a
href="https://redirect.github.com/actions/checkout/pull/1703">actions/checkout#1703</a></li>
<li>Bump github/codeql-action from 2 to 3 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1694">actions/checkout#1694</a></li>
<li>Bump actions/setup-node from 1 to 4 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1696">actions/checkout#1696</a></li>
<li>Bump actions/upload-artifact from 2 to 4 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1695">actions/checkout#1695</a></li>
<li>README: Suggest <code>user.email</code> to be
<code>41898282+github-actions[bot]@users.noreply.github.com</code> by <a
href="https://github.com/cory-miller"><code>@​cory-miller</code></a> in
<a
href="https://redirect.github.com/actions/checkout/pull/1707">actions/checkout#1707</a></li>
</ul>
<h2>v4.1.4</h2>
<ul>
<li>Disable <code>extensions.worktreeConfig</code> when disabling
<code>sparse-checkout</code> by <a
href="https://github.com/jww3"><code>@​jww3</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1692">actions/checkout#1692</a></li>
<li>Add dependabot config by <a
href="https://github.com/cory-miller"><code>@​cory-miller</code></a> in
<a
href="https://redirect.github.com/actions/checkout/pull/1688">actions/checkout#1688</a></li>
<li>Bump the minor-actions-dependencies group with 2 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1693">actions/checkout#1693</a></li>
<li>Bump word-wrap from 1.2.3 to 1.2.5 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1643">actions/checkout#1643</a></li>
</ul>
<h2>v4.1.3</h2>
<ul>
<li>Check git version before attempting to disable
<code>sparse-checkout</code> by <a
href="https://github.com/jww3"><code>@​jww3</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1656">actions/checkout#1656</a></li>
<li>Add SSH user parameter by <a
href="https://github.com/cory-miller"><code>@​cory-miller</code></a> in
<a
href="https://redirect.github.com/actions/checkout/pull/1685">actions/checkout#1685</a></li>
<li>Update <code>actions/checkout</code> version in
<code>update-main-version.yml</code> by <a
href="https://github.com/jww3"><code>@​jww3</code></a> in <a
href="https://redirect.github.com/actions/checkout/pull/1650">actions/checkout#1650</a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/actions/checkout/commit/08eba0b27e820071cde6df949e0beb9ba4906955"><code>08eba0b</code></a>
Prepare release v4.3.0 (<a
href="https://redirect.github.com/actions/checkout/issues/2237">#2237</a>)</li>
<li><a
href="https://github.com/actions/checkout/commit/631c7dc4f80f88219c5ee78fee08c6b62fac8da1"><code>631c7dc</code></a>
Update package dependencies (<a
href="https://redirect.github.com/actions/checkout/issues/2236">#2236</a>)</li>
<li><a
href="https://github.com/actions/checkout/commit/8edcb1bdb4e267140fa742c62e395cd74f332709"><code>8edcb1b</code></a>
Update CODEOWNERS for actions (<a
href="https://redirect.github.com/actions/checkout/issues/2224">#2224</a>)</li>
<li><a
href="https://github.com/actions/checkout/commit/09d2acae674a48949e3602304ab46fd20ae0c42f"><code>09d2aca</code></a>
Update README.md (<a
href="https://redirect.github.com/actions/checkout/issues/2194">#2194</a>)</li>
<li><a
href="https://github.com/actions/checkout/commit/85e6279cec87321a52edac9c87bce653a07cf6c2"><code>85e6279</code></a>
Adjust positioning of user email note and permissions heading (<a
href="https://redirect.github.com/actions/checkout/issues/2044">#2044</a>)</li>
<li><a
href="https://github.com/actions/checkout/commit/009b9ae9e446ad8d9b8c809870b0fbcc5e03573e"><code>009b9ae</code></a>
Documentation update - add recommended permissions to Readme (<a
href="https://redirect.github.com/actions/checkout/issues/2043">#2043</a>)</li>
<li><a
href="https://github.com/actions/checkout/commit/cbb722410c2e876e24abbe8de2cc27693e501dcb"><code>cbb7224</code></a>
Update README.md (<a
href="https://redirect.github.com/actions/checkout/issues/1977">#1977</a>)</li>
<li><a
href="https://github.com/actions/checkout/commit/3b9b8c884f6b4bb4d5be2779c26374abadae0871"><code>3b9b8c8</code></a>
docs: update README.md (<a
href="https://redirect.github.com/actions/checkout/issues/1971">#1971</a>)</li>
<li>See full diff in <a
href="https://github.com/actions/checkout/compare/11bd71901bbe5b1630ceea73d27597364c9af683...08eba0b27e820071cde6df949e0beb9ba4906955">compare
view</a></li>
</ul>
</details>
<br />

Updates `actions/cache` from 4.2.3 to 4.2.4
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/actions/cache/releases">actions/cache's
releases</a>.</em></p>
<blockquote>
<h2>v4.2.4</h2>
<h2>What's Changed</h2>
<ul>
<li>Update README.md by <a
href="https://github.com/nebuk89"><code>@​nebuk89</code></a> in <a
href="https://redirect.github.com/actions/cache/pull/1620">actions/cache#1620</a></li>
<li>Upgrade <code>@actions/cache</code> to <code>4.0.5</code> and move
<code>@protobuf-ts/plugin</code> to dev depdencies by <a
href="https://github.com/Link"><code>@​Link</code></a>- in <a
href="https://redirect.github.com/actions/cache/pull/1634">actions/cache#1634</a></li>
<li>Prepare release <code>4.2.4</code> by <a
href="https://github.com/Link"><code>@​Link</code></a>- in <a
href="https://redirect.github.com/actions/cache/pull/1636">actions/cache#1636</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/nebuk89"><code>@​nebuk89</code></a> made
their first contribution in <a
href="https://redirect.github.com/actions/cache/pull/1620">actions/cache#1620</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/actions/cache/compare/v4...v4.2.4">https://github.com/actions/cache/compare/v4...v4.2.4</a></p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/actions/cache/blob/main/RELEASES.md">actions/cache's
changelog</a>.</em></p>
<blockquote>
<h1>Releases</h1>
<h3>4.2.4</h3>
<ul>
<li>Bump <code>@actions/cache</code> to v4.0.5</li>
</ul>
<h3>4.2.3</h3>
<ul>
<li>Bump <code>@actions/cache</code> to v4.0.3 (obfuscates SAS token in
debug logs for cache entries)</li>
</ul>
<h3>4.2.2</h3>
<ul>
<li>Bump <code>@actions/cache</code> to v4.0.2</li>
</ul>
<h3>4.2.1</h3>
<ul>
<li>Bump <code>@actions/cache</code> to v4.0.1</li>
</ul>
<h3>4.2.0</h3>
<p>TLDR; The cache backend service has been rewritten from the ground up
for improved performance and reliability. <a
href="https://github.com/actions/cache">actions/cache</a> now integrates
with the new cache service (v2) APIs.</p>
<p>The new service will gradually roll out as of <strong>February 1st,
2025</strong>. The legacy service will also be sunset on the same date.
Changes in these release are <strong>fully backward
compatible</strong>.</p>
<p><strong>We are deprecating some versions of this action</strong>. We
recommend upgrading to version <code>v4</code> or <code>v3</code> as
soon as possible before <strong>February 1st, 2025.</strong> (Upgrade
instructions below).</p>
<p>If you are using pinned SHAs, please use the SHAs of versions
<code>v4.2.0</code> or <code>v3.4.0</code></p>
<p>If you do not upgrade, all workflow runs using any of the deprecated
<a href="https://github.com/actions/cache">actions/cache</a> will
fail.</p>
<p>Upgrading to the recommended versions will not break your
workflows.</p>
<h3>4.1.2</h3>
<ul>
<li>Add GitHub Enterprise Cloud instances hostname filters to inform API
endpoint choices - <a
href="https://redirect.github.com/actions/cache/pull/1474">#1474</a></li>
<li>Security fix: Bump braces from 3.0.2 to 3.0.3 - <a
href="https://redirect.github.com/actions/cache/pull/1475">#1475</a></li>
</ul>
<h3>4.1.1</h3>
<ul>
<li>Restore original behavior of <code>cache-hit</code> output - <a
href="https://redirect.github.com/actions/cache/pull/1467">#1467</a></li>
</ul>
<h3>4.1.0</h3>
<ul>
<li>Ensure <code>cache-hit</code> output is set when a cache is missed -
<a
href="https://redirect.github.com/actions/cache/pull/1404">#1404</a></li>
<li>Deprecate <code>save-always</code> input - <a
href="https://redirect.github.com/actions/cache/pull/1452">#1452</a></li>
</ul>
<h3>4.0.2</h3>
<ul>
<li>Fixed restore <code>fail-on-cache-miss</code> not working.</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/actions/cache/commit/0400d5f644dc74513175e3cd8d07132dd4860809"><code>0400d5f</code></a>
Merge pull request <a
href="https://redirect.github.com/actions/cache/issues/1636">#1636</a>
from actions/Link-/release-4.2.4</li>
<li><a
href="https://github.com/actions/cache/commit/374a27f26986edd8c430f386d152a856e179c0ae"><code>374a27f</code></a>
Prepare release 4.2.4</li>
<li><a
href="https://github.com/actions/cache/commit/358a7306cd9d78ceffc19271e69cd8528462fccf"><code>358a730</code></a>
Merge pull request <a
href="https://redirect.github.com/actions/cache/issues/1634">#1634</a>
from actions/Link-/optimise-deps</li>
<li><a
href="https://github.com/actions/cache/commit/2ee706ef74683b68fd97d45e549070fc28642768"><code>2ee706e</code></a>
Fix with another approach</li>
<li><a
href="https://github.com/actions/cache/commit/94f7b5d9135a3af2d928e87120da293c9a920f90"><code>94f7b5d</code></a>
Fix bundle exec</li>
<li><a
href="https://github.com/actions/cache/commit/c36116c3f4852e9868973e98be949d101f296afa"><code>c36116c</code></a>
Fix the workflow to use licensed from source</li>
<li><a
href="https://github.com/actions/cache/commit/320fe7d56bfd8d9e7b7694dce399643f5b61d580"><code>320fe7d</code></a>
Update the licensed workflow to use the latest version</li>
<li><a
href="https://github.com/actions/cache/commit/d81cc477d92d48462edee5b1e53b15613993e818"><code>d81cc47</code></a>
Add licensed output</li>
<li><a
href="https://github.com/actions/cache/commit/de243982c557f21f36de55f0c01cd6a8e7a6aa71"><code>de24398</code></a>
Add licensed output</li>
<li><a
href="https://github.com/actions/cache/commit/e7b6a9cc9d34d03fd2bf2834b35a8b9e82faa8e5"><code>e7b6a9c</code></a>
<code>@​protobuf-ts/plugin</code> to dev dependencies</li>
<li>Additional commits viewable in <a
href="https://github.com/actions/cache/compare/5a3ec84eff668545956fd18022155c47e93e2684...0400d5f644dc74513175e3cd8d07132dd4860809">compare
view</a></li>
</ul>
</details>
<br />

Updates `crate-ci/typos` from 1.34.0 to 1.35.3
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/crate-ci/typos/releases">crate-ci/typos's
releases</a>.</em></p>
<blockquote>
<h2>v1.35.3</h2>
<h2>[1.35.3] - 2025-08-08</h2>
<h3>Fixes</h3>
<ul>
<li>Don't correct <code>ratatui</code> in Rust files</li>
</ul>
<h2>v1.35.2</h2>
<h2>[1.35.2] - 2025-08-07</h2>
<h3>Fixes</h3>
<ul>
<li>Don't correct <code>unmarshaling</code></li>
</ul>
<h2>v1.35.1</h2>
<h2>[1.35.1] - 2025-08-04</h2>
<h3>Fixes</h3>
<ul>
<li>Fix typo in correction to <code>apostroph</code></li>
<li>Fix typo in correction to <code>cordinate</code></li>
<li>Fix typo in correction to <code>reproduceability</code></li>
<li>Fix typo in correction to <code>revolutionss</code></li>
<li>Fix typo in correction to <code>transivity</code></li>
</ul>
<h2>v1.35.0</h2>
<h2>[1.35.0] - 2025-08-04</h2>
<h3>Features</h3>
<ul>
<li>Updated the dictionary with the <a
href="https://redirect.github.com/crate-ci/typos/issues/1331">July
2025</a> changes</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/crate-ci/typos/blob/master/CHANGELOG.md">crate-ci/typos's
changelog</a>.</em></p>
<blockquote>
<h1>Change Log</h1>
<p>All notable changes to this project will be documented in this
file.</p>
<p>The format is based on <a href="http://keepachangelog.com/">Keep a
Changelog</a>
and this project adheres to <a href="http://semver.org/">Semantic
Versioning</a>.</p>
<!-- raw HTML omitted -->
<h2>[Unreleased] - ReleaseDate</h2>
<h2>[1.35.3] - 2025-08-08</h2>
<h3>Fixes</h3>
<ul>
<li>Don't correct <code>ratatui</code> in Rust files</li>
</ul>
<h2>[1.35.2] - 2025-08-07</h2>
<h3>Fixes</h3>
<ul>
<li>Don't correct <code>unmarshaling</code></li>
</ul>
<h2>[1.35.1] - 2025-08-04</h2>
<h3>Fixes</h3>
<ul>
<li>Fix typo in correction to <code>apostroph</code></li>
<li>Fix typo in correction to <code>cordinate</code></li>
<li>Fix typo in correction to <code>reproduceability</code></li>
<li>Fix typo in correction to <code>revolutionss</code></li>
<li>Fix typo in correction to <code>transivity</code></li>
</ul>
<h2>[1.35.0] - 2025-08-04</h2>
<h3>Features</h3>
<ul>
<li>Updated the dictionary with the <a
href="https://redirect.github.com/crate-ci/typos/issues/1331">July
2025</a> changes</li>
</ul>
<h2>[1.34.0] - 2025-06-30</h2>
<h3>Features</h3>
<ul>
<li>Updated the dictionary with the <a
href="https://redirect.github.com/crate-ci/typos/issues/1309">June
2025</a> changes</li>
</ul>
<h2>[1.33.1] - 2025-06-02</h2>
<h3>Fixes</h3>
<ul>
<li><em>(dict)</em> Don't correct <code>wasn't</code> to
<code>wasm't</code></li>
</ul>
<h2>[1.33.0] - 2025-06-02</h2>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/crate-ci/typos/commit/52bd719c2c91f9d676e2aa359fc8e0db8925e6d8"><code>52bd719</code></a>
chore: Release</li>
<li><a
href="https://github.com/crate-ci/typos/commit/c6f77dda9e9bf82551f03a500347eb06ce8a90b1"><code>c6f77dd</code></a>
docs: Update changelog</li>
<li><a
href="https://github.com/crate-ci/typos/commit/e35d08c453d5ac2a4630b633dbb63e819b129193"><code>e35d08c</code></a>
Merge pull request <a
href="https://redirect.github.com/crate-ci/typos/issues/1353">#1353</a>
from Rolv-Apneseth/ratatui</li>
<li><a
href="https://github.com/crate-ci/typos/commit/9d6691bc8cf087436d192d03414b9c2420570343"><code>9d6691b</code></a>
fix: Ignore <code>ratatui</code> in Rust files</li>
<li><a
href="https://github.com/crate-ci/typos/commit/f1231bc2bcc92b2b18da70a877cf89afce08dd42"><code>f1231bc</code></a>
chore: Release</li>
<li><a
href="https://github.com/crate-ci/typos/commit/66def6387b9bb7954423333521eed23e75651f6e"><code>66def63</code></a>
docs: Update changelog</li>
<li><a
href="https://github.com/crate-ci/typos/commit/623f09b5bc658227e7e051fc494f3af24030d1cf"><code>623f09b</code></a>
chore: Release</li>
<li><a
href="https://github.com/crate-ci/typos/commit/1080316783320230c1f65e1c374e44dfc13829c6"><code>1080316</code></a>
chore: Release</li>
<li><a
href="https://github.com/crate-ci/typos/commit/442605b52920ac6faab2e457d3bafc0a6d05a5d1"><code>442605b</code></a>
Merge pull request <a
href="https://redirect.github.com/crate-ci/typos/issues/1352">#1352</a>
from epage/marshaling</li>
<li><a
href="https://github.com/crate-ci/typos/commit/983f866bac2164c77fc4ad8a06cdb0738c38ddba"><code>983f866</code></a>
fix(dict): Don't correct marshaling</li>
<li>Additional commits viewable in <a
href="https://github.com/crate-ci/typos/compare/392b78fe18a52790c53f42456e46124f77346842...52bd719c2c91f9d676e2aa359fc8e0db8925e6d8">compare
view</a></li>
</ul>
</details>
<br />

Updates `docker/login-action` from 3.4.0 to 3.5.0
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/docker/login-action/releases">docker/login-action's
releases</a>.</em></p>
<blockquote>
<h2>v3.5.0</h2>
<ul>
<li>Support dual-stack endpoints for AWS ECR by <a
href="https://github.com/Spacefish"><code>@​Spacefish</code></a> <a
href="https://github.com/crazy-max"><code>@​crazy-max</code></a> in <a
href="https://redirect.github.com/docker/login-action/pull/874">docker/login-action#874</a>
<a
href="https://redirect.github.com/docker/login-action/pull/876">docker/login-action#876</a></li>
<li>Bump <code>@​aws-sdk/client-ecr</code> to 3.859.0 in <a
href="https://redirect.github.com/docker/login-action/pull/860">docker/login-action#860</a>
<a
href="https://redirect.github.com/docker/login-action/pull/878">docker/login-action#878</a></li>
<li>Bump <code>@​aws-sdk/client-ecr-public</code> to 3.859.0 in <a
href="https://redirect.github.com/docker/login-action/pull/860">docker/login-action#860</a>
<a
href="https://redirect.github.com/docker/login-action/pull/878">docker/login-action#878</a></li>
<li>Bump <code>@​docker/actions-toolkit</code> from 0.57.0 to 0.62.1 in
<a
href="https://redirect.github.com/docker/login-action/pull/870">docker/login-action#870</a></li>
<li>Bump form-data from 2.5.1 to 2.5.5 in <a
href="https://redirect.github.com/docker/login-action/pull/875">docker/login-action#875</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/docker/login-action/compare/v3.4.0...v3.5.0">https://github.com/docker/login-action/compare/v3.4.0...v3.5.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/docker/login-action/commit/184bdaa0721073962dff0199f1fb9940f07167d1"><code>184bdaa</code></a>
Merge pull request <a
href="https://redirect.github.com/docker/login-action/issues/878">#878</a>
from docker/dependabot/npm_and_yarn/aws-sdk-dependenc...</li>
<li><a
href="https://github.com/docker/login-action/commit/5c6bc94683baa064818f51e7417087c2ac58b32c"><code>5c6bc94</code></a>
chore: update generated content</li>
<li><a
href="https://github.com/docker/login-action/commit/caf405864315c6006c5581b540e5047cf728b4e7"><code>caf4058</code></a>
build(deps): bump the aws-sdk-dependencies group with 2 updates</li>
<li><a
href="https://github.com/docker/login-action/commit/ef38ec311a7df3f01475313e7c5bb584b74b112a"><code>ef38ec3</code></a>
Merge pull request <a
href="https://redirect.github.com/docker/login-action/issues/860">#860</a>
from docker/dependabot/npm_and_yarn/aws-sdk-dependenc...</li>
<li><a
href="https://github.com/docker/login-action/commit/d52e8ef81c0de894e9c95bed8de0ee5955ec7eb7"><code>d52e8ef</code></a>
chore: update generated content</li>
<li><a
href="https://github.com/docker/login-action/commit/9644ab7025be3206ff4b12f1531a1b6919022b00"><code>9644ab7</code></a>
build(deps): bump the aws-sdk-dependencies group with 2 updates</li>
<li><a
href="https://github.com/docker/login-action/commit/7abd1d512621d8896b31f4ea992d207f15915ad6"><code>7abd1d5</code></a>
Merge pull request <a
href="https://redirect.github.com/docker/login-action/issues/875">#875</a>
from docker/dependabot/npm_and_yarn/form-data-2.5.5</li>
<li><a
href="https://github.com/docker/login-action/commit/1a81202c4fda440f3b33eca3381d5d39c7efe85e"><code>1a81202</code></a>
Merge pull request <a
href="https://redirect.github.com/docker/login-action/issues/876">#876</a>
from crazy-max/aws-public-dual-stack</li>
<li><a
href="https://github.com/docker/login-action/commit/d1ab30dc54161cbfd704562857677edf4dd7837a"><code>d1ab30d</code></a>
chore: update generated content</li>
<li><a
href="https://github.com/docker/login-action/commit/f25ff28d1c8cd9a7c35896711238fed682755e1c"><code>f25ff28</code></a>
support dual-stack for aws public ecr</li>
<li>Additional commits viewable in <a
href="https://github.com/docker/login-action/compare/74a5d142397b4f367a81961eba4e8cd7edddf772...184bdaa0721073962dff0199f1fb9940f07167d1">compare
view</a></li>
</ul>
</details>
<br />

Updates `google-github-actions/setup-gcloud` from 2.1.5 to 2.2.0
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/google-github-actions/setup-gcloud/releases">google-github-actions/setup-gcloud's
releases</a>.</em></p>
<blockquote>
<h2>v2.2.0</h2>
<h2>What's Changed</h2>
<ul>
<li>Introduce an option to skip the tool cache by <a
href="https://github.com/sethvargo"><code>@​sethvargo</code></a> in <a
href="https://redirect.github.com/google-github-actions/setup-gcloud/pull/718">google-github-actions/setup-gcloud#718</a></li>
<li>Release: v2.2.0 by <a
href="https://github.com/google-github-actions-bot"><code>@​google-github-actions-bot</code></a>
in <a
href="https://redirect.github.com/google-github-actions/setup-gcloud/pull/719">google-github-actions/setup-gcloud#719</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/google-github-actions/setup-gcloud/compare/v2.1.5...v2.2.0">https://github.com/google-github-actions/setup-gcloud/compare/v2.1.5...v2.2.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/google-github-actions/setup-gcloud/commit/cb1e50a9932213ecece00a606661ae9ca44f3397"><code>cb1e50a</code></a>
Release: v2.2.0 (<a
href="https://redirect.github.com/google-github-actions/setup-gcloud/issues/719">#719</a>)</li>
<li><a
href="https://github.com/google-github-actions/setup-gcloud/commit/ef52f8c087fe78d43262625448b746144fe6448c"><code>ef52f8c</code></a>
Introduce an option to skip the tool cache (<a
href="https://redirect.github.com/google-github-actions/setup-gcloud/issues/718">#718</a>)</li>
<li>See full diff in <a
href="https://github.com/google-github-actions/setup-gcloud/compare/6a7c903a70c8625ed6700fa299f5ddb4ca6022e9...cb1e50a9932213ecece00a606661ae9ca44f3397">compare
view</a></li>
</ul>
</details>
<br />

Updates `actions/download-artifact` from 4.3.0 to 5.0.0
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/actions/download-artifact/releases">actions/download-artifact's
releases</a>.</em></p>
<blockquote>
<h2>v5.0.0</h2>
<h2>What's Changed</h2>
<ul>
<li>Update README.md by <a
href="https://github.com/nebuk89"><code>@​nebuk89</code></a> in <a
href="https://redirect.github.com/actions/download-artifact/pull/407">actions/download-artifact#407</a></li>
<li>BREAKING fix: inconsistent path behavior for single artifact
downloads by ID by <a
href="https://github.com/GrantBirki"><code>@​GrantBirki</code></a> in <a
href="https://redirect.github.com/actions/download-artifact/pull/416">actions/download-artifact#416</a></li>
</ul>
<h2>v5.0.0</h2>
<h3>🚨 Breaking Change</h3>
<p>This release fixes an inconsistency in path behavior for single
artifact downloads by ID. <strong>If you're downloading single artifacts
by ID, the output path may change.</strong></p>
<h4>What Changed</h4>
<p>Previously, <strong>single artifact downloads</strong> behaved
differently depending on how you specified the artifact:</p>
<ul>
<li><strong>By name</strong>: <code>name: my-artifact</code> → extracted
to <code>path/</code> (direct)</li>
<li><strong>By ID</strong>: <code>artifact-ids: 12345</code> → extracted
to <code>path/my-artifact/</code> (nested)</li>
</ul>
<p>Now both methods are consistent:</p>
<ul>
<li><strong>By name</strong>: <code>name: my-artifact</code> → extracted
to <code>path/</code> (unchanged)</li>
<li><strong>By ID</strong>: <code>artifact-ids: 12345</code> → extracted
to <code>path/</code> (fixed - now direct)</li>
</ul>
<h4>Migration Guide</h4>
<h5> No Action Needed If:</h5>
<ul>
<li>You download artifacts by <strong>name</strong></li>
<li>You download <strong>multiple</strong> artifacts by ID</li>
<li>You already use <code>merge-multiple: true</code> as a
workaround</li>
</ul>
<h5>⚠️ Action Required If:</h5>
<p>You download <strong>single artifacts by ID</strong> and your
workflows expect the nested directory structure.</p>
<p><strong>Before v5 (nested structure):</strong></p>
<pre lang="yaml"><code>- uses: actions/download-artifact@v4
  with:
    artifact-ids: 12345
    path: dist
# Files were in: dist/my-artifact/
</code></pre>
<blockquote>
<p>Where <code>my-artifact</code> is the name of the artifact you
previously uploaded</p>
</blockquote>
<p><strong>To maintain old behavior (if needed):</strong></p>
<pre lang="yaml"><code>&lt;/tr&gt;&lt;/table&gt; 
</code></pre>
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/actions/download-artifact/commit/634f93cb2916e3fdff6788551b99b062d0335ce0"><code>634f93c</code></a>
Merge pull request <a
href="https://redirect.github.com/actions/download-artifact/issues/416">#416</a>
from actions/single-artifact-id-download-path</li>
<li><a
href="https://github.com/actions/download-artifact/commit/b19ff4302770b82aa4694b63703b547756dacce6"><code>b19ff43</code></a>
refactor: resolve download path correctly in artifact download tests
(mainly ...</li>
<li><a
href="https://github.com/actions/download-artifact/commit/e262cbee4ab8c473c61c59a81ad8e9dc760e90db"><code>e262cbe</code></a>
bundle dist</li>
<li><a
href="https://github.com/actions/download-artifact/commit/bff23f9308ceb2f06d673043ea6311519be6a87b"><code>bff23f9</code></a>
update docs</li>
<li><a
href="https://github.com/actions/download-artifact/commit/fff8c148a8fdd56aa81fcb019f0b5f6c65700c4d"><code>fff8c14</code></a>
fix download path logic when downloading a single artifact by id</li>
<li><a
href="https://github.com/actions/download-artifact/commit/448e3f862ab3ef47aa50ff917776823c9946035b"><code>448e3f8</code></a>
Merge pull request <a
href="https://redirect.github.com/actions/download-artifact/issues/407">#407</a>
from actions/nebuk89-patch-1</li>
<li><a
href="https://github.com/actions/download-artifact/commit/47225c44b359a5155efdbbbc352041b3e249fb1b"><code>47225c4</code></a>
Update README.md</li>
<li>See full diff in <a
href="https://github.com/actions/download-artifact/compare/d3f86a106a0bac45b974a628896c90dbdf5c8093...634f93cb2916e3fdff6788551b99b062d0335ce0">compare
view</a></li>
</ul>
</details>
<br />

Updates `tj-actions/changed-files` from
c2ca2493190021783138cb8aac49bcee14b4bb89 to
f963b3f3562b00b6d2dd25efc390eb04e51ef6c6
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/tj-actions/changed-files/blob/main/HISTORY.md">tj-actions/changed-files's
changelog</a>.</em></p>
<blockquote>
<h1>Changelog</h1>
<h1><a
href="https://github.com/tj-actions/changed-files/compare/v46.0.4...v46.0.5">46.0.5</a>
- (2025-04-09)</h1>
<h2><!-- raw HTML omitted -->⚙️ Miscellaneous Tasks</h2>
<ul>
<li><strong>deps:</strong> Bump yaml from 2.7.0 to 2.7.1 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2520">#2520</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/ed68ef82c095e0d48ec87eccea555d944a631a4c">ed68ef8</a>)
- (dependabot[bot])</li>
<li><strong>deps-dev:</strong> Bump typescript from 5.8.2 to 5.8.3 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2516">#2516</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/a7bc14b808f23d3b467a4079c69a81f1a4500fd5">a7bc14b</a>)
- (dependabot[bot])</li>
<li><strong>deps-dev:</strong> Bump <code>@​types/node</code> from
22.13.11 to 22.14.0 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2517">#2517</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/3d751f6b6d84071a17e1b9cf4ed79a80a27dd0ab">3d751f6</a>)
- (dependabot[bot])</li>
<li><strong>deps-dev:</strong> Bump eslint-plugin-prettier from 5.2.3 to
5.2.6 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2519">#2519</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/e2fda4ec3cb0bc2a353843cae823430b3124db8f">e2fda4e</a>)
- (dependabot[bot])</li>
<li><strong>deps-dev:</strong> Bump ts-jest from 29.2.6 to 29.3.1 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2518">#2518</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/0bed1b1132ec4879a39a2d624cf82a00d0bcfa48">0bed1b1</a>)
- (dependabot[bot])</li>
<li><strong>deps:</strong> Bump github/codeql-action from 3.28.12 to
3.28.15 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2530">#2530</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/68024587dc36f49685c96d59d3f1081830f968bb">6802458</a>)
- (dependabot[bot])</li>
<li><strong>deps:</strong> Bump tj-actions/branch-names from 8.0.1 to
8.1.0 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2521">#2521</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/cf2e39e86bf842d1f9bc5bca56c0a6b207cca792">cf2e39e</a>)
- (dependabot[bot])</li>
<li><strong>deps:</strong> Bump tj-actions/verify-changed-files from
20.0.1 to 20.0.4 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2523">#2523</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/6abeaa506a419f85fa9e681260b443adbeebb3d4">6abeaa5</a>)
- (dependabot[bot])</li>
</ul>
<h2><!-- raw HTML omitted -->⬆️ Upgrades</h2>
<ul>
<li>Upgraded to v46.0.4 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2511">#2511</a>)</li>
</ul>
<p>Co-authored-by: github-actions[bot]
&lt;41898282+github-actions[bot]<a
href="https://github.com/users"><code>@​users</code></a>.noreply.github.com&gt;
(<a
href="https://github.com/tj-actions/changed-files/commit/6f67ee9ac810f0192ea7b3d2086406f97847bcf9">6f67ee9</a>)
- (github-actions[bot])</p>
<h1><a
href="https://github.com/tj-actions/changed-files/compare/v46.0.3...v46.0.4">46.0.4</a>
- (2025-04-03)</h1>
<h2><!-- raw HTML omitted -->🐛 Bug Fixes</h2>
<ul>
<li>Bug modified_keys and changed_key outputs not set when no changes
detected (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2509">#2509</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/6cb76d07bee4c9772c6882c06c37837bf82a04d3">6cb76d0</a>)
- (Tonye Jack)</li>
</ul>
<h2><!-- raw HTML omitted -->📚 Documentation</h2>
<ul>
<li>Update readme (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2508">#2508</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/b74df86ccb65173a8e33ba5492ac1a2ca6b216fd">b74df86</a>)
- (Tonye Jack)</li>
</ul>
<h2><!-- raw HTML omitted -->⬆️ Upgrades</h2>
<ul>
<li>Upgraded to v46.0.3 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2506">#2506</a>)</li>
</ul>
<p>Co-authored-by: github-actions[bot]
&lt;41898282+github-actions[bot]<a
href="https://github.com/users"><code>@​users</code></a>.noreply.github.com&gt;
Co-authored-by: Tonye Jack <a
href="mailto:jtonye@ymail.com">jtonye@ymail.com</a> (<a
href="https://github.com/tj-actions/changed-files/commit/27ae6b33eaed7bf87272fdeb9f1c54f9facc9d99">27ae6b3</a>)
- (github-actions[bot])</p>
<h1><a
href="https://github.com/tj-actions/changed-files/compare/v46.0.2...v46.0.3">46.0.3</a>
- (2025-03-23)</h1>
<h2><!-- raw HTML omitted -->🔄 Update</h2>
<ul>
<li>Updated README.md (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2501">#2501</a>)</li>
</ul>
<p>Co-authored-by: github-actions[bot]
&lt;41898282+github-actions[bot]<a
href="https://github.com/users"><code>@​users</code></a>.noreply.github.com&gt;
(<a
href="https://github.com/tj-actions/changed-files/commit/41e0de576a0f2b64d9f06f2773f539109e55a70a">41e0de5</a>)
- (github-actions[bot])</p>
<ul>
<li>Updated README.md (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2499">#2499</a>)</li>
</ul>
<p>Co-authored-by: github-actions[bot]
&lt;41898282+github-actions[bot]<a
href="https://github.com/users"><code>@​users</code></a>.noreply.github.com&gt;
(<a
href="https://github.com/tj-actions/changed-files/commit/945787811a795cd840a1157ac590dd7827a05c8e">9457878</a>)
- (github-actions[bot])</p>
<h2><!-- raw HTML omitted -->📚 Documentation</h2>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/tj-actions/changed-files/commit/f963b3f3562b00b6d2dd25efc390eb04e51ef6c6"><code>f963b3f</code></a>
chore(deps-dev): bump <code>@​types/node</code> from 24.1.0 to 24.2.0
(<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2640">#2640</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/f956744105e18d78bba3844a1199ce43d6503017"><code>f956744</code></a>
chore(deps): bump actions/download-artifact from 4.3.0 to 5.0.0 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2641">#2641</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/9009babdfafec9874564eacad3fb7006205ba31a"><code>9009bab</code></a>
chore(deps): bump yaml from 2.8.0 to 2.8.1 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2642">#2642</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/2ecafed8a9a7bcf95ff103a3753b27e044af2736"><code>2ecafed</code></a>
chore(deps-dev): bump eslint-plugin-prettier from 5.5.3 to 5.5.4 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2643">#2643</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/8cdfb7636d150253dee416a80f11c67f5ba7e9be"><code>8cdfb76</code></a>
chore(deps): bump tj-actions/eslint-changed-files from 25.3.1 to 25.3.2
(<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2638">#2638</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/087c158d0f1269d7ac8571378b39f3130f96a736"><code>087c158</code></a>
chore(deps-dev): bump ts-jest from 29.4.0 to 29.4.1 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2639">#2639</a>)</li>
<li>See full diff in <a
href="https://github.com/tj-actions/changed-files/compare/c2ca2493190021783138cb8aac49bcee14b4bb89...f963b3f3562b00b6d2dd25efc390eb04e51ef6c6">compare
view</a></li>
</ul>
</details>
<br />

Updates `github/codeql-action` from 3.29.7 to 3.29.8
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/github/codeql-action/releases">github/codeql-action's
releases</a>.</em></p>
<blockquote>
<h2>v3.29.8</h2>
<h1>CodeQL Action Changelog</h1>
<p>See the <a
href="https://github.com/github/codeql-action/releases">releases
page</a> for the relevant changes to the CodeQL CLI and language
packs.</p>
<h2>3.29.8 - 08 Aug 2025</h2>
<ul>
<li>Fix an issue where the Action would autodetect unsupported languages
such as HTML. <a
href="https://redirect.github.com/github/codeql-action/pull/3015">#3015</a></li>
</ul>
<p>See the full <a
href="https://github.com/github/codeql-action/blob/v3.29.8/CHANGELOG.md">CHANGELOG.md</a>
for more information.</p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/github/codeql-action/blob/main/CHANGELOG.md">github/codeql-action's
changelog</a>.</em></p>
<blockquote>
<h1>CodeQL Action Changelog</h1>
<p>See the <a
href="https://github.com/github/codeql-action/releases">releases
page</a> for the relevant changes to the CodeQL CLI and language
packs.</p>
<h2>[UNRELEASED]</h2>
<p>No user facing changes.</p>
<h2>3.29.8 - 08 Aug 2025</h2>
<ul>
<li>Fix an issue where the Action would autodetect unsupported languages
such as HTML. <a
href="https://redirect.github.com/github/codeql-action/pull/3015">#3015</a></li>
</ul>
<h2>3.29.7 - 07 Aug 2025</h2>
<p>This release rolls back 3.29.6 to address issues with language
autodetection. It is identical to 3.29.5.</p>
<h2>3.29.6 - 07 Aug 2025</h2>
<ul>
<li>The <code>cleanup-level</code> input to the <code>analyze</code>
Action is now deprecated. The CodeQL Action has written a limited amount
of intermediate results to the database since version 2.2.5, and now
automatically manages cleanup. <a
href="https://redirect.github.com/github/codeql-action/pull/2999">#2999</a></li>
<li>Update default CodeQL bundle version to 2.22.3. <a
href="https://redirect.github.com/github/codeql-action/pull/3000">#3000</a></li>
</ul>
<h2>3.29.5 - 29 Jul 2025</h2>
<ul>
<li>Update default CodeQL bundle version to 2.22.2. <a
href="https://redirect.github.com/github/codeql-action/pull/2986">#2986</a></li>
</ul>
<h2>3.29.4 - 23 Jul 2025</h2>
<p>No user facing changes.</p>
<h2>3.29.3 - 21 Jul 2025</h2>
<p>No user facing changes.</p>
<h2>3.29.2 - 30 Jun 2025</h2>
<ul>
<li>Experimental: When the <code>quality-queries</code> input for the
<code>init</code> action is provided with an argument, separate
<code>.quality.sarif</code> files are produced and uploaded for each
language with the results of the specified queries. Do not use this in
production as it is part of an internal experiment and subject to change
at any time. <a
href="https://redirect.github.com/github/codeql-action/pull/2935">#2935</a></li>
</ul>
<h2>3.29.1 - 27 Jun 2025</h2>
<ul>
<li>Fix bug in PR analysis where user-provided <code>include</code>
query filter fails to exclude non-included queries. <a
href="https://redirect.github.com/github/codeql-action/pull/2938">#2938</a></li>
<li>Update default CodeQL bundle version to 2.22.1. <a
href="https://redirect.github.com/github/codeql-action/pull/2950">#2950</a></li>
</ul>
<h2>3.29.0 - 11 Jun 2025</h2>
<ul>
<li>Update default CodeQL bundle version to 2.22.0. <a
href="https://redirect.github.com/github/codeql-action/pull/2925">#2925</a></li>
<li>Bump minimum CodeQL bundle version to 2.16.6. <a
href="https://redirect.github.com/github/codeql-action/pull/2912">#2912</a></li>
</ul>
<h2>3.28.21 - 28 July 2025</h2>
<p>No user facing changes.</p>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/github/codeql-action/commit/76621b61decf072c1cee8dd1ce2d2a82d33c17ed"><code>76621b6</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/3019">#3019</a>
from github/update-v3.29.8-679a40d33</li>
<li><a
href="https://github.com/github/codeql-action/commit/29ac3cefbb645d41622f6f9baa1415e06d73cf06"><code>29ac3ce</code></a>
Add release notes for 3.29.7</li>
<li><a
href="https://github.com/github/codeql-action/commit/737cfdebe687c6e720fb99761f23d89751c3b93a"><code>737cfde</code></a>
Update changelog for v3.29.8</li>
<li><a
href="https://github.com/github/codeql-action/commit/679a40d337fedd9b7318253dd72bfe7dc6d1886c"><code>679a40d</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/3014">#3014</a>
from github/henrymercer/rebuild-dispatch</li>
<li><a
href="https://github.com/github/codeql-action/commit/6fe50b283a3d2e5533299f72d99216cd8815500f"><code>6fe50b2</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/3015">#3015</a>
from github/henrymercer/language-autodetection-worka...</li>
<li><a
href="https://github.com/github/codeql-action/commit/6bc91d64f66d435200c8ba85c64878c3cbfad33b"><code>6bc91d6</code></a>
Add changelog note</li>
<li><a
href="https://github.com/github/codeql-action/commit/6b4fedca4f3428195d7ba1ca7c7404f9ea472911"><code>6b4fedc</code></a>
Bump Action patch version</li>
<li><a
href="https://github.com/github/codeql-action/commit/5794ffcb4ab0e87e4b8a8446ef048488303db295"><code>5794ffc</code></a>
Fix auto-detection of extractors that aren't languages</li>
<li><a
href="https://github.com/github/codeql-action/commit/bd62bf449cd8695f818546752cc8157693e1716c"><code>bd62bf4</code></a>
Finish in-progress merges</li>
<li><a
href="https://github.com/github/codeql-action/commit/2afb4e6f3c84ec0534284f2b47ae8206dcb401bf"><code>2afb4e6</code></a>
Avoid specifying branch unnecessarily</li>
<li>Additional commits viewable in <a
href="https://github.com/github/codeql-action/compare/51f77329afa6477de8c49fc9c7046c15b9a4e79d...76621b61decf072c1cee8dd1ce2d2a82d33c17ed">compare
view</a></li>
</ul>
</details>
<br />

<details>
<summary>Most Recent Ignore Conditions Applied to This Pull
Request</summary>

| Dependency Name | Ignore Conditions |
| --- | --- |
| crate-ci/typos | [>= 1.30.a, < 1.31] |
</details>


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 16:10:46 +00:00
dependabot[bot] 331f85e0ac chore: bump github.com/chromedp/chromedp from 0.13.3 to 0.14.1 (#19292)
Bumps
[github.com/chromedp/chromedp](https://github.com/chromedp/chromedp)
from 0.13.3 to 0.14.1.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/chromedp/chromedp/commit/422fa06290cda228e5712bdda55fbf7a0f6c8466"><code>422fa06</code></a>
fix(allocator): Set --enable-unsafe-swiftshader with --disable-gpu</li>
<li><a
href="https://github.com/chromedp/chromedp/commit/c34c35fb81d21803824f9f298d9eac740bcfde9e"><code>c34c35f</code></a>
Fixing issue with page.Navigate calls</li>
<li><a
href="https://github.com/chromedp/chromedp/commit/c3337896f2239c5b7715a424c13f14d95d3dc4a3"><code>c333789</code></a>
allocator: fix race that causes workgroup panic</li>
<li><a
href="https://github.com/chromedp/chromedp/commit/2f3596f46c773ec5af6eb10e5fdfee9a4b2f6688"><code>2f3596f</code></a>
Run modernize -fix -test ./...</li>
<li><a
href="https://github.com/chromedp/chromedp/commit/743c1e442dd5e0536d46c64bb2d6360bec0ac082"><code>743c1e4</code></a>
Fix CreateTarget call</li>
<li><a
href="https://github.com/chromedp/chromedp/commit/a2c672facedf743ba9f9cea01151358ca30f3be2"><code>a2c672f</code></a>
fix: <a
href="https://redirect.github.com/chromedp/chromedp/issues/1448">#1448</a></li>
<li><a
href="https://github.com/chromedp/chromedp/commit/5a4d7c0955a049d70f219b181d78302525f9ef63"><code>5a4d7c0</code></a>
Updating cdproto</li>
<li>See full diff in <a
href="https://github.com/chromedp/chromedp/compare/v0.13.3...v0.14.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/chromedp/chromedp&package-manager=go_modules&previous-version=0.13.3&new-version=0.14.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 15:37:04 +00:00
dependabot[bot] 39bcd819cc chore: bump github.com/aws/aws-sdk-go-v2/feature/rds/auth from 1.5.1 to 1.6.2 (#19291)
Bumps
[github.com/aws/aws-sdk-go-v2/feature/rds/auth](https://github.com/aws/aws-sdk-go-v2)
from 1.5.1 to 1.6.2.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/CHANGELOG.md">github.com/aws/aws-sdk-go-v2/feature/rds/auth's
changelog</a>.</em></p>
<blockquote>
<h1>Release (2021-10-11)</h1>
<h2>General Highlights</h2>
<ul>
<li><strong>Dependency Update</strong>: Updated to the latest SDK module
versions</li>
</ul>
<h2>Module Highlights</h2>
<ul>
<li><code>github.com/aws/aws-sdk-go-v2/feature/ec2/imds</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/feature/ec2/imds/CHANGELOG.md#v160-2021-10-11">v1.6.0</a>
<ul>
<li><strong>Feature</strong>: Respect passed in Context
Deadline/Timeout. Updates the IMDS Client operations to not override the
passed in Context's Deadline or Timeout options. If an Client operation
is called with a Context with a Deadline or Timeout, the client will no
longer override it with the client's default timeout.</li>
<li><strong>Bug Fix</strong>: Fix IMDS client's response handling and
operation timeout race. Fixes <a
href="https://redirect.github.com/aws/aws-sdk-go-v2/issues/1253">#1253</a></li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/amplifybackend</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/amplifybackend/CHANGELOG.md#v150-2021-10-11">v1.5.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>

<li><code>github.com/aws/aws-sdk-go-v2/service/applicationautoscaling</code>:
<a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/applicationautoscaling/CHANGELOG.md#v170-2021-10-11">v1.7.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/apprunner</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/apprunner/CHANGELOG.md#v130-2021-10-11">v1.3.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/backup</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/backup/CHANGELOG.md#v160-2021-10-11">v1.6.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/chime</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/chime/CHANGELOG.md#v1110-2021-10-11">v1.11.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/codebuild</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/codebuild/CHANGELOG.md#v1110-2021-10-11">v1.11.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/databrew</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/databrew/CHANGELOG.md#v1100-2021-10-11">v1.10.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/ec2</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/ec2/CHANGELOG.md#v1190-2021-10-11">v1.19.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/efs</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/efs/CHANGELOG.md#v180-2021-10-11">v1.8.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>

<li><code>github.com/aws/aws-sdk-go-v2/service/elasticloadbalancingv2</code>:
<a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/elasticloadbalancingv2/CHANGELOG.md#v190-2021-10-11">v1.9.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/firehose</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/firehose/CHANGELOG.md#v170-2021-10-11">v1.7.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/frauddetector</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/frauddetector/CHANGELOG.md#v1100-2021-10-11">v1.10.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/fsx</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/fsx/CHANGELOG.md#v1100-2021-10-11">v1.10.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/glue</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/glue/CHANGELOG.md#v1120-2021-10-11">v1.12.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/grafana</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/grafana/CHANGELOG.md#v100-2021-10-11">v1.0.0</a>
<ul>
<li><strong>Release</strong>: New AWS service client module</li>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/iotevents</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/iotevents/CHANGELOG.md#v180-2021-10-11">v1.8.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/kendra</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/kendra/CHANGELOG.md#v1120-2021-10-11">v1.12.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/kms</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/kms/CHANGELOG.md#v170-2021-10-11">v1.7.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/lexmodelsv2</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/lexmodelsv2/CHANGELOG.md#v190-2021-10-11">v1.9.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
<li><code>github.com/aws/aws-sdk-go-v2/service/lexruntimev2</code>: <a
href="https://github.com/aws/aws-sdk-go-v2/blob/service/pi/v1.6.2/service/lexruntimev2/CHANGELOG.md#v160-2021-10-11">v1.6.0</a>
<ul>
<li><strong>Feature</strong>: API client updated</li>
</ul>
</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/26a9df85b9bd8b23a4a0db1bc2f14ef88a1234e7"><code>26a9df8</code></a>
Release 2021-10-11</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/29c9052835b1a9ac5d9f3833a7d549cbd8a50ea4"><code>29c9052</code></a>
update api models (<a
href="https://redirect.github.com/aws/aws-sdk-go-v2/issues/1455">#1455</a>)</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/0d3bd7a3ee7b0eda33531db18f4aa404225381e0"><code>0d3bd7a</code></a>
feature/ec2/imds: Fix Client's response handling and operation timeout
race (...</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/f1baf2dc6d42d48d46bc079d574f60f7a92a223b"><code>f1baf2d</code></a>
Update stale_issue.yml (<a
href="https://redirect.github.com/aws/aws-sdk-go-v2/issues/1447">#1447</a>)</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/74bf5cfb9e3108a48d95e23ca00901cb50cdba2f"><code>74bf5cf</code></a>
Update SDK to use shared tooling for changelog and release handling (<a
href="https://redirect.github.com/aws/aws-sdk-go-v2/issues/1431">#1431</a>)</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/f7e09fbe15942bd0bcff35620a0c099109e5fdd0"><code>f7e09fb</code></a>
Fix a typo in the Retryer docs (<a
href="https://redirect.github.com/aws/aws-sdk-go-v2/issues/1441">#1441</a>)</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/654440450eb02e128d94dd3aa4ac690a80aabc3a"><code>6544404</code></a>
Release 2021-09-30</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/54c5dd79da51255301812dfabd37f90818a2316c"><code>54c5dd7</code></a>
update endpoint for cloud control (<a
href="https://redirect.github.com/aws/aws-sdk-go-v2/issues/1444">#1444</a>)</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/f70d329ff8d41fd0602cd370516d41a5b2c28000"><code>f70d329</code></a>
update models (<a
href="https://redirect.github.com/aws/aws-sdk-go-v2/issues/1443">#1443</a>)</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/cc132614991d2e36a7b5ca8685aea13bf1337224"><code>cc13261</code></a>
Release 2021-09-24</li>
<li>Additional commits viewable in <a
href="https://github.com/aws/aws-sdk-go-v2/compare/service/pi/v1.5.1...service/pi/v1.6.2">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/aws/aws-sdk-go-v2/feature/rds/auth&package-manager=go_modules&previous-version=1.5.1&new-version=1.6.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 15:34:43 +00:00
dependabot[bot] 894a80b86b chore: bump github.com/mark3labs/mcp-go from 0.36.0 to 0.37.0 (#19290)
Bumps [github.com/mark3labs/mcp-go](https://github.com/mark3labs/mcp-go)
from 0.36.0 to 0.37.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/mark3labs/mcp-go/releases">github.com/mark3labs/mcp-go's
releases</a>.</em></p>
<blockquote>
<h2>Release v0.37.0</h2>
<h2>⚠️ Breaking Changes</h2>
<p>The <code>Result.Meta</code> field type has changed from
<code>map[string]any</code> to <code>*Meta</code>. Code that directly
accesses or sets this field will need to be updated:</p>
<pre lang="go"><code>// Before (v0.36.0 and earlier):
result.Meta = map[string]any{&quot;key&quot;: &quot;value&quot;}
<p>// After (v0.37.0):
result.Meta = &amp;mcp.Meta{AdditionalFields:
map[string]any{&quot;key&quot;: &quot;value&quot;}}
</code></pre></p>
<h2>What's Changed</h2>
<ul>
<li>Replace Prompts/Resources/Resource Templates by <a
href="https://github.com/dgageot"><code>@​dgageot</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/518">mark3labs/mcp-go#518</a></li>
<li>Update server.go race condition by <a
href="https://github.com/outofthisworld"><code>@​outofthisworld</code></a>
in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/524">mark3labs/mcp-go#524</a></li>
<li>task: add _meta field to relevant types as defined in MCP
specification by <a
href="https://github.com/buraksenn"><code>@​buraksenn</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/429">mark3labs/mcp-go#429</a></li>
<li>feat: implement sampling support for Streamable HTTP transport by <a
href="https://github.com/andig"><code>@​andig</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/515">mark3labs/mcp-go#515</a></li>
<li>Fix SSE transport not properly handling HTTP/2 NO_ERROR
disconnections by <a
href="https://github.com/okoshi-f"><code>@​okoshi-f</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/509">mark3labs/mcp-go#509</a></li>
<li>feat: add thread-safe <code>SetExpectedState</code> for
cross-request OAuth flows by <a
href="https://github.com/sd2k"><code>@​sd2k</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/500">mark3labs/mcp-go#500</a></li>
<li>feat: allow to set a custom logger in the SSE and STDIO clients by
<a href="https://github.com/caarlos0"><code>@​caarlos0</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/525">mark3labs/mcp-go#525</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/outofthisworld"><code>@​outofthisworld</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/524">mark3labs/mcp-go#524</a></li>
<li><a href="https://github.com/buraksenn"><code>@​buraksenn</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/429">mark3labs/mcp-go#429</a></li>
<li><a href="https://github.com/andig"><code>@​andig</code></a> made
their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/515">mark3labs/mcp-go#515</a></li>
<li><a href="https://github.com/okoshi-f"><code>@​okoshi-f</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/509">mark3labs/mcp-go#509</a></li>
<li><a href="https://github.com/caarlos0"><code>@​caarlos0</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/525">mark3labs/mcp-go#525</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/mark3labs/mcp-go/compare/v0.36.0...v0.37.0">https://github.com/mark3labs/mcp-go/compare/v0.36.0...v0.37.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/6da5cd164852f4d90c39c4ce70dc3dd0aed906f2"><code>6da5cd1</code></a>
feat: allow to set a custom logger in the SSE and STDIO clients (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/525">#525</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/9259d32af54f69fbdc8c69b762c6a9449f0413b1"><code>9259d32</code></a>
feat: add thread-safe <code>SetExpectedState</code> for cross-request
OAuth flows (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/500">#500</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/a63f10e5b74cf6cfe2fa59b07b8e3f54a69366b9"><code>a63f10e</code></a>
Fix SSE transport not properly handling HTTP/2 NO_ERROR disconnections
(<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/509">#509</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/fda6b38ed3a514e7943b46d46fcac27a71204e67"><code>fda6b38</code></a>
feat: implement sampling support for Streamable HTTP transport (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/515">#515</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/6e5d6fd976451bc1a1cc32e26cababce562c0ceb"><code>6e5d6fd</code></a>
fix unmarshalling error for Meta property</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/57740b672a283f27346158289449b1d8f0c31a59"><code>57740b6</code></a>
task: add _meta field to relevant types (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/429">#429</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/96de11276c5934385ce4b95f493fcef172f438de"><code>96de112</code></a>
Update server.go race condition (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/524">#524</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/4cca302f5eac488b407d87ac58fffd63517e6af6"><code>4cca302</code></a>
Replace Prompts/Resources/Resource Templates (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/518">#518</a>)</li>
<li>See full diff in <a
href="https://github.com/mark3labs/mcp-go/compare/v0.36.0...v0.37.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/mark3labs/mcp-go&package-manager=go_modules&previous-version=0.36.0&new-version=0.37.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 15:32:14 +00:00
dependabot[bot] 2a81449b75 chore: bump the x group with 7 updates (#19289)
[//]: # (dependabot-start)
⚠️  **Dependabot is rebasing this PR** ⚠️ 

Rebasing might not happen immediately, so don't worry if this takes some
time.

Note: if you make any changes to this PR yourself, they will take
precedence over the rebase.

---

[//]: # (dependabot-end)

Bumps the x group with 7 updates:

| Package | From | To |
| --- | --- | --- |
| [golang.org/x/crypto](https://github.com/golang/crypto) | `0.40.0` |
`0.41.0` |
| [golang.org/x/mod](https://github.com/golang/mod) | `0.26.0` |
`0.27.0` |
| [golang.org/x/net](https://github.com/golang/net) | `0.42.0` |
`0.43.0` |
| [golang.org/x/sys](https://github.com/golang/sys) | `0.34.0` |
`0.35.0` |
| [golang.org/x/term](https://github.com/golang/term) | `0.33.0` |
`0.34.0` |
| [golang.org/x/text](https://github.com/golang/text) | `0.27.0` |
`0.28.0` |
| [golang.org/x/tools](https://github.com/golang/tools) | `0.35.0` |
`0.36.0` |

Updates `golang.org/x/crypto` from 0.40.0 to 0.41.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/crypto/commit/ef5341b70697ceb55f904384bd982587224e8b0c"><code>ef5341b</code></a>
go.mod: update golang.org/x dependencies</li>
<li><a
href="https://github.com/golang/crypto/commit/b999374650442ee37e9bbd97d6a11ad7ed999b98"><code>b999374</code></a>
acme: fix pebble subprocess output data race</li>
<li><a
href="https://github.com/golang/crypto/commit/c247dead11de7671a21a6c5169555e2aa5313caa"><code>c247dea</code></a>
x509roots/fallback: store bundle certs directly in DER</li>
<li><a
href="https://github.com/golang/crypto/commit/1fda73153feef7b246f24005838c387e354e5e3b"><code>1fda731</code></a>
acme: increase pebble test waitForServer attempts</li>
<li><a
href="https://github.com/golang/crypto/commit/1b4c3d2e8c8be172c6af8f2f72778e69e74d2e78"><code>1b4c3d2</code></a>
x509roots/fallback: update bundle</li>
<li><a
href="https://github.com/golang/crypto/commit/b903b535d3ef82fab12a9cc0fa50fccc396ced55"><code>b903b53</code></a>
acme: capture pebble test subprocess stdout/stderr</li>
<li>See full diff in <a
href="https://github.com/golang/crypto/compare/v0.40.0...v0.41.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/mod` from 0.26.0 to 0.27.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/mod/commit/f8a9fe217cff893cb67f4acad96a0021c13ee6e7"><code>f8a9fe2</code></a>
go.mod: update golang.org/x dependencies</li>
<li>See full diff in <a
href="https://github.com/golang/mod/compare/v0.26.0...v0.27.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/net` from 0.42.0 to 0.43.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/net/commit/e74bc31d69f225b635e065a602db3fbfa9850f93"><code>e74bc31</code></a>
go.mod: update golang.org/x dependencies</li>
<li><a
href="https://github.com/golang/net/commit/af6926ea18d0703b9f24713074bc7079cf50a744"><code>af6926e</code></a>
http2: remove references to defunct http2.golang.org test server</li>
<li>See full diff in <a
href="https://github.com/golang/net/compare/v0.42.0...v0.43.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/sys` from 0.34.0 to 0.35.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/sys/commit/5b936e1f126baa13682eff91c2e4d5d9e3a0b71d"><code>5b936e1</code></a>
unix/linux: update to Linux kernel 6.16, Go to 1.24.5</li>
<li><a
href="https://github.com/golang/sys/commit/3a827038f29dfeda71ad5d6fdba5cef0b5720a97"><code>3a82703</code></a>
unix: remove redundant xnu version check for {p}readv/{p}writev</li>
<li><a
href="https://github.com/golang/sys/commit/9920300fc80d500263287b0b4906010f81e3acc4"><code>9920300</code></a>
unix: add missing nft conntrack constants</li>
<li><a
href="https://github.com/golang/sys/commit/ad4e0fcb710c6502fe5d4dba89040508f45ba069"><code>ad4e0fc</code></a>
unix: remove redundant word in comment</li>
<li><a
href="https://github.com/golang/sys/commit/084ad875b3b515f8e782e5bf42ce40e316126e9e"><code>084ad87</code></a>
unix: fix //sys decl after CL 548795</li>
<li>See full diff in <a
href="https://github.com/golang/sys/compare/v0.34.0...v0.35.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/term` from 0.33.0 to 0.34.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/term/commit/a35244d18d7756b12deca31a518c0fa1327d050a"><code>a35244d</code></a>
go.mod: update golang.org/x dependencies</li>
<li><a
href="https://github.com/golang/term/commit/4f53e0cd3924d70667107169374a480bfd208348"><code>4f53e0c</code></a>
term: allow multi-line bracketed paste to not create single line with
verbati...</li>
<li><a
href="https://github.com/golang/term/commit/27f29d8328742b97c08c2186027d32cdc438345c"><code>27f29d8</code></a>
term: remove duplicate flag and add comment on windows</li>
<li>See full diff in <a
href="https://github.com/golang/term/compare/v0.33.0...v0.34.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/text` from 0.27.0 to 0.28.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/text/commit/425d715b4a85c7698cedf621412bb53794cbda53"><code>425d715</code></a>
go.mod: update golang.org/x dependencies</li>
<li>See full diff in <a
href="https://github.com/golang/text/compare/v0.27.0...v0.28.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/tools` from 0.35.0 to 0.36.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/tools/commit/44d18e11572cd133e1eec6811ba57d78ff20addf"><code>44d18e1</code></a>
go.mod: update golang.org/x dependencies</li>
<li><a
href="https://github.com/golang/tools/commit/52b9c68d0135f3d3c2dd2ebdabdfea7e1891fd20"><code>52b9c68</code></a>
go/ast/inspector: remove obsolete unsafe import</li>
<li><a
href="https://github.com/golang/tools/commit/b155480fce19b20e4598a0b8ca83620f1724b7f2"><code>b155480</code></a>
gopls/doc/features: add &quot;MCP&quot; to index.</li>
<li><a
href="https://github.com/golang/tools/commit/992bf9c2a4c3c32dc19e4e6df9bbc255c1808af0"><code>992bf9c</code></a>
gopls/internal/golang/hover: show alias real type decl for types
only</li>
<li><a
href="https://github.com/golang/tools/commit/861996a8e6524e998ff987217493af5fbd9e5793"><code>861996a</code></a>
go/ssa: pass GOEXPERIMENT=aliastypeparams only on Go 1.23</li>
<li><a
href="https://github.com/golang/tools/commit/528efdabbedbd4f98749aa907b412900f5bc3ee5"><code>528efda</code></a>
gopls/internal/analysis/modernize/forvar: provide fix for second loop
var</li>
<li><a
href="https://github.com/golang/tools/commit/bdddfd54ae82000b66cfeadfe6849bdcfefb35cf"><code>bdddfd5</code></a>
gopls/internal/server: add counters for add and remove struct tags</li>
<li><a
href="https://github.com/golang/tools/commit/23dd839aec5d324ef8d353e1bb7163a9d4e63803"><code>23dd839</code></a>
gopls/internal/filewatcher: fix race condition on watcher shutdown</li>
<li><a
href="https://github.com/golang/tools/commit/3a8978cc911172228fd3f5ecb8205d095fea5f05"><code>3a8978c</code></a>
cmd/digraph: fix bug in allpaths</li>
<li><a
href="https://github.com/golang/tools/commit/bae51bdd6e039c826b91c579f4db0294cfb9a5f7"><code>bae51bd</code></a>
gopls/internal/server: add windsurf and cursor as language client</li>
<li>Additional commits viewable in <a
href="https://github.com/golang/tools/compare/v0.35.0...v0.36.0">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 15:31:01 +00:00
dependabot[bot] ddf3a50ac0 chore: bump google.golang.org/api from 0.242.0 to 0.246.0 (#19284)
Bumps
[google.golang.org/api](https://github.com/googleapis/google-api-go-client)
from 0.242.0 to 0.246.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/googleapis/google-api-go-client/releases">google.golang.org/api's
releases</a>.</em></p>
<blockquote>
<h2>v0.246.0</h2>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.245.0...v0.246.0">0.246.0</a>
(2025-08-06)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3261">#3261</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/b792200673836a4a042bb48938dff17ee6a0954f">b792200</a>)</li>
</ul>
<h3>Bug Fixes</h3>
<ul>
<li><strong>idtoken:</strong> Don't assume DefaultTransport is a
http.Transport (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3263">#3263</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/61fba51991b51d84065a1c66e4a49434462d2c94">61fba51</a>),
refs <a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3260">#3260</a></li>
</ul>
<h2>v0.245.0</h2>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.244.0...v0.245.0">0.245.0</a>
(2025-08-05)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3252">#3252</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/07167280e3c760ca963632dc541e9c1428c639b9">0716728</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3254">#3254</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/702998a9a8285e1093886fc1b0fdfbcc8112fd6f">702998a</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3255">#3255</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/0f103667e9560e28646edc7aa03e47e71983aae5">0f10366</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3256">#3256</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/83176a94b64c04b46b4926f41f5f87d7a54f71f6">83176a9</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3257">#3257</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/efc337167473eb103dbd70f9b5f9491ec1cff75c">efc3371</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3259">#3259</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/bf38d3ad99d570f956658f9f63209a5143f94703">bf38d3a</a>)</li>
</ul>
<h3>Bug Fixes</h3>
<ul>
<li><strong>gensupport:</strong> Fix transferChunk race condition by
returning response with non-cancelled context. (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3258">#3258</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/091d42217a08f1a5873cc13cfb51d4275b18e2e6">091d422</a>)</li>
</ul>
<h2>v0.244.0</h2>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.243.0...v0.244.0">0.244.0</a>
(2025-07-30)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3241">#3241</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/2c204857ee78454d1e2cafb5df2bc3720fc0afbc">2c20485</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3243">#3243</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/cac72a14582b9675f5889a346f4f195988a2c9b5">cac72a1</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3244">#3244</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/e6b1c8715fbffd4598a9c80c21c274f858ea2cfe">e6b1c87</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3245">#3245</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/2c1ff18dfc5f5c9e422ed03c8daf571264eaec4c">2c1ff18</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3247">#3247</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/09e5c0743dfa02b62cf54c797725b5c09744ec65">09e5c07</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3249">#3249</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/214eb4ea568f09bb4b874216e1b4084acb93de49">214eb4e</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3250">#3250</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/ce50789a30c76512543819a36eb0fb91b86edc44">ce50789</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3251">#3251</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/e5c3e1801eaa85fa23ee046f1ffe8193c282b6fd">e5c3e18</a>)</li>
</ul>
<h2>v0.243.0</h2>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.242.0...v0.243.0">0.243.0</a>
(2025-07-22)</h2>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/googleapis/google-api-go-client/blob/main/CHANGES.md">google.golang.org/api's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.245.0...v0.246.0">0.246.0</a>
(2025-08-06)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3261">#3261</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/b792200673836a4a042bb48938dff17ee6a0954f">b792200</a>)</li>
</ul>
<h3>Bug Fixes</h3>
<ul>
<li><strong>idtoken:</strong> Don't assume DefaultTransport is a
http.Transport (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3263">#3263</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/61fba51991b51d84065a1c66e4a49434462d2c94">61fba51</a>),
refs <a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3260">#3260</a></li>
</ul>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.244.0...v0.245.0">0.245.0</a>
(2025-08-05)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3252">#3252</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/07167280e3c760ca963632dc541e9c1428c639b9">0716728</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3254">#3254</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/702998a9a8285e1093886fc1b0fdfbcc8112fd6f">702998a</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3255">#3255</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/0f103667e9560e28646edc7aa03e47e71983aae5">0f10366</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3256">#3256</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/83176a94b64c04b46b4926f41f5f87d7a54f71f6">83176a9</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3257">#3257</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/efc337167473eb103dbd70f9b5f9491ec1cff75c">efc3371</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3259">#3259</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/bf38d3ad99d570f956658f9f63209a5143f94703">bf38d3a</a>)</li>
</ul>
<h3>Bug Fixes</h3>
<ul>
<li><strong>gensupport:</strong> Fix transferChunk race condition by
returning response with non-cancelled context. (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3258">#3258</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/091d42217a08f1a5873cc13cfb51d4275b18e2e6">091d422</a>)</li>
</ul>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.243.0...v0.244.0">0.244.0</a>
(2025-07-30)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3241">#3241</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/2c204857ee78454d1e2cafb5df2bc3720fc0afbc">2c20485</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3243">#3243</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/cac72a14582b9675f5889a346f4f195988a2c9b5">cac72a1</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3244">#3244</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/e6b1c8715fbffd4598a9c80c21c274f858ea2cfe">e6b1c87</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3245">#3245</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/2c1ff18dfc5f5c9e422ed03c8daf571264eaec4c">2c1ff18</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3247">#3247</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/09e5c0743dfa02b62cf54c797725b5c09744ec65">09e5c07</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3249">#3249</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/214eb4ea568f09bb4b874216e1b4084acb93de49">214eb4e</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3250">#3250</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/ce50789a30c76512543819a36eb0fb91b86edc44">ce50789</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3251">#3251</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/e5c3e1801eaa85fa23ee046f1ffe8193c282b6fd">e5c3e18</a>)</li>
</ul>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.242.0...v0.243.0">0.243.0</a>
(2025-07-22)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3233">#3233</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/a269dca39e5315e9bfc77cc05b3dbd64af9baa25">a269dca</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3235">#3235</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/b656000d19f9627de3e2817451f82c339ce4e4bb">b656000</a>)</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/3341cca405908a19792c898b585a27ae245ed368"><code>3341cca</code></a>
chore(main): release 0.246.0 (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3262">#3262</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/61fba51991b51d84065a1c66e4a49434462d2c94"><code>61fba51</code></a>
fix(idtoken): don't assume DefaultTransport is a http.Transport (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3263">#3263</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/b792200673836a4a042bb48938dff17ee6a0954f"><code>b792200</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3261">#3261</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/ed4d4caf7f9e4cb29e0d5f629e1b3ab623f0d982"><code>ed4d4ca</code></a>
chore(main): release 0.245.0 (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3253">#3253</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/091d42217a08f1a5873cc13cfb51d4275b18e2e6"><code>091d422</code></a>
fix(gensupport): fix transferChunk race condition by returning response
with ...</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/bf38d3ad99d570f956658f9f63209a5143f94703"><code>bf38d3a</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3259">#3259</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/efc337167473eb103dbd70f9b5f9491ec1cff75c"><code>efc3371</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3257">#3257</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/83176a94b64c04b46b4926f41f5f87d7a54f71f6"><code>83176a9</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3256">#3256</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/0f103667e9560e28646edc7aa03e47e71983aae5"><code>0f10366</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3255">#3255</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/702998a9a8285e1093886fc1b0fdfbcc8112fd6f"><code>702998a</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3254">#3254</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/googleapis/google-api-go-client/compare/v0.242.0...v0.246.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=google.golang.org/api&package-manager=go_modules&previous-version=0.242.0&new-version=0.246.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 15:28:32 +00:00
Mathias Fredriksson 1b66495b70 fix(coderd/prometheusmetrics)!: filter deleted wsbuilds to reduce db load (#19197)
This change removes the `GetLatestWorkspaceBuilds` query which includes
all workspaces for all time (including deleted). This allows us to also
stop using `GetProvisionerJobsByIDs` for said builds as the job status
is included in `GetWorkspaces` called separately.

**BREAKING CHANGE**: The `coderd_api_workspace_latest_build` Prometheus
metric no longer includes builds belonging to deleted workspaces, as
such, this metric will show fewer statuses.

Fixes coder/internal#717
2025-08-11 14:48:31 +03:00
Cian Johnston 060fb57d28 chore(enterprise/coderd): ignore log errors in TestGetCryptoKeys/Unauthorized (#19282)
Fixes https://github.com/coder/internal/issues/797
2025-08-11 12:32:29 +01:00
Jakub Domeracki 5d42b1861e fix: upload the slim binaries from the build directory to the GCS bucket (#19281)
Updated the upload script to copy the slim binaries from the ./build
directory to the GCS bucket (instead of the ./site/out/bin directory)
2025-08-11 12:54:44 +02:00
Thomas Kosiewski b7e026682a fix: skip bash tests on Windows (#19277)
Adds Windows compatibility to toolsdk tests

This PR adds Windows compatibility to the toolsdk tests by:

1. Adding build constraints to exclude bash_test.go from running on
Windows
2. Skipping the WorkspaceSSHExec test on Windows platforms with a clear
message

These changes ensure tests run properly across all supported platforms.

Related to https://github.com/coder/internal/issues/798

Signed-off-by: Thomas Kosiewski <tk@coder.com>
2025-08-11 11:43:25 +02:00
Rowan Smith dadeab881b docs: fix broken link (#19275)
Fixed a broken link to the coder registry so that it correctly loads
agent modules

https://coder.com/docs/ai-coder/custom-agents
2025-08-11 13:27:30 +10:00
dependabot[bot] ab41e98180 chore: bump coder/slackme/coder from 1.0.30 to 1.0.31 in /dogfood/coder-envbuilder (#19274)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/slackme/coder&package-manager=terraform&previous-version=1.0.30&new-version=1.0.31)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 00:47:58 +00:00
dependabot[bot] 99f252f2d1 chore: bump coder/dotfiles/coder from 1.2.0 to 1.2.1 in /dogfood/coder-envbuilder (#19273)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/dotfiles/coder&package-manager=terraform&previous-version=1.2.0&new-version=1.2.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 00:46:54 +00:00
dependabot[bot] acb38b1a7e chore: bump coder/jetbrains/coder from 1.0.0 to 1.0.2 in /dogfood/coder (#19272)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/jetbrains/coder&package-manager=terraform&previous-version=1.0.0&new-version=1.0.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 00:46:38 +00:00
dependabot[bot] 7b877310b5 chore: bump coder/git-clone/coder from 1.1.0 to 1.1.1 in /dogfood/coder (#19271)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/git-clone/coder&package-manager=terraform&previous-version=1.1.0&new-version=1.1.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 00:46:13 +00:00
ケイラ 4f1db8b866 chore: upgrade to storybook 9 (#18983) 2025-08-08 14:36:27 -06:00
Steven Masley ce935657f6 test: start migrating dbauthz tests to mocked db (#19257)
This PR adds a framework to move to a mocked db. And therefore massively speed up these tests.
2025-08-08 13:46:24 -05:00
Cian Johnston 155c7bbc65 chore(coderd/provisionerdserver): avoid fk error on invalid ai_task_sidebar_app_id (#19253)
This is a workaround for https://github.com/coder/coder/issues/18776

We avoid the foreign key issue by checking the previously inserted
workspace applications before calling UpdateWorkspaceAITask. Now,
affected workspaces will show as "not running an AI task" on the single
task view, which is technically correct.

We also insert a provisioner job log at WARN level to ensure that the
user sees some information that they have run into this issue, as well
as logging on the server side.

Longer term, we plan to modify how the workspace tasks view is
presented. This is a stopgap measure until we solidify that plan.

NOTE: this does **not** address the fact that stopping a workspace with
`has_ai_task: true` will result in the completed stop build no longer
having `has_ai_task: true`, resulting in tasks "disappearing" on stop.
2025-08-08 18:06:32 +01:00
Cian Johnston afb54f6884 chore: revert feat(enterprise/coderd): allow system users to be added to groups (#19254)
This reverts commit b200fc8e67
(https://github.com/coder/coder/pull/18341).
2025-08-08 12:18:07 +01:00
Sas Swart b200fc8e67 feat(enterprise/coderd): allow system users to be added to groups (#18341)
closes https://github.com/coder/coder/issues/18274

This pull request makes system users visible in various group related
queries so that they can be added to and removed from groups. This
allows system user quotas to be configured. System users are still
ignored in certain queries, such as when license seat consumption is
determined.

This pull request further ensures the existence of a
"coder_prebuilt_workspaces" group in any organization that needs
prebuilt workspaces

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
  * Organization and group member listings now include system users.
* **Bug Fixes**
* Updated tests to reflect the inclusion of system users in member and
group queries.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-08 11:03:17 +02:00
Rowan Smith bdde9828b4 docs: fix marketplace links for GCP (#19250) 2025-08-08 16:00:09 +10:00
ケイラ 7bb52e1f8a test: add tests for updating workspace acl (#19240) 2025-08-07 17:09:46 -06:00
ケイラ d1e64affd6 refactor: migrate Abbr to Tailwind (#19242) 2025-08-07 15:27:49 -06:00
Michael Smith 5225c5671d fix(site): add tests for createMockWebSocket (#19172)
Needed for https://github.com/coder/coder/pull/19126 and
https://github.com/coder/coder/pull/18679

## Changes made
- Moved `createWebSocket` to dedicated file and addressed edge cases for
making it a reliable mock
- Added test cases to validate mock functionality
2025-08-07 16:54:50 -04:00
Steven Masley 0a3afeddc8 chore: add more pprof labels for various go routines (#19243)
- ReplicaSync
- Notifications
- MetricsAggregator
- DBPurge
2025-08-07 20:05:32 +00:00
Yevhenii Shcherbina c65996a041 feat: add user_secrets table (#19162)
Closes https://github.com/coder/internal/issues/780

## Summary of changes:
- added `user_secrets` table
- `user_secrets` table contains `env_name` and `file_path` fields which
are not used at the moment, but will be used in later PRs
- `user_secrets` table doesn't contain `value_key_id`, I will add it in
a separate migration in a dbcrypt PR
- on one hand I don't want to add fields which are not used (because
it's a risk smth may change in implementation later), on the other hand
I don't want to add too many migrations for user secrets table
- added unique sql indexes
- added sql queries for CRUD operations on user-secrets
- introduced new `ResourceUserSecret` resource
- basic unit-tests for CRUD ops and authorization behavior
- Role updates:
  - owner:
    - remove `ResourceUserSecret` from site-wide perms
    - add `ResourceUserSecret` to user-wide perms
   - orgAdmin
- remove `ResourceUserSecret` from org-wide perms; seems it's not
strictly required, because `ResourceUserSecret` is not tied to
organization in dbauthz wrappers?
   - memberRole
- no need to change memberRole because it implicitly has access to
user-secrets thanks to the `allPermsExcept`
   - is it enough changes to roles?
   
Main questions:
- [ ] We will have 2 migrations for user-secrets:
  - initial migration (in current PR)
  - adding `value_key_id` in dbcrypt PR
  - is this approach reasonable?
- [ ] Are changes to roles's permissions are correct?
- [ ] Are changes in roles_test.go are correct?

---------

Co-authored-by: Steven Masley <Emyrk@users.noreply.github.com>
2025-08-07 15:58:59 -04:00
Steven Masley 34c46c0748 chore: rename service -> coder_service, remove agent_id label (#19241)
Pyroscope uses `service` tag for top level distinction. So move our
`service` -> `coder_service`
2025-08-07 13:58:39 -05:00
Andrew Aquino b8851f03e3 fix: prevent horizontal form section info from overlapping form fields (#19189)
...on screens that are not wide enough to accommodate 2-column layout.

closes #19055 

Sticky positioning on form section info still works as expected on
desktop:


https://github.com/user-attachments/assets/e8f5b364-d20e-4248-acc6-848293947c92

Sticky positioning is no longer applied to form section info on
tablet/mobile:


https://github.com/user-attachments/assets/c52c6b04-7b73-457e-9d9e-0b461fff56ac
2025-08-07 11:08:23 -07:00
Steven Masley 8ba8b4f061 chore: add profiling labels for pprof analysis (#19232)
PProf labels segment the code into groups for determing the source of
cpu/memory profiles. Since the web server and background jobs share a
lot of the same code (eg wsbuilder), it helps to know if the load is
user induced, or background job based.
2025-08-07 11:21:17 -05:00
ケイラ 26458cd6f0 refactor: consolidate template and workspace acl validation (#19192) 2025-08-07 10:14:58 -06:00
Danielle Maywood 02de067d46 refactor(site): remove usage of throw in TaskApps.tsx (#19235) 2025-08-07 17:03:51 +01:00
Danielle Maywood ffbd58336a fix(site): fix render crash when no embedded apps are defined for task (#19215)
Fixes https://github.com/coder/coder/issues/19101

We now gracefully handle the scenario where there are no embedded apps
defined for a task.
2025-08-07 14:24:23 +01:00
Spike Curtis 6ba55213fb test: fix timeout on TestServer_X11_EvictionLRU (#19217)
fixes https://github.com/coder/internal/issues/878

On my dev system it takes 900ms, but looking at timestamps in CI it took
25 seconds. Bumping timeout to 60s.

Also fixes the segfault.
2025-08-07 16:40:38 +04:00
Marcin Tojek 2851d9f3ea fix: return empty array if no option multi-selected (#19224)
Related: https://github.com/coder/coder/issues/19145
2025-08-07 11:37:58 +00:00
Spike Curtis 91780db1fe fix: upgrade to 1.24.6 to fix race in lib/pq queries (#19214)
fixes: https://github.com/coder/internal/issues/731

THIS IS A SECURITY FIX

upgrade to go 1.24.6 to avoid https://github.com/golang/go/issues/74831 (CVE-2025-47907)

Also points to a new version of our lib/pq fork that worked around the Go issue, which should restore better performance.
2025-08-07 13:49:51 +04:00
Dean Sheather 82d5a20762 fix: fix flake in workspace TTL test caused by new constraint (#19213) 2025-08-07 07:16:01 +00:00
Ethan 99d75cc000 fix: use system context for querying workspaces when deleting users (#19211)
Closes #19209.

In `templates.go`, we do this to make sure we count ALL workspaces for a template before we try and delete that template:
https://github.com/coder/coder/blob/dc598856e3be0926573dbbe2ec680e95a139093a/coderd/templates.go#L81-L99

However, we weren't doing the same when attempting to delete users, leading to the linked issue. We can solve the issue the same way as we do for templates.
2025-08-07 16:31:27 +10:00
Dean Sheather 9edca92c74 fix: fix incorrect migration in constraint (#19212) 2025-08-07 06:19:00 +00:00
Dean Sheather dc598856e3 chore: improve build deadline code (#19203)
- Adds/improves a lot of comments to make the autostop calculation code
clearer
- Changes the behavior of the enterprise template schedule store to
match the behavior of the workspace TTL endpoint when the new TTL is
zero
- Fixes a bug in the workspace TTL endpoint where it could unset the
build deadline, even though a max_deadline was specified
- Adds a new constraint to the workspace_builds table that enforces the
deadline is non-zero and below the max_deadline if it is set
- Adds CHECK constraint enum generation to scripts/dbgen, used for
testing the above constraint
- Adds Dean and Danielle as CODEOWNERS for the autostop calculation code
2025-08-07 11:00:31 +10:00
Steven Masley ec3b8cea91 chore: add quick filter option for authored templates (#19206) 2025-08-06 17:26:17 -05:00
Marcin Tojek a7fac302bb feat: implement rich multi-selector (#19201)
Fixes: https://github.com/coder/coder/issues/19182
2025-08-06 23:03:51 +02:00
Stephen Kirby 9505ecc73d feat(docs): promote dynamic parameters doc to GA (#19171) 2025-08-06 14:21:58 -05:00
Steven Masley a2e8aa9c28 chore: update coder/preview to v1.0.3 to fix nil ptr deref (#19205)
Woul happen in empty plans, AKA templates with 0 terraform content
2025-08-06 12:40:09 -05:00
Danielle Maywood 1c70d32ef3 fix(site): hide "Show parent apps" when no running or starting devcontainers (#19200)
Fixes https://github.com/coder/coder/issues/19199

We now hide the "Show parent apps" button when there are no running or
starting devcontainers.
2025-08-06 18:24:38 +01:00
Steven Masley 3024bdebcb chore: support 'me' as the username for template author (#19204)
`author:me` to find my templates. Much nicer than knowing my own
username
2025-08-06 11:45:07 -05:00
Steven Masley 5b80c47e8c feat: add author filter command to template filtering (#19202)
Can do `author:username` to filter templates created by a certain
author. Adding to help clean out some templates that I created on our
dev instance. This makes sorting a bit easier.
2025-08-06 10:41:01 -05:00
Jakub Domeracki 408e19fd98 fix: adjust the condition to actually run this step from release branches (#19187)
fix: adjust the condition to actually run this step from release branches
2025-08-06 10:06:23 +02:00
ケイラ 5c88d93207 chore: update to node 20.19.4 (#19188) 2025-08-06 08:19:02 +02:00
Stephen Kirby a2fc26114c chore(docs): update calendar and helm install docs for v2.25.0 (#19186)
Co-authored-by: M Atif Ali <atif@coder.com>
2025-08-06 02:40:40 +00:00
Steven Masley 4ba93824f9 chore(helm): make coder pprof endpoint available externally (#19185)
PProf is still disabled by default
2025-08-05 14:19:57 -05:00
Danielle Maywood cc609cbd53 fix(site): display tasks link when no templates contain an AI task (#19184)
Fixes https://github.com/coder/coder/issues/19059

This change ensures we always show the "Tasks" link, even when a deployment doesn't yet have a tasks template set up.
2025-08-05 19:30:17 +01:00
Danielle Maywood 760dc8b467 fix(agent/agentcontainers): fix TestDevcontainerDiscovery/AutoStart flake (#19179)
Fixes https://github.com/coder/internal/issues/864
2025-08-05 13:58:55 +01:00
Ethan 8b66a5ad59 chore(codersdk/workspacesdk): make dialer fail fast for authnz errors (#19173)
Closes #18599.

The linked issue was created due to me assuming the dialer didn't fail fast at all. In reality, it does fail fast, but only for a select few status codes. Auth[n|z] errors aren't any of those status codes, despite being 'permanent' in the same way a `400` is.
This PR makes 401* and 403 'permanent' errors, meaning the dialer will give up immediately after receiving them from coderd.

*One reason to receive a 401 is when the supplied resume_token is invalid. These are not permanent errors, and when we encounter those the dialer will retain the existing behaviour of unsetting the resume token and retrying.
2025-08-05 17:52:22 +10:00
Spike Curtis 7eb41193f8 test: fix TestSSHServer_ClosesStdin to handle non-atomic write (#19174)
fixes https://github.com/coder/internal/issues/863

We read an output file in a loop, but this could lead to races where the other process has created the file but not written, or a partial write in progress.  Fix is to retry if the content is shorter than we expect.
2025-08-05 11:36:21 +04:00
Cian Johnston b0ba798f78 chore(coderd/provisionerdserver): remove dangerous usage of dbtestutil.DisableForeignKeysAndTriggers (#19122)
May have caught https://github.com/coder/coder/issues/18776
2025-08-04 21:51:33 +01:00
Jakub Domeracki d05a15cb12 fix: adjust the kubectl exec example (#19148)
Current example fails since kubectl version 1.31:
```sh
$ kubectl exec -it deployment/coder /bin/bash -n coder
error: exec [POD] [COMMAND] is not supported anymore. Use exec [POD] -- [COMMAND] instead
```

The legacy syntax was removed in:
https://github.com/kubernetes/kubernetes/pull/125437
2025-08-04 21:24:09 +02:00
Hugo Dutka c94333d9b5 docs: oauth2-provider fixes (#19170)
Adds the oauth2-provider doc page to the manifest so it's rendered in
the docs, fixes formatting in the oauth2-provider doc, and links to it
from the MCP doc.

To see the formatting issues, visit
https://coder.com/docs/@4bcf44a/admin/integrations/oauth2-provider. To
see the doc after the fixes, visit
https://coder.com/docs/@f05969a/admin/integrations/oauth2-provider.
2025-08-04 21:20:51 +02:00
Thomas Kosiewski 247efc0dcc docs: add OAuth2 provider experimental feature documentation (#19165)
# Add OAuth2 Provider Documentation

This PR adds comprehensive documentation for the experimental OAuth2
Provider feature, which allows Coder to function as an OAuth2
authorization server. The documentation covers:

- Feature overview and experimental status warning
- Setup requirements and enabling the feature
- Methods for creating OAuth2 applications (UI and API)
- Integration patterns including standard OAuth2 and PKCE flows
- Discovery endpoints and token management
- Testing and development guidance
- Troubleshooting common issues
- Security considerations and current limitations

The documentation is marked as experimental and includes appropriate
warnings about production usage.

Signed-off-by: Thomas Kosiewski <tk@coder.com>
2025-08-04 20:17:47 +02:00
35C4n0r dc395c3b51 chore: add openai icon (#19118)
Co-authored-by: ケイラ <mckayla@hey.com>
2025-08-04 11:42:16 -06:00
Hugo Dutka a02d1c1e59 docs: document how to start a remote MCP Coder server (#19150)
Document how to start a remote MCP Coder server. Addresses
https://github.com/coder/internal/issues/823.
2025-08-04 18:53:12 +02:00
Phorcys 75749efec7 chore: update diagrams to meet new branding (#19164) 2025-08-04 16:52:51 +00:00
Jon Ayers 8a8c13382e feat: update form-data dependency to 4.0.4 (#19128) 2025-08-04 12:42:50 -04:00
dependabot[bot] 06eaa006ea chore: bump github.com/prometheus/client_golang from 1.22.0 to 1.23.0 (#19159)
Bumps
[github.com/prometheus/client_golang](https://github.com/prometheus/client_golang)
from 1.22.0 to 1.23.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/prometheus/client_golang/releases">github.com/prometheus/client_golang's
releases</a>.</em></p>
<blockquote>
<h2>v1.23.0 - 2025-07-30</h2>
<ul>
<li>[CHANGE] Minimum required Go version is now 1.23, only the two
latest Go versions are supported from now on. <a
href="https://redirect.github.com/prometheus/client_golang/issues/1812">#1812</a></li>
<li>[FEATURE] Add WrapCollectorWith and WrapCollectorWithPrefix <a
href="https://redirect.github.com/prometheus/client_golang/issues/1766">#1766</a></li>
<li>[FEATURE] Add exemplars for native histograms <a
href="https://redirect.github.com/prometheus/client_golang/issues/1686">#1686</a></li>
<li>[ENHANCEMENT] exp/api: Bubble up status code from writeResponse <a
href="https://redirect.github.com/prometheus/client_golang/issues/1823">#1823</a></li>
<li>[ENHANCEMENT] collector/go: Update runtime metrics for Go v1.23 and
v1.24 <a
href="https://redirect.github.com/prometheus/client_golang/issues/1833">#1833</a></li>
<li>[BUGFIX] exp/api: client prompt return on context cancellation <a
href="https://redirect.github.com/prometheus/client_golang/issues/1729">#1729</a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/prometheus/client_golang/blob/main/CHANGELOG.md">github.com/prometheus/client_golang's
changelog</a>.</em></p>
<blockquote>
<h2>1.23.0 / 2025-07-30</h2>
<ul>
<li>[CHANGE] Minimum required Go version is now 1.23, only the two
latest Go versions are supported from now on. <a
href="https://redirect.github.com/prometheus/client_golang/issues/1812">#1812</a></li>
<li>[FEATURE] Add WrapCollectorWith and WrapCollectorWithPrefix <a
href="https://redirect.github.com/prometheus/client_golang/issues/1766">#1766</a></li>
<li>[FEATURE] Add exemplars for native histograms <a
href="https://redirect.github.com/prometheus/client_golang/issues/1686">#1686</a></li>
<li>[ENHANCEMENT] exp/api: Bubble up status code from writeResponse <a
href="https://redirect.github.com/prometheus/client_golang/issues/1823">#1823</a></li>
<li>[ENHANCEMENT] collector/go: Update runtime metrics for Go v1.23 and
v1.24 <a
href="https://redirect.github.com/prometheus/client_golang/issues/1833">#1833</a></li>
<li>[BUGFIX] exp/api: client prompt return on context cancellation <a
href="https://redirect.github.com/prometheus/client_golang/issues/1729">#1729</a></li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/prometheus/client_golang/commit/e4b2208dd8cb6d1425f00250db842ec3c1e8749e"><code>e4b2208</code></a>
Cut v1.23.0 (<a
href="https://redirect.github.com/prometheus/client_golang/issues/1848">#1848</a>)</li>
<li><a
href="https://github.com/prometheus/client_golang/commit/d9492afd3a6f2e9782a7fc10363281bfd5b743bb"><code>d9492af</code></a>
cut v1.23.0-rc.1 (<a
href="https://redirect.github.com/prometheus/client_golang/issues/1842">#1842</a>)</li>
<li><a
href="https://github.com/prometheus/client_golang/commit/aeae8a0b4f54a8fa720d19b88638a2d048596f82"><code>aeae8a0</code></a>
Cut v1.23.0-rc.0 (<a
href="https://redirect.github.com/prometheus/client_golang/issues/1837">#1837</a>)</li>
<li><a
href="https://github.com/prometheus/client_golang/commit/b157309b723f0b8588ea604bb78dbbba196803f2"><code>b157309</code></a>
Update common Prometheus files (<a
href="https://redirect.github.com/prometheus/client_golang/issues/1832">#1832</a>)</li>
<li><a
href="https://github.com/prometheus/client_golang/commit/a704e287f467b79744c30af996b7d710d4c6900d"><code>a704e28</code></a>
build(deps): bump the github-actions group with 3 updates (<a
href="https://redirect.github.com/prometheus/client_golang/issues/1826">#1826</a>)</li>
<li><a
href="https://github.com/prometheus/client_golang/commit/c7743110ad2c599de3d8c23682d978a12f9f36d1"><code>c774311</code></a>
Fix errNotImplemented reference (<a
href="https://redirect.github.com/prometheus/client_golang/issues/1835">#1835</a>)</li>
<li><a
href="https://github.com/prometheus/client_golang/commit/db4db7bb0065a76c75b7df6f61d2cf183ecfc473"><code>db4db7b</code></a>
Update runtime metrics for Go v1.23 and v1.24 (<a
href="https://redirect.github.com/prometheus/client_golang/issues/1833">#1833</a>)</li>
<li><a
href="https://github.com/prometheus/client_golang/commit/99d380ebfe865ae2c973c80184bc97ac0d98f083"><code>99d380e</code></a>
Update common Prometheus files (<a
href="https://redirect.github.com/prometheus/client_golang/issues/1831">#1831</a>)</li>
<li><a
href="https://github.com/prometheus/client_golang/commit/f3ef320dcde30f31188c577ad71e6480e91bf464"><code>f3ef320</code></a>
Merge pull request <a
href="https://redirect.github.com/prometheus/client_golang/issues/1828">#1828</a>
from prometheus/dependabot/go_modules/exp/github.com...</li>
<li><a
href="https://github.com/prometheus/client_golang/commit/520c91ae841ff7264b5379fe85e6215fc62734a6"><code>520c91a</code></a>
build(deps): bump github.com/prometheus/common in /exp</li>
<li>Additional commits viewable in <a
href="https://github.com/prometheus/client_golang/compare/v1.22.0...v1.23.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/prometheus/client_golang&package-manager=go_modules&previous-version=1.22.0&new-version=1.23.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 15:57:47 +00:00
dependabot[bot] 83aafd8238 chore: bump google.golang.org/grpc from 1.73.0 to 1.74.2 (#19158)
Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from
1.73.0 to 1.74.2.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/grpc/grpc-go/releases">google.golang.org/grpc's
releases</a>.</em></p>
<blockquote>
<h2>Release 1.74.2</h2>
<h1>New Features</h1>
<ul>
<li>grpc: introduce new <code>DialOptions</code> and
<code>ServerOptions</code> (<code>WithStaticStreamWindowSize</code>,
<code>WithStaticConnWindowSize</code>,
<code>StaticStreamWindowSize</code>, <code>StaticConnWindowSize</code>)
that force fixed window sizes for all HTTP/2 connections. By default,
gRPC uses dynamic sizing of these windows based upon a BDP estimation
algorithm. The existing options (<code>WithInitialWindowSize</code>,
etc) also disable BDP estimation, but this behavior will be changed in a
following release. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8283">#8283</a>)</li>
</ul>
<h1>API Changes</h1>
<ul>
<li>balancer: add <code>ExitIdle</code> method to <code>Balancer</code>
interface. Earlier, implementing this method was optional. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8367">#8367</a>)</li>
</ul>
<h1>Behavior Changes</h1>
<ul>
<li>xds: Remove the <code>GRPC_EXPERIMENTAL_ENABLE_LEAST_REQUEST</code>
environment variable that allows disabling the least request balancer
with xDS. Least request was made available by default with xDS in
v1.72.0. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8248">#8248</a>)
<ul>
<li>Special Thanks: <a
href="https://github.com/atollena"><code>@​atollena</code></a></li>
</ul>
</li>
<li>server: allow 0s grpc-timeout header values, which older gRPC-Java
versions could send. This restores the behavior of grpc-go before
v1.73.0. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8439">#8439</a>)</li>
</ul>
<h1>Bug Fixes</h1>
<ul>
<li>googledirectpath: avoid logging the error message <code>Attempt to
set a bootstrap configuration...</code> when creating multiple
directpath channels. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8419">#8419</a>)</li>
</ul>
<h1>Performance Improvements</h1>
<ul>
<li>transport: reduce heap allocations by pooling objects and avoiding
method-to-closure conversions. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8361">#8361</a>)</li>
<li>transport: reduce heap allocations by re-using
<code>mem.Reader</code> objects. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8360">#8360</a>)</li>
</ul>
<h1>Documentation</h1>
<ul>
<li>examples: add examples to demonstrate enabling experimental metrics
using the OpenTelemetry plugin. (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8388">#8388</a>)
<ul>
<li>Special Thanks: <a
href="https://github.com/vinothkumarr227"><code>@​vinothkumarr227</code></a></li>
</ul>
</li>
</ul>
<h2>Release 1.74.1</h2>
<p>Version 1.74.1 retracts release v1.74.0 and itself. Release 1.74.0
was accidentally tagged on the wrong commit and should not be used.
Version 1.73.0 should be used until 1.74.2 is released.</p>
<p>Release 1.74.0 was accidentally tagged on the wrong commit and should
not be used. Version 1.73.0 should be used until 1.74.1 is released.</p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/grpc/grpc-go/commit/e9e00cb28e350d6440145d883d1d6cf675f3c0f3"><code>e9e00cb</code></a>
Change version to 1.74.2 (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8470">#8470</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/bd7cb0a95b518e3f987cccbc44b4ba9a0e51eb80"><code>bd7cb0a</code></a>
Change version to 1.74.2-dev (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8461">#8461</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/002a22c03ed5cb1068ab800fc329c1f199037b63"><code>002a22c</code></a>
Change version to 1.74.1 (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8455">#8455</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/6e8e7e48d13e1891e0f3b5df22f16746edb6e788"><code>6e8e7e4</code></a>
Retract v1.74.0 and v1.74.1 (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8457">#8457</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/48c9e4d1eee9b075a1855dadc24f66157dbf60b3"><code>48c9e4d</code></a>
Change version to 1.74.1-dev (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8408">#8408</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/b8b6cffbb2a9c5dc41fd7ab902b4a0cc37c05b19"><code>b8b6cff</code></a>
Change version to 1.74.0 (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8407">#8407</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/077e2c37bd9f14b1300e3d1feedd431d105895c0"><code>077e2c3</code></a>
Cherry-pick <a
href="https://redirect.github.com/grpc/grpc-go/issues/8411">#8411</a>,
<a
href="https://redirect.github.com/grpc/grpc-go/issues/8419">#8419</a>,
<a
href="https://redirect.github.com/grpc/grpc-go/issues/8422">#8422</a>,
<a href="https://redirect.github.com/grpc/grpc-go/issues/8445">#8445</a>
and <a
href="https://redirect.github.com/grpc/grpc-go/issues/8451">#8451</a> to
v1.74.x (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8454">#8454</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/b34f845d7056a2e052ddb4e99d9d691bf69159bf"><code>b34f845</code></a>
server: allow 0s grpc-timeout header values, as java is known to be able
to s...</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/1787f9427568898e905841f40798bbb78c8dd52c"><code>1787f94</code></a>
xdsclient: export genericResourceTypeDecoder (<a
href="https://redirect.github.com/grpc/grpc-go/issues/8406">#8406</a>)</li>
<li><a
href="https://github.com/grpc/grpc-go/commit/15299ccca32bba47c533b0a8e8ba2564a29d71db"><code>15299cc</code></a>
xdsclient: make a function to return the supported resource type
implementati...</li>
<li>Additional commits viewable in <a
href="https://github.com/grpc/grpc-go/compare/v1.73.0...v1.74.2">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=google.golang.org/grpc&package-manager=go_modules&previous-version=1.73.0&new-version=1.74.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 15:46:34 +00:00
dependabot[bot] 1ae5cac7b6 chore: bump github.com/aws/aws-sdk-go-v2/config from 1.29.14 to 1.30.2 (#19154)
Bumps
[github.com/aws/aws-sdk-go-v2/config](https://github.com/aws/aws-sdk-go-v2)
from 1.29.14 to 1.30.2.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/383fd26928547348efed0ee1f8914d9e7a1b0287"><code>383fd26</code></a>
Release 2024-07-10</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/4a055f9d9e17eb7ef2206e8e37ba98d661d13e6a"><code>4a055f9</code></a>
Regenerated Clients</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/e3457953351e6993f57f5ab8e373af8af70be45b"><code>e345795</code></a>
Update endpoints model</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/52a10ac239cc1aab2d070fbb004f6445ca0ddcc0"><code>52a10ac</code></a>
Update API model</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/adab0de9e4ae75aee4f894c99fd1e2ce2de0035e"><code>adab0de</code></a>
remove unused jmespath dependency from main module (<a
href="https://redirect.github.com/aws/aws-sdk-go-v2/issues/2707">#2707</a>)</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/0e07cc82b25692dce8f68e0b5bd0d0c5cdbcd279"><code>0e07cc8</code></a>
Release 2024-07-09</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/5e3583451cd8a91dbca2cc22672c2cfa0c7860cf"><code>5e35834</code></a>
Regenerated Clients</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/a2a28a1eec2a1b6f12f813e4900430a9cc79b6c2"><code>a2a28a1</code></a>
Update endpoints model</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/f5489732257180b7c19456abb050214c2f5cac26"><code>f548973</code></a>
Update API model</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/e7aad565a65dab9b37da7b49c1c79a699c49d85e"><code>e7aad56</code></a>
Release 2024-07-08</li>
<li>Additional commits viewable in <a
href="https://github.com/aws/aws-sdk-go-v2/compare/config/v1.29.14...v1.30.2">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/aws/aws-sdk-go-v2/config&package-manager=go_modules&previous-version=1.29.14&new-version=1.30.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 15:34:39 +00:00
dependabot[bot] 181c2f00ae chore: bump github.com/coreos/go-oidc/v3 from 3.14.1 to 3.15.0 (#19156)
Bumps [github.com/coreos/go-oidc/v3](https://github.com/coreos/go-oidc)
from 3.14.1 to 3.15.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/coreos/go-oidc/releases">github.com/coreos/go-oidc/v3's
releases</a>.</em></p>
<blockquote>
<h2>v3.15.0</h2>
<h2>What's Changed</h2>
<ul>
<li>oidc: verify the ID Token's signature before processing claims by <a
href="https://github.com/ericchiang"><code>@​ericchiang</code></a> in <a
href="https://redirect.github.com/coreos/go-oidc/pull/464">coreos/go-oidc#464</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/coreos/go-oidc/compare/v3.14.1...v3.15.0">https://github.com/coreos/go-oidc/compare/v3.14.1...v3.15.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/coreos/go-oidc/commit/8d1e57e7e7fb4db0bac61cc200d43846ba071977"><code>8d1e57e</code></a>
oidc: verify the ID Token's signature before processing claims</li>
<li>See full diff in <a
href="https://github.com/coreos/go-oidc/compare/v3.14.1...v3.15.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/coreos/go-oidc/v3&package-manager=go_modules&previous-version=3.14.1&new-version=3.15.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 15:29:10 +00:00
dependabot[bot] ce9b20867d chore: bump github.com/fergusstrange/embedded-postgres from 1.31.0 to 1.32.0 (#19155)
Bumps
[github.com/fergusstrange/embedded-postgres](https://github.com/fergusstrange/embedded-postgres)
from 1.31.0 to 1.32.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/fergusstrange/embedded-postgres/releases">github.com/fergusstrange/embedded-postgres's
releases</a>.</em></p>
<blockquote>
<h2>v1.32.0</h2>
<h2>What's Changed</h2>
<ul>
<li>Ensure target directories exist before extraction and add test for
runtime path creation by <a
href="https://github.com/fergusstrange"><code>@​fergusstrange</code></a>
in <a
href="https://redirect.github.com/fergusstrange/embedded-postgres/pull/158">fergusstrange/embedded-postgres#158</a></li>
<li>Add support for Postgres 17 and update default version by <a
href="https://github.com/fergusstrange"><code>@​fergusstrange</code></a>
in <a
href="https://redirect.github.com/fergusstrange/embedded-postgres/pull/159">fergusstrange/embedded-postgres#159</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/fergusstrange/embedded-postgres/compare/v1.31.0...v1.32.0">https://github.com/fergusstrange/embedded-postgres/compare/v1.31.0...v1.32.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/fergusstrange/embedded-postgres/commit/0c7d03d6005dda276bcf9041c9be89ebe86c34e1"><code>0c7d03d</code></a>
Add support for Postgres 17 and update default version (<a
href="https://redirect.github.com/fergusstrange/embedded-postgres/issues/159">#159</a>)</li>
<li><a
href="https://github.com/fergusstrange/embedded-postgres/commit/bab016e3d52239a871b12798f6ddbeefc9d2045a"><code>bab016e</code></a>
Ensure target directories exist before extraction and add test for
runtime pa...</li>
<li>See full diff in <a
href="https://github.com/fergusstrange/embedded-postgres/compare/v1.31.0...v1.32.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/fergusstrange/embedded-postgres&package-manager=go_modules&previous-version=1.31.0&new-version=1.32.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 15:26:10 +00:00
dependabot[bot] b4f241391b chore: bump github.com/aws/aws-sdk-go-v2 from 1.36.4 to 1.37.1 (#19151)
Bumps
[github.com/aws/aws-sdk-go-v2](https://github.com/aws/aws-sdk-go-v2)
from 1.36.4 to 1.37.1.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/67148dbe156c9519ccc35f7e46f1df7367c67b81"><code>67148db</code></a>
Release 2025-07-30</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/b21029eeb2699fcba879fd3639464fbb887c0178"><code>b21029e</code></a>
Regenerated Clients</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/6c2dde6522c75df1cfeb807e6f7823f644298d78"><code>6c2dde6</code></a>
Update endpoints model</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/7b710ac3e2a805dc0c2efa8bead2abb66bfe6169"><code>7b710ac</code></a>
Update API model</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/179df1ca8e873d6374f4739e6bab67f3ed62a3c0"><code>179df1c</code></a>
update CONTRIBUTING.md</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/456e51a2895e2ce6c712cebacebb10ad5a8f359e"><code>456e51a</code></a>
fix changelog</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/4ce8fece3fe625af2d8db3d673fcc8265af50485"><code>4ce8fec</code></a>
Join errors when retry token is unavailable (<a
href="https://redirect.github.com/aws/aws-sdk-go-v2/issues/3121">#3121</a>)</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/1eea3dbe07dffcef2fdba6f8e2206b32b91d8a83"><code>1eea3db</code></a>
Release 2025-07-29</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/b63d556f10e3a6a6a48458eeaf5b288feef79c58"><code>b63d556</code></a>
Regenerated Clients</li>
<li><a
href="https://github.com/aws/aws-sdk-go-v2/commit/1258955cdd238d60ed14ed5ce44cedd6e514f41c"><code>1258955</code></a>
Update endpoints model</li>
<li>Additional commits viewable in <a
href="https://github.com/aws/aws-sdk-go-v2/compare/v1.36.4...v1.37.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/aws/aws-sdk-go-v2&package-manager=go_modules&previous-version=1.36.4&new-version=1.37.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 15:21:27 +00:00
Danielle Maywood b8e2344ef5 chore(agent/agentcontainers): disable project autostart by default (#19114)
We disable the logic that allows autostarting discovered devcontainers
by default. We want this behavior to be opt-in rather than opt-out.

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-08-04 16:21:13 +01:00
dependabot[bot] 8f538d4412 chore: bump github.com/mark3labs/mcp-go from 0.34.0 to 0.36.0 (#19152)
Bumps [github.com/mark3labs/mcp-go](https://github.com/mark3labs/mcp-go)
from 0.34.0 to 0.36.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/mark3labs/mcp-go/releases">github.com/mark3labs/mcp-go's
releases</a>.</em></p>
<blockquote>
<h2>Release v0.36.0</h2>
<h2>What's Changed</h2>
<ul>
<li>Add defs field to ToolsInputSchema by <a
href="https://github.com/ostafen"><code>@​ostafen</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/488">mark3labs/mcp-go#488</a></li>
<li>Remove <code>sampling_server</code> binary file by <a
href="https://github.com/JeffreyCA"><code>@​JeffreyCA</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/512">mark3labs/mcp-go#512</a></li>
<li>chore: remove comments related to JSON-Batching by <a
href="https://github.com/cryo-zd"><code>@​cryo-zd</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/514">mark3labs/mcp-go#514</a></li>
<li>feat: support structured content and output schema by <a
href="https://github.com/pottekkat"><code>@​pottekkat</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/460">mark3labs/mcp-go#460</a></li>
<li>Hide error log when it's not useful by <a
href="https://github.com/dgageot"><code>@​dgageot</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/517">mark3labs/mcp-go#517</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/ostafen"><code>@​ostafen</code></a> made
their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/488">mark3labs/mcp-go#488</a></li>
<li><a href="https://github.com/JeffreyCA"><code>@​JeffreyCA</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/512">mark3labs/mcp-go#512</a></li>
<li><a href="https://github.com/dgageot"><code>@​dgageot</code></a> made
their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/517">mark3labs/mcp-go#517</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/mark3labs/mcp-go/compare/v0.35.0...v0.36.0">https://github.com/mark3labs/mcp-go/compare/v0.35.0...v0.36.0</a></p>
<h2>Release v0.35.0</h2>
<h2>What's Changed</h2>
<ul>
<li>Http headers by <a
href="https://github.com/adityamj"><code>@​adityamj</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/480">mark3labs/mcp-go#480</a></li>
<li>fix: check if resp is nil on error for initialize methods by <a
href="https://github.com/pottekkat"><code>@​pottekkat</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/492">mark3labs/mcp-go#492</a></li>
<li>Fix race condition in stdio.SendRequest with canceled context by <a
href="https://github.com/ezynda3"><code>@​ezynda3</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/503">mark3labs/mcp-go#503</a></li>
<li>Embed client capabilities into the Session by <a
href="https://github.com/ardaguclu"><code>@​ardaguclu</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/491">mark3labs/mcp-go#491</a></li>
<li>enhc(server): allow adding multiple resource templates at once by <a
href="https://github.com/rafaeljusto"><code>@​rafaeljusto</code></a> in
<a
href="https://redirect.github.com/mark3labs/mcp-go/pull/483">mark3labs/mcp-go#483</a></li>
<li>Get rid of binary file. by <a
href="https://github.com/wkoszek"><code>@​wkoszek</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/505">mark3labs/mcp-go#505</a></li>
<li>feat: implement protocol version negotiation by <a
href="https://github.com/ezynda3"><code>@​ezynda3</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/502">mark3labs/mcp-go#502</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/adityamj"><code>@​adityamj</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/480">mark3labs/mcp-go#480</a></li>
<li><a href="https://github.com/ardaguclu"><code>@​ardaguclu</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/491">mark3labs/mcp-go#491</a></li>
<li><a
href="https://github.com/rafaeljusto"><code>@​rafaeljusto</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/483">mark3labs/mcp-go#483</a></li>
<li><a href="https://github.com/wkoszek"><code>@​wkoszek</code></a> made
their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/505">mark3labs/mcp-go#505</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/mark3labs/mcp-go/compare/v0.34.0...v0.35.0">https://github.com/mark3labs/mcp-go/compare/v0.34.0...v0.35.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/cf352645f0aee9b9fb3dc1f735e7c5c9419a1a56"><code>cf35264</code></a>
Merge pull request <a
href="https://redirect.github.com/mark3labs/mcp-go/issues/517">#517</a>
from dgageot/remote-context-cancelled-log</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/8f9d5387d8726529763739007590b2baa380bdd2"><code>8f9d538</code></a>
feat: support structured content and output schema (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/460">#460</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/a43b1048c0c78263858b33129575e9b6c04dad4c"><code>a43b104</code></a>
chore: remove comments related to JSON-Batching (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/514">#514</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/e327695b8b1f5d84c28959fde844f67c432eb3de"><code>e327695</code></a>
Hide error when it's not useful</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/617fcf1f1599ba269e22490d291c77f0fa6a2894"><code>617fcf1</code></a>
Remove <code>sampling_server</code> binary file (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/512">#512</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/5ad6c8d86c75da25113c8a2f843cbbc0a994ba03"><code>5ad6c8d</code></a>
Add defs field to ToolsInputSchema (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/488">#488</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/3964d510cd31aada6eb553fc3d286d4842a28a56"><code>3964d51</code></a>
feat: implement protocol version negotiation (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/502">#502</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/38ac77cf9f42386f1beea4f224fa45eb9b08a926"><code>38ac77c</code></a>
Get rid of binary file. (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/505">#505</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/722d95462707280068b05f33fbd6f5ec5dba6228"><code>722d954</code></a>
enhc(server): allow adding multiple resource templates at once (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/483">#483</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/cc3f765e152630f88f224c4ba3fe867bc5bef598"><code>cc3f765</code></a>
Embed client capabilities into the Session (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/491">#491</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/mark3labs/mcp-go/compare/v0.34.0...v0.36.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/mark3labs/mcp-go&package-manager=go_modules&previous-version=0.34.0&new-version=0.36.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 15:21:04 +00:00
dependabot[bot] 5df3bf713c ci: bump the github-actions group with 6 updates (#19149)
Bumps the github-actions group with 6 updates:

| Package | From | To |
| --- | --- | --- |
|
[step-security/harden-runner](https://github.com/step-security/harden-runner)
| `2.12.2` | `2.13.0` |
| [chromaui/action](https://github.com/chromaui/action) | `13.1.2` |
`13.1.3` |
|
[google-github-actions/auth](https://github.com/google-github-actions/auth)
| `2.1.11` | `2.1.12` |
|
[tj-actions/changed-files](https://github.com/tj-actions/changed-files)
| `055970845dd036d7345da7399b7e89f2e10f2b04` |
`c2ca2493190021783138cb8aac49bcee14b4bb89` |
| [tj-actions/branch-names](https://github.com/tj-actions/branch-names)
| `8.2.1` | `9.0.2` |
| [github/codeql-action](https://github.com/github/codeql-action) |
`3.29.3` | `3.29.5` |

Updates `step-security/harden-runner` from 2.12.2 to 2.13.0
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/step-security/harden-runner/releases">step-security/harden-runner's
releases</a>.</em></p>
<blockquote>
<h2>v2.13.0</h2>
<h2>What's Changed</h2>
<ul>
<li>Improved job markdown summary</li>
<li>Https monitoring for all domains (included with the enterprise
tier)</li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/step-security/harden-runner/compare/v2...v2.13.0">https://github.com/step-security/harden-runner/compare/v2...v2.13.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/step-security/harden-runner/commit/ec9f2d5744a09debf3a187a3f4f675c53b671911"><code>ec9f2d5</code></a>
Merge pull request <a
href="https://redirect.github.com/step-security/harden-runner/issues/565">#565</a>
from step-security/rc-24</li>
<li><a
href="https://github.com/step-security/harden-runner/commit/04bcbc31cfcefe0cf4720832008735021cec5ec4"><code>04bcbc3</code></a>
update agent</li>
<li><a
href="https://github.com/step-security/harden-runner/commit/7c7a56fcaa124ab72fff1cc3e81257f264fd7317"><code>7c7a56f</code></a>
feat: get job summary from API</li>
<li>See full diff in <a
href="https://github.com/step-security/harden-runner/compare/v2.12.2...ec9f2d5744a09debf3a187a3f4f675c53b671911">compare
view</a></li>
</ul>
</details>
<br />

Updates `chromaui/action` from 13.1.2 to 13.1.3
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/chromaui/action/commit/58d9ffb36c90c97a02d061544ecc849cc4a242a9"><code>58d9ffb</code></a>
v13.1.3</li>
<li>See full diff in <a
href="https://github.com/chromaui/action/compare/4d8ebd13658d795114f8051e25c28d66f14886c6...58d9ffb36c90c97a02d061544ecc849cc4a242a9">compare
view</a></li>
</ul>
</details>
<br />

Updates `google-github-actions/auth` from 2.1.11 to 2.1.12
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/google-github-actions/auth/releases">google-github-actions/auth's
releases</a>.</em></p>
<blockquote>
<h2>v2.1.12</h2>
<h2>What's Changed</h2>
<ul>
<li>Add retries for getIDToken by <a
href="https://github.com/sethvargo"><code>@​sethvargo</code></a> in <a
href="https://redirect.github.com/google-github-actions/auth/pull/502">google-github-actions/auth#502</a></li>
<li>Release: v2.1.12 by <a
href="https://github.com/google-github-actions-bot"><code>@​google-github-actions-bot</code></a>
in <a
href="https://redirect.github.com/google-github-actions/auth/pull/503">google-github-actions/auth#503</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/google-github-actions/auth/compare/v2.1.11...v2.1.12">https://github.com/google-github-actions/auth/compare/v2.1.11...v2.1.12</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/google-github-actions/auth/commit/b7593ed2efd1c1617e1b0254da33b86225adb2a5"><code>b7593ed</code></a>
Release: v2.1.12 (<a
href="https://redirect.github.com/google-github-actions/auth/issues/503">#503</a>)</li>
<li><a
href="https://github.com/google-github-actions/auth/commit/c1ee334b4fb145a02e9d8343bb2e9f0dd06e586b"><code>c1ee334</code></a>
Add retries for getIDToken (<a
href="https://redirect.github.com/google-github-actions/auth/issues/502">#502</a>)</li>
<li>See full diff in <a
href="https://github.com/google-github-actions/auth/compare/140bb5113ffb6b65a7e9b937a81fa96cf5064462...b7593ed2efd1c1617e1b0254da33b86225adb2a5">compare
view</a></li>
</ul>
</details>
<br />

Updates `tj-actions/changed-files` from
055970845dd036d7345da7399b7e89f2e10f2b04 to
c2ca2493190021783138cb8aac49bcee14b4bb89
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/tj-actions/changed-files/blob/main/HISTORY.md">tj-actions/changed-files's
changelog</a>.</em></p>
<blockquote>
<h1>Changelog</h1>
<h1><a
href="https://github.com/tj-actions/changed-files/compare/v46.0.4...v46.0.5">46.0.5</a>
- (2025-04-09)</h1>
<h2><!-- raw HTML omitted -->⚙️ Miscellaneous Tasks</h2>
<ul>
<li><strong>deps:</strong> Bump yaml from 2.7.0 to 2.7.1 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2520">#2520</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/ed68ef82c095e0d48ec87eccea555d944a631a4c">ed68ef8</a>)
- (dependabot[bot])</li>
<li><strong>deps-dev:</strong> Bump typescript from 5.8.2 to 5.8.3 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2516">#2516</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/a7bc14b808f23d3b467a4079c69a81f1a4500fd5">a7bc14b</a>)
- (dependabot[bot])</li>
<li><strong>deps-dev:</strong> Bump <code>@​types/node</code> from
22.13.11 to 22.14.0 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2517">#2517</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/3d751f6b6d84071a17e1b9cf4ed79a80a27dd0ab">3d751f6</a>)
- (dependabot[bot])</li>
<li><strong>deps-dev:</strong> Bump eslint-plugin-prettier from 5.2.3 to
5.2.6 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2519">#2519</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/e2fda4ec3cb0bc2a353843cae823430b3124db8f">e2fda4e</a>)
- (dependabot[bot])</li>
<li><strong>deps-dev:</strong> Bump ts-jest from 29.2.6 to 29.3.1 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2518">#2518</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/0bed1b1132ec4879a39a2d624cf82a00d0bcfa48">0bed1b1</a>)
- (dependabot[bot])</li>
<li><strong>deps:</strong> Bump github/codeql-action from 3.28.12 to
3.28.15 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2530">#2530</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/68024587dc36f49685c96d59d3f1081830f968bb">6802458</a>)
- (dependabot[bot])</li>
<li><strong>deps:</strong> Bump tj-actions/branch-names from 8.0.1 to
8.1.0 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2521">#2521</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/cf2e39e86bf842d1f9bc5bca56c0a6b207cca792">cf2e39e</a>)
- (dependabot[bot])</li>
<li><strong>deps:</strong> Bump tj-actions/verify-changed-files from
20.0.1 to 20.0.4 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2523">#2523</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/6abeaa506a419f85fa9e681260b443adbeebb3d4">6abeaa5</a>)
- (dependabot[bot])</li>
</ul>
<h2><!-- raw HTML omitted -->⬆️ Upgrades</h2>
<ul>
<li>Upgraded to v46.0.4 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2511">#2511</a>)</li>
</ul>
<p>Co-authored-by: github-actions[bot]
&lt;41898282+github-actions[bot]<a
href="https://github.com/users"><code>@​users</code></a>.noreply.github.com&gt;
(<a
href="https://github.com/tj-actions/changed-files/commit/6f67ee9ac810f0192ea7b3d2086406f97847bcf9">6f67ee9</a>)
- (github-actions[bot])</p>
<h1><a
href="https://github.com/tj-actions/changed-files/compare/v46.0.3...v46.0.4">46.0.4</a>
- (2025-04-03)</h1>
<h2><!-- raw HTML omitted -->🐛 Bug Fixes</h2>
<ul>
<li>Bug modified_keys and changed_key outputs not set when no changes
detected (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2509">#2509</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/6cb76d07bee4c9772c6882c06c37837bf82a04d3">6cb76d0</a>)
- (Tonye Jack)</li>
</ul>
<h2><!-- raw HTML omitted -->📚 Documentation</h2>
<ul>
<li>Update readme (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2508">#2508</a>)
(<a
href="https://github.com/tj-actions/changed-files/commit/b74df86ccb65173a8e33ba5492ac1a2ca6b216fd">b74df86</a>)
- (Tonye Jack)</li>
</ul>
<h2><!-- raw HTML omitted -->⬆️ Upgrades</h2>
<ul>
<li>Upgraded to v46.0.3 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2506">#2506</a>)</li>
</ul>
<p>Co-authored-by: github-actions[bot]
&lt;41898282+github-actions[bot]<a
href="https://github.com/users"><code>@​users</code></a>.noreply.github.com&gt;
Co-authored-by: Tonye Jack <a
href="mailto:jtonye@ymail.com">jtonye@ymail.com</a> (<a
href="https://github.com/tj-actions/changed-files/commit/27ae6b33eaed7bf87272fdeb9f1c54f9facc9d99">27ae6b3</a>)
- (github-actions[bot])</p>
<h1><a
href="https://github.com/tj-actions/changed-files/compare/v46.0.2...v46.0.3">46.0.3</a>
- (2025-03-23)</h1>
<h2><!-- raw HTML omitted -->🔄 Update</h2>
<ul>
<li>Updated README.md (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2501">#2501</a>)</li>
</ul>
<p>Co-authored-by: github-actions[bot]
&lt;41898282+github-actions[bot]<a
href="https://github.com/users"><code>@​users</code></a>.noreply.github.com&gt;
(<a
href="https://github.com/tj-actions/changed-files/commit/41e0de576a0f2b64d9f06f2773f539109e55a70a">41e0de5</a>)
- (github-actions[bot])</p>
<ul>
<li>Updated README.md (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2499">#2499</a>)</li>
</ul>
<p>Co-authored-by: github-actions[bot]
&lt;41898282+github-actions[bot]<a
href="https://github.com/users"><code>@​users</code></a>.noreply.github.com&gt;
(<a
href="https://github.com/tj-actions/changed-files/commit/945787811a795cd840a1157ac590dd7827a05c8e">9457878</a>)
- (github-actions[bot])</p>
<h2><!-- raw HTML omitted -->📚 Documentation</h2>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/tj-actions/changed-files/commit/c2ca2493190021783138cb8aac49bcee14b4bb89"><code>c2ca249</code></a>
test: manual triggered workflows (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2637">#2637</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/94d97fe3f88298bf8b2f2db6fa2ab150f3c1ab77"><code>94d97fe</code></a>
chore(deps): bump tj-actions/branch-names from 9.0.1 to 9.0.2 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2636">#2636</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/18b05b98fcd9dc0bd3870d7a6571535999ba0c3f"><code>18b05b9</code></a>
chore(deps): bump github/codeql-action from 3.29.4 to 3.29.5 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2635">#2635</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/db8d0bfea5a44e51abd5dc1454386c668ae901f9"><code>db8d0bf</code></a>
chore(deps): bump tj-actions/git-cliff from 1.5.0 to 2.0.2 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2632">#2632</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/0e2e8f70c5c6854ee9ff9f94bc2f1b9e7fcead78"><code>0e2e8f7</code></a>
chore(deps): bump tj-actions/branch-names from 8.2.1 to 9.0.1 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2633">#2633</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/5f2e971c1fcf53fda99e27a542f5e79cff0e7059"><code>5f2e971</code></a>
chore(deps-dev): bump <code>@​types/node</code> from 24.0.15 to 24.1.0
(<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2626">#2626</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/498cf3f89140b3c7b8353c5ae1354765717026ad"><code>498cf3f</code></a>
chore(deps-dev): bump jest from 30.0.4 to 30.0.5 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2627">#2627</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/8378ac87b7b199cd230495c133c4f6b19215e757"><code>8378ac8</code></a>
chore(deps): bump github/codeql-action from 3.29.3 to 3.29.4 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2628">#2628</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/4bfe3cb5bd6f0db4dc8668c4d6bef45ccf2b8ab5"><code>4bfe3cb</code></a>
chore(deps): bump nrwl/nx-set-shas from 4.3.0 to 4.3.3 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2630">#2630</a>)</li>
<li><a
href="https://github.com/tj-actions/changed-files/commit/a0370f61698fcac830a08949da9fdf96ea0f3ab7"><code>a0370f6</code></a>
chore(deps): bump github/codeql-action from 3.29.2 to 3.29.3 (<a
href="https://redirect.github.com/tj-actions/changed-files/issues/2625">#2625</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/tj-actions/changed-files/compare/055970845dd036d7345da7399b7e89f2e10f2b04...c2ca2493190021783138cb8aac49bcee14b4bb89">compare
view</a></li>
</ul>
</details>
<br />

Updates `tj-actions/branch-names` from 8.2.1 to 9.0.2
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/tj-actions/branch-names/releases">tj-actions/branch-names's
releases</a>.</em></p>
<blockquote>
<h2>v9.0.2</h2>
<h2>What's Changed</h2>
<ul>
<li>Upgraded to v9.0.1 by <a
href="https://github.com/github-actions"><code>@​github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/tj-actions/branch-names/pull/424">tj-actions/branch-names#424</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/tj-actions/branch-names/compare/v9...v9.0.2">https://github.com/tj-actions/branch-names/compare/v9...v9.0.2</a></p>
<h2>v9.0.1</h2>
<h2>What's Changed</h2>
<ul>
<li>build(deps): bump tj-actions/git-cliff from 1.5.0 to 2.0.2 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/tj-actions/branch-names/pull/422">tj-actions/branch-names#422</a></li>
<li>build(deps): bump codacy/codacy-analysis-cli-action from 4.4.5 to
4.4.7 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/tj-actions/branch-names/pull/421">tj-actions/branch-names#421</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/tj-actions/branch-names/compare/v9.0.0...v9.0.1">https://github.com/tj-actions/branch-names/compare/v9.0.0...v9.0.1</a></p>
<h2>v9.0.0</h2>
<h2>What's Changed</h2>
<ul>
<li>Upgraded to v8.2.1 by <a
href="https://github.com/github-actions"><code>@​github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/tj-actions/branch-names/pull/417">tj-actions/branch-names#417</a></li>
<li>chore: update action.yml by <a
href="https://github.com/jackton1"><code>@​jackton1</code></a> in <a
href="https://redirect.github.com/tj-actions/branch-names/pull/418">tj-actions/branch-names#418</a></li>
<li>Updated README.md by <a
href="https://github.com/github-actions"><code>@​github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/tj-actions/branch-names/pull/419">tj-actions/branch-names#419</a></li>
<li>security: fix unsafe outputs by <a
href="https://github.com/jackton1"><code>@​jackton1</code></a> in <a
href="https://redirect.github.com/tj-actions/branch-names/pull/420">tj-actions/branch-names#420</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/tj-actions/branch-names/compare/v8...v9.0.0">https://github.com/tj-actions/branch-names/compare/v8...v9.0.0</a></p>
<h2>v9</h2>
<h1>Changes in v9.0.2</h1>
<h2>What's Changed</h2>
<ul>
<li>Upgraded to v9.0.1 by <a
href="https://github.com/github-actions"><code>@​github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/tj-actions/branch-names/pull/424">tj-actions/branch-names#424</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/tj-actions/branch-names/compare/v9...v9.0.2">https://github.com/tj-actions/branch-names/compare/v9...v9.0.2</a></p>
<hr />
<h1>Changes in v9.0.1</h1>
<h2>What's Changed</h2>
<ul>
<li>build(deps): bump tj-actions/git-cliff from 1.5.0 to 2.0.2 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/tj-actions/branch-names/pull/422">tj-actions/branch-names#422</a></li>
<li>build(deps): bump codacy/codacy-analysis-cli-action from 4.4.5 to
4.4.7 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/tj-actions/branch-names/pull/421">tj-actions/branch-names#421</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/tj-actions/branch-names/compare/v9.0.0...v9.0.1">https://github.com/tj-actions/branch-names/compare/v9.0.0...v9.0.1</a></p>
<hr />
<h1>Changes in v9.0.0</h1>
<h2>What's Changed</h2>
<ul>
<li>Upgraded to v8.2.1 by <a
href="https://github.com/github-actions"><code>@​github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/tj-actions/branch-names/pull/417">tj-actions/branch-names#417</a></li>
<li>chore: update action.yml by <a
href="https://github.com/jackton1"><code>@​jackton1</code></a> in <a
href="https://redirect.github.com/tj-actions/branch-names/pull/418">tj-actions/branch-names#418</a></li>
<li>Updated README.md by <a
href="https://github.com/github-actions"><code>@​github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/tj-actions/branch-names/pull/419">tj-actions/branch-names#419</a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/tj-actions/branch-names/blob/main/HISTORY.md">tj-actions/branch-names's
changelog</a>.</em></p>
<blockquote>
<h1>Changelog</h1>
<h1><a
href="https://github.com/tj-actions/branch-names/compare/v9.0.1...v9.0.2">9.0.2</a>
- (2025-07-31)</h1>
<h2><!-- raw HTML omitted -->🔄 Update</h2>
<ul>
<li>Update update-readme.yml (<a
href="https://github.com/tj-actions/branch-names/commit/5250492686b253f06fa55861556d1027b067aeb5">5250492</a>)
- (Tonye Jack)</li>
<li>Update update-readme.yml (<a
href="https://github.com/tj-actions/branch-names/commit/a2bc4958de72a5590a03c317bcb11581ae7866e7">a2bc495</a>)
- (Tonye Jack)</li>
<li>Update README.md (<a
href="https://github.com/tj-actions/branch-names/commit/169ddc10b28b8cbc75996ee56c1dbf4448ca6f06">169ddc1</a>)
- (Tonye Jack)</li>
<li>Update README.md (<a
href="https://github.com/tj-actions/branch-names/commit/4d35052be347a49c829b8a8e9855f40f14a00be6">4d35052</a>)
- (Tonye Jack)</li>
<li>Updated README.md (<a
href="https://redirect.github.com/tj-actions/branch-names/issues/423">#423</a>)</li>
</ul>
<p>Co-authored-by: github-actions[bot]
&lt;41898282+github-actions[bot]<a
href="https://github.com/users"><code>@​users</code></a>.noreply.github.com&gt;
(<a
href="https://github.com/tj-actions/branch-names/commit/6be34a848cdd6067dda01ded8bd9b0853bbe3b23">6be34a8</a>)
- (github-actions[bot])</p>
<h2><!-- raw HTML omitted -->⬆️ Upgrades</h2>
<ul>
<li>Upgraded from v9.0.0 -&gt; v9.0.1 (<a
href="https://redirect.github.com/tj-actions/branch-names/issues/424">#424</a>)</li>
</ul>
<p>Co-authored-by: github-actions[bot]
&lt;41898282+github-actions[bot]<a
href="https://github.com/users"><code>@​users</code></a>.noreply.github.com&gt;
(<a
href="https://github.com/tj-actions/branch-names/commit/c0714e7ecc0a7baec34a69b87df070fa6a823e7f">c0714e7</a>)
- (github-actions[bot])</p>
<h1><a
href="https://github.com/tj-actions/branch-names/compare/v9.0.0...v9.0.1">9.0.1</a>
- (2025-07-26)</h1>
<h2><!-- raw HTML omitted -->👷 CI/CD</h2>
<ul>
<li><strong>deps:</strong> Bump codacy/codacy-analysis-cli-action from
4.4.5 to 4.4.7 (<a
href="https://redirect.github.com/tj-actions/branch-names/issues/421">#421</a>)
(<a
href="https://github.com/tj-actions/branch-names/commit/386e117ea34339627a40843704a60a3bc9359234">386e117</a>)
- (dependabot[bot])</li>
<li><strong>deps:</strong> Bump tj-actions/git-cliff from 1.5.0 to 2.0.2
(<a
href="https://redirect.github.com/tj-actions/branch-names/issues/422">#422</a>)
(<a
href="https://github.com/tj-actions/branch-names/commit/2114174008e541048c2313bfc2c296a484785f14">2114174</a>)
- (dependabot[bot])</li>
</ul>
<h1><a
href="https://github.com/tj-actions/branch-names/compare/v8.2.1...v9.0.0">9.0.0</a>
- (2025-07-25)</h1>
<h2><!-- raw HTML omitted -->🔄 Update</h2>
<ul>
<li>Updated README.md (<a
href="https://redirect.github.com/tj-actions/branch-names/issues/419">#419</a>)</li>
</ul>
<p>Co-authored-by: github-actions[bot]
&lt;41898282+github-actions[bot]<a
href="https://github.com/users"><code>@​users</code></a>.noreply.github.com&gt;
(<a
href="https://github.com/tj-actions/branch-names/commit/f904073f20285d3ff38d2dedb647c7e81ab9ccc6">f904073</a>)
- (github-actions[bot])</p>
<h2><!-- raw HTML omitted -->⚙️ Miscellaneous Tasks</h2>
<ul>
<li>Update action.yml (<a
href="https://redirect.github.com/tj-actions/branch-names/issues/418">#418</a>)
(<a
href="https://github.com/tj-actions/branch-names/commit/c81796132291bcac45a405bba3ff42c5c0c2a3e2">c817961</a>)
- (Tonye Jack)</li>
</ul>
<h2><!-- raw HTML omitted -->🛡️ Security</h2>
<ul>
<li>Fix unsafe outputs (<a
href="https://redirect.github.com/tj-actions/branch-names/issues/420">#420</a>)
(<a
href="https://github.com/tj-actions/branch-names/commit/e497ceb8ccd43fd9573cf2e375216625bc411d1f">e497ceb</a>)
- (Tonye Jack)</li>
</ul>
<h2><!-- raw HTML omitted -->⬆️ Upgrades</h2>
<ul>
<li>Upgraded from v8.2.0 -&gt; v8.2.1 (<a
href="https://redirect.github.com/tj-actions/branch-names/issues/417">#417</a>)</li>
</ul>
<p>Co-authored-by: github-actions[bot]
&lt;41898282+github-actions[bot]<a
href="https://github.com/users"><code>@​users</code></a>.noreply.github.com&gt;
(<a
href="https://github.com/tj-actions/branch-names/commit/46ae71df6d27dd78ff96d2aaf0a59411f9c19e4e">46ae71d</a>)
- (github-actions[bot])</p>
<h1><a
href="https://github.com/tj-actions/branch-names/compare/v8.2.0...v8.2.1">8.2.1</a>
- (2025-04-11)</h1>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/tj-actions/branch-names/commit/5250492686b253f06fa55861556d1027b067aeb5"><code>5250492</code></a>
Update update-readme.yml</li>
<li><a
href="https://github.com/tj-actions/branch-names/commit/a2bc4958de72a5590a03c317bcb11581ae7866e7"><code>a2bc495</code></a>
Update update-readme.yml</li>
<li><a
href="https://github.com/tj-actions/branch-names/commit/169ddc10b28b8cbc75996ee56c1dbf4448ca6f06"><code>169ddc1</code></a>
Update README.md</li>
<li><a
href="https://github.com/tj-actions/branch-names/commit/4d35052be347a49c829b8a8e9855f40f14a00be6"><code>4d35052</code></a>
Update README.md</li>
<li><a
href="https://github.com/tj-actions/branch-names/commit/c0714e7ecc0a7baec34a69b87df070fa6a823e7f"><code>c0714e7</code></a>
Upgraded from v9.0.0 -&gt; v9.0.1 (<a
href="https://redirect.github.com/tj-actions/branch-names/issues/424">#424</a>)</li>
<li><a
href="https://github.com/tj-actions/branch-names/commit/6be34a848cdd6067dda01ded8bd9b0853bbe3b23"><code>6be34a8</code></a>
Updated README.md (<a
href="https://redirect.github.com/tj-actions/branch-names/issues/423">#423</a>)</li>
<li><a
href="https://github.com/tj-actions/branch-names/commit/386e117ea34339627a40843704a60a3bc9359234"><code>386e117</code></a>
build(deps): bump codacy/codacy-analysis-cli-action from 4.4.5 to 4.4.7
(<a
href="https://redirect.github.com/tj-actions/branch-names/issues/421">#421</a>)</li>
<li><a
href="https://github.com/tj-actions/branch-names/commit/2114174008e541048c2313bfc2c296a484785f14"><code>2114174</code></a>
build(deps): bump tj-actions/git-cliff from 1.5.0 to 2.0.2 (<a
href="https://redirect.github.com/tj-actions/branch-names/issues/422">#422</a>)</li>
<li><a
href="https://github.com/tj-actions/branch-names/commit/e497ceb8ccd43fd9573cf2e375216625bc411d1f"><code>e497ceb</code></a>
security: fix unsafe outputs (<a
href="https://redirect.github.com/tj-actions/branch-names/issues/420">#420</a>)</li>
<li><a
href="https://github.com/tj-actions/branch-names/commit/f904073f20285d3ff38d2dedb647c7e81ab9ccc6"><code>f904073</code></a>
Updated README.md (<a
href="https://redirect.github.com/tj-actions/branch-names/issues/419">#419</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/tj-actions/branch-names/compare/dde14ac574a8b9b1cedc59a1cf312788af43d8d8...5250492686b253f06fa55861556d1027b067aeb5">compare
view</a></li>
</ul>
</details>
<br />

Updates `github/codeql-action` from 3.29.3 to 3.29.5
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/github/codeql-action/releases">github/codeql-action's
releases</a>.</em></p>
<blockquote>
<h2>v3.29.5</h2>
<h1>CodeQL Action Changelog</h1>
<p>See the <a
href="https://github.com/github/codeql-action/releases">releases
page</a> for the relevant changes to the CodeQL CLI and language
packs.</p>
<h2>3.29.5 - 29 Jul 2025</h2>
<ul>
<li>Update default CodeQL bundle version to 2.22.2. <a
href="https://redirect.github.com/github/codeql-action/pull/2986">#2986</a></li>
</ul>
<p>See the full <a
href="https://github.com/github/codeql-action/blob/v3.29.5/CHANGELOG.md">CHANGELOG.md</a>
for more information.</p>
<h2>v3.29.4</h2>
<h1>CodeQL Action Changelog</h1>
<p>See the <a
href="https://github.com/github/codeql-action/releases">releases
page</a> for the relevant changes to the CodeQL CLI and language
packs.</p>
<h2>3.29.4 - 23 Jul 2025</h2>
<p>No user facing changes.</p>
<p>See the full <a
href="https://github.com/github/codeql-action/blob/v3.29.4/CHANGELOG.md">CHANGELOG.md</a>
for more information.</p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/github/codeql-action/blob/main/CHANGELOG.md">github/codeql-action's
changelog</a>.</em></p>
<blockquote>
<h1>CodeQL Action Changelog</h1>
<p>See the <a
href="https://github.com/github/codeql-action/releases">releases
page</a> for the relevant changes to the CodeQL CLI and language
packs.</p>
<h2>[UNRELEASED]</h2>
<p>No user facing changes.</p>
<h2>3.29.5 - 29 Jul 2025</h2>
<ul>
<li>Update default CodeQL bundle version to 2.22.2. <a
href="https://redirect.github.com/github/codeql-action/pull/2986">#2986</a></li>
</ul>
<h2>3.29.4 - 23 Jul 2025</h2>
<p>No user facing changes.</p>
<h2>3.29.3 - 21 Jul 2025</h2>
<p>No user facing changes.</p>
<h2>3.29.2 - 30 Jun 2025</h2>
<ul>
<li>Experimental: When the <code>quality-queries</code> input for the
<code>init</code> action is provided with an argument, separate
<code>.quality.sarif</code> files are produced and uploaded for each
language with the results of the specified queries. Do not use this in
production as it is part of an internal experiment and subject to change
at any time. <a
href="https://redirect.github.com/github/codeql-action/pull/2935">#2935</a></li>
</ul>
<h2>3.29.1 - 27 Jun 2025</h2>
<ul>
<li>Fix bug in PR analysis where user-provided <code>include</code>
query filter fails to exclude non-included queries. <a
href="https://redirect.github.com/github/codeql-action/pull/2938">#2938</a></li>
<li>Update default CodeQL bundle version to 2.22.1. <a
href="https://redirect.github.com/github/codeql-action/pull/2950">#2950</a></li>
</ul>
<h2>3.29.0 - 11 Jun 2025</h2>
<ul>
<li>Update default CodeQL bundle version to 2.22.0. <a
href="https://redirect.github.com/github/codeql-action/pull/2925">#2925</a></li>
<li>Bump minimum CodeQL bundle version to 2.16.6. <a
href="https://redirect.github.com/github/codeql-action/pull/2912">#2912</a></li>
</ul>
<h2>3.28.21 - 28 July 2025</h2>
<p>No user facing changes.</p>
<h2>3.28.20 - 21 July 2025</h2>
<ul>
<li>Remove support for combining SARIF files from a single upload for
GHES 3.18, see <a
href="https://github.blog/changelog/2024-05-06-code-scanning-will-stop-combining-runs-from-a-single-upload/">the
changelog post</a>. <a
href="https://redirect.github.com/github/codeql-action/pull/2959">#2959</a></li>
</ul>
<h2>3.28.19 - 03 Jun 2025</h2>
<ul>
<li>The CodeQL Action no longer includes its own copy of the extractor
for the <code>actions</code> language, which is currently in public
preview.
The <code>actions</code> extractor has been included in the CodeQL CLI
since v2.20.6. If your workflow has enabled the <code>actions</code>
language <em>and</em> you have pinned
your <code>tools:</code> property to a specific version of the CodeQL
CLI earlier than v2.20.6, you will need to update to at least CodeQL
v2.20.6 or disable
<code>actions</code> analysis.</li>
<li>Update default CodeQL bundle version to 2.21.4. <a
href="https://redirect.github.com/github/codeql-action/pull/2910">#2910</a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/github/codeql-action/commit/51f77329afa6477de8c49fc9c7046c15b9a4e79d"><code>51f7732</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2997">#2997</a>
from github/update-v3.29.5-80a09d7b0</li>
<li><a
href="https://github.com/github/codeql-action/commit/8e90243ddbe0de3f12f4fa361675387b7f94c48d"><code>8e90243</code></a>
Update changelog for v3.29.5</li>
<li><a
href="https://github.com/github/codeql-action/commit/80a09d7b0b5468297f127c81b43cb7335eed0f30"><code>80a09d7</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2996">#2996</a>
from github/dependabot/npm_and_yarn/npm-240ab9fad0</li>
<li><a
href="https://github.com/github/codeql-action/commit/8388115dc8d6af25bf915cc8455a7d6a77253970"><code>8388115</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2994">#2994</a>
from github/mergeback/changelog/v3.28.21</li>
<li><a
href="https://github.com/github/codeql-action/commit/401ecaf503b1a19fc0fbd253cc5afe7759870068"><code>401ecaf</code></a>
Merge branch 'main' into mergeback/changelog/v3.28.21</li>
<li><a
href="https://github.com/github/codeql-action/commit/ab5c0c5fa56442a68c2d51b194ccc93faaaaa639"><code>ab5c0c5</code></a>
Merge branch 'main' into dependabot/npm_and_yarn/npm-240ab9fad0</li>
<li><a
href="https://github.com/github/codeql-action/commit/cd264d4dcdc5ee89d8590821e29c66a1bdcaa968"><code>cd264d4</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2986">#2986</a>
from github/update-bundle/codeql-bundle-v2.22.2</li>
<li><a
href="https://github.com/github/codeql-action/commit/4599055b1e273f63344615ade2c46c852c6d5c63"><code>4599055</code></a>
Merge branch 'main' into update-bundle/codeql-bundle-v2.22.2</li>
<li><a
href="https://github.com/github/codeql-action/commit/fd7ad511e6bd5985ebbc84944e0e173d39a968b8"><code>fd7ad51</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2971">#2971</a>
from github/update-supported-enterprise-server-versions</li>
<li><a
href="https://github.com/github/codeql-action/commit/ac0c9bfe1e34d6a76860325c1b4abe8208ce98a6"><code>ac0c9bf</code></a>
Merge branch 'main' into
update-supported-enterprise-server-versions</li>
<li>Additional commits viewable in <a
href="https://github.com/github/codeql-action/compare/d6bbdef45e766d081b84a2def353b0055f728d3e...51f77329afa6477de8c49fc9c7046c15b9a4e79d">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 14:57:47 +00:00
Jon Ayers 2a2851e494 chore: check integrity of Go in Dockefile (#19130) 2025-08-04 08:27:27 -04:00
Jon Ayers 40dbc557bd fix: ignore goroutine leak for protocol lookup on windows (#19131) 2025-08-04 08:26:56 -04:00
Hugo Dutka 79cd80e5ca feat: add MCP tools for ChatGPT (#19102)
Addresses https://github.com/coder/internal/issues/772.

Adds the toolset query parameter to the `/api/experimental/mcp/http` endpoint, which, when set to "chatgpt", exposes new `fetch` and `search` tools compatible with ChatGPT, as described in the
[ChatGPT docs](https://platform.openai.com/docs/mcp). These tools are
exposed in isolation because in my usage I found that ChatGPT refuses to
connect to Coder if it sees additional MCP tools.

<img width="1248" height="908" alt="Screenshot 2025-07-30 at 16 36 56"
src="https://github.com/user-attachments/assets/ca31e57b-d18b-4998-9554-7a96a141527a"
/>
2025-08-04 14:11:22 +02:00
Spike Curtis d4b44185da chore: add database dump and dbfake logging (#19144)
relates to  #778

Somehow in `TestWorkspaceAgent` the agent with the test instance identifier is not being added to the database, or is getting deleted.

I'm adding some additional logging to `dbfake` and setting the affected tests to dump postgres on error, to see if we can get to the bottom of the issue.
2025-08-04 13:22:04 +04:00
Spike Curtis e80f91e900 chore: add small scenario to scaletest (#19110)
Relaxes the `terraform` version constraint to be at least 1.9, since
1.12 is installed in our Dogfood image

Adds a `small` scenario to keep costs down while we continue to develop
capabilities.
2025-08-04 10:04:44 +04:00
Ethan b95cf47f99 ci: set valid xcode version in release script (#19143)
16.0.0 was yanked from the macOS runners, so this will likely need cherry picking into the upcoming release branch.

We've already checked everything builds fine on #19125.

In a few releases we'll stop building the dylib and also therefore remove xcode as a dependency on coder/coder altogether.
2025-08-04 15:01:24 +10:00
Ethan decd9b7818 ci: conditionally disable spotlight indexing on nightly gauntlet (#19142)
Same as #19124
2025-08-04 15:01:01 +10:00
dependabot[bot] 719c9cc409 chore: bump coder/filebrowser/coder from 1.1.1 to 1.1.2 in /dogfood/coder-envbuilder (#19140)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/filebrowser/coder&package-manager=terraform&previous-version=1.1.1&new-version=1.1.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 01:22:36 +00:00
dependabot[bot] c849a9579d chore: bump coder/filebrowser/coder from 1.1.1 to 1.1.2 in /dogfood/coder (#19139)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/filebrowser/coder&package-manager=terraform&previous-version=1.1.1&new-version=1.1.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 01:14:08 +00:00
dependabot[bot] a512f1a055 chore: bump coder/dotfiles/coder from 1.2.0 to 1.2.1 in /dogfood/coder (#19138)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/dotfiles/coder&package-manager=terraform&previous-version=1.2.0&new-version=1.2.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 01:14:00 +00:00
dependabot[bot] b605569929 chore: bump coder/slackme/coder from 1.0.30 to 1.0.31 in /dogfood/coder (#19136)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/slackme/coder&package-manager=terraform&previous-version=1.0.30&new-version=1.0.31)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 01:10:46 +00:00
dependabot[bot] 206b5683f9 chore: bump coder/coder-login/coder from 1.0.30 to 1.0.31 in /dogfood/coder-envbuilder (#19137)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/coder-login/coder&package-manager=terraform&previous-version=1.0.30&new-version=1.0.31)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 01:10:31 +00:00
dependabot[bot] e8ca4f8cf4 chore: bump coder/zed/coder from 1.0.0 to 1.0.1 in /dogfood/coder (#19135)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/zed/coder&package-manager=terraform&previous-version=1.0.0&new-version=1.0.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 01:07:55 +00:00
dependabot[bot] 369a74a566 chore: bump coder/coder-login/coder from 1.0.30 to 1.0.31 in /dogfood/coder (#19134)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/coder-login/coder&package-manager=terraform&previous-version=1.0.30&new-version=1.0.31)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 01:06:53 +00:00
dependabot[bot] 9626a2bafe chore: bump coder/personalize/coder from 1.0.30 to 1.0.31 in /dogfood/coder-envbuilder (#19133)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/personalize/coder&package-manager=terraform&previous-version=1.0.30&new-version=1.0.31)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 01:06:14 +00:00
dependabot[bot] 0c761792ae chore: bump coder/personalize/coder from 1.0.30 to 1.0.31 in /dogfood/coder (#19132)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/personalize/coder&package-manager=terraform&previous-version=1.0.30&new-version=1.0.31)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 01:05:17 +00:00
Jon Ayers c9ed0dd927 chore: pin dependencies in Dockerfiles (#19129) 2025-08-03 18:26:41 -04:00
Cian Johnston 0d7cc5c156 ci: bump xcode version to 16.1.0 (#19125) 2025-08-03 20:53:04 +01:00
Cian Johnston 6a35400f67 ci: conditionally disable spotlight indexing (#19124)
Work around for following issue:
```
Run sudo mdutil -a -i off
  sudo mdutil -a -i off
  sudo mdutil -X /
  sudo launchctl bootout system /System/Library/LaunchDaemons/com.apple.metadata.mds.plist
  shell: /bin/bash -e {0}
4 files/directories removed
Boot-out failed: 5: Input/output error
```

This can happen if spotlight has already been disabled.
2025-08-02 18:23:46 +01:00
Garrett Delfosse 6ba4b5bbc9 docs: update module registry URLs to correct path structure (#18681)
## Summary
- Updated documentation references to use the correct registry path
structure
- Changed URLs from incorrect paths to the correct format:
  - Modules main page: registry.coder.com/modules
  - Specific modules: registry.coder.com/modules/coder/{module-name}

## Test plan
- Verify that all documentation links to modules point to the correct
URL structure

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Edward Angert <EdwardAngert@users.noreply.github.com>
2025-08-02 06:03:15 +05:00
Danielle Maywood a185d3a2c3 fix(site): ensure notification settings page follows RBAC correctly (#19097)
Ensure template admin and user admins are able to see the correct
notification groups on the notification settings page.

---------

Co-authored-by: ケイラ <mckayla@hey.com>
2025-07-31 21:20:27 +01:00
Eric Paulsen 8b43503aaf docs: remove deprecated JFrog Xray integration documentation (#19113) 2025-07-31 18:46:39 +01:00
ケイラ 1cffd11619 feat: add workspace sharing page (#19107) 2025-07-31 15:05:09 +00:00
Danielle Maywood ddb5b87815 chore(agent/agentcontainers): test current prebuilds integration (#19074)
As it turns out, prebuilds + devcontainers appear to already work
together. This PR has created a test that simulates a prebuild claim
happening to `agentcontainers.API`, to see how we handle it.
2025-07-31 15:31:44 +01:00
ケイラ ed62ddc38e chore: add workspace-sharing experiment (#19106) 2025-07-31 07:52:57 -06:00
Danielle Maywood cc4f8da6e1 fix(agent/agentcontainers): fix devcontainer integration tests (#19109)
It appears we accidentally merged a change that broke our devcontainer
integration tests https://github.com/coder/coder/pull/18570.
2025-07-31 13:24:23 +01:00
Benjamin Peinhardt e4dc2d9418 fix: add constraint and runtime check for provisioner logs size limit (#18893)
This PR sets a constraint of 1MB on the provisioner job logs written to
the database. This is consistent with the constraint we place on
workspace agent logs:
https://github.com/coder/coder/blob/4ac6be6d835dc36c242e35a26b584b784040bf28/coderd/database/dump.sql#L2030

It also adds a message printed to the front end about the provisioner
log overflow, and updates the message printed to the front end when
workspace startup logs exceed the max, as it was causing some customers
to think their startup script had failed to run.
2025-07-30 19:09:53 -05:00
ケイラ eeb0bbefb9 feat: implement acl for workspaces (#19094) 2025-07-30 17:02:51 -06:00
Callum Styan d736af1fa3 fix: handle potential DB conflict due to concurrent upload requests in postFile (#19005)
This issue manifests when users have multiple templates which rely on
the same files, for example see:
https://github.com/coder/coder/issues/17442

---------

Signed-off-by: Callum Styan <callumstyan@gmail.com>
2025-07-30 13:55:30 -07:00
Callum Styan ffbfaf2a6f feat: allow bypassing current CORS magic based on template config (#18706)
Solves https://github.com/coder/coder/issues/15096

This is a slight rework/refactor of the earlier PRs from @dannykopping
and @Emyrk:
- https://github.com/coder/coder/pull/15669
- https://github.com/coder/coder/pull/15684
- https://github.com/coder/coder/pull/17596

Rather than having a per-app CORS behaviour setting and additionally a
template level setting for ports, this PR adds a single template level
CORS behaviour setting that is then used by all apps/ports for
workspaces created from that template.

The main changes are in `proxy.go` and `request.go` to:
a) get the CORS behaviour setting from the template
b) have `HandleSubdomain` bypass the CORS middleware handler if the
selected behaviour is `passthru`
c) in `proxyWorkspaceApp`, do not modify the response if the selected
behaviour is `passthru`

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Added support for configuring CORS behavior ("simple" or "passthru")
at the template level for all shared ports.
* Introduced a new "CORS Behavior" setting in the template creation and
settings forms.
* API endpoints and responses now include the optional `cors_behavior`
property for templates.
* Workspace apps and proxy now honor the specified CORS behavior,
enabling conditional CORS middleware application.
* Enhanced workspace app tests with comprehensive scenarios covering
CORS behaviors and authentication states.

* **Bug Fixes**
  * None.

* **Documentation**
* Updated API and admin documentation to describe the new
`cors_behavior` property and its usage.
* Added examples and schema references for CORS behavior in relevant API
docs.

* **Tests**
* Extended automated tests to cover different CORS behavior scenarios
for templates and workspace apps.

* **Chores**
* Updated audit logging to track changes to the `cors_behavior` field on
templates.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Signed-off-by: Callum Styan <callumstyan@gmail.com>
2025-07-30 13:42:39 -07:00
Susana Ferreira 96e32d60a2 chore(site): add preset combobox to dynamic parameters page (#19100)
## Description

This PR updates the `CreateWorkspacePageViewExperimental` page to use
the `Combobox` React component for preset selection. This aligns it with
the implementation used in the standard `CreateWorkspacePageView`,
ensuring consistency in UI behavior and component usage across both
pages.

<img width="2084" height="792" alt="Screenshot 2025-07-30 at 13 58 23"
src="https://github.com/user-attachments/assets/b8e4ed37-9c59-499f-b4e3-7aaca847eaa1"
/>

Related to `CreateWorkspacePageView` changes:
https://github.com/coder/coder/pull/19063
2025-07-30 18:02:59 +01:00
Edward Angert 998fbdfbb3 docs: use CODER_LOG_FILTER instead of CODER_VERBOSE (#19105)
closes #18833

replace suggestions to use the now-deprecated `CODER_VERBOSE` with more
specific `CODER_LOG_FILTER`

thanks @UnicornyRainbow!

---------

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
2025-07-30 12:35:45 -04:00
Edward Angert 428ec351fe docs: add code-server/vs code web comparison table (#19104)
closes #18815 

adds a doc with comparison table and links to main documentation for
code-server


[preview](https://coder.com/docs/@18815-code-server-vs/user-guides/workspace-access/code-server)

---------

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
2025-07-30 12:35:27 -04:00
Sas Swart f256a23a77 feat: validate presets on template import (#18844)
Typos and other errors often result in invalid presets in a template.
Coder would import these broken templates and present them to users when
they create workspaces. An unsuspecting user who chooses a broken preset
would then experience a failed workspace build with no obvious error
message.

This PR adds additional validation beyond what is possible in the
Terraform provider schema. Coder will now present a more helpful error
message to template authors when they upload a new template version:

<img width="1316" height="286" alt="Screenshot 2025-07-14 at 12 22 49"
src="https://github.com/user-attachments/assets/7f5f778f-d9ae-487a-95e2-f6f1ca604a9c"
/>

The frontend warning is less helpful right now, but I'd like to address
that in a follow-up since I need frontend help:

<img width="1102" height="616" alt="image"
src="https://github.com/user-attachments/assets/e838ffc8-ef4f-428d-9280-74fa0c491666"
/>

closes https://github.com/coder/coder/issues/17333


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
* Improved validation and error reporting for template presets,
providing clearer feedback when presets cannot be parsed or reference
undefined parameters.

* **Bug Fixes**
* Enhanced error handling during template version creation to better
detect and report issues with presets.

* **Tests**
* Added new tests to verify validation of both valid and invalid
Terraform presets during template version creation.
* Improved test reliability by enabling dynamic control over error
injection in database-related tests.

* **Chores**
* Updated a dependency to the latest version for improved stability and
features.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-07-30 15:28:56 +02:00
Cian Johnston 26d232da6f fix(site): hide preset selector in TasksPage if no presets available (#19099) 2025-07-30 11:18:12 +01:00
Susana Ferreira 101351f502 chore: update dogfood coder template presets with description and icon (#19084)
## Description

This PR updates the dogfood template presets to include a description
and a icon.
Requires [terraform-provider-coder
v2.9.0](https://github.com/coder/terraform-provider-coder/releases/tag/v2.9.0).

Related to:
* https://github.com/coder/coder/pull/18977
* https://github.com/coder/coder/pull/19063
2025-07-30 11:00:33 +01:00
Susana Ferreira 44d9356985 fix(site): remove redundant alt text to prevent duplicated accessible names (#19087)
## Description

Removes the redundant `alt` text in the `Combobox` component to prevent
screen readers from announcing duplicated names (e.g. "Rust Rust").

## Changes
* Remove redundant `alt` text from `Combobox` `ExternalImage`
* Update `Combobox` tests accordingly

Related to:
https://github.com/coder/coder/pull/19063#discussion_r2240459424
2025-07-30 09:54:43 +01:00
ケイラ 4bced62bf1 chore: add site/ CODEOWNERS (#19086) 2025-07-29 12:26:32 -06:00
Atif Ali 3a3972c44d chore: add catalog-info.yaml for backstage integration (#19085) 2025-07-29 22:56:53 +05:00
Asher 558e25d591 feat: support shift+enter in terminal (#19021)
It acts the same alt+enter, but is more familiar to users.

Closes #18864
2025-07-29 09:27:11 -08:00
Susana Ferreira 71738f6db9 feat(site): support icon and description in preset (#19063)
## Description

This PR updates the `CreateWorkspacePageView` to use the `Combobox`
React component instead of `SelectFilter` for the Preset selection.

## Changes

* Updated `CreateWorkspacePageView` to use the `Combobox` component in
place of `SelectFilter`.
* Modified the `Combobox` component to render preset icons using
`ExternalImage` instead of `Avatar`.

<img width="2172" height="1138" alt="Screenshot 2025-07-29 at 12 27 14"
src="https://github.com/user-attachments/assets/2ef8342f-7927-4430-bf87-bc93c47d2980"
/>

<img width="2176" height="1112" alt="Screenshot 2025-07-29 at 12 27 21"
src="https://github.com/user-attachments/assets/863089a6-dcfd-46ed-8b85-68838ee04f28"
/>

Follow-up from: https://github.com/coder/coder/pull/18977

---------

Co-authored-by: Jaayden Halko <jaayden.halko@gmail.com>
2025-07-29 17:45:32 +01:00
Danielle Maywood 219d1b4101 chore(agent/agentcontainers): skip part of test if on darwin (#19081) 2025-07-29 17:06:17 +01:00
Ethan 6147da58dd chore: add vpn-daemon run command for macos (#19080)
Continues to address https://github.com/coder/coder-desktop-macos/issues/201

Identical to the windows command, except we don't write to stdio. We're retaining the system we have for logging on macOS, where we push logs over the tunnel and use the OS logger. 

I've tested that a build with this command works end-to-end with my new version of Coder Desktop macOS.

Also brings in the soft net isolation changes from `main` of coder/tailscale.
2025-07-30 02:03:20 +10:00
Susana Ferreira 4e7331a9c4 feat(cli): support description in create and presets list CLI commands (#19079)
## Description

This PR improves the `coder templates presets` and `coder create` CLI
commands to include preset descriptions.

## Changes

* Added a `description` column to the `coder templates presets list` CLI
command.
* Fixed the `-o json` output for `coder templates presets list` to
correctly include and format data.
* Updated the `coder create` CLI command to display the preset's
description in the selection menu.

Follow-up from: 
* https://github.com/coder/coder/pull/18910 
* https://github.com/coder/coder/pull/18912
* https://github.com/coder/coder/pull/18977
2025-07-29 16:59:26 +01:00
Ethan 415273f648 ci: sign macos slim binaries on dogfood builds (#19077)
This will be necessary for future versions of Coder Desktop to connect to dogfood.
2025-07-30 01:22:16 +10:00
35C4n0r 0ef7720f8c feat: add tmux and gemini icons (#19031)
Related PRs: #246 #229

---------

Co-authored-by: DevCats <christofer@coder.com>
2025-07-29 19:49:17 +05:00
Cian Johnston 812d72c5bb fix: sanitize app status summary (#19075)
Fixes https://github.com/coder/coder/issues/18875
2025-07-29 15:24:11 +01:00
Jaayden Halko 29486f9d4e fix: fix e2e tests (#19076)
Closes https://github.com/coder/internal/issues/824
2025-07-29 10:23:57 -04:00
Hugo Dutka b666d52171 feat(codersdk/toolsdk): add MCP workspace bash background parameter (#19034)
Addresses coder/internal#820

---------

Signed-off-by: Thomas Kosiewski <tk@coder.com>
Co-authored-by: Thomas Kosiewski <tk@coder.com>
2025-07-29 16:20:02 +02:00
Dean Sheather bf78966256 chore: remove soft isolation configurability (#19069)
Undoes a lot of the changes in 5319d47dfa

Keeps the `netns.SetCoderSoftIsolation()` call, but always sets it to
`true` when using a TUN device.
2025-07-29 22:30:17 +10:00
Jaayden Halko 1320b8d5be feat: make dynamic parameters opt-in by default for new templates (#19006)
resolves #18975 

---------

Co-authored-by: Steven Masley <stevenmasley@gmail.com>
Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
2025-07-28 20:41:49 -05:00
Austen Bruhn faac75389b feat(helm): add pod-level securityContext support for certificate mounting (#19041)
**Add pod-level securityContext support to Coder Helm chart**

Adds `coder.podSecurityContext` field to enable pod-level security
settings, primarily to solve TLS certificate mounting permission issues.

**Problem**: When mounting TLS certificates from Kubernetes secrets, the
Coder process (UID 1000) cannot read the files due to restrictive
permissions.

**Solution**: Setting `podSecurityContext.fsGroup: 1000` ensures
Kubernetes sets group ownership of mounted volumes to GID 1000, allowing
the Coder process to read certificate files.

**Changes**:
- Added `podSecurityContext` field to values.yaml with documentation
- Updated `_coder.yaml` template to include pod-level security context
- Added test case and golden files
- Maintains backward compatibility (opt-in feature)

**Usage**:
```yaml
coder:
  podSecurityContext:
    fsGroup: 1000  # Enables TLS cert access
```

Fixes #19038
2025-07-28 20:41:32 -04:00
Andrew Aquino 72b8ab530e fix(docs): add missing GFM alert directives to blockquotes (#19042)
I just added support for rendering GFM alerts inside of numbered lists
in coder.com (see https://github.com/coder/coder.com/pull/328), and
noticed that these plain blockquotes should probably be alerts.

This should cover all the missing alerts. I found them by searching for
the regex `^\s*>\s` within docs/**/*.md

Is `[!NOTE]` the correct type for these? Or do we want to use
tip/important/etc?

- @mtojek CONTRIBUTING.md
- @johnstcn support-bundle.md
- @matifali gateway.md
2025-07-28 15:00:56 -07:00
Michael Suchacz 36d2e01471 chore: add managed ai usage consumption to license view (#18934)
Customers with licenses not supporting managed AI agents will receive
the following information:
<img width="597" height="261" alt="image"
src="https://github.com/user-attachments/assets/b794a9f2-bca8-494e-a8d1-cc6e6bc43bfe"
/>

Customers with active licenes for managed AI agents will see:
<img width="604" height="293" alt="image"
src="https://github.com/user-attachments/assets/7ce8931c-05c6-4e64-a5a1-2e9364e99de2"
/>

Closes https://github.com/coder/internal/issues/813

---------

Co-authored-by: McKayla Washburn <mckayla@hey.com>
2025-07-28 20:27:49 +02:00
Susana Ferreira 0672bf5084 feat: support icon and description in preset (#18977)
## Description 

This PR adds support for `description` and `icon` fields to
`template_version_presets`. These fields will allow displaying richer
information for presets in the UI, improving the user experience when
creating a workspace.
Both fields are optional, non-nullable, and default to empty strings.

## Changes

* Database migration with the addition of `description VARCHAR(128)` and
`icon VARCHAR(256)` columns to the `template_version_presets` table.
* Updated the `CreateWorkspacePageView` in the UI

Note: UI changes will be addressed in a separate PR
2025-07-28 15:02:26 +01:00
Jaayden Halko 58123e17ca fix: fix to display tooltip on hover (#19058) 2025-07-28 10:00:41 -04:00
Susana Ferreira b975d6d9b3 feat(cli): add CLI support for creating a workspace with preset (#18912)
## Description 

This PR introduces a `--preset` flag for the `create` command to allow
users to apply a predefined preset to their workspace build.

## Changes

- The `--preset` flag on the `create` command integrates with the
parameter resolution logic and takes precedence over other sources
(e.g., CLI/env vars, last build, etc.).
- Added internal logic to ensure that preset parameters override
parameters values during resolution.
- Updated tests and added new ones to cover these flows.

## Implementation logic

* If a template has presets and includes a default, the CLI will
automatically use the default when `--preset` is not specified.
* If a template has presets but no default, the CLI will prompt the user
to select one when `--preset` is not specified.
* If a template does not have presets, the CLI will not prompt the user
for a preset.
* If the user specifies a preset using the `--preset` flag, that preset
will be used.
* If the user passes `--preset None`, no preset will be applied.

This logic aligns with the behavior in the UI for consistency.

```
> coder create --help

USAGE:
  coder create [flags] [workspace]

  Create a workspace

    - Create a workspace for another user (if you have permission):

        $ coder create <username>/<workspace_name>

OPTIONS:
      (...)

      --preset string, $CODER_PRESET_NAME
          Specify the name of a template version preset. Use 'none' to explicitly indicate that no preset should be used.

      (...)

  -y, --yes bool
          Bypass prompts.
```

## Breaking change

**Note:** This is a breaking change to the create CLI command. If a
template includes presets and the user does not provide a `--preset`
flag, the CLI will now prompt the user to select one. This behavior may
break non-interactive scripts or automated workflows.


Relates to PR: https://github.com/coder/coder/pull/18910 - please
consider both PRs together as they’re part of the same workflow
Relates to issue: https://github.com/coder/coder/issues/16594
2025-07-28 14:46:04 +01:00
Danielle Maywood 66cf90c736 feat(agent/agentcontainers): allow auto start for discovered containers (#19040)
Closes https://github.com/coder/internal/issues/711

When a `devcontainer.json` has been found and it has `.customizations.coder.autoStart = true`, we will now auto start this dev container.
2025-07-28 12:30:52 +01:00
Thomas Kosiewski 398e80f003 feat: add timeout support to workspace bash tool (#19035)
# Add timeout support to workspace bash tool

This PR adds a timeout feature to the workspace bash tool, allowing
users to specify a maximum execution time for commands. Key changes
include:

- Added a `timeout_ms` parameter to control command execution time
(defaults to 60 seconds, with a maximum of 5 minutes)
- Implemented a new `executeCommandWithTimeout` function that properly
handles command timeouts
- Added proper output capturing during timeout scenarios, returning all
output collected before the timeout
- Updated documentation to explain the timeout feature and provide usage
examples
- Added comprehensive tests for the timeout functionality, including
integration tests

When a command times out, the tool now returns all captured output up to
that point along with a cancellation message, making it clear to users
what happened.

Signed-off-by: Thomas Kosiewski <tk@coder.com>
2025-07-28 11:25:43 +02:00
Thomas Kosiewski d1595781e1 fix: fix nil pointer dereference in ReportTask (#19045)
This pull request addresses a bug related to a nil pointer dereference
in the task reporting functionality.

### Bug Fixes and Error Handling:

* Updated `RegisterTools` in `mcp.go` to skip registering the
`ReportTask` tool in the remote MCP context when a task reporter is not
configured, preventing potential nil pointer dereference panics.
* Added a check in `toolsdk.go` to ensure task reporting dependencies
are available before invoking the reporter, returning an appropriate
error if not.

### Test Coverage:

* Added `TestReportTaskNilPointerDeref` in `toolsdk_test.go` to verify
that the system does not panic when task reporting dependencies are
missing and instead returns a clear error message.
* Added `TestReportTaskWithReporter` in `toolsdk_test.go` to validate
correct behavior when a task reporter is configured, ensuring the
handler processes the request as expected.

Signed-off-by: Thomas Kosiewski <tk@coder.com>
2025-07-28 11:23:29 +02:00
Cian Johnston 6bf2ec3eb1 chore: fix unbound variable in develop.sh (#19043)
Missed this in https://github.com/coder/coder/pull/18991
2025-07-28 09:20:35 +01:00
Dean Sheather 2a430ab435 fix: avoid duplicating logs on Coder Connect Windows (#19052)
The sinks are already added to the logger above, so they're just getting duplicated
2025-07-28 14:02:00 +10:00
dependabot[bot] 8d6cc51da9 chore: bump coder/code-server/coder from 1.3.0 to 1.3.1 in /dogfood/coder-envbuilder (#19050)
[//]: # (dependabot-start)
⚠️  **Dependabot is rebasing this PR** ⚠️ 

Rebasing might not happen immediately, so don't worry if this takes some
time.

Note: if you make any changes to this PR yourself, they will take
precedence over the rebase.

---

[//]: # (dependabot-end)



[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/code-server/coder&package-manager=terraform&previous-version=1.3.0&new-version=1.3.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-28 00:32:41 +00:00
dependabot[bot] d0a7d84191 chore: bump coder/cursor/coder from 1.2.0 to 1.2.1 in /dogfood/coder (#19047)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/cursor/coder&package-manager=terraform&previous-version=1.2.0&new-version=1.2.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-28 00:32:32 +00:00
dependabot[bot] 10b8610045 chore: bump coder/code-server/coder from 1.3.0 to 1.3.1 in /dogfood/coder (#19049)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/code-server/coder&package-manager=terraform&previous-version=1.3.0&new-version=1.3.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-28 00:32:24 +00:00
dependabot[bot] 355dd9c119 chore: bump coder/vscode-web/coder from 1.3.0 to 1.3.1 in /dogfood/coder (#19048)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/vscode-web/coder&package-manager=terraform&previous-version=1.3.0&new-version=1.3.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-28 00:32:15 +00:00
dependabot[bot] c2a271ffda chore: bump coder/windsurf/coder from 1.1.0 to 1.1.1 in /dogfood/coder (#19046)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/windsurf/coder&package-manager=terraform&previous-version=1.1.0&new-version=1.1.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-28 00:32:08 +00:00
Steven Masley 38755e204d chore: remove actDef function, had no value (#19019) 2025-07-24 14:52:03 -05:00
Cian Johnston 9a05a8a28a feat: add preset selector in TasksPage (#19012)
* Adds a preset selector in TasksPage with the default preset pre-selected and at the top of the list.
* If no default preset exists, the user is prompted to select one.
* If a preset defines an AI Prompt, it will override the textarea.
2025-07-24 20:19:33 +01:00
ケイラ 5c31b983e5 chore: update logo in index.html (#19017) 2025-07-24 09:48:05 -06:00
Susana Ferreira 931b97caab feat(cli): add CLI support for listing presets (#18910)
## Description 

This PR introduces a new `list presets` command to display the presets
associated with a given template.
By default, it displays the presets for the template's active version,
unless a `--template-version` flag is provided.

## Changes

* Added a new `list presets` command under `coder templates presets` to
display presets associated with a template.
* By default, the command lists presets from the template’s active
version.
* Users can override the default behavior by providing the
`--template-version` flag to target a specific version.

```
> coder templates versions presets list --help

USAGE:
  coder templates presets list [flags] <template>

  List all presets of the specified template. Defaults to the active template version.

OPTIONS:
  -O, --org string, $CODER_ORGANIZATION
          Select which organization (uuid or name) to use.

  -c, --column [name|parameters|default|desired prebuild instances] (default: name,parameters,default,desired prebuild instances)
          Columns to display in table output.

  -o, --output table|json (default: table)
          Output format.

      --template-version string
          Specify a template version to list presets for. Defaults to the active version.
```

Related PR: https://github.com/coder/coder/pull/18912 - please consider
both PRs together as they’re part of the same workflow
Relates to issue: https://github.com/coder/coder/issues/16594

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Added CLI commands to manage and list presets for specific template
versions, supporting tabular and JSON output.
* Introduced a new CLI subcommand group for template version presets,
including detailed help and documentation.
* Added support for displaying and managing the desired number of
prebuild instances for presets in CLI, API, and UI.

* **Documentation**
* Updated and expanded CLI and API documentation to describe new
commands, options, and the desired prebuild instances field in presets.
* Added new help output and reference files for template version presets
commands.

* **Bug Fixes**
* Ensured correct handling and display of the desired prebuild instances
property for presets across CLI, API, and UI.

* **Tests**
* Introduced end-to-end tests for listing template version presets,
covering scenarios with and without presets.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-07-24 16:44:36 +01:00
Susana Ferreira 070178c454 chore: bump github.com/coder/terraform-provider-coder/v2 from 2.8.0 to 2.9.0 (#19032)
Bumps
[github.com/coder/terraform-provider-coder/v2](https://github.com/coder/terraform-provider-coder)
from 2.8.0 to 2.9.0.

Release:
https://github.com/coder/terraform-provider-coder/releases/tag/v2.9.0
2025-07-24 12:17:21 +01:00
Danielle Maywood 25d70ce7bc fix(agent/agentcontainers): respect ignore files (#19016)
Closes https://github.com/coder/coder/issues/19011

We now use
[go-git](https://pkg.go.dev/github.com/go-git/go-git/v5@v5.16.2/plumbing/format/gitignore)'s
`gitignore` plumbing implementation to parse the `.gitignore` files and
match against the patterns generated. We use this to ignore any ignored
files in the git repository.

Unfortunately I've had to slightly re-implement some of the interface
exposed by `go-git` because they use `billy.Filesystem` instead of
`afero.Fs`.
2025-07-24 12:12:05 +01:00
Ethan 5c1bf1d46c test(coderd/database): use seperate context for subtests to fix flake (#19029)
Fixes flakes like https://github.com/coder/coder/actions/runs/16487670478/job/46615625141, caused by the issue described in https://coder.com/blog/go-testing-contexts-and-t-parallel

It'd be cool if we could lint for this? That a context from an outer test isn't used in a subtest if that subtest calls `t.Parallel`.
2025-07-24 20:07:54 +10:00
Dean Sheather 9a05b4679b chore: fix TestManagedAgentLimit flake (#19026)
Closes https://github.com/coder/internal/issues/812
2025-07-24 05:13:15 +00:00
Dean Sheather 5319d47dfa chore: add support for tailscale soft isolation in VPN (#19023) 2025-07-24 04:18:29 +00:00
blink-so[bot] 28789d7204 feat: add View Source button for template administrators in workspace creation (#18951) 2025-07-23 11:16:53 -06:00
Cian Johnston bb83071b5f chore: override codersdk.SessionTokenCookie in develop.sh (#18991)
Updates `develop.sh`, `coder-dev.sh` and `build_go.sh` to conditionally override `codersdk.SessionTokenCookie` for usage in nested development scenario.
2025-07-23 12:48:15 +01:00
Danielle Maywood f41275eb39 feat(agent/agentcontainers): auto detect dev containers (#18950)
Relates to https://github.com/coder/internal/issues/711

This PR implements a project discovery mechanism that searches for any
dev container projects and makes them visible in the UI so that they can
be started. To make the wording on the site more clear, "Rebuild" has
been changed to "Start" when there is no container associated with a
known dev container configuration. I've also made it so that site will
show the dev container config path when there is no other name
available.

### Design decisions

Just want to ensure my explanation for a few design decisions are noted
down:
- We only search for dev container configurations inside git
repositories
- We only search for these git repositories if they're at the top level
or a direct child of the agent directory.

This limited approach is to reduce the amount of files we ultimately
walk when trying to find these projects. It makes sense to limit it to
only the agent directory, although I'm open to expanding how deep we
search.
2025-07-22 19:02:43 +01:00
Thomas Kosiewski c6efe64a65 fix: handle nil writer in bash MCP tool (#18978)
- Refactors the bash tool to use `io.Discard` instead of nil to avoid panics.

- Enhances panic recovery in `codersdk/toolsdk/toolsdk.go` by adding stack trace information in development builds. When a panic occurs in a tool handler:
   - In development builds: The error includes the full stack trace for easier debugging
   - In production builds: A simpler error message is shown without the stack trace
2025-07-22 18:03:26 +02:00
Jaayden Halko dd2fb896eb fix: debounce slider to avoid laggy behavior (#18980)
resolves #18856 
resolves coder/internal#753
2025-07-22 11:15:43 -04:00
Steven Masley 99adb4a15b chore: update codeowners to include emyrk specific features (#18974) 2025-07-22 08:56:56 -05:00
Dean Sheather 62dc8310d1 fix: use httponly flag on coder_signed_app_token cookie (#18989) 2025-07-22 22:44:20 +10:00
Cian Johnston c4b69bbe63 fix: prioritise human-initiated builds over prebuilds (#18933)
Continues from https://github.com/coder/coder/pull/18882

- Reverts extraneous changes
- Adds explicit `ORDER BY initiator_id = $PREBUILDS_USER_ID` to
`AcquireProvisionerJob`
- Improves test added for above PR

---------

Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: kylecarbs <7122116+kylecarbs@users.noreply.github.com>
2025-07-22 13:03:50 +01:00
Marcin Tojek e98dce7f99 fix: mute Claude API key warning if Bedrock in use (#18988)
Fixes: https://github.com/coder/coder/issues/17402
2025-07-22 13:56:20 +02:00
Kacper Sawicki 482463c51a feat: extend workspace build reasons to track connection types (#18827)
This PR introduces new build reason values to identify what type of
connection triggered a workspace build, helping to troubleshoot
workspace-related issues.

## Database Migration
Added migration 000349_extend_workspace_build_reason.up.sql that extends
the build_reason enum with new values:
```
dashboard, cli, ssh_connection, vscode_connection, jetbrains_connection
```

## Implementation
The build reason is specified through the API when creating new
workspace builds:

- Dashboard: Automatically sets reason to `dashboard` when users start
workspaces via the web interface
- CLI `start` command: Sets reason to `cli` when workspaces are started
via the command line
- CLI `ssh` command: Sets reason to ssh_connection when workspaces are
started due to SSH connections
- VS Code connections: Will be set to `vscode_connection` by the VS Code
extension through CLI hidden flag
(https://github.com/coder/vscode-coder/pull/550)
- JetBrains connections: Will be set to `jetbrains_connection` by the
Jetbrains Toolbox
(https://github.com/coder/coder-jetbrains-toolbox/pull/150) and
Jetbrains Gateway extension
(https://github.com/coder/jetbrains-coder/pull/561)

## UI Changes:
* Tooltip with reason in Build history
<img width="309" height="457" alt="image"
src="https://github.com/user-attachments/assets/bde8440b-bf3b-49a1-a244-ed7e8eb9763c"
/>

* Reason in Audit Logs Row tooltip
<img width="906" height="237" alt="image"
src="https://github.com/user-attachments/assets/ebbb62c7-cf07-4398-afbf-323c83fb6426"
/>

<img width="909" height="188" alt="image"
src="https://github.com/user-attachments/assets/1ddbab07-44bf-4dee-8867-b4e2cd56ae96"
/>
2025-07-22 13:11:27 +02:00
Dean Sheather 0ebd4356a0 fix: use system context for managed agent count query (#18985) 2025-07-22 06:03:35 +00:00
Dean Sheather 9a6dd73f68 feat: add managed agent license limit checks (#18937)
- Adds a query for counting managed agent workspace builds between two
timestamps
- The "Actual" field in the feature entitlement for managed agents is
now populated with the value read from the database
- The wsbuilder package now validates AI agent usage against the limit
when a license is installed

Closes coder/internal#777
2025-07-22 13:39:26 +10:00
blink-so[bot] aa1a985381 docs: update DX integration title from 'DX Data Cloud' to 'DX' (#18981)
Simplifies the title to reduce customer confusion as requested by
@kylejaggi.

The DX platform covers all products, not just Data Cloud. This change
makes the documentation clearer for customers who might get confused
about which DX product the integration refers to.

**Changes:**
- Updated page title from "DX Data Cloud" to "DX" in
`docs/admin/integrations/dx-data-cloud.md`

**Testing:**
- Verified the markdown renders correctly
- No functional changes, documentation-only update

---------

Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: bpmct <22407953+bpmct@users.noreply.github.com>
2025-07-21 22:02:44 +00:00
ケイラ 19afeda98a feat: improve workspace upgrade flow when template parameters change (#18917) 2025-07-21 15:42:04 -06:00
Jaayden Halko d7b12535db chore: remove beta labels for dynamic parameters (#18976)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Style**
* Removed the "beta" badge from various workspace and template settings
pages. The "Dynamic parameters" feature no longer displays a beta label
in the interface.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-07-21 16:16:33 -04:00
Thomas Kosiewski 326c02459f feat: add workspace SSH execution tool for AI SDK (#18924)
# Add SSH Command Execution Tool for Coder Workspaces

This PR adds a new AI tool `coder_workspace_ssh_exec` that allows executing commands in Coder workspaces via SSH. The tool provides functionality similar to the `coder ssh <workspace> <command>` CLI command.

Key features:
- Executes commands in workspaces via SSH and returns the output and exit code
- Automatically starts workspaces if they're stopped
- Waits for the agent to be ready before executing commands
- Trims leading and trailing whitespace from command output
- Supports various workspace identifier formats:
  - `workspace` (uses current user)
  - `owner/workspace`
  - `owner--workspace`
  - `workspace.agent` (specific agent)
  - `owner/workspace.agent`

The implementation includes:
- A new tool definition with schema and handler
- Helper functions for workspace and agent discovery
- Workspace name normalization to handle different input formats
- Comprehensive test coverage including integration tests

This tool enables AI assistants to execute commands in user workspaces, making it possible to automate tasks and provide more interactive assistance.

<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

* **New Features**
  * Introduced the ability to execute bash commands inside a Coder workspace via SSH, supporting multiple workspace identification formats.
* **Tests**
  * Added comprehensive unit and integration tests for executing bash commands in workspaces, including input validation, output handling, and error scenarios.
* **Chores**
  * Registered the new bash execution tool in the global tools list.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-07-21 21:24:00 +02:00
blink-so[bot] 75c124013f fix: remove remaining v prefixes from all module versions in dogfood directory (#18971)
This PR completes the fix for Dependabot version prefix issues by
removing the remaining `v` prefixes that weren't caught in the previous
merge.

**Fixed modules:**

**dogfood/coder-envbuilder/main.tf:**
- slackme: `v1.0.30` → `1.0.30`
- dotfiles: `v1.2.0` → `1.2.0` 
- personalize: `v1.0.30` → `1.0.30`
- code-server: `v1.3.0` → `1.3.0`
- filebrowser: `v1.1.1` → `1.1.1`
- coder-login: `v1.0.30` → `1.0.30`

**dogfood/coder/main.tf:**
- dotfiles: `v1.2.0` → `1.2.0`
- git-clone: `v1.1.0` → `1.1.0`
- vscode-web: `v1.3.0` → `1.3.0`
- coder-login: `v1.0.30` → `1.0.30`
- cursor: `v1.2.0` → `1.2.0`

Now **all** modules in the dogfood directory use consistent version
formatting without the `v` prefix.

Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: matifali <10648092+matifali@users.noreply.github.com>
2025-07-21 13:45:04 -05:00
Thomas Kosiewski 1db096d8f9 chore: fix CodeRabbit config to disable review status (#18973)
Disable review status in CodeRabbit configuration

Change-Id: I0ee266e0b284832b65762a4f7a3f26d56af53e86
Signed-off-by: Thomas Kosiewski <tk@coder.com>
2025-07-21 20:26:01 +02:00
Steven Masley aedc019b4e feat: include template variables in dynamic parameter rendering (#18819)
Closes https://github.com/coder/coder/issues/18671

Template variables now loaded into dynamic parameters.
2025-07-21 13:02:31 -05:00
Jon Ayers 40a6367d4b chore: update CLAUDE.md to discourage time.Sleep (#18967) 2025-07-21 12:55:16 -04:00
blink-so[bot] 6d335910ea Update dogfood envbuilder template to use dev.registry.coder.com (#18968)
Updates the dogfood envbuilder template to pull modules from
`dev.registry.coder.com` instead of `registry.coder.com` to match the
regular dogfood template.

This ensures consistency between both dogfood templates and uses the
development registry for testing new module versions.

Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: matifali <10648092+matifali@users.noreply.github.com>
2025-07-21 16:51:05 +00:00
dependabot[bot] b181644930 chore: bump coder/coder-login/coder from 1.0.15 to v1.0.30 in /dogfood/coder-envbuilder (#18962)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/coder-login/coder&package-manager=terraform&previous-version=1.0.15&new-version=v1.0.30)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 16:32:01 +00:00
dependabot[bot] 1a3c1d0533 chore: bump coder/dotfiles/coder from 1.0.29 to v1.2.0 in /dogfood/coder-envbuilder (#18965)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/dotfiles/coder&package-manager=terraform&previous-version=1.0.29&new-version=v1.2.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 16:31:55 +00:00
dependabot[bot] 56c6b0f939 chore: bump coder/filebrowser/coder from 1.0.31 to v1.1.1 in /dogfood/coder-envbuilder (#18963)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/filebrowser/coder&package-manager=terraform&previous-version=1.0.31&new-version=v1.1.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 16:31:47 +00:00
dependabot[bot] 9d60acbfc3 chore: bump coder/code-server/coder from 1.2.0 to v1.3.0 in /dogfood/coder-envbuilder (#18960)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/code-server/coder&package-manager=terraform&previous-version=1.2.0&new-version=v1.3.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 16:27:18 +00:00
dependabot[bot] b05574ba53 chore: bump coder/windsurf/coder from 1.0.0 to 1.1.0 in /dogfood/coder (#18958)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/windsurf/coder&package-manager=terraform&previous-version=1.0.0&new-version=1.1.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 16:27:13 +00:00
dependabot[bot] 235bb5b279 chore: bump coder/personalize/coder from 1.0.2 to v1.0.30 in /dogfood/coder-envbuilder (#18959)
[//]: # (dependabot-start)
⚠️  **Dependabot is rebasing this PR** ⚠️ 

Rebasing might not happen immediately, so don't worry if this takes some
time.

Note: if you make any changes to this PR yourself, they will take
precedence over the rebase.

---

[//]: # (dependabot-end)



[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/personalize/coder&package-manager=terraform&previous-version=1.0.2&new-version=v1.0.30)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 16:27:06 +00:00
dependabot[bot] 90eb5c3d6f chore: bump coder/slackme/coder from 1.0.2 to 1.0.30 in /dogfood/coder (#18956)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/slackme/coder&package-manager=terraform&previous-version=1.0.2&new-version=1.0.30)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 16:27:02 +00:00
dependabot[bot] 8c68961a1c chore: bump coder/slackme/coder from 1.0.2 to v1.0.30 in /dogfood/coder-envbuilder (#18961)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/slackme/coder&package-manager=terraform&previous-version=1.0.2&new-version=v1.0.30)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 16:26:56 +00:00
dependabot[bot] 847373aba1 chore: bump coder/personalize/coder from 1.0.2 to 1.0.30 in /dogfood/coder (#18957)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/personalize/coder&package-manager=terraform&previous-version=1.0.2&new-version=1.0.30)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 16:26:44 +00:00
ケイラ a9b110df68 chore: remove site/ CODEOWNERS entry (#18954) 2025-07-21 10:04:44 -06:00
dependabot[bot] e6b3b5900f chore: bump github.com/go-chi/chi/v5 from 5.1.0 to 5.2.2 (#18475) 2025-07-21 17:53:28 +02:00
Thomas Kosiewski 4ac6be6d83 chore: add CodeRabbit config with disabled auto-reviews (#18949) 2025-07-21 15:51:48 +01:00
dependabot[bot] b235f8cfeb chore: bump coder/git-clone/coder from 1.0.18 to v1.1.0 in /dogfood/coder (#18947)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/git-clone/coder&package-manager=terraform&previous-version=1.0.18&new-version=v1.1.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 14:40:23 +00:00
dependabot[bot] be672682f5 chore: bump coder/vscode-web/coder from 1.2.0 to v1.3.0 in /dogfood/coder (#18946)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/vscode-web/coder&package-manager=terraform&previous-version=1.2.0&new-version=v1.3.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 14:40:12 +00:00
dependabot[bot] d86dcdbb92 chore: bump coder/cursor/coder from 1.1.0 to v1.2.0 in /dogfood/coder (#18944)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/cursor/coder&package-manager=terraform&previous-version=1.1.0&new-version=v1.2.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 14:39:58 +00:00
dependabot[bot] dc5399d261 chore: bump coder/dotfiles/coder from 1.0.29 to v1.2.0 in /dogfood/coder (#18943)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/dotfiles/coder&package-manager=terraform&previous-version=1.0.29&new-version=v1.2.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 14:39:48 +00:00
dependabot[bot] 79f4d262a6 chore: bump coder/coder-login/coder from 1.0.15 to v1.0.30 in /dogfood/coder (#18945)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=coder/coder-login/coder&package-manager=terraform&previous-version=1.0.15&new-version=v1.0.30)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 14:39:42 +00:00
dependabot[bot] a10f25659c chore: bump google.golang.org/api from 0.241.0 to 0.242.0 (#18941)
Bumps
[google.golang.org/api](https://github.com/googleapis/google-api-go-client)
from 0.241.0 to 0.242.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/googleapis/google-api-go-client/releases">google.golang.org/api's
releases</a>.</em></p>
<blockquote>
<h2>v0.242.0</h2>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.241.0...v0.242.0">0.242.0</a>
(2025-07-16)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3226">#3226</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/9bd47c484b01476118eee059103a36373a6e560b">9bd47c4</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3228">#3228</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/2ee2e31870227ca989696c35f57be0b616a4fea2">2ee2e31</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3229">#3229</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/6fdc3ebb204a9a3275ccca159be884ec387848ac">6fdc3eb</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3230">#3230</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/d5fa61e954f9ccd53074a67b223a5af0a6446970">d5fa61e</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3231">#3231</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/96d4d98a3d73775fa606b8dbdc6f900287f335be">96d4d98</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3232">#3232</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/2ab275bbcb1a8c206099ca7b2e66bd5d0c0b9eac">2ab275b</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/googleapis/google-api-go-client/blob/main/CHANGES.md">google.golang.org/api's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.241.0...v0.242.0">0.242.0</a>
(2025-07-16)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3226">#3226</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/9bd47c484b01476118eee059103a36373a6e560b">9bd47c4</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3228">#3228</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/2ee2e31870227ca989696c35f57be0b616a4fea2">2ee2e31</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3229">#3229</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/6fdc3ebb204a9a3275ccca159be884ec387848ac">6fdc3eb</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3230">#3230</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/d5fa61e954f9ccd53074a67b223a5af0a6446970">d5fa61e</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3231">#3231</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/96d4d98a3d73775fa606b8dbdc6f900287f335be">96d4d98</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3232">#3232</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/2ab275bbcb1a8c206099ca7b2e66bd5d0c0b9eac">2ab275b</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/16277b75e6b0b8146ea1f462a5f007b9f76fbe6b"><code>16277b7</code></a>
chore(main): release 0.242.0 (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3227">#3227</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/2ab275bbcb1a8c206099ca7b2e66bd5d0c0b9eac"><code>2ab275b</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3232">#3232</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/96d4d98a3d73775fa606b8dbdc6f900287f335be"><code>96d4d98</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3231">#3231</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/d5fa61e954f9ccd53074a67b223a5af0a6446970"><code>d5fa61e</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3230">#3230</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/6fdc3ebb204a9a3275ccca159be884ec387848ac"><code>6fdc3eb</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3229">#3229</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/2ee2e31870227ca989696c35f57be0b616a4fea2"><code>2ee2e31</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3228">#3228</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/9bd47c484b01476118eee059103a36373a6e560b"><code>9bd47c4</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3226">#3226</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/f1d0fc0610cf1185bb9a705b04bdd4e8a26c5963"><code>f1d0fc0</code></a>
test(transport): replaced deprecated grpc.WithInsecure code</li>
<li>See full diff in <a
href="https://github.com/googleapis/google-api-go-client/compare/v0.241.0...v0.242.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=google.golang.org/api&package-manager=go_modules&previous-version=0.241.0&new-version=0.242.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 14:33:16 +00:00
Cian Johnston 198d50dbc2 chore: replace original GetPrebuiltWorkspaces with optimized version (#18832)
Fixes https://github.com/coder/internal/issues/715

Follow-up from https://github.com/coder/coder/pull/18717

Now that we've determined the updated query is safe, remove the duplication.
2025-07-21 15:31:11 +01:00
dependabot[bot] af01562e35 chore: bump golang.org/x/tools from 0.34.0 to 0.35.0 in the x group (#18942)
Bumps the x group with 1 update:
[golang.org/x/tools](https://github.com/golang/tools).

Updates `golang.org/x/tools` from 0.34.0 to 0.35.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/tools/commit/50ec2f15fda46d8960c1d871856265127b4dcce5"><code>50ec2f1</code></a>
go.mod: update golang.org/x dependencies</li>
<li><a
href="https://github.com/golang/tools/commit/197c6c1b47160df25b9cd6598d88525c27a01e5a"><code>197c6c1</code></a>
gopls/internal/mcp: more tuning of tools and prompts</li>
<li><a
href="https://github.com/golang/tools/commit/9563af690255d5b5f7802773c0853f1176130da4"><code>9563af6</code></a>
gopls/internal/mcp: include module paths in workspace summaries</li>
<li><a
href="https://github.com/golang/tools/commit/88a4eb3018821e07f501b483e0f6f4eac4146198"><code>88a4eb3</code></a>
gopls/internal/cmd: wait for startup log in TestMCPCommandHTTP</li>
<li><a
href="https://github.com/golang/tools/commit/4738c7c0b1a53ae0c0fa248a8c31d2a07922dc9b"><code>4738c7c</code></a>
gopls/internal/cmd: avoid the use of channels in the sessions API</li>
<li><a
href="https://github.com/golang/tools/commit/ae1841752658d1d164b5926e72b2b0751fe5db17"><code>ae18417</code></a>
gopls/internal/filewatcher: skip test for unsupported OS</li>
<li><a
href="https://github.com/golang/tools/commit/8391b17713e95ac9bc23d8de7c0303b11c4a190b"><code>8391b17</code></a>
gopls/doc: document Zed editor</li>
<li><a
href="https://github.com/golang/tools/commit/778fe21d5d9f021763cced9defde671c6329d921"><code>778fe21</code></a>
gopls/internal/util/tokeninternal: move from internal/tokeninternal</li>
<li><a
href="https://github.com/golang/tools/commit/0343b7064dcefd5b28e53395fa70768990cc71fb"><code>0343b70</code></a>
internal/jsonrpc2/stack: move from internal/stack</li>
<li><a
href="https://github.com/golang/tools/commit/8c9f4cc0c2a00d508755a558cf73e0dab8d78863"><code>8c9f4cc</code></a>
gopls/internal/filewatcher: refactor filewatcher to pass in handler
func</li>
<li>Additional commits viewable in <a
href="https://github.com/golang/tools/compare/v0.34.0...v0.35.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=golang.org/x/tools&package-manager=go_modules&previous-version=0.34.0&new-version=0.35.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 14:21:53 +00:00
dependabot[bot] e4c2099031 chore: bump github.com/valyala/fasthttp from 1.63.0 to 1.64.0 (#18940)
Bumps [github.com/valyala/fasthttp](https://github.com/valyala/fasthttp)
from 1.63.0 to 1.64.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/valyala/fasthttp/releases">github.com/valyala/fasthttp's
releases</a>.</em></p>
<blockquote>
<h2>v1.64.0</h2>
<h2>⚠️ Deprecation warning! ⚠️</h2>
<p>In the next version of fasthttp headers delimited by just
<code>\n</code> (instead of <code>\r\n</code>) are no longer
supported!</p>
<h2>What's Changed</h2>
<ul>
<li>Add warning for deprecated newline separator by <a
href="https://github.com/erikdubbelboer"><code>@​erikdubbelboer</code></a>
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2031">valyala/fasthttp#2031</a></li>
<li>refact: eliminate duplication in Request/Response via struct
embedding by <a
href="https://github.com/ksw2000"><code>@​ksw2000</code></a> in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2027">valyala/fasthttp#2027</a></li>
<li>chore(deps): bump golang.org/x/sys from 0.33.0 to 0.34.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2034">valyala/fasthttp#2034</a></li>
<li>chore(deps): bump golang.org/x/crypto from 0.39.0 to 0.40.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2036">valyala/fasthttp#2036</a></li>
<li>chore(deps): bump golang.org/x/net from 0.41.0 to 0.42.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2035">valyala/fasthttp#2035</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/valyala/fasthttp/compare/v1.63.0...v1.64.0">https://github.com/valyala/fasthttp/compare/v1.63.0...v1.64.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/valyala/fasthttp/commit/b1a54c8de5720d048bc2cc9aef47903bda171a9e"><code>b1a54c8</code></a>
chore(deps): bump golang.org/x/net from 0.41.0 to 0.42.0 (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2035">#2035</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/7ac856f71f3b3f8a0df682af0d3d09c88bf0519b"><code>7ac856f</code></a>
chore(deps): bump golang.org/x/crypto from 0.39.0 to 0.40.0 (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2036">#2036</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/2a917b661a90127b84796d80fc30d4e70845ecfa"><code>2a917b6</code></a>
chore(deps): bump golang.org/x/sys from 0.33.0 to 0.34.0 (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2034">#2034</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/a3c9dab7573946aa0afcee62d94fbfb58e3c4c2c"><code>a3c9dab</code></a>
Add warning for deprecated newline separator (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2031">#2031</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/eb1f908d9764ef1a355bab13ed83ce7cfc5e793e"><code>eb1f908</code></a>
refact: eliminate duplication in Request/Response via struct embedding
(<a
href="https://redirect.github.com/valyala/fasthttp/issues/2027">#2027</a>)</li>
<li>See full diff in <a
href="https://github.com/valyala/fasthttp/compare/v1.63.0...v1.64.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/valyala/fasthttp&package-manager=go_modules&previous-version=1.63.0&new-version=1.64.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 14:16:42 +00:00
dependabot[bot] 4c1a46150b chore: bump github.com/mark3labs/mcp-go from 0.33.0 to 0.34.0 (#18939)
Bumps [github.com/mark3labs/mcp-go](https://github.com/mark3labs/mcp-go)
from 0.33.0 to 0.34.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/mark3labs/mcp-go/releases">github.com/mark3labs/mcp-go's
releases</a>.</em></p>
<blockquote>
<h2>v0.34.0</h2>
<h2>What's Changed</h2>
<ul>
<li>fix(streamable_http): ensure graceful shutdown to prevent close
reque… by <a
href="https://github.com/sunerpy"><code>@​sunerpy</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/477">mark3labs/mcp-go#477</a></li>
<li>fix(streamble_http) SendNotification not work bug by <a
href="https://github.com/Robin-ZMH"><code>@​Robin-ZMH</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/473">mark3labs/mcp-go#473</a></li>
<li>refactor: replace fmt.Errorf with TransportError wrapper by <a
href="https://github.com/AdamShannag"><code>@​AdamShannag</code></a> in
<a
href="https://redirect.github.com/mark3labs/mcp-go/pull/486">mark3labs/mcp-go#486</a></li>
<li>fix <code>Content-Type: application/json; charset=utf-8</code> error
by <a href="https://github.com/oldweipro"><code>@​oldweipro</code></a>
in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/478">mark3labs/mcp-go#478</a></li>
<li>feat: Inprocess sampling support by <a
href="https://github.com/ezynda3"><code>@​ezynda3</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/487">mark3labs/mcp-go#487</a></li>
<li>feat: support in tool result handling &amp; update example by <a
href="https://github.com/CocaineCong"><code>@​CocaineCong</code></a> in
<a
href="https://redirect.github.com/mark3labs/mcp-go/pull/467">mark3labs/mcp-go#467</a></li>
<li>feat(logging): add support for send log message notifications and
implemented the <code>SessionWithLogging</code> interface on
<code>streamableHttpSession</code> by <a
href="https://github.com/sunerpy"><code>@​sunerpy</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/484">mark3labs/mcp-go#484</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/sunerpy"><code>@​sunerpy</code></a> made
their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/477">mark3labs/mcp-go#477</a></li>
<li><a href="https://github.com/Robin-ZMH"><code>@​Robin-ZMH</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/473">mark3labs/mcp-go#473</a></li>
<li><a
href="https://github.com/AdamShannag"><code>@​AdamShannag</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/486">mark3labs/mcp-go#486</a></li>
<li><a href="https://github.com/oldweipro"><code>@​oldweipro</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/478">mark3labs/mcp-go#478</a></li>
<li><a
href="https://github.com/CocaineCong"><code>@​CocaineCong</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/467">mark3labs/mcp-go#467</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/mark3labs/mcp-go/compare/v0.33.0...v0.34.0">https://github.com/mark3labs/mcp-go/compare/v0.33.0...v0.34.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/ffea75ff8133a2efec8ae549f0a5bc25cd27f8a4"><code>ffea75f</code></a>
feat(logging): add support for send log message notifications and
implemented...</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/e859847efc844f904dac49f8220cb5c911ffed91"><code>e859847</code></a>
feat: support in tool result handling &amp; update example (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/467">#467</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/9c352bd3f37f776d3390b22957da4ad114f114b1"><code>9c352bd</code></a>
feat: Inprocess sampling support (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/487">#487</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/78eb7a3c790dc7de26b9d61039a9527ef4022833"><code>78eb7a3</code></a>
fix <code>Content-Type: application/json; charset=utf-8</code> error (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/478">#478</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/c8c52a8c25536b4cdc1ad7725338a5b0d336f13f"><code>c8c52a8</code></a>
refactor: replace fmt.Errorf with TransportError wrapper (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/486">#486</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/65df1b095c8274f7cb0997fbd1a7bdbf12a2fc43"><code>65df1b0</code></a>
fix(streamble_http) SendNotification not work bug (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/473">#473</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/2d479bb4995a6279223c524f27ad94bf7e7a30cd"><code>2d479bb</code></a>
Merge pull request <a
href="https://redirect.github.com/mark3labs/mcp-go/issues/477">#477</a>
from sunerpy/main</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/bee9f90bab8622796cb7e9348acdaaebcc3cd7ed"><code>bee9f90</code></a>
fix(streamable_http): ensure graceful shutdown to prevent close request
errors</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/56f25011a0a97b4bb60e7742f017ce0ce098ae66"><code>56f2501</code></a>
fix quick-start</li>
<li>See full diff in <a
href="https://github.com/mark3labs/mcp-go/compare/v0.33.0...v0.34.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/mark3labs/mcp-go&package-manager=go_modules&previous-version=0.33.0&new-version=0.34.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 14:13:04 +00:00
dependabot[bot] 6b141d76de ci: bump the github-actions group with 6 updates (#18938)
Bumps the github-actions group with 6 updates:

| Package | From | To |
| --- | --- | --- |
|
[step-security/harden-runner](https://github.com/step-security/harden-runner)
| `2.12.2` | `2.13.0` |
|
[google-github-actions/auth](https://github.com/google-github-actions/auth)
| `2.1.10` | `2.1.11` |
|
[google-github-actions/setup-gcloud](https://github.com/google-github-actions/setup-gcloud)
| `2.1.4` | `2.1.5` |
|
[google-github-actions/get-gke-credentials](https://github.com/google-github-actions/get-gke-credentials)
| `2.3.3` | `2.3.4` |
| [github/codeql-action](https://github.com/github/codeql-action) |
`3.29.2` | `3.29.3` |
|
[umbrelladocs/action-linkspector](https://github.com/umbrelladocs/action-linkspector)
| `1.3.6` | `1.3.7` |

Updates `step-security/harden-runner` from 2.12.2 to 2.13.0
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/step-security/harden-runner/releases">step-security/harden-runner's
releases</a>.</em></p>
<blockquote>
<h2>v2.13.0</h2>
<h2>What's Changed</h2>
<ul>
<li>Improved job markdown summary</li>
<li>Https monitoring for all domains (included with the enterprise
tier)</li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/step-security/harden-runner/compare/v2...v2.13.0">https://github.com/step-security/harden-runner/compare/v2...v2.13.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/step-security/harden-runner/commit/ec9f2d5744a09debf3a187a3f4f675c53b671911"><code>ec9f2d5</code></a>
Merge pull request <a
href="https://redirect.github.com/step-security/harden-runner/issues/565">#565</a>
from step-security/rc-24</li>
<li><a
href="https://github.com/step-security/harden-runner/commit/04bcbc31cfcefe0cf4720832008735021cec5ec4"><code>04bcbc3</code></a>
update agent</li>
<li><a
href="https://github.com/step-security/harden-runner/commit/7c7a56fcaa124ab72fff1cc3e81257f264fd7317"><code>7c7a56f</code></a>
feat: get job summary from API</li>
<li>See full diff in <a
href="https://github.com/step-security/harden-runner/compare/6c439dc8bdf85cadbbce9ed30d1c7b959517bc49...ec9f2d5744a09debf3a187a3f4f675c53b671911">compare
view</a></li>
</ul>
</details>
<br />

Updates `google-github-actions/auth` from 2.1.10 to 2.1.11
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/google-github-actions/auth/releases">google-github-actions/auth's
releases</a>.</em></p>
<blockquote>
<h2>v2.1.11</h2>
<h2>What's Changed</h2>
<ul>
<li>Update troubleshooting docs for Python by <a
href="https://github.com/sethvargo"><code>@​sethvargo</code></a> in <a
href="https://redirect.github.com/google-github-actions/auth/pull/488">google-github-actions/auth#488</a></li>
<li>Add linters by <a
href="https://github.com/sethvargo"><code>@​sethvargo</code></a> in <a
href="https://redirect.github.com/google-github-actions/auth/pull/499">google-github-actions/auth#499</a></li>
<li>Update deps by <a
href="https://github.com/sethvargo"><code>@​sethvargo</code></a> in <a
href="https://redirect.github.com/google-github-actions/auth/pull/500">google-github-actions/auth#500</a></li>
<li>Release: v2.1.11 by <a
href="https://github.com/google-github-actions-bot"><code>@​google-github-actions-bot</code></a>
in <a
href="https://redirect.github.com/google-github-actions/auth/pull/501">google-github-actions/auth#501</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/google-github-actions/auth/compare/v2.1.10...v2.1.11">https://github.com/google-github-actions/auth/compare/v2.1.10...v2.1.11</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/google-github-actions/auth/commit/140bb5113ffb6b65a7e9b937a81fa96cf5064462"><code>140bb51</code></a>
Release: v2.1.11 (<a
href="https://redirect.github.com/google-github-actions/auth/issues/501">#501</a>)</li>
<li><a
href="https://github.com/google-github-actions/auth/commit/ab3132e2ad698521ee1355566103fa838732e48c"><code>ab3132e</code></a>
Update deps (<a
href="https://redirect.github.com/google-github-actions/auth/issues/500">#500</a>)</li>
<li><a
href="https://github.com/google-github-actions/auth/commit/25b96bac992fdf64486c6fd3fd3d9c4cddb3a812"><code>25b96ba</code></a>
Add linters (<a
href="https://redirect.github.com/google-github-actions/auth/issues/499">#499</a>)</li>
<li><a
href="https://github.com/google-github-actions/auth/commit/0920706a19e9d22c3d0da43d1db5939c6ad837a8"><code>0920706</code></a>
Update troubleshooting docs for Python (<a
href="https://redirect.github.com/google-github-actions/auth/issues/488">#488</a>)</li>
<li>See full diff in <a
href="https://github.com/google-github-actions/auth/compare/ba79af03959ebeac9769e648f473a284504d9193...140bb5113ffb6b65a7e9b937a81fa96cf5064462">compare
view</a></li>
</ul>
</details>
<br />

Updates `google-github-actions/setup-gcloud` from 2.1.4 to 2.1.5
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/google-github-actions/setup-gcloud/releases">google-github-actions/setup-gcloud's
releases</a>.</em></p>
<blockquote>
<h2>v2.1.5</h2>
<h2>What's Changed</h2>
<ul>
<li>security: bump undici from 5.28.5 to 5.29.0 in the npm_and_yarn
group by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/google-github-actions/setup-gcloud/pull/711">google-github-actions/setup-gcloud#711</a></li>
<li>Update linters by <a
href="https://github.com/sethvargo"><code>@​sethvargo</code></a> in <a
href="https://redirect.github.com/google-github-actions/setup-gcloud/pull/715">google-github-actions/setup-gcloud#715</a></li>
<li>Update deps by <a
href="https://github.com/sethvargo"><code>@​sethvargo</code></a> in <a
href="https://redirect.github.com/google-github-actions/setup-gcloud/pull/716">google-github-actions/setup-gcloud#716</a></li>
<li>Release: v2.1.5 by <a
href="https://github.com/google-github-actions-bot"><code>@​google-github-actions-bot</code></a>
in <a
href="https://redirect.github.com/google-github-actions/setup-gcloud/pull/717">google-github-actions/setup-gcloud#717</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/google-github-actions/setup-gcloud/compare/v2.1.4...v2.1.5">https://github.com/google-github-actions/setup-gcloud/compare/v2.1.4...v2.1.5</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/google-github-actions/setup-gcloud/commit/6a7c903a70c8625ed6700fa299f5ddb4ca6022e9"><code>6a7c903</code></a>
Release: v2.1.5 (<a
href="https://redirect.github.com/google-github-actions/setup-gcloud/issues/717">#717</a>)</li>
<li><a
href="https://github.com/google-github-actions/setup-gcloud/commit/e838bc6edfe3907980c74d5aad506fd6e173b0d6"><code>e838bc6</code></a>
Update deps (<a
href="https://redirect.github.com/google-github-actions/setup-gcloud/issues/716">#716</a>)</li>
<li><a
href="https://github.com/google-github-actions/setup-gcloud/commit/98d8f78fcc2354c736499a506ad9e7be3f4c2640"><code>98d8f78</code></a>
Update linters (<a
href="https://redirect.github.com/google-github-actions/setup-gcloud/issues/715">#715</a>)</li>
<li><a
href="https://github.com/google-github-actions/setup-gcloud/commit/a8b58010a5b2a061afd605f50e88629c9ec7536b"><code>a8b5801</code></a>
security: bump undici from 5.28.5 to 5.29.0 in the npm_and_yarn group
(<a
href="https://redirect.github.com/google-github-actions/setup-gcloud/issues/711">#711</a>)</li>
<li>See full diff in <a
href="https://github.com/google-github-actions/setup-gcloud/compare/77e7a554d41e2ee56fc945c52dfd3f33d12def9a...6a7c903a70c8625ed6700fa299f5ddb4ca6022e9">compare
view</a></li>
</ul>
</details>
<br />

Updates `google-github-actions/get-gke-credentials` from 2.3.3 to 2.3.4
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/google-github-actions/get-gke-credentials/releases">google-github-actions/get-gke-credentials's
releases</a>.</em></p>
<blockquote>
<h2>v2.3.4</h2>
<h2>What's Changed</h2>
<ul>
<li>security: bump undici from 5.28.5 to 5.29.0 in the npm_and_yarn
group by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/google-github-actions/get-gke-credentials/pull/333">google-github-actions/get-gke-credentials#333</a></li>
<li>Update linters by <a
href="https://github.com/sethvargo"><code>@​sethvargo</code></a> in <a
href="https://redirect.github.com/google-github-actions/get-gke-credentials/pull/334">google-github-actions/get-gke-credentials#334</a></li>
<li>Update deps by <a
href="https://github.com/sethvargo"><code>@​sethvargo</code></a> in <a
href="https://redirect.github.com/google-github-actions/get-gke-credentials/pull/335">google-github-actions/get-gke-credentials#335</a></li>
<li>Release: v2.3.4 by <a
href="https://github.com/google-github-actions-bot"><code>@​google-github-actions-bot</code></a>
in <a
href="https://redirect.github.com/google-github-actions/get-gke-credentials/pull/336">google-github-actions/get-gke-credentials#336</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/google-github-actions/get-gke-credentials/compare/v2.3.3...v2.3.4">https://github.com/google-github-actions/get-gke-credentials/compare/v2.3.3...v2.3.4</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/google-github-actions/get-gke-credentials/commit/8e574c49425fa7efed1e74650a449bfa6a23308a"><code>8e574c4</code></a>
Release: v2.3.4 (<a
href="https://redirect.github.com/google-github-actions/get-gke-credentials/issues/336">#336</a>)</li>
<li><a
href="https://github.com/google-github-actions/get-gke-credentials/commit/820551c1d9b3734a98590d5020e3a479a3600019"><code>820551c</code></a>
Update deps (<a
href="https://redirect.github.com/google-github-actions/get-gke-credentials/issues/335">#335</a>)</li>
<li><a
href="https://github.com/google-github-actions/get-gke-credentials/commit/503071673e50fd4fe5973d69174dc780288d61e9"><code>5030716</code></a>
Update linters (<a
href="https://redirect.github.com/google-github-actions/get-gke-credentials/issues/334">#334</a>)</li>
<li><a
href="https://github.com/google-github-actions/get-gke-credentials/commit/36f99de330d5a168c801b87721b96719a0a9ada0"><code>36f99de</code></a>
security: bump undici from 5.28.5 to 5.29.0 in the npm_and_yarn group
(<a
href="https://redirect.github.com/google-github-actions/get-gke-credentials/issues/333">#333</a>)</li>
<li>See full diff in <a
href="https://github.com/google-github-actions/get-gke-credentials/compare/d0cee45012069b163a631894b98904a9e6723729...8e574c49425fa7efed1e74650a449bfa6a23308a">compare
view</a></li>
</ul>
</details>
<br />

Updates `github/codeql-action` from 3.29.2 to 3.29.3
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/github/codeql-action/releases">github/codeql-action's
releases</a>.</em></p>
<blockquote>
<h2>v3.29.3</h2>
<h1>CodeQL Action Changelog</h1>
<p>See the <a
href="https://github.com/github/codeql-action/releases">releases
page</a> for the relevant changes to the CodeQL CLI and language
packs.</p>
<h2>3.29.3 - 21 Jul 2025</h2>
<p>No user facing changes.</p>
<p>See the full <a
href="https://github.com/github/codeql-action/blob/v3.29.3/CHANGELOG.md">CHANGELOG.md</a>
for more information.</p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/github/codeql-action/blob/main/CHANGELOG.md">github/codeql-action's
changelog</a>.</em></p>
<blockquote>
<h1>CodeQL Action Changelog</h1>
<p>See the <a
href="https://github.com/github/codeql-action/releases">releases
page</a> for the relevant changes to the CodeQL CLI and language
packs.</p>
<h2>[UNRELEASED]</h2>
<p>No user facing changes.</p>
<h2>3.29.3 - 21 Jul 2025</h2>
<p>No user facing changes.</p>
<h2>3.29.2 - 30 Jun 2025</h2>
<ul>
<li>Experimental: When the <code>quality-queries</code> input for the
<code>init</code> action is provided with an argument, separate
<code>.quality.sarif</code> files are produced and uploaded for each
language with the results of the specified queries. Do not use this in
production as it is part of an internal experiment and subject to change
at any time. <a
href="https://redirect.github.com/github/codeql-action/pull/2935">#2935</a></li>
</ul>
<h2>3.29.1 - 27 Jun 2025</h2>
<ul>
<li>Fix bug in PR analysis where user-provided <code>include</code>
query filter fails to exclude non-included queries. <a
href="https://redirect.github.com/github/codeql-action/pull/2938">#2938</a></li>
<li>Update default CodeQL bundle version to 2.22.1. <a
href="https://redirect.github.com/github/codeql-action/pull/2950">#2950</a></li>
</ul>
<h2>3.29.0 - 11 Jun 2025</h2>
<ul>
<li>Update default CodeQL bundle version to 2.22.0. <a
href="https://redirect.github.com/github/codeql-action/pull/2925">#2925</a></li>
<li>Bump minimum CodeQL bundle version to 2.16.6. <a
href="https://redirect.github.com/github/codeql-action/pull/2912">#2912</a></li>
</ul>
<h2>3.28.20 - 21 July 2025</h2>
<ul>
<li>Remove support for combining SARIF files from a single upload for
GHES 3.18, see <a
href="https://github.blog/changelog/2024-05-06-code-scanning-will-stop-combining-runs-from-a-single-upload/">the
changelog post</a>. <a
href="https://redirect.github.com/github/codeql-action/pull/2959">#2959</a></li>
</ul>
<h2>3.28.19 - 03 Jun 2025</h2>
<ul>
<li>The CodeQL Action no longer includes its own copy of the extractor
for the <code>actions</code> language, which is currently in public
preview.
The <code>actions</code> extractor has been included in the CodeQL CLI
since v2.20.6. If your workflow has enabled the <code>actions</code>
language <em>and</em> you have pinned
your <code>tools:</code> property to a specific version of the CodeQL
CLI earlier than v2.20.6, you will need to update to at least CodeQL
v2.20.6 or disable
<code>actions</code> analysis.</li>
<li>Update default CodeQL bundle version to 2.21.4. <a
href="https://redirect.github.com/github/codeql-action/pull/2910">#2910</a></li>
</ul>
<h2>3.28.18 - 16 May 2025</h2>
<ul>
<li>Update default CodeQL bundle version to 2.21.3. <a
href="https://redirect.github.com/github/codeql-action/pull/2893">#2893</a></li>
<li>Skip validating SARIF produced by CodeQL for improved performance.
<a
href="https://redirect.github.com/github/codeql-action/pull/2894">#2894</a></li>
<li>The number of threads and amount of RAM used by CodeQL can now be
set via the <code>CODEQL_THREADS</code> and <code>CODEQL_RAM</code>
runner environment variables. If set, these environment variables
override the <code>threads</code> and <code>ram</code> inputs
respectively. <a
href="https://redirect.github.com/github/codeql-action/pull/2891">#2891</a></li>
</ul>
<h2>3.28.17 - 02 May 2025</h2>
<ul>
<li>Update default CodeQL bundle version to 2.21.2. <a
href="https://redirect.github.com/github/codeql-action/pull/2872">#2872</a></li>
</ul>
<h2>3.28.16 - 23 Apr 2025</h2>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/github/codeql-action/commit/d6bbdef45e766d081b84a2def353b0055f728d3e"><code>d6bbdef</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2977">#2977</a>
from github/update-v3.29.3-7710ed11e</li>
<li><a
href="https://github.com/github/codeql-action/commit/210cc9bfa2103f4b7c4701ee383183b944c62578"><code>210cc9b</code></a>
Update changelog for v3.29.3</li>
<li><a
href="https://github.com/github/codeql-action/commit/7710ed11e398ea99c7f7004c2b2e0f580458db42"><code>7710ed1</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2970">#2970</a>
from github/cklin/diff-informed-feature-enable</li>
<li><a
href="https://github.com/github/codeql-action/commit/6a49a8cbce6ecbd74ea251a48dbc84e64ce3be4d"><code>6a49a8c</code></a>
build: refresh js files</li>
<li><a
href="https://github.com/github/codeql-action/commit/3aef4108d1730e17b6fd24f8b9c49d8fcc87d46d"><code>3aef410</code></a>
Add diff-informed-analysis-utils.test.ts</li>
<li><a
href="https://github.com/github/codeql-action/commit/614b64c6ec97a4ad54f7c99c5becbf593144dbfb"><code>614b64c</code></a>
Diff-informed analysis: disable for GHES below 3.19</li>
<li><a
href="https://github.com/github/codeql-action/commit/aefb854fe5563f4650638224c839c6e9b33c25b5"><code>aefb854</code></a>
Feature.DiffInformedQueries: default to true</li>
<li><a
href="https://github.com/github/codeql-action/commit/03a2a17e75d20e4ff461b43f161fb2b52165f632"><code>03a2a17</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2967">#2967</a>
from github/cklin/overlay-feature-flags</li>
<li><a
href="https://github.com/github/codeql-action/commit/07455ed3c36f739ad76d1c4e55f8b49550f74344"><code>07455ed</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2972">#2972</a>
from github/koesie10/ghes-satisfies</li>
<li><a
href="https://github.com/github/codeql-action/commit/3fb562ddcce3ca92b83ea1bb7abaa579a1ab882d"><code>3fb562d</code></a>
build: refresh js files</li>
<li>Additional commits viewable in <a
href="https://github.com/github/codeql-action/compare/181d5eefc20863364f96762470ba6f862bdef56b...d6bbdef45e766d081b84a2def353b0055f728d3e">compare
view</a></li>
</ul>
</details>
<br />

Updates `umbrelladocs/action-linkspector` from 1.3.6 to 1.3.7
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/umbrelladocs/action-linkspector/releases">umbrelladocs/action-linkspector's
releases</a>.</em></p>
<blockquote>
<h2>Release v1.3.7</h2>
<p>v1.3.7: PR <a
href="https://redirect.github.com/umbrelladocs/action-linkspector/issues/47">#47</a>
- Update linkspector version to 0.4.7</p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/UmbrellaDocs/action-linkspector/commit/874d01cae9fd488e3077b08952093235bd626977"><code>874d01c</code></a>
Merge pull request <a
href="https://redirect.github.com/umbrelladocs/action-linkspector/issues/47">#47</a>
from UmbrellaDocs/update-linkspector-version</li>
<li><a
href="https://github.com/UmbrellaDocs/action-linkspector/commit/bfc5bc55f5a8fc268165639b78b3ce6ae64915ad"><code>bfc5bc5</code></a>
Update linkspector version to 0.4.7</li>
<li>See full diff in <a
href="https://github.com/umbrelladocs/action-linkspector/compare/3a951c1f0dca72300c2320d0eb39c2bafe429ab1...874d01cae9fd488e3077b08952093235bd626977">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 13:21:37 +00:00
Hugo Dutka ceb4b973b4 chore: run full macos and windows pg tests in the nightly gauntlet (#18787)
This PR starts running the full test suite on Windows and macOS in the
nightly gauntlet, since the regular CI only runs agent and cli tests.
The full suite is too slow to be run on every PR.
2025-07-21 15:18:49 +02:00
Danielle Maywood f751f81052 fix(coderd): fix flake in TestAPI/ModifyAutostopWithRunningWorkspace (#18932)
Fixes https://github.com/coder/internal/issues/521

This happened due to a race condition present in how
`AwaitWorkspaceBuildJobCompleted` works.

`AwaitWorkspaceBuildJobCompleted` works by waiting until
`/api/v2/workspacesbuilds/{workspacebuild}/` returns a workspace build
with `.Job.CompletedAt != nil`. The issue here is that _sometimes_ the
returned `codersdk.WorkspaceBuild` can contain a build from _before_ a
provisioner job completed, but contain the provisioner job from _after_
it completed.

Let me demonstrate:

Here we query the database for `database.WorkspaceBuild`.

https://github.com/coder/coder/blob/a3f64f74f794c733126ad21cd1feb0801caf67c4/coderd/coderd.go#L1409-L1415

Inside of the `workspaceBuild` route handler, we call
`workspaceBuildsData`

https://github.com/coder/coder/blob/a3f64f74f794c733126ad21cd1feb0801caf67c4/coderd/workspacebuilds.go#L54

This then calls `GetProvisionerJobsByIDsWithQueuePosition`

https://github.com/coder/coder/blob/a3f64f74f794c733126ad21cd1feb0801caf67c4/coderd/workspacebuilds.go#L852-L856

As these two calls happen _outside of a transaction_, the state of the
world can change underneath. This can result in an in-progress workspace
build having a completed provisioner job attached to it.
2025-07-21 13:04:28 +01:00
Thomas Kosiewski 0d3b7703f7 docs: remove dbmem references from documentation files (#18861)
Change-Id: Ic33bc383d00d0e354c25a0dd6080a4307d9862b6
Signed-off-by: Thomas Kosiewski <tk@coder.com>
2025-07-21 11:21:58 +02:00
dependabot[bot] 7c66dcd238 chore: bump terraform-google-modules/container-vm/google from 3.0.0 to 3.2.0 in /examples/templates/gcp-vm-container (#18925)
Bumps
[terraform-google-modules/container-vm/google](https://github.com/terraform-google-modules/terraform-google-container-vm)
from 3.0.0 to 3.2.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/releases">terraform-google-modules/container-vm/google's
releases</a>.</em></p>
<blockquote>
<h2>v3.2.0</h2>
<h2><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/compare/v3.1.1...v3.2.0">3.2.0</a>
(2024-08-29)</h2>
<h3>Features</h3>
<ul>
<li><strong>deps:</strong> Update Terraform Google Provider to v6
(major) (<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/138">#138</a>)
(<a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/b8065338e38b51230f06aec573a2f8027c30c566">b806533</a>)</li>
</ul>
<h2>v3.1.1</h2>
<h2><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/compare/v3.1.0...v3.1.1">3.1.1</a>
(2024-01-08)</h2>
<h3>Bug Fixes</h3>
<ul>
<li><strong>deps:</strong> lint updates for cft/developer-tools v1.18
(<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/123">#123</a>)
(<a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/2d57bef2f9ff75f5ca0a0b7f5d21985b823be1a6">2d57bef</a>)</li>
<li>upgraded versions.tf to include minor bumps from tpg v5 (<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/118">#118</a>)
(<a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/14fcdf3463b254098a5bc4a6e01003b3eee2d75c">14fcdf3</a>)</li>
</ul>
<h2>v3.1.0</h2>
<h2><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/compare/v3.0.1...v3.1.0">3.1.0</a>
(2022-09-19)</h2>
<h3>Features</h3>
<ul>
<li>expose cos_project variable (<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/91">#91</a>)
(<a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/b32263d30cf2a61d20ddbca94733bf3abfb7a446">b32263d</a>)</li>
</ul>
<h2>v3.0.1</h2>
<h2><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/compare/v3.0.0...v3.0.1">3.0.1</a>
(2022-07-20)</h2>
<h3>Bug Fixes</h3>
<ul>
<li>restart policy kills konlet-startup container fix for the value
Never (<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/87">#87</a>)
(<a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/fcbdafa2d5b00792c388dcda1e1715f5e2a615e6">fcbdafa</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/blob/main/CHANGELOG.md">terraform-google-modules/container-vm/google's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/compare/v3.1.1...v3.2.0">3.2.0</a>
(2024-08-29)</h2>
<h3>Features</h3>
<ul>
<li><strong>deps:</strong> Update Terraform Google Provider to v6
(major) (<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/138">#138</a>)
(<a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/b8065338e38b51230f06aec573a2f8027c30c566">b806533</a>)</li>
</ul>
<h2><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/compare/v3.1.0...v3.1.1">3.1.1</a>
(2024-01-08)</h2>
<h3>Bug Fixes</h3>
<ul>
<li><strong>deps:</strong> lint updates for cft/developer-tools v1.18
(<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/123">#123</a>)
(<a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/2d57bef2f9ff75f5ca0a0b7f5d21985b823be1a6">2d57bef</a>)</li>
<li>upgraded versions.tf to include minor bumps from tpg v5 (<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/118">#118</a>)
(<a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/14fcdf3463b254098a5bc4a6e01003b3eee2d75c">14fcdf3</a>)</li>
</ul>
<h2><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/compare/v3.0.1...v3.1.0">3.1.0</a>
(2022-09-19)</h2>
<h3>Features</h3>
<ul>
<li>expose cos_project variable (<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/91">#91</a>)
(<a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/b32263d30cf2a61d20ddbca94733bf3abfb7a446">b32263d</a>)</li>
</ul>
<h2><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/compare/v3.0.0...v3.0.1">3.0.1</a>
(2022-07-20)</h2>
<h3>Bug Fixes</h3>
<ul>
<li>restart policy kills konlet-startup container fix for the value
Never (<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/87">#87</a>)
(<a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/fcbdafa2d5b00792c388dcda1e1715f5e2a615e6">fcbdafa</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/ceba2c777b5fbdc74debcbad63b02f94b6abcb60"><code>ceba2c7</code></a>
chore(master): release 3.2.0 (<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/139">#139</a>)</li>
<li><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/b8065338e38b51230f06aec573a2f8027c30c566"><code>b806533</code></a>
feat(deps): Update Terraform Google Provider to v6 (major) (<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/138">#138</a>)</li>
<li><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/b9c7fdd2cd0bd09942440ac372fdee47bde57db9"><code>b9c7fdd</code></a>
chore(deps): Update cft/developer-tools Docker tag to v1.22 (<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/136">#136</a>)</li>
<li><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/5efa4d20a97b4b30c4392bbf5d788e65f0dd51c7"><code>5efa4d2</code></a>
chore(deps): Update cft/developer-tools Docker tag to v1.21 (<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/131">#131</a>)</li>
<li><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/d9045637650a82354f11b4d170b96f20b2a00167"><code>d904563</code></a>
chore(deps): Update Terraform
terraform-google-modules/project-factory/google...</li>
<li><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/30b7909f74ef3228daac07c771366e910059e9f5"><code>30b7909</code></a>
chore(deps): Update Terraform terraform-google-modules/vm/google to v11
(<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/129">#129</a>)</li>
<li><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/5dc397e54a63e9ae63bc165a80e35b2a18ff6d99"><code>5dc397e</code></a>
chore(deps): Update cft/developer-tools Docker tag to v1.19 (<a
href="https://redirect.github.com/terraform-google-modules/terraform-google-container-vm/issues/128">#128</a>)</li>
<li><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/aefea73c5602277b4876e3b0d14f7aaa90151bcc"><code>aefea73</code></a>
chore: update .github/workflows/lint.yaml</li>
<li><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/924324901e4219d7e4d72d8168b2f90dbc1d923b"><code>9243249</code></a>
chore: update CODEOWNERS</li>
<li><a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/commit/8361f4d105e415b166c1ddcbcc080ff31360058b"><code>8361f4d</code></a>
chore: update .github/workflows/stale.yml</li>
<li>Additional commits viewable in <a
href="https://github.com/terraform-google-modules/terraform-google-container-vm/compare/v3.0.0...v3.2.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=terraform-google-modules/container-vm/google&package-manager=terraform&previous-version=3.0.0&new-version=3.2.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 09:05:33 +00:00
Thomas Kosiewski fcd361d374 feat: add logo SVG and replace inline SVG with image reference (#18930)
# Replace SVG with external logo file in OAuth2 authorization page

This PR replaces the inline SVG logo in the OAuth2 authorization page with a reference to an external SVG file. The change:

1. Adds a new `logo.svg` file in the static directory with the Coder logo
2. Updates the OAuth2 authorization page to use this external file instead of embedding the SVG directly

This approach improves maintainability by centralizing the logo in a single file and reduces duplication in the codebase.
2025-07-21 11:04:21 +02:00
blink-so[bot] f3c1353322 docs: fix typo 'protyping' to 'prototyping' in AI Coding Agents page (#18928)
Fixes #18926

Simple typo fix: changed 'protyping' to 'prototyping' in the AI Coding
Agents documentation page.

Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: bpmct <22407953+bpmct@users.noreply.github.com>
2025-07-20 20:16:19 +00:00
Thomas Kosiewski 7b06fc77ae refactor: simplify OAuth2 authorization flow and use 302 redirects (#18923)
# Refactor OAuth2 Provider Authorization Flow

This PR refactors the OAuth2 provider authorization flow by:

1. Removing the `authorizeMW` middleware and directly implementing its functionality in the `ShowAuthorizePage` handler
2. Simplifying function signatures by removing unnecessary parameters:
   - Removed `db` parameter from `ShowAuthorizePage`
   - Removed `accessURL` parameter from `ProcessAuthorize`
3. Changing the redirect status code in `ProcessAuthorize` from 307 (Temporary Redirect) to 302 (Found) to improve compatibility with external OAuth2 apps and browsers. (Technical explanation: we replied with a 307 to a POST request, thus the browser performs a redirect to that URL as a POST request, but we need it to be a GET request to be compatible. Thus, we use the 302 redirect so that browsers turn it into a GET request when redirecting back to the redirect_uri.)

The changes maintain the same functionality while simplifying the code and improving compatibility with external systems.
2025-07-20 16:22:52 +02:00
Thomas Kosiewski 071383bbe8 feat: add RFC 9728 OAuth2 resource metadata support (#18920)
# Enhanced OAuth2 and MCP Compliance for API Authentication

This PR improves OAuth2 and MCP (Microsoft Cloud for Sovereignty)
compliance by:

1. Adding RFC 9728 compliant `WWW-Authenticate` headers with resource
metadata URLs
2. Passing the configured `AccessURL` to API key middleware for proper
audience validation
3. Creating specialized CORS handling for OAuth2 and MCP endpoints with
appropriate headers
4. Making the `state` parameter optional in OAuth2 authorization
requests

These changes ensure proper OAuth2 token audience validation against the
configured access URL and improve interoperability with OAuth2 clients
by providing better error responses and metadata discovery.

Signed-off-by: Thomas Kosiewski <tk@coder.com>
2025-07-19 22:05:15 +02:00
Michael Smith f47efc62ee fix(site): speed up state syncs and validate input for debounce hook logic (#18877)
No issue to link – I'm basically pushing some updates upstream from the
version of the hook I copied over for the Registry website.

## Changes made
- Updated debounce functions to have input validation for timeouts
- Updated `useDebouncedValue` to flush state syncs immediately if
timeout value is `0`
- Updated tests to reflect changes
- Cleaned up some comments and parameter names to make things more clear
2025-07-17 18:15:42 -04:00
DevCats 6746e16502 docs: add contribution documentation for modules and templates (#18820)
draft: add contribution docs for modules and templates individually to
be referenced in coder docs manifest.

---------

Co-authored-by: Atif Ali <atif@coder.com>
2025-07-17 16:23:42 -05:00
Dean Sheather 183a6ebbdf chore: add managed_agent_limit licensing feature (#18876)
Note that enforcement and checking usage will come in a future PR.

This feature is implemented differently than existing features in a few
ways.

It's highly recommended that reviewers read:
- This document which outlines the methods we could've used for license
enforcement:
https://www.notion.so/coderhq/AI-Agent-License-Enforcement-21ed579be59280c088b9c1dc5e364ee8
- Phase 0 of the actual RFC document:
https://www.notion.so/coderhq/Usage-based-Billing-AI-b-210d579be592800eb257de7eecd2d26d

### Multiple features in the license, a single feature in codersdk

Firstly, the feature is represented as a single feature in the codersdk
world, but is represented with multiple features in the license.

E.g. in the license you may have:

    {
      "features": {
        "managed_agent_limit_soft": 100,
        "managed_agent_limit_hard": 200
      }
    }

But the entitlements endpoint will return a single feature:

    {
      "features": {
        "managed_agent_limit": {
          "limit": 200,
          "soft_limit": 100
        }
      }
    }

This is required because of our rigid parsing that uses a
`map[string]int64` for features in the license. To avoid requiring all
customers to upgrade to use new licenses, the decision was made to just
use two features and merge them into one. Older Coder deployments will
parse this feature (from new licenses) as two separate features, but
it's not a problem because they don't get used anywhere obviously.

The reason we want to differentiate between a "soft" and "hard" limit is
so we can show admins how much of the usage is "included" vs. how much
they can use before they get hard cut-off.

### Usage period features will be compared and trump based on license
issuance time

The second major difference to other features is that "usage period"
features such as `managed_agent_limit` will now be primarily compared by
the `iat` (issued at) claim of the license they come from. This differs
from previous features. The reason this was done was so we could reduce
limits with newer licenses, which the current comparison code does not
allow for.

This effectively means if you have two active licenses:
- `iat`: 2025-07-14, `managed_agent_limit_soft`: 100,
`managed_agent_limit_hard`: 200
- `iat`: 2025-07-15, `managed_agent_limit_soft`: 50,
`managed_agent_limit_hard`: 100

Then the resulting `managed_agent_limit` entitlement will come from the
second license, even though the values are smaller than another valid
license. The existing comparison code would prefer the first license
even though it was issued earlier.

### Usage period features will count usage between the start and end
dates of the license

Existing limit features, like the user limit, just measure the current
usage value of the feature. The active user count is a gauge that goes
up and down, whereas agent usage can only be incremented, so it doesn't
make sense to use a continually incrementing counter forever and ever
for managed agents.

For managed agent limit, we count the usage between `nbf` (not before)
and `exp` (expires at) of the license that the entitlement comes from.
In the example above, we'd use the issued at date and expiry of the
second license as this date range.

This essentially means, when you get a new license, the usage resets to
zero.

The actual usage counting code will be implemented in a follow-up PR.

### Managed agent limit has a default entitlement value

Temporarily (until further notice), we will be providing licenses with
`feature_set` set to `premium` a default limit.
- Soft limit: `800 * user_limit`
- Hard limit: `1000 * user_limit`

"Enterprise" licenses do not get any default limit and are not entitled
to use the feature.

Unlicensed customers (e.g. OSS) will be permitted to use the feature as
much as they want without limits. This will be implemented when the
counting code is implemented in a follow-up PR.

Closes https://github.com/coder/internal/issues/760
2025-07-17 20:19:01 +10:00
Dean Sheather a1b87a67c6 fix: use client preferred URL for the default DERP (#18911)
The agentsdk currently does a remap of the DERP map to change the
EmbeddedRelay node's URL to match the agent's access URL.

This PR makes changes to the `workspacesdk` (used by clients like the
CLI) and `vpn` (used by Coder Desktop) to match this behavior.

This enables us the ability to try Coder clients in dogfood over a VPN
without changing the global access URL.
2025-07-17 20:17:44 +10:00
Danielle Maywood fb00cd2c1a fix(agent/agentcontainers): fix TestAPI/NoUpdaterLoopLogspam flake (#18905) 2025-07-17 10:59:02 +01:00
Atif Ali aae5fc243a chore(dogfood): add JetBrains fleet ide module (#18817)
We need to dogfood this new fleet module.

> [!NOTE]
> Only works if Coder CLI or Coder Desktop is installed
2025-07-17 10:17:38 +05:00
Edward Angert d304fb4f2d docs: hotfix mainline version number in docs/install/releases to 2.24.2 (#18906)
hotfix

[preview](https://coder.com/docs/@2-24-mainline/install/releases)

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
2025-07-17 10:16:59 +05:00
Danielle Maywood bfb9aa464d fix(site): only attempt to watch when dev containers enabled (#18892) 2025-07-17 00:03:59 +01:00
Atif Ali ca6b5e3415 docs: update port forwarding docs to include Coder Desktop (#18870)
Noticed that Coder Desktop was missing from port-forwarding docs which
is kind of a big feature for Coder Connect.


[preview](https://coder.com/docs/@atif%2Fdesktop-ports/user-guides/workspace-access/port-forwarding)

---------

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
Co-authored-by: Edward Angert <EdwardAngert@users.noreply.github.com>
2025-07-16 19:57:55 +00:00
Marcin Tojek b4c9725443 chore: update ascii logo (#18899)
This PR updates the ASCII logo in the HTML output.
2025-07-16 14:33:46 -03:00
ケイラ 0cdcf89069 chore: update CODEOWNERS (#18891) 2025-07-15 14:52:05 -06:00
ケイラ 9774264928 chore: add image style for kiro.svg (#18889)
The `whiteWithColor` style gives this image a more appropriate treatment
on light themes
2025-07-15 14:09:00 -06:00
blink-so[bot] e76115c67d chore: add kiro: protocol to external app whitelist (#18884)
Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: matifali <10648092+matifali@users.noreply.github.com>
2025-07-15 18:45:16 +00:00
Atif Ali 5758594ff7 chore: add kiro icon (#18881) 2025-07-15 23:41:21 +05:00
ケイラ 52c4b61391 feat: add search to parameter dropdowns (#18729) 2025-07-15 11:23:49 -06:00
Susana Ferreira dad033ee3d fix(site): exclude workspace schedule settings for prebuilt workspaces (#18826)
## Description

This PR updates the UI to avoid rendering workspace schedule settings
(autostop, autostart, etc.) for prebuilt workspaces. Instead, it
displays an informational message with a link to the relevant
documentation.

## Changes

* Introduce `IsPrebuild` parameter to `convertWorkspace` to indicate
whether the workspace is a prebuild.
* Prevent the Workspace Schedule settings form from rendering in the UI
for prebuilt workspaces.
* Display an info alert with a link to documentation when viewing a
prebuilt workspace.

<img width="2980" height="864" alt="Screenshot 2025-07-10 at 13 16 13"
src="https://github.com/user-attachments/assets/5f831c21-50bb-4e05-beea-dbeb930ddff8"
/>


Relates with: https://github.com/coder/coder/pull/18762

---------

Co-authored-by: BrunoQuaresma <bruno_nonato_quaresma@hotmail.com>
2025-07-15 14:11:04 +01:00
Jakub Domeracki e4d3453e2b feat: publish CLI binaries and detached signatures to releases.coder.com (#18874)
Starting with version `2.24.X `, Coder CLI binaries & corresponding
detached signatures will get published to the GCS bucket
releases.coder.com.
2025-07-15 13:15:58 +02:00
Danielle Maywood 089f9603ed fix(site): only attempt to watch containers when agent connected (#18873)
This PR ensures we do not attempt to call `containers/watch` on the
agent _before_ it is connected.
2025-07-15 11:16:14 +01:00
dependabot[bot] 43546336c9 chore: bump github.com/gohugoio/hugo from 0.147.0 to 0.148.1 (#18852)
Bumps [github.com/gohugoio/hugo](https://github.com/gohugoio/hugo) from
0.147.0 to 0.148.1.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/gohugoio/hugo/releases">github.com/gohugoio/hugo's
releases</a>.</em></p>
<blockquote>
<h2>v0.148.1</h2>
<h2>What's Changed</h2>
<ul>
<li>Fix assignment to entry in nil map 6f42cfbc9 <a
href="https://github.com/bep"><code>@​bep</code></a> <a
href="https://redirect.github.com/gohugoio/hugo/issues/13853">#13853</a></li>
<li>deps: Downgrade github.com/niklasfasching/go-org v1.9.0 =&gt; v1.8.0
a84beee42 <a href="https://github.com/bep"><code>@​bep</code></a> <a
href="https://redirect.github.com/gohugoio/hugo/issues/13846">#13846</a></li>
</ul>
<h2>v0.148.0</h2>
<blockquote>
<p>[!NOTE]<br />
There's some minor breaking changes in this release. Please <a
href="https://discourse.gohugo.io/t/breaking-changes-in-v0-148-0/55257">read
this</a> thread for more information.</p>
</blockquote>
<h2>Note</h2>
<ul>
<li>Fix some uglyURLs issues for home, section and taxonomy kind (note)
b8ba33ca9 <a href="https://github.com/bep"><code>@​bep</code></a> <a
href="https://redirect.github.com/gohugoio/hugo/issues/4428">#4428</a>
<a
href="https://redirect.github.com/gohugoio/hugo/issues/7497">#7497</a></li>
<li>Fix branch paths when OutputFormat.Path is configured (note)
f967212b7 <a href="https://github.com/bep"><code>@​bep</code></a> <a
href="https://redirect.github.com/gohugoio/hugo/issues/13829">#13829</a></li>
</ul>
<h2>Bug fixes</h2>
<ul>
<li>resources/page: Allow full datetime prefix in filenames 1b4c42366 <a
href="https://github.com/jmooring"><code>@​jmooring</code></a> <a
href="https://redirect.github.com/gohugoio/hugo/issues/13830">#13830</a></li>
</ul>
<h2>Improvements</h2>
<ul>
<li>Add Ancestors (plural) method to GitInfo, rename Ancestor field to
Parent 3e2f1cdfd <a href="https://github.com/bep"><code>@​bep</code></a>
<a
href="https://redirect.github.com/gohugoio/hugo/issues/13839">#13839</a></li>
<li>Allow creating home pages from content adapters bba6996e1 <a
href="https://github.com/bep"><code>@​bep</code></a></li>
<li>Remove the internal GitInfo type and make Page.GitInf() return a
pointer 90d397b14 <a
href="https://github.com/bep"><code>@​bep</code></a> <a
href="https://redirect.github.com/gohugoio/hugo/issues/5693">#5693</a></li>
<li>source: Expose Ancestor in GitInfo 61e6c730d <a
href="https://github.com/jenbroek"><code>@​jenbroek</code></a> <a
href="https://redirect.github.com/gohugoio/hugo/issues/5693">#5693</a></li>
<li>config: Increase test coverage 266d46dcc <a
href="https://github.com/pixel365"><code>@​pixel365</code></a></li>
<li>markup/goldmark: Change link and image render hook enablement to
enums 84b31721b <a
href="https://github.com/jmooring"><code>@​jmooring</code></a> <a
href="https://redirect.github.com/gohugoio/hugo/issues/13535">#13535</a></li>
<li>hugolib: Honor implicit &quot;page&quot; type during template
selection cfc8d315b <a
href="https://github.com/jmooring"><code>@​jmooring</code></a> <a
href="https://redirect.github.com/gohugoio/hugo/issues/13826">#13826</a></li>
<li>deploy: walkLocal worker pool for performance dd6e2c872 <a
href="https://github.com/davidejones"><code>@​davidejones</code></a></li>
</ul>
<h2>Dependency Updates</h2>
<ul>
<li>build(deps): bump github.com/evanw/esbuild from 0.25.5 to 0.25.6
0a5b87028 <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]</li>
<li>build(deps): bump github.com/olekukonko/tablewriter from 1.0.7 to
1.0.8 94e2c276a <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]</li>
<li>build(deps): bump github.com/niklasfasching/go-org from 1.8.0 to
1.9.0 e77b2ad8f <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]</li>
<li>build(deps): bump github.com/alecthomas/chroma/v2 from 2.18.0 to
2.19.0 9487acf6a <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]</li>
<li>build(deps): bump golang.org/x/tools from 0.32.0 to 0.34.0 1e9a0b93e
<a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]</li>
</ul>
<h2>v0.147.9</h2>
<h2>Improvements and fixes</h2>
<ul>
<li>Remove WARN with false negatives 6a4a3ab8f <a
href="https://github.com/bep"><code>@​bep</code></a> <a
href="https://redirect.github.com/gohugoio/hugo/issues/13806">#13806</a></li>
<li>resources/page: Make sure a map is always initialized 36f6f987a <a
href="https://github.com/bep"><code>@​bep</code></a> <a
href="https://redirect.github.com/gohugoio/hugo/issues/13810">#13810</a></li>
<li>tpl/tplimpl: Copy embedded HTML table render hook to each output
format 18a9ca7d7 <a
href="https://github.com/jmooring"><code>@​jmooring</code></a> <a
href="https://redirect.github.com/gohugoio/hugo/issues/13351">#13351</a></li>
<li>tpl/tplimpl: Change resources.GetRemote errors to suppressible
warnings b6c8dfa9d <a
href="https://github.com/jmooring"><code>@​jmooring</code></a> <a
href="https://redirect.github.com/gohugoio/hugo/issues/13803">#13803</a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/gohugoio/hugo/commit/98ba786f2f5dca0866f47ab79f394370bcb77d2f"><code>98ba786</code></a>
releaser: Bump versions for release of 0.148.1</li>
<li><a
href="https://github.com/gohugoio/hugo/commit/6f42cfbc9b80a6e1639e3c0661f530e84590fa6a"><code>6f42cfb</code></a>
Fix assignment to entry in nil map</li>
<li><a
href="https://github.com/gohugoio/hugo/commit/a84beee429d3b0297b1a97b191d641154f7c2e81"><code>a84beee</code></a>
deps: Downgrade github.com/niklasfasching/go-org v1.9.0 =&gt;
v1.8.0</li>
<li><a
href="https://github.com/gohugoio/hugo/commit/65893efd8d1f52d50bd589d84a4c9031d96e7d8d"><code>65893ef</code></a>
releaser: Prepare repository for 0.149.0-DEV</li>
<li><a
href="https://github.com/gohugoio/hugo/commit/c0d9bebacc6bf42a91a74d8bb0de7bc775c8e573"><code>c0d9beb</code></a>
releaser: Bump versions for release of 0.148.0</li>
<li><a
href="https://github.com/gohugoio/hugo/commit/3e2f1cdfdbeb8a1470b216bfb28b78ab14b8c0f4"><code>3e2f1cd</code></a>
Add Ancestors (plural) method to GitInfo, rename Ancestor field to
Parent</li>
<li><a
href="https://github.com/gohugoio/hugo/commit/0a5b870281a47d1045443c081968fc96f8d5e06f"><code>0a5b870</code></a>
build(deps): bump github.com/evanw/esbuild from 0.25.5 to 0.25.6</li>
<li><a
href="https://github.com/gohugoio/hugo/commit/bba6996e15570e542193a043054de3b00cd96e18"><code>bba6996</code></a>
Allow creating home pages from content adapters</li>
<li><a
href="https://github.com/gohugoio/hugo/commit/94e2c276a8592488eedc07e259147425ddf91c2b"><code>94e2c27</code></a>
build(deps): bump github.com/olekukonko/tablewriter from 1.0.7 to
1.0.8</li>
<li><a
href="https://github.com/gohugoio/hugo/commit/90d397b14299b1cb03a6b3a3e9e1ce6dfc36cdad"><code>90d397b</code></a>
Remove the internal GitInfo type and make Page.GitInf() return a
pointer</li>
<li>Additional commits viewable in <a
href="https://github.com/gohugoio/hugo/compare/v0.147.0...v0.148.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/gohugoio/hugo&package-manager=go_modules&previous-version=0.147.0&new-version=0.148.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-15 09:27:09 +00:00
Susana Ferreira f1eec2d267 fix(cli): scope context per subtest to fix flake test in prebuilt workspace delete (#18872)
## Description

This PR fixes a flaky test in
`TestDelete/Prebuilt_workspace_delete_permissions`:
https://github.com/coder/internal/issues/764

Previously, all subtests used the same context created at the top level.
Since the subtests run in parallel, they could run for too long and
cause the shared context to expire. This sometimes led to context
deadline exceeded errors, especially during the `testutil.Eventually`
check for running prebuilt workspaces.

The fix is to create a fresh context per subtest, ensuring they are
isolated and not prematurely cancelled due to other subtests' durations.
2025-07-15 10:21:11 +01:00
dependabot[bot] c643214b47 chore: bump google.golang.org/api from 0.231.0 to 0.241.0 (#18849)
Bumps
[google.golang.org/api](https://github.com/googleapis/google-api-go-client)
from 0.231.0 to 0.241.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/googleapis/google-api-go-client/releases">google.golang.org/api's
releases</a>.</em></p>
<blockquote>
<h2>v0.241.0</h2>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.240.0...v0.241.0">0.241.0</a>
(2025-07-09)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3219">#3219</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/987e4abe1e113ac37f42f378bb05eac44c65e448">987e4ab</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3221">#3221</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/7e31abbe694798ee20645793367f57ecf9f3740b">7e31abb</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3222">#3222</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/3346ebb0706a0fce703f5ada0182522b7a1d6dc8">3346ebb</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3223">#3223</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/f94c92cafe32e768ec48307db9924d8b746b3d25">f94c92c</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3224">#3224</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/3f1f756570d556a0e26f7594bcc3353eabc0a5ea">3f1f756</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3225">#3225</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/8799cd8e4cadab9c6dad2c63a8c199cd1e0e3f2e">8799cd8</a>)</li>
</ul>
<h2>v0.240.0</h2>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.239.0...v0.240.0">0.240.0</a>
(2025-07-02)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3210">#3210</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/c0efdb50d507feb4340e7b1ad2be61eaa9960ba7">c0efdb5</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3212">#3212</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/c699558a9c2b574bdda5d9d697c7fadaeb65b3c1">c699558</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3214">#3214</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/7b435988338692bdfcae2c174f41a8bb71c4abb1">7b43598</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3215">#3215</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/22e2c3806882276b2437288c2ebf84204cb7c077">22e2c38</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3216">#3216</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/e8c35043996ce513a5cd829da72a79c1c46206ad">e8c3504</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3217">#3217</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/604190c29e745ca177927b465d3855008b1e1902">604190c</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3218">#3218</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/0a46af7bb3db597ef1d459191b3bc55345c61692">0a46af7</a>)</li>
</ul>
<h2>v0.239.0</h2>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.238.0...v0.239.0">0.239.0</a>
(2025-06-25)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3199">#3199</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/2bdd042ac9a9b4115ea14239f4ffc6d947b3ead8">2bdd042</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3201">#3201</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/8eff56f43f278eb7072da807eb492969d9b6ec00">8eff56f</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3202">#3202</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/f7c299e9c00588b68e02e6fa464ab92a7d7f70d4">f7c299e</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3203">#3203</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/459c5a8db5a2262fa9d4fd5031f8bd81569fe751">459c5a8</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3205">#3205</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/ca610d5390bb286d5f815ee8d296a7cdf7dd4baa">ca610d5</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3206">#3206</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/98b739881e1fd09b2f2b7c0122b675fb02625b7c">98b7398</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3207">#3207</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/71fe287d9c34180ed81ede37531b37b23a7c11dc">71fe287</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3209">#3209</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/27d1aa43d1fb592c0273a5617af68d397d1c9ac7">27d1aa4</a>)</li>
</ul>
<h2>v0.238.0</h2>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.237.0...v0.238.0">0.238.0</a>
(2025-06-17)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3192">#3192</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/3ad311895f95da734942ad4bc527f32412d1ad4f">3ad3118</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3196">#3196</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/8cb55ce5040dbcc0de4436f1d47de876bebf607a">8cb55ce</a>)</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/googleapis/google-api-go-client/blob/main/CHANGES.md">google.golang.org/api's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.240.0...v0.241.0">0.241.0</a>
(2025-07-09)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3219">#3219</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/987e4abe1e113ac37f42f378bb05eac44c65e448">987e4ab</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3221">#3221</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/7e31abbe694798ee20645793367f57ecf9f3740b">7e31abb</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3222">#3222</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/3346ebb0706a0fce703f5ada0182522b7a1d6dc8">3346ebb</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3223">#3223</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/f94c92cafe32e768ec48307db9924d8b746b3d25">f94c92c</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3224">#3224</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/3f1f756570d556a0e26f7594bcc3353eabc0a5ea">3f1f756</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3225">#3225</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/8799cd8e4cadab9c6dad2c63a8c199cd1e0e3f2e">8799cd8</a>)</li>
</ul>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.239.0...v0.240.0">0.240.0</a>
(2025-07-02)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3210">#3210</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/c0efdb50d507feb4340e7b1ad2be61eaa9960ba7">c0efdb5</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3212">#3212</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/c699558a9c2b574bdda5d9d697c7fadaeb65b3c1">c699558</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3214">#3214</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/7b435988338692bdfcae2c174f41a8bb71c4abb1">7b43598</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3215">#3215</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/22e2c3806882276b2437288c2ebf84204cb7c077">22e2c38</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3216">#3216</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/e8c35043996ce513a5cd829da72a79c1c46206ad">e8c3504</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3217">#3217</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/604190c29e745ca177927b465d3855008b1e1902">604190c</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3218">#3218</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/0a46af7bb3db597ef1d459191b3bc55345c61692">0a46af7</a>)</li>
</ul>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.238.0...v0.239.0">0.239.0</a>
(2025-06-25)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3199">#3199</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/2bdd042ac9a9b4115ea14239f4ffc6d947b3ead8">2bdd042</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3201">#3201</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/8eff56f43f278eb7072da807eb492969d9b6ec00">8eff56f</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3202">#3202</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/f7c299e9c00588b68e02e6fa464ab92a7d7f70d4">f7c299e</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3203">#3203</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/459c5a8db5a2262fa9d4fd5031f8bd81569fe751">459c5a8</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3205">#3205</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/ca610d5390bb286d5f815ee8d296a7cdf7dd4baa">ca610d5</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3206">#3206</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/98b739881e1fd09b2f2b7c0122b675fb02625b7c">98b7398</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3207">#3207</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/71fe287d9c34180ed81ede37531b37b23a7c11dc">71fe287</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3209">#3209</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/27d1aa43d1fb592c0273a5617af68d397d1c9ac7">27d1aa4</a>)</li>
</ul>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.237.0...v0.238.0">0.238.0</a>
(2025-06-17)</h2>
<h3>Features</h3>
<ul>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3192">#3192</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/3ad311895f95da734942ad4bc527f32412d1ad4f">3ad3118</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3196">#3196</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/8cb55ce5040dbcc0de4436f1d47de876bebf607a">8cb55ce</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3197">#3197</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/98994c400492542ca9f7d89e608dccbdb89caa11">98994c4</a>)</li>
<li><strong>all:</strong> Auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3198">#3198</a>)
(<a
href="https://github.com/googleapis/google-api-go-client/commit/582459736e746998eecb609b0d23ddce778d5d8c">5824597</a>)</li>
</ul>
<h2><a
href="https://github.com/googleapis/google-api-go-client/compare/v0.236.0...v0.237.0">0.237.0</a>
(2025-06-12)</h2>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/f942bc9f863a4851f9d67e0aea8ce7fcafb635e2"><code>f942bc9</code></a>
chore(main): release 0.241.0 (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3220">#3220</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/8799cd8e4cadab9c6dad2c63a8c199cd1e0e3f2e"><code>8799cd8</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3225">#3225</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/3f1f756570d556a0e26f7594bcc3353eabc0a5ea"><code>3f1f756</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3224">#3224</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/f94c92cafe32e768ec48307db9924d8b746b3d25"><code>f94c92c</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3223">#3223</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/3346ebb0706a0fce703f5ada0182522b7a1d6dc8"><code>3346ebb</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3222">#3222</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/7e31abbe694798ee20645793367f57ecf9f3740b"><code>7e31abb</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3221">#3221</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/987e4abe1e113ac37f42f378bb05eac44c65e448"><code>987e4ab</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3219">#3219</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/9f7dd0d6600833ed29eb7dcefe7e9ad1f203ba36"><code>9f7dd0d</code></a>
chore(main): release 0.240.0 (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3211">#3211</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/0a46af7bb3db597ef1d459191b3bc55345c61692"><code>0a46af7</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3218">#3218</a>)</li>
<li><a
href="https://github.com/googleapis/google-api-go-client/commit/604190c29e745ca177927b465d3855008b1e1902"><code>604190c</code></a>
feat(all): auto-regenerate discovery clients (<a
href="https://redirect.github.com/googleapis/google-api-go-client/issues/3217">#3217</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/googleapis/google-api-go-client/compare/v0.231.0...v0.241.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=google.golang.org/api&package-manager=go_modules&previous-version=0.231.0&new-version=0.241.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-15 09:16:22 +00:00
dependabot[bot] bfdacae286 chore: bump the x group across 1 directory with 9 updates (#18851)
Bumps the x group with 4 updates in the / directory:
[golang.org/x/crypto](https://github.com/golang/crypto),
[golang.org/x/mod](https://github.com/golang/mod),
[golang.org/x/net](https://github.com/golang/net) and
[golang.org/x/oauth2](https://github.com/golang/oauth2).

Updates `golang.org/x/crypto` from 0.39.0 to 0.40.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/crypto/commit/459a9db11b9c43bb1d61722bfd371751d6de05c9"><code>459a9db</code></a>
go.mod: update golang.org/x dependencies</li>
<li><a
href="https://github.com/golang/crypto/commit/74e709ad8a8068445173aa5f3e8d7c89caf510c3"><code>74e709a</code></a>
ssh: add AlgorithmNegotiationError</li>
<li><a
href="https://github.com/golang/crypto/commit/b3790b8d914304c8187dc2c86800101c329d77cd"><code>b3790b8</code></a>
acme: fix TLSALPN01ChallengeCert for IP address identifiers</li>
<li><a
href="https://github.com/golang/crypto/commit/1dc4269656dd23b2c4e71c51b8af6bc2b63eecb7"><code>1dc4269</code></a>
acme: add Pebble integration testing</li>
<li><a
href="https://github.com/golang/crypto/commit/97bf78725562ce22e18036873215f2203b3e0e1e"><code>97bf787</code></a>
blake2b: implement hash.XOF</li>
<li><a
href="https://github.com/golang/crypto/commit/952517d181d424f6c77f7460bf728205cb048411"><code>952517d</code></a>
x509roots/fallback: update bundle</li>
<li><a
href="https://github.com/golang/crypto/commit/c6fce028266aa1271946a7dfde94cd71cf077d5e"><code>c6fce02</code></a>
ssh: refuse to parse certificates that use a certificate as signing
key</li>
<li><a
href="https://github.com/golang/crypto/commit/0ae49b8145643036e0e6c266cf4edc0f543ea9e0"><code>0ae49b8</code></a>
ssh: reject certificate keys used as signature keys for SSH certs</li>
<li>See full diff in <a
href="https://github.com/golang/crypto/compare/v0.39.0...v0.40.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/mod` from 0.25.0 to 0.26.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/mod/commit/ea04085b103002db3b0d02d6ebbd97a0ffa29202"><code>ea04085</code></a>
go.mod: update golang.org/x dependencies</li>
<li>See full diff in <a
href="https://github.com/golang/mod/compare/v0.25.0...v0.26.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/net` from 0.41.0 to 0.42.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/net/commit/76358aa57e0c5fa267fe08795631a173d0cec833"><code>76358aa</code></a>
go.mod: update golang.org/x dependencies</li>
<li>See full diff in <a
href="https://github.com/golang/net/compare/v0.41.0...v0.42.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/oauth2` from 0.29.0 to 0.30.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/oauth2/commit/cf1431934151b3a93e0b3286eb6798ca08ea3770"><code>cf14319</code></a>
oauth2: fix expiration time window check</li>
<li><a
href="https://github.com/golang/oauth2/commit/32d34ef364e670a650fe59267b92301ff7ed08f1"><code>32d34ef</code></a>
internal: include clientID in auth style cache key</li>
<li><a
href="https://github.com/golang/oauth2/commit/2d34e3091be3f4b4700842fb663dad98a10ddfb6"><code>2d34e30</code></a>
oauth2: replace a magic number with AuthStyleUnknown</li>
<li><a
href="https://github.com/golang/oauth2/commit/696f7b31289a98558822be146698b7834e477e63"><code>696f7b3</code></a>
all: modernize with doc links and any</li>
<li><a
href="https://github.com/golang/oauth2/commit/471209bbe29fc1e3bf8d4ca3ca89d67f8817d521"><code>471209b</code></a>
oauth2: drop dependency on go-cmp</li>
<li><a
href="https://github.com/golang/oauth2/commit/6968da209b8fd816452d22ad1b4faca197a5b974"><code>6968da2</code></a>
oauth2: sync Token.ExpiresIn from internal Token</li>
<li><a
href="https://github.com/golang/oauth2/commit/d2c4e0a6256426212864554628e234ebe6005347"><code>d2c4e0a</code></a>
oauth2: context instead of golang.org/x/net/context in doc</li>
<li><a
href="https://github.com/golang/oauth2/commit/883dc3c9d87d538c301ebff2ccdcc8b6a0b92890"><code>883dc3c</code></a>
endpoints: add various endpoints from stale CLs</li>
<li><a
href="https://github.com/golang/oauth2/commit/1c06e8705ef848db9c7553a78b630b9b9f138a87"><code>1c06e87</code></a>
all: make use of oauth.Token.ExpiresIn</li>
<li>See full diff in <a
href="https://github.com/golang/oauth2/compare/v0.29.0...v0.30.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/sync` from 0.15.0 to 0.16.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/sync/commit/7fad2c9213e0821bd78435a9c106806f2fc383f1"><code>7fad2c9</code></a>
errgroup: revert propagation of panics</li>
<li>See full diff in <a
href="https://github.com/golang/sync/compare/v0.15.0...v0.16.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/sys` from 0.33.0 to 0.34.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/sys/commit/751c3c6ac2a644645976e8e7f3db0b75c87d32c6"><code>751c3c6</code></a>
unix: add missing NFT_PAYLOAD_* consts on linux</li>
<li><a
href="https://github.com/golang/sys/commit/0c740cc0f8b112e19e255caefb622a53779c0481"><code>0c740cc</code></a>
unix: update Go to 1.24.3</li>
<li><a
href="https://github.com/golang/sys/commit/d62d31c6166a69390ea553149bf921e215216610"><code>d62d31c</code></a>
unix: update Linux constants and types to v6.14</li>
<li>See full diff in <a
href="https://github.com/golang/sys/compare/v0.33.0...v0.34.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/term` from 0.32.0 to 0.33.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/term/commit/30da5dd58fc835bf6704fa7464ac3d23202d8685"><code>30da5dd</code></a>
go.mod: update golang.org/x dependencies</li>
<li>See full diff in <a
href="https://github.com/golang/term/compare/v0.32.0...v0.33.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/text` from 0.26.0 to 0.27.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/text/commit/b6d26456dd3ff554a56f10b1e388db0f8ca862d1"><code>b6d2645</code></a>
go.mod: update golang.org/x dependencies</li>
<li>See full diff in <a
href="https://github.com/golang/text/compare/v0.26.0...v0.27.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `golang.org/x/tools` from 0.33.0 to 0.34.0
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/golang/tools/commit/578c1213983a83e6411536ddf6bbf3a1faf97aea"><code>578c121</code></a>
go.mod: update golang.org/x dependencies</li>
<li><a
href="https://github.com/golang/tools/commit/f114dcf97d4f35feb86030bb9e1c5c8fc6fd8942"><code>f114dcf</code></a>
gopls/internal/protocol: refine DocumentURI Clean method and its
usages</li>
<li><a
href="https://github.com/golang/tools/commit/82ee0fd1228b85b95daadd1901e83a9200d661e6"><code>82ee0fd</code></a>
internal/mcp: change paginateList to a generic helper</li>
<li><a
href="https://github.com/golang/tools/commit/64bfecc32e163d2684a85b73472919e02da50180"><code>64bfecc</code></a>
gopls/internal/golang: fix extract bug with anon functions</li>
<li><a
href="https://github.com/golang/tools/commit/4546fbd0b20190ede82382b293ae4440923ecaea"><code>4546fbd</code></a>
internal/mcp: unify json tag parsing</li>
<li><a
href="https://github.com/golang/tools/commit/82473ce934847055bec96f8a96e4d1fc38ecefa9"><code>82473ce</code></a>
gopls/doc/release: tweak v0.19</li>
<li><a
href="https://github.com/golang/tools/commit/f3c581ff0cb8b4b87129f04094005c4b0f962bf9"><code>f3c581f</code></a>
gopls/internal/protocol: add DocumentURI.Base accessor</li>
<li><a
href="https://github.com/golang/tools/commit/d9bacab54dfed6ac3f871f422bb0b2cb5eb5c428"><code>d9bacab</code></a>
gopls/internal/server: improve &quot;editing generated file&quot;
warning</li>
<li><a
href="https://github.com/golang/tools/commit/1afeefa8150f171e0a8f0948015513b31d59d2f3"><code>1afeefa</code></a>
internal/mcp: unexport FileResourceHandler</li>
<li><a
href="https://github.com/golang/tools/commit/33d59880f345d37e4262f5f8e504ddfb6818266b"><code>33d5988</code></a>
gopls/internal/server: Organize Imports of generated files</li>
<li>Additional commits viewable in <a
href="https://github.com/golang/tools/compare/v0.33.0...v0.34.0">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ethan Dickson <ethan@coder.com>
2025-07-15 09:04:20 +00:00
Danielle Maywood bd3d0ea482 fix(agent/agentcontainers): fix TestAPI/IgnoreCustomization flake (#18863) 2025-07-15 10:01:04 +01:00
blink-so[bot] 87e5365f79 docs: add cloud-specific database instance recommendations (#18862)
Enhances the Performance efficiency section in the validated
architectures documentation with specific instance type recommendations
for AWS, Azure, and GCP.

**Changes:**
- Added recommended instance types for small, medium, and large
deployments across all three major cloud providers
- Included guidance on avoiding burstable instances (t-family, B-series)
for production workloads
- Added note about CPU baseline limitations for burstable instances

This addresses customer questions about appropriate database instance
sizing.

---------

Signed-off-by: Danny Kopping <dannykopping@gmail.com>
Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: dannykopping <373762+dannykopping@users.noreply.github.com>
Co-authored-by: Danny Kopping <dannykopping@gmail.com>
2025-07-15 09:53:34 +01:00
Ethan de4a270316 docs: improve audit logs copy (#18807)
Many of the issues with the copy on #18739 were because I blindly copied from the audit logs page. This PR adds Edward's copy suggestions from that PR to the audit logs page.

[preview](https://coder.com/docs/@ethan-improve-audit-logs-copy/admin/security/audit-logs)

I've included this in the PR stack, as the previous PR modifies the auto-gen docs for audit logs.
2025-07-15 16:14:30 +10:00
Ethan ef807e41ce chore: mark workspace apps and workspace agents as unaudited (#18761)
The main goal of this PR is to remove Workspace Apps and Workspace Agents from the auto-generated audit log documentation, that incorrectly claims they are audited resources (no longer true with the addition of the connection log).

Though I believe we haven't touched any codepaths for returning audit logs, this PR also adds a test that ensures we continue to return *existing* connection, disconnect and open events correctly from the audit log API.
2025-07-15 16:08:42 +10:00
Ethan 6b17aee425 docs: add connection logs page (#18739)
This is the final PR for moving connection logs out of the audit log and into the new connection logs page.

This PR documents the feature.

[preview](https://coder.com/docs/@ethan%2Fdocs-add-connection-logs/admin/monitoring/connection-logs)
2025-07-15 15:52:41 +10:00
Ethan f42de9fe12 chore!: delete old connection events from audit log (#18735)
### Breaking change (changelog note):
>With new connection events appearing in the Connection Log, connection events older than 90 days will now be deleted from the Audit Log. If you require this legacy data, we recommend querying it from the REST API or making a backup of the database/these events before upgrading your Coder deployment. Please see the PR for details on what exactly will be deleted. 
Of note is that there are currently no plans to delete connection events from the Connection Log.


### Context

This is the fifth PR for moving connection events out of the audit log.

In previous PRs:
- **New** connection logs have been routed to the `connection_logs` table. They will *not* appear in the audit log.
- These new connection logs are served from the new `/api/v2/connectionlog` endpoint.

In this PR:
- We'll now clean existing connection events out of the audit log, if they are older than 90 days, We do this in batches of 1000, every 10 minutes.

The criteria for deletion is simple:
```
WHERE
(
     action = 'connect'
     OR action = 'disconnect'
     OR action = 'open'
     OR action = 'close'
)
AND "time" < @before_time::timestamp with time zone
```
where `@before_time` is currently configured to 90 days in the past.


Future PRs:
- Write documentation for the endpoint / feature
2025-07-15 15:45:36 +10:00
Ethan b5260d5699 feat(site): add connection log page (#18708)
This is the fourth PR for moving connection events out of the audit log.

This PR adds `/connectionlog` to the frontend. This page is identical in structure to the audit log, but with different filters and contents.

The connection log lists sessions, and the time they start. If we support tracking the end time of a session, and we've received a disconnect event for that session, the end timestamp is also included.
       
Demo:


https://github.com/user-attachments/assets/e0fff799-0ed6-45f7-a8c0-237839659ef9



<img width="346" alt="image" src="https://github.com/user-attachments/assets/6de29945-55c2-4fe5-9a4f-d42e476ded25" />
<img width="184" alt="image" src="https://github.com/user-attachments/assets/e83234bc-4d9d-4f71-b668-9256a600659c" />


Since the styling is identical to that of the audit log, I've continued to use MUI table components. When the audit log is migrated off MUI/restyled, this table can be too, relatively easily.

Future PRs:
- Write a query to delete old events from the audit log, call it from dbpurge.
- Write documentation for the endpoint / feature
2025-07-15 15:11:31 +10:00
Cian Johnston 1ee6b8d5b1 chore: fix flake in TestWorkspaceBuildsProvisionerState (#18839)
Fixes https://github.com/coder/internal/issues/761
2025-07-15 15:07:13 +10:00
Ethan 7c077d39c5 chore: populate connectionlog count using a separate query (#18629)
This is the third PR for moving connection events out of the audit log.

This PR populates `count` on `ConnectionLogResponse` using a separate query, to preemptively mitigate the issue described in #17689. It's structurally identical to a portion of https://github.com/coder/coder/pull/18600, but for the connection log instead of the audit log.
       
Future PRs:
- Implement a table in the Web UI for viewing connection logs.
- Write a query to delete old events from the audit log, call it from dbpurge.
- Write documentation for the endpoint / feature
2025-07-15 15:03:30 +10:00
Ethan 7a339a1ffe feat: add connectionlogs API (#18628)
This is the second PR for moving connection events out of the audit log.

This PR:
- Adds the `/api/v2/connectionlog` endpoint
- Adds filtering for `GetAuthorizedConnectionLogsOffset` and thus the endpoint. 
There's quite a few, but I was aiming for feature parity with the audit log.
  1. `organization:<id|name>`
  2. `workspace_owner:<username>`
  3. `workspace_owner_email:<email>`
  4. `type:<ssh|vscode|jetbrains|reconnecting_pty|workspace_app|port_forwarding>`
  5. `username:<username>` 
     - Only includes web-based connection events (workspace apps, web port forwarding) as only those include user metadata.
  6. `user_email:<email>`
  7. `connected_after:<time>`
  8. `connected_before:<time>`
  9. `workspace_id:<id>`
  10. `connection_id:<id>`
      - If you have one snapshot of the connection log, and some sessions are ongoing in that snapshot, you could use this filter to check if they've been closed since.
  11. `status:<connected|disconnected>`
       - If `connected` only sessions with a null `close_time` are returned, if `disconnected`, only those with a non-null `close_time`. If filter is omitted, both are returned.
       
Future PRs:
- Populate `count` on `ConnectionLogResponse` using a seperate query (to preemptively mitigate the issue described in #17689)
- Implement a table in the Web UI for viewing connection logs.
- Write a query to delete old events from the audit log, call it from dbpurge.
- Write documentation for the endpoint / feature (including these filters)
2025-07-15 14:55:34 +10:00
Ethan 08e17a07fc chore!: route connection logs to new table (#18340)
### Breaking Change (changelog note):
> User connections to workspaces, and the opening of workspace apps or ports will no longer create entries in the audit log. Those events will now be included in the 'Connection Log'.
Please see the 'Connection Log' page in the dashboard, and the Connection Log [documentation](https://coder.com/docs/admin/monitoring/connection-logs) for details. Those with permission to view the Audit Log will also be able to view the Connection Log. The new Connection Log has the same licensing restrictions as the Audit Log, and requires a Premium Coder deployment.

### Context

This is the first PR of a few for moving connection events out of the audit log, and into a new database table and web UI page called the 'Connection Log'.

This PR:
- Creates the new table
- Adds and tests queries for inserting and reading, including reading with an RBAC filter.
- Implements the corresponding RBAC changes, such that anyone who can view the audit log can read from the table
- Implements, under the enterprise package, a `ConnectionLogger` abstraction to replace the `Auditor` abstraction for these logs. (No-op'd in AGPL, like the `Auditor`)
- Routes SSH connection and Workspace App events into the new `ConnectionLogger`
- Updates all existing tests to check the values of the `ConnectionLogger` instead of the `Auditor`.

Future PRs:
- Add filtering to the query
- Add an enterprise endpoint to query the new table
- Write a query to delete old events from the audit log, call it from dbpurge.
- Implement a table in the Web UI for viewing connection logs.


> [!NOTE]
> The PRs in this stack obviously won't be (completely) atomic. Whilst they'll each pass CI, the stack is designed to be merged all at once. I'm splitting them up for the sake of those reviewing, and so changes can be reviewed as early as possible.  Despite this, it's really hard to make this PR any smaller than it already is. I'll be keeping it in draft until it's actually ready to merge.
2025-07-15 14:36:06 +10:00
Danielle Maywood 43b0bb7f61 feat(site): use websocket connection for devcontainer updates (#18808)
Instead of polling every 10 seconds, we instead use a WebSocket
connection for more timely updates.
2025-07-14 21:35:35 +01:00
Edward Angert 7cf3263fbd docs: document issue with macos coder desktop behind vpn (#18855)
docs for https://github.com/coder/coder-desktop-macos/issues/201 and
https://github.com/coder/coder-desktop-windows/issues/147

> If the logged in Coder deployment requires a VPN to connect, Coder
Connect can't establish communication through the VPN,
> and will time out.


[preview](https://coder.com/docs/@201-desktop-mac-vpn/user-guides/desktop)

---------

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
Co-authored-by: Dean Sheather <dean@deansheather.com>
2025-07-14 12:33:48 -04:00
Spike Curtis 4980f18022 ci: remove retries/reruns (#18788)
Removes retries / reruns from our CI as they are masking flaky tests
that don't get fixed.

Also limits the Windows and macOS postgresql tests to the CLI and Agent
for now, since we don't officially support coderd on these platforms and
they are particularly flaky.
2025-07-14 17:40:33 +02:00
dependabot[bot] 2e34a1e404 chore: bump github.com/hashicorp/hcl/v2 from 2.23.0 to 2.24.0 (#18854)
Bumps [github.com/hashicorp/hcl/v2](https://github.com/hashicorp/hcl)
from 2.23.0 to 2.24.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/hashicorp/hcl/releases">github.com/hashicorp/hcl/v2's
releases</a>.</em></p>
<blockquote>
<h2>v2.24.0</h2>
<h3>Enhancements</h3>
<ul>
<li>Add support for decoding block and attribute source ranges when
using <code>gohcl</code>. (<a
href="https://redirect.github.com/hashicorp/hcl/pull/703">#703</a>)</li>
<li>hclsyntax: Detect and reject invalid nested splat result. (<a
href="https://redirect.github.com/hashicorp/hcl/pull/724">#724</a>)</li>
</ul>
<h3>Bugs Fixed</h3>
<ul>
<li>Correct handling of unknown objects in Index function. (<a
href="https://redirect.github.com/hashicorp/hcl/pull/763">#763</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/hashicorp/hcl/blob/main/CHANGELOG.md">github.com/hashicorp/hcl/v2's
changelog</a>.</em></p>
<blockquote>
<h2>v2.24.0 (July 7, 2025)</h2>
<h3>Enhancements</h3>
<ul>
<li>Add support for decoding block and attribute source ranges when
using <code>gohcl</code>. (<a
href="https://redirect.github.com/hashicorp/hcl/pull/703">#703</a>)</li>
<li>hclsyntax: Detect and reject invalid nested splat result. (<a
href="https://redirect.github.com/hashicorp/hcl/pull/724">#724</a>)</li>
</ul>
<h3>Bugs Fixed</h3>
<ul>
<li>Correct handling of unknown objects in Index function. (<a
href="https://redirect.github.com/hashicorp/hcl/pull/763">#763</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/hashicorp/hcl/commit/6b5068090eef06b1f127f61529db5ba0be7ed343"><code>6b50680</code></a>
Update CHANGELOG.md (<a
href="https://redirect.github.com/hashicorp/hcl/issues/764">#764</a>)</li>
<li><a
href="https://github.com/hashicorp/hcl/commit/77ef278eaae165adbe82d39a1b8e7707ad7d501a"><code>77ef278</code></a>
ops: handle unknown objects correctly when looking up by index (<a
href="https://redirect.github.com/hashicorp/hcl/issues/763">#763</a>)</li>
<li><a
href="https://github.com/hashicorp/hcl/commit/dfa124f3c93ff1764fda03702a7a9aa8c9db48d8"><code>dfa124f</code></a>
[Compliance] - PR Template Changes Required (<a
href="https://redirect.github.com/hashicorp/hcl/issues/761">#761</a>)</li>
<li><a
href="https://github.com/hashicorp/hcl/commit/6b5c4c2bac7140d1f676d294e99ff5d696b8fbf9"><code>6b5c4c2</code></a>
fix errors thrown by errcheck linter (<a
href="https://redirect.github.com/hashicorp/hcl/issues/755">#755</a>)</li>
<li><a
href="https://github.com/hashicorp/hcl/commit/61bd79dedd738d45edd16f6eb0ca405d0484a7b7"><code>61bd79d</code></a>
suppress and fix lint errors by unused (<a
href="https://redirect.github.com/hashicorp/hcl/issues/754">#754</a>)</li>
<li><a
href="https://github.com/hashicorp/hcl/commit/8b8cb9c9fa85c1f91083ee866c0ca3d1b910404b"><code>8b8cb9c</code></a>
build(deps): bump golangci/golangci-lint-action</li>
<li><a
href="https://github.com/hashicorp/hcl/commit/aa4e44796409371ce1f3d452c81b334d7bbdbfcc"><code>aa4e447</code></a>
build(deps): bump actions/setup-go</li>
<li><a
href="https://github.com/hashicorp/hcl/commit/72443636fe97ebb2e1ce1aa2bfa87dd426d8a88f"><code>7244363</code></a>
Update go-cty to latest (<a
href="https://redirect.github.com/hashicorp/hcl/issues/749">#749</a>)</li>
<li><a
href="https://github.com/hashicorp/hcl/commit/b4e27ae471da2b5a30329239713f7f3ed630c2dc"><code>b4e27ae</code></a>
test_suite: refactor schema validation of diagnostic file range, pos (<a
href="https://redirect.github.com/hashicorp/hcl/issues/750">#750</a>)</li>
<li><a
href="https://github.com/hashicorp/hcl/commit/314d2366eadcbd243f2988a535587d7fea94442e"><code>314d236</code></a>
fix staticcheck lint errors</li>
<li>Additional commits viewable in <a
href="https://github.com/hashicorp/hcl/compare/v2.23.0...v2.24.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/hashicorp/hcl/v2&package-manager=go_modules&previous-version=2.23.0&new-version=2.24.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-14 14:57:09 +00:00
dependabot[bot] b56c6a1d2d ci: bump the github-actions group with 3 updates (#18853)
Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-14 14:53:45 +00:00
dependabot[bot] b2cf55fd71 chore: bump github.com/mark3labs/mcp-go from 0.32.0 to 0.33.0 (#18850)
Bumps [github.com/mark3labs/mcp-go](https://github.com/mark3labs/mcp-go)
from 0.32.0 to 0.33.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/mark3labs/mcp-go/releases">github.com/mark3labs/mcp-go's
releases</a>.</em></p>
<blockquote>
<h2>Release v0.33.0</h2>
<h2>What's Changed</h2>
<ul>
<li>fix(server): Fix the logic of the WithStateLess function by <a
href="https://github.com/dcsunny"><code>@​dcsunny</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/387">mark3labs/mcp-go#387</a></li>
<li>fix(srv/stream): correct handleGet status code to 200 by <a
href="https://github.com/cryo-zd"><code>@​cryo-zd</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/379">mark3labs/mcp-go#379</a></li>
<li>Add an example of an in process client by <a
href="https://github.com/edwardcqian"><code>@​edwardcqian</code></a> in
<a
href="https://redirect.github.com/mark3labs/mcp-go/pull/371">mark3labs/mcp-go#371</a></li>
<li>feat: add type-safe array items helper functions by <a
href="https://github.com/davidleitw"><code>@​davidleitw</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/396">mark3labs/mcp-go#396</a></li>
<li>Issue 400 fix by <a
href="https://github.com/ozzyozbourne"><code>@​ozzyozbourne</code></a>
in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/406">mark3labs/mcp-go#406</a></li>
<li>fix(client/transport/stream): check for nil pointer by <a
href="https://github.com/dinistavares"><code>@​dinistavares</code></a>
in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/404">mark3labs/mcp-go#404</a></li>
<li>feat: add ResourceLink type and parsing support by <a
href="https://github.com/chenmingyong0423"><code>@​chenmingyong0423</code></a>
in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/407">mark3labs/mcp-go#407</a></li>
<li>Fix docs by <a
href="https://github.com/ezynda3"><code>@​ezynda3</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/430">mark3labs/mcp-go#430</a></li>
<li>feat: client-side streamable-http transport supports continuously
listening by <a
href="https://github.com/leavez"><code>@​leavez</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/317">mark3labs/mcp-go#317</a></li>
<li>feature: add support ResourceTemplates to mcptest package by <a
href="https://github.com/Slach"><code>@​Slach</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/449">mark3labs/mcp-go#449</a></li>
<li>Add support for MCP host session management by <a
href="https://github.com/C0deKing"><code>@​C0deKing</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/466">mark3labs/mcp-go#466</a></li>
<li>docs: Fix unused import in readme example by <a
href="https://github.com/Squiry"><code>@​Squiry</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/469">mark3labs/mcp-go#469</a></li>
<li>Support creating an <code>Stdio</code> client with options by <a
href="https://github.com/peteski22"><code>@​peteski22</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/457">mark3labs/mcp-go#457</a></li>
<li>Implement sampling in Stdio by <a
href="https://github.com/ezynda3"><code>@​ezynda3</code></a> in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/461">mark3labs/mcp-go#461</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/dcsunny"><code>@​dcsunny</code></a> made
their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/387">mark3labs/mcp-go#387</a></li>
<li><a
href="https://github.com/edwardcqian"><code>@​edwardcqian</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/371">mark3labs/mcp-go#371</a></li>
<li><a
href="https://github.com/davidleitw"><code>@​davidleitw</code></a> made
their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/396">mark3labs/mcp-go#396</a></li>
<li><a
href="https://github.com/ozzyozbourne"><code>@​ozzyozbourne</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/406">mark3labs/mcp-go#406</a></li>
<li><a
href="https://github.com/dinistavares"><code>@​dinistavares</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/404">mark3labs/mcp-go#404</a></li>
<li><a
href="https://github.com/chenmingyong0423"><code>@​chenmingyong0423</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/407">mark3labs/mcp-go#407</a></li>
<li><a href="https://github.com/Slach"><code>@​Slach</code></a> made
their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/449">mark3labs/mcp-go#449</a></li>
<li><a href="https://github.com/C0deKing"><code>@​C0deKing</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/466">mark3labs/mcp-go#466</a></li>
<li><a href="https://github.com/Squiry"><code>@​Squiry</code></a> made
their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/469">mark3labs/mcp-go#469</a></li>
<li><a href="https://github.com/peteski22"><code>@​peteski22</code></a>
made their first contribution in <a
href="https://redirect.github.com/mark3labs/mcp-go/pull/457">mark3labs/mcp-go#457</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/mark3labs/mcp-go/compare/v0.32.0...v0.33.0">https://github.com/mark3labs/mcp-go/compare/v0.32.0...v0.33.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/6a54215f5b4cdeb1ab9ed602bcf87ebb0222e691"><code>6a54215</code></a>
Implement sampling in Stdio (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/461">#461</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/656a7b4cab77cb913b5f9613c547859596499d6a"><code>656a7b4</code></a>
Support creating an <code>Stdio</code> client with options (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/457">#457</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/01e802f3854d9591f791a39fc148e57768681267"><code>01e802f</code></a>
Fix unused import in readme example (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/469">#469</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/d0fa06e9209195f89bb22b3c952ec038f7d1905a"><code>d0fa06e</code></a>
Add support for MCP host session management (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/466">#466</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/251da138d6b5ade77bb2155e0aa294843cb16337"><code>251da13</code></a>
feature: add support ResourceTemplates to mcptest package (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/449">#449</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/1eddde7bd69b760f745a1b4064969cffcf97e935"><code>1eddde7</code></a>
feat: client-side streamable-http transport supports continuously
listening ...</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/8f5b048218f6d044c3322f16b8cb0b08e10bf5d0"><code>8f5b048</code></a>
Fix docs (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/430">#430</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/0fdb1974c5728a74ae061e650d25bf90c5c43437"><code>0fdb197</code></a>
feat: add ResourceLink type and parsing support (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/407">#407</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/d807ae7b7ac1c2b3c24347d1d602506b9cdcd998"><code>d807ae7</code></a>
fix(client/transport/stream): check for nil pointer (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/404">#404</a>)</li>
<li><a
href="https://github.com/mark3labs/mcp-go/commit/93176e8a70cffc2886bd446fe8464badcd5035da"><code>93176e8</code></a>
fixed nil error (<a
href="https://redirect.github.com/mark3labs/mcp-go/issues/406">#406</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/mark3labs/mcp-go/compare/v0.32.0...v0.33.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/mark3labs/mcp-go&package-manager=go_modules&previous-version=0.32.0&new-version=0.33.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-14 14:31:57 +00:00
Edward Angert 78af5e0f53 docs: add note about incompatible immutable parameters behavior to parameters doc (#18814)
closes #18370 

workspace creation page checks for

1. required parameters
2. incompatible immutable parameters

and if there's an issue, disables the **Create workspace** button until
it's resolved


[preview](https://coder.com/docs/@18370-immutable-params/admin/templates/extending-templates/parameters#mutability)

---------

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
2025-07-14 11:43:43 +00:00
Atif Ali 3126f21d87 revert: "docs: add coder registry link to docs sidebar" (#18837) 2025-07-11 16:09:23 +00:00
Atif Ali c25e666d12 docs: add coder registry link to docs sidebar (#18585)
I am not sure if this works

---------

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
Co-authored-by: Edward Angert <EdwardAngert@users.noreply.github.com>
2025-07-11 08:12:09 -04:00
Edward Angert 040fa30aba docs: update screenshots with new logo (#18830)
stage 1 of many

- new login screenshot
- remove unused platforms screenshots
- update [screenshots
doc](https://coder.com/docs/@2025-screenshots/about/screenshots)
- update [quickstart
doc](https://coder.com/docs/@2025-screenshots/tutorials/quickstart)

closes #18813 

<details><summary>list of screenshots with old logo or that are
outdated</summary>

|docs/images/|notes?|
|--|--|
|logo-black.png| |
|jupyter-notebook.png| |
|platforms/docker/login.png| |
|platforms/docker/create-workspace.png| |
|platforms/docker/ides.png| |
|platforms/gcp/marketplace.png| |
|platforms/gcp/start.png| |
|platforms/aws/aws-linux.png| |
|platforms/aws/marketplace.png| |
|platforms/kubernetes/template-variables.png| |
|platforms/kubernetes/region-picker.png| |
|platforms/kubernetes/starter-template.png| |
|install/windows-installer.png| |
|install/homebrew.png| |
|screenshots/create-template.png| |
|screenshots/login.png| |
|screenshots/starter_templates.png| |
|screenshots/settings.png| |
|screenshots/audit.png| |
|screenshots/workspace-running-with-topbar.png| |
|screenshots/workspaces_listing.png| |
|screenshots/templates_listing.png| |
|screenshots/welcome-create-admin-user.png| |
|screenshots/workspace_launch.png| |
|screenshots/templates_insights.png| |
|screenshots/healthcheck.png| |
|screenshots/terraform.png| |
|deploy-pr-manually.png| |
|workspace-update.png| |
|custom-app.png| |
|code-server.png| |
|networking/annotatedports.png| |
|networking/portsharingmax.png| |
|networking/portforwarddashboard.png| |
|networking/listeningports.png| |
|agent-metadata.png| |
|jupyter.png| |
|admin/service-banner-maintenance.png| |
|admin/provisioner-tags.png| |
|admin/github-app-register.png| |
|admin/licenses/licenses-screen.png| |
|admin/licenses/licenses-nolicense.png| |
|admin/licenses/add-license-ui.png| |
|admin/service-banner-config.png| |
|admin/group-allowlist.png| |
|admin/networking/workspace-proxies/ws-proxy-picker.png| |
|admin/setup/appearance/application-name-logo-url.png| |
|admin/setup/appearance/announcement_banner_settings.png| |
|admin/setup/appearance/support-links.png| |
|admin/setup/appearance/service-banner-secret.png| |
|admin/quota-buildlog.png| |
|admin/integrations/kube-region-picker.png| |
|admin/integrations/coder-logstream-kube-logs-wrong-image.png| |
|admin/integrations/coder-logstream-kube-logs-pod-crashed.png| |
|admin/integrations/coder-logstream-kube-logs-normal.png| |
|admin/integrations/coder-logstream-kube-logs-quota-exceeded.png| |
|admin/git-auth-template.png| |
|admin/github-app-install.png| |
|admin/users/organizations/role-sync.png| |
|admin/users/organizations/group-sync-empty.png| |
|admin/users/organizations/workspace-list.png| |
|admin/users/organizations/new-organization.png| |
|admin/users/organizations/role-sync-empty.png| |
|admin/users/organizations/template-org-picker.png| |
|admin/users/organizations/organization-members.png| |
|admin/users/organizations/org-dropdown-create.png| |
|admin/users/organizations/default-organization-settings.png| |
|admin/users/organizations/group-sync.png| |
|admin/users/organizations/idp-org-sync.png| |
|admin/users/organizations/admin-settings-orgs.png| |
|admin/users/organizations/custom-roles.png| |
|admin/users/quotas/quota-groups.png| |
|admin/users/create-token.png| |
|admin/users/headless-user.png| |
|admin/provisioners/provisioner-jobs.png| |
|admin/github-app-permissions.png| |
|admin/templates/coder-apps-ui.png| |
|admin/templates/starter-templates.png| |
|admin/templates/create-template.png| |
|admin/templates/schedule/template-schedule-settings.png| |
|admin/templates/schedule/user-quiet-hours.png| |
|admin/templates/coder-metadata-ui.png| |
|admin/templates/duplicate-menu.png| |
|admin/templates/agent-metadata-ui.png| |
|admin/templates/troubleshooting/workspace-build-timings-ui.png| |
|admin/templates/duplicate-page.png| |
|admin/templates/new-duplicate-template.png| |
|admin/templates/import-template.png| |

|admin/templates/extend-templates/prebuilt/replacement-notification.png|
|
|admin/templates/extend-templates/prebuilt/prebuilt-workspaces.png| |

|admin/templates/extend-templates/dyn-params/dynamic-params-compare.png|
|

|admin/templates/extend-templates/dyn-params/enable-dynamic-parameters.png|
|
|admin/templates/extend-templates/template-preset-dropdown.png| |
|admin/monitoring/health-check.png| |
|admin/monitoring/logstream-kube.png| |
|admin/monitoring/notifications/user-notification-preferences.png| |
|admin/monitoring/notifications/notification-admin-prefs.png| |
|admin/workspace-proxy-picker.png| |
|admin/admin-settings-general.png| |
|admin/deployment-id-copy-clipboard.png| |
|icons-gallery.png| |
|start/setup-page.png| |
|start/workspace-schedule-settings.png| |
|start/build-template.png| |
|start/starter-templates.png| |
|start/create-template.png| |
|start/create-workspace.png| |
|start/template-preview.png| |
|start/blank-workspaces.png| |
|start/template-source-code.png| |
|start/first-template.png| |
|start/workspace-ready.png| |
|start/template-edit-source-code.png| |
|start/template-publish.png| |
|start/starter-templates-annotated.png| |
|display-apps.png| |
|workspace-automatic-updates.png| |
|workspaces/autostop.png| |
|workspaces/autostart.png| |
|create-workspace-from-templates-ui.png| |
|ide-row.png| |
|editors.png| |
|delete-template.png| |
|logo-white.png| |
|template-rbac.png| |
|coderapp-port-forward.png| |
|user-guides/terminal-access.png| |
|user-guides/workspace-bulk-actions.png| |
|user-guides/devcontainers/devcontainer-agent-ports.png| |
|user-guides/devcontainers/devcontainer-web-terminal.png| |
|user-guides/create-workspace-ui.png| |
|user-guides/workspace-view-connection-annotated.png| |
|user-guides/remote-desktops/web-rdp-demo.png| |
|user-guides/remote-desktops/amazon-dcv-windows-demo.png| |
|user-guides/desktop/coder-desktop-file-sync-add.png| |
|user-guides/desktop/coder-desktop-session-token.png| |
|user-guides/desktop/coder-desktop-win-pre-sign-in.png| |
|user-guides/desktop/coder-desktop-file-sync-conflicts-mouseover.png| |
|user-guides/desktop/coder-desktop-mac-pre-sign-in.png| |
|user-guides/desktop/coder-desktop-file-sync-watching.png| |
|user-guides/desktop/coder-desktop-win-enable-coder-connect.png| |
|user-guides/desktop/coder-desktop-sign-in.png| |
|user-guides/desktop/coder-desktop-file-sync.png| |
|user-guides/desktop/coder-desktop-file-sync-staging.png| |
|user-guides/desktop/chrome-insecure-origin.png| |
|user-guides/desktop/coder-desktop-workspaces.png| |
|user-guides/jetbrains/toolbox/workspaces.png| |
|user-guides/jetbrains/toolbox/install.png| |
|user-guides/jetbrains/toolbox/login-token.png| |
|user-guides/jetbrains/toolbox/login-url.png| |
|user-guides/schedule-settings-workspace.png| |
|user-guides/dotfiles-module.png| |
|user-guides/workspace-list-ui.png| |
|user-guides/workspace-settings-location.png| |
|template-variables.png| |
|ides/code-web-extensions.png| |
|ides/copilot.png| |
|architecture-multi-region.png| |
|external-apps.png| |
|guides/ai-agents/tasks-ui.png| |
|guides/ai-agents/duplicate.png| |
|guides/ai-agents/landing.png| |
|guides/ai-agents/workspace-page.png| |
|guides/ai-agents/realworld-ui.png| |
|guides/xray-integration/example.png| |
|guides/using-organizations/workspace-list.png| |
|guides/using-organizations/new-organization.png| |
|guides/using-organizations/template-org-picker.png| |
|guides/using-organizations/deployment-organizations.png| |
|guides/using-organizations/organization-members.png| |
|readme-logos.png| |
|metadata-ui.png| |
|secret-metadata-ui.png| |
|projector-intellij.png| |
|schedule.png| |
|ssh-keys.png| |
|template-scheduling.png| |
|templates/general-settings.png| |
|templates/build-template.png| |
|templates/update.png| |
|templates/starter-templates.png| |
|templates/create-template.png| |
|templates/select-template.png| |
|templates/pre-filled-parameters.png| |
|templates/source-code.png| |
|templates/upload-create-your-first-template.png| |
|templates/create-workspace.png| |
|templates/edit-source-code.png| |
|templates/permissions.png| |
|templates/coder-session-token.png| |
|templates/starter-templates-button.png| |
|templates/template-tour.png| |
|templates/edit-files.png| |
|templates/workspace-ready.png| |
|templates/template-menu-settings.png| |
|templates/workspace-apps.png| |
|templates/coder-login-web.png| |
|templates/new-workspace.png| |
|templates/template-variables.png| |
|templates/use-template.png| |
|templates/healthy-workspace-agent.png| |
|templates/update-policies.png| |
|templates/upload-create-template-form.png| |
|templates/develop-in-docker-template.png| |
|templates/publish.png| |
|templates/devcontainers.png| |
|templates/create-template-permissions.png| |
|port-forward-dashboard.png| |
|creating-workspace-ui.png| |
|parameters.png| |
|best-practice/build-timeline.png| |
|file-browser.png| |
|architecture-single-region.png| |
|gateway/plugin-settings-marketplace.png| |
|gateway/plugin-session-token.png| |
|gateway/plugin-connect-to-coder.png| |
|gateway/plugin-select-ide.png| |
|gateway/plugin-ide-list.png| |
|hero-image.png| |

</details>

---------

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
2025-07-10 16:01:20 -04:00
Ethan c1b2304d18 test(agent/agentssh): use fish shell compatible exit status checking (#18824)
This (week-old) test was failing in my workspace because I use fish shell. 
I really do not like that Fish shell does not support `$?`, but I also do like Fish shell! We have a few people at Coder who use it who would appreciate this change.
2025-07-10 19:50:30 +10:00
Edward Angert b882d46d91 docs: fix relative links in about/contributing (#18818)
hotfix

---------

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
2025-07-09 20:04:48 +00:00
Bruno Quaresma 5a8a19be70 feat: auto reconnect the terminal (#18796)
**Changes:**
- Use [websocket-ts](https://www.npmjs.com/package/websocket-ts) to have
auto reconnection out of the box 🙏
- Update the disconnected alert message to "Trying to connect..." since
the connection is always trying to reconnect
- Remove `useWithRetry` because it is not necessary anymore

**Other topics:**
- The disconnected alert is displaying a simple message, but we can
include more info such as the number of attemtps
- The reconnection feature is in a good state and adding value. IMO, any
improvement can be done after getting this merged

Closes https://github.com/coder/internal/issues/659
2025-07-09 15:04:24 -03:00
Steven Masley 00ba0278d2 chore: modify parameter dynamic immutability behavior (#18583)
Immutability behavior is determined by the current build, not affected by the previous
2025-07-09 08:45:24 -06:00
Bruno Quaresma 9c61ef82b0 test: fix DeploymentSidebarView stories (#18812) 2025-07-09 10:09:10 -04:00
Cian Johnston 0367dbac43 chore: optimize GetPrebuiltWorkspaces query (#18717)
* Adds GetRunningPrebuiltWorkspacesOptimized query
* Runs both original and updated query side-by-side and logs diffs
2025-07-09 11:30:42 +01:00
Jakub Domeracki dc0919da33 feat: sign coder binaries with the release key using GPG (#18774)
### Description
This PR introduces GPG signing for all Coder *slim-binaries*.
Detached signatures will allow users to verify the integrity and
authenticity of the binaries they download.

### Changes
  * `scripts/sign_with_gpg.sh`: New script to sign a given binary
     using GPG. It imports the release key, signs the binary, and
     verifies the signature.
   * `scripts/build_go.sh`: Updated to call `sign_with_gpg.sh` when the
     `CODER_SIGN_GPG` environment variable is set to 1.
   * `.github/workflows/release.yaml`: The` CODER_SIGN_GPG` environment
     variable is now set to 1 during the release build, enabling GPG
     signing for all release binaries.
   * `.github/workflows/ci.yaml`: The `CODER_SIGN_GPG` environment
     variable is now set to 1 during the CI build, enabling GPG
     signing for all CI binaries.
* `Makefile`: Detached signatures are moved to the `/site/out/bin/
`directory
2025-07-09 11:53:27 +02:00
Hugo Dutka 3c2f3d640b chore: remove dbmem (#18803)
Remove the in-memory database. Addresses #15109.
2025-07-09 09:46:31 +02:00
Steven Masley 1319ae293f chore: support zip filetypes in the file cache (#18750) 2025-07-08 15:46:39 -06:00
Atif Ali 79d1465e23 chore: update module sources for Windsurf, Zed and JetBrains (#18759) 2025-07-08 20:33:34 +00:00
blink-so[bot] 39ed0c32e6 docs: simplify PostgreSQL setup by using 'postgresql' as release name (#18754)
Fixes #18751

Use `postgresql` as the Helm release name instead of `coder-db` to make
the service name more intuitive and eliminate confusion entirely.

## Changes
- Changed `helm install coder-db bitnami/postgresql` to `helm install
postgresql bitnami/postgresql`
- Updated PostgreSQL URLs from
`coder-db-postgresql.coder.svc.cluster.local` to
`postgresql.coder.svc.cluster.local`
- Removed explanatory notes about service naming (no longer needed)

## Benefits
 Makes examples work out-of-the-box for most users
 Uses the most straightforward and intuitive release name
 Eliminates confusion about service naming entirely
 Simpler documentation without complex explanations

## Testing
- Verified that `helm install postgresql bitnami/postgresql` creates
service named `postgresql`
- Confirmed this approach works with the connection URL
`postgresql.coder.svc.cluster.local`

Suggested by @EdwardAngert as a cleaner solution than explaining the
service naming dependency.

---------

Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: matifali <10648092+matifali@users.noreply.github.com>
Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
Co-authored-by: Edward Angert <EdwardAngert@users.noreply.github.com>
2025-07-08 13:20:15 -04:00
Allen Conlon 10c1e36fff feat: add publishing of helm charts to ghcr registry (#18316) 2025-07-08 22:19:12 +05:00
Mathias Fredriksson 6c4db7a2bc feat(cli): replace open vscode container with devcontainer subagent (#18765)
This change allows a devcontainer to be opened via the agent syntax,
`coder open vscode <workspace>.<agent>` and removes the `--container`
option to simplify the subcommand. Accessing the subagent will behave
similarly to how the `--container` option behaved.

Fixes coder/internal#748
2025-07-08 19:21:41 +03:00
Mathias Fredriksson 5f50dcce5a feat(cli): improve devcontainer support for coder show (#18793)
Fixes coder/internal#747
2025-07-08 16:16:00 +00:00
Hugo Dutka 2f50b3b7bb chore(site): remove dbmem from tests (#18802)
Related to https://github.com/coder/coder/issues/15109.
2025-07-08 15:28:48 +00:00
Hugo Dutka 8e038db463 chore(enterprise/replicasync): remove dbmem from tests (#18801)
Related to https://github.com/coder/coder/issues/15109.
2025-07-08 15:25:01 +00:00
Hugo Dutka 5e9cbe8a1b chore(coderd): remove dbmem from tests (#18800)
Related to https://github.com/coder/coder/issues/15109.
2025-07-08 15:19:14 +00:00
Hugo Dutka 66e490986f chore(enterprise/trialer): remove dbmem from tests (#18798)
Related to https://github.com/coder/coder/issues/15109.
2025-07-09 01:17:14 +10:00
Hugo Dutka b65e133a17 chore(enterprise/coderd): remove dbmem from tests (#18797)
Related to https://github.com/coder/coder/issues/15109.
2025-07-09 01:16:46 +10:00
Susana Ferreira 0dc36127c0 chore(dogfood): update filebrowser module to version 1.1.1 (#18799)
Workspaces with `Write Coder on Coder` template are failing with an
error in the agent related to File Browser:
```
2025/07/08 14:00:29 Using database: /home/coder/filebrowser.db  
2025/07/08 14:00:29 password is too short, minimum length is 12
```
Updating filebrowser module version to 1.1.1:
https://github.com/coder/registry/pull/173
2025-07-08 16:13:36 +01:00
Hugo Dutka 733d3f1287 chore(enterprise/cli): remove dbmem from tests (#18795)
Related to https://github.com/coder/coder/issues/15109.
2025-07-08 14:59:03 +00:00
Hugo Dutka f147ebf37d chore(enterprise/audit): remove dbmem from tests (#18794)
Related to https://github.com/coder/coder/issues/15109.
2025-07-08 14:39:02 +00:00
Hugo Dutka 7f681910e9 chore(coderd/updatecheck): remove dbmem from tests (#18792)
Related to https://github.com/coder/coder/issues/15109.
2025-07-08 14:32:46 +00:00
Hugo Dutka e0fb15eeff chore(coderd/searchquery): remove dbmem from tests (#18791)
Related to https://github.com/coder/coder/issues/15109.
2025-07-08 14:32:24 +00:00
Hugo Dutka 321396d9d6 chore(coderd/rbac/rolestore): remove dbmem from tests (#18789)
Related to https://github.com/coder/coder/issues/15109
2025-07-08 16:31:20 +02:00
Hugo Dutka ac4be155d9 chore(coderd/runtimeconfig): remove dbmem from tests (#18790)
Related to https://github.com/coder/coder/issues/15109.
2025-07-08 14:31:05 +00:00
Spike Curtis bf0271fd65 chore: stop running postgres-only tests if DB is not set (#18784)
Fixes https://github.com/coder/internal/issues/695

PostgreSQL tests are getting run in a non-postgres CI job because the tests don't get skipped if the `DB=` env is unset. This PR adds a skip for them.

They are flaking in the `test-go-race` CI job. They run fine in the `test-go-race-pg` job, which pre-creates the postgres server, so the flakiness is almost certainly related to spinning up the database server.
2025-07-08 15:56:22 +04:00
Susana Ferreira 211393a69c fix: exclude prebuilt workspaces from lifecycle executor (#18762)
## Description

This PR updates the lifecycle executor to explicitly exclude prebuilt
workspaces from being considered for lifecycle operations such as
`autostart`, `autostop`, `dormancy`, `default TTL` and `failure TTL`.

Prebuilt workspaces (i.e., those owned by the prebuild system user) are
handled separately by the prebuild reconciliation loop. Including them
in the lifecycle executor could lead to unintended behavior such as
incorrect scheduling or state transitions.

## Changes

* Updated the lifecycle executor query
`GetWorkspacesEligibleForTransition` to exclude workspaces with
`owner_id = 'c42fdf75-3097-471c-8c33-fb52454d81c0'` (prebuilds).
* Added tests to verify prebuilt workspaces are not considered in:
  * Autostop
  * Autostart
  * Default TTL
  * Dormancy
  * Failure TTL

Fixes: https://github.com/coder/coder/issues/18740
Related to: https://github.com/coder/coder/issues/18658
2025-07-08 11:35:28 +01:00
Danielle Maywood 0118e75009 fix(agent): disable dev container integration inside sub agents (#18781)
It appears we accidentally broke this logic in a previous PR. This
should now correctly disable the agent api as we'd expect.
2025-07-08 11:05:30 +01:00
Cian Johnston 1195f31025 chore(site): reduce fetch interval on workspaces page (#18725)
Relates to https://github.com/coder/internal/issues/720

* Reduces workspaces data refetch interval if no builds are pending
* Sets `refetchOnWindowFocus: always` to mitigate impact of reduced polling duration
2025-07-08 11:00:05 +01:00
Kacper Sawicki 8202514ce0 feat!: add ability to cancel pending workspace build (#18713)
Closes #17791 

This PR adds ability to cancel workspace builds that are in "pending"
status.

Breaking changes:
- CancelWorkspaceBuild method in codersdk now accepts an optional
request parameter

API:
- Added `expect_status` query parameter to the cancel workspace build
endpoint
- This parameter ensures the job hasn't changed state before canceling
- API returns `412 Precondition Failed` if the job is not in the
expected status
- Valid values: `running` or `pending`
- Wrapped the entire cancel method in a database transaction

UI:
- Added confirmation dialog to the `Cancel` button, since it's a
destructive operation

![image](https://github.com/user-attachments/assets/437aa5f4-5669-45b6-82a0-e46f277114bf)

![image](https://github.com/user-attachments/assets/423b5cb1-a4fb-4a10-933b-c1c73f4b838c)


- Enabled cancel action for pending workspaces (`expect_status=pending`
is sent if workspace is in pending status)

![image](https://github.com/user-attachments/assets/32d35ff1-12e6-4f7b-9f6c-fde9da9de6cf)

---------

Co-authored-by: Dean Sheather <dean@deansheather.com>
2025-07-08 11:02:58 +02:00
Edward Angert 2f42b64182 docs: update dynamic parameters for beta release (#18512)
Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
Co-authored-by: Stephen Kirby <kirby@coder.com>
Co-authored-by: Stephen Kirby <58410745+stirby@users.noreply.github.com>
Co-authored-by: Atif Ali <atif@coder.com>
Co-authored-by: Jaayden Halko <jaayden.halko@gmail.com>
Co-authored-by: Mathias Fredriksson <mafredri@gmail.com>
Co-authored-by: Steven Masley <Emyrk@users.noreply.github.com>
Co-authored-by: Thomas Kosiewski <tk@coder.com>
Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: bpmct <22407953+bpmct@users.noreply.github.com>
Co-authored-by: Bruno Quaresma <bruno@coder.com>
Co-authored-by: BrunoQuaresma <3165839+BrunoQuaresma@users.noreply.github.com>
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Ethan <39577870+ethanndickson@users.noreply.github.com>
Co-authored-by: kylecarbs <7122116+kylecarbs@users.noreply.github.com>
Co-authored-by: Ben Potter <ben@coder.com>
Co-authored-by: Hugo Dutka <hugo@coder.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: ケイラ <mckayla@hey.com>
2025-07-07 19:46:34 -05:00
blink-so[bot] 83192e2462 docs: restore missing AI agent images to fix 404 errors (#18780)
Fixes #18767

This PR restores the missing `landing.png` and `duplicate.png` images
that were accidentally deleted in commit
b26c9e2432.

## Problem
The images were deleted during a documentation restructure, but external
links and cached website content are still referencing these image URLs,
causing 404 errors:
-
`https://raw.githubusercontent.com/coder/coder/main/docs/images/guides/ai-agents/landing.png`
-
`https://raw.githubusercontent.com/coder/coder/main/docs/images/guides/ai-agents/duplicate.png`

## Solution
Restore the original images from the git history to maintain backward
compatibility for external references while preserving the current
documentation structure.

## Testing
 Verified images are restored to correct location
 Confirmed file sizes match original images
 No conflicts with current documentation structure

Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: kylecarbs <7122116+kylecarbs@users.noreply.github.com>
2025-07-07 19:48:10 -04:00
Thomas Kosiewski 3dcd2acf1d fix: return 404 instead of 401 for missing OAuth2 apps (#18755)
## Problem

Users were being automatically logged out when deleting OAuth2
applications.

## Root Cause

1. User deletes OAuth2 app successfully
2. React Query automatically refetches the app data  
3. Management API incorrectly returned **401 Unauthorized** for the
missing app
4. Frontend axios interceptor sees 401 and calls `signOut()`
5. User gets logged out unexpectedly

## Solution

- Change management API to return **404 Not Found** for missing OAuth2
apps
- OAuth2 protocol endpoints continue returning 401 per RFC 6749
- Rename `writeInvalidClient` to `writeClientNotFound` for clarity

## Additional Changes

- Add conditional OAuth2 navigation when experiment is enabled or in dev
builds
- Add `isDevBuild()` utility and `buildInfo` to dashboard context
- Minor improvements to format script and warning dialogs

Signed-off-by: Thomas Kosiewski <tk@coder.com>
2025-07-07 19:57:32 +02:00
ケイラ f2983164f5 chore: fix some small groups and acl typos (#18732)
- Add `format:"uri"` to `Group.AvatarURL` (matches `User.AvatarURL`
field)
- `<user_id>` and `<group_id>` were backwards in the `example:` tags
- The `@Success` annotation for `/acl [get]` had an incorrect type
2025-07-07 11:01:17 -06:00
dependabot[bot] 935bd340b1 chore: bump github.com/valyala/fasthttp from 1.62.0 to 1.63.0 (#18771)
Bumps [github.com/valyala/fasthttp](https://github.com/valyala/fasthttp)
from 1.62.0 to 1.63.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/valyala/fasthttp/releases">github.com/valyala/fasthttp's
releases</a>.</em></p>
<blockquote>
<h2>v1.63.0</h2>
<h2>What's Changed</h2>
<ul>
<li>chore(deps): bump securego/gosec from 2.22.3 to 2.22.4 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2007">valyala/fasthttp#2007</a></li>
<li>fix: removed resolved issue link from readme file, issue no longer
ex… by <a
href="https://github.com/viralkansarav"><code>@​viralkansarav</code></a>
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2008">valyala/fasthttp#2008</a></li>
<li>feat: Add iter.Seq2 iterator by <a
href="https://github.com/ksw2000"><code>@​ksw2000</code></a> in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2011">valyala/fasthttp#2011</a></li>
<li>Removed old information from main documentation as these functions
does not exist by <a
href="https://github.com/viralkansarav"><code>@​viralkansarav</code></a>
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2012">valyala/fasthttp#2012</a></li>
<li>Proposal : To add Unsafe Zero-Allocation Conversions Sections in
main documentation by <a
href="https://github.com/viralkansarav"><code>@​viralkansarav</code></a>
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2013">valyala/fasthttp#2013</a></li>
<li>chore(deps): bump golang.org/x/net from 0.40.0 to 0.41.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2018">valyala/fasthttp#2018</a></li>
<li>Drop support before go1.20 by <a
href="https://github.com/erikdubbelboer"><code>@​erikdubbelboer</code></a>
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2022">valyala/fasthttp#2022</a></li>
<li>chore(deps): bump securego/gosec from 2.22.4 to 2.22.5 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2025">valyala/fasthttp#2025</a></li>
<li>Implement io.StringWriter on some more types by <a
href="https://github.com/erikdubbelboer"><code>@​erikdubbelboer</code></a>
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2023">valyala/fasthttp#2023</a></li>
<li>chore(deps): bump github.com/andybalholm/brotli from 1.1.1 to 1.2.0
by <a href="https://github.com/dependabot"><code>@​dependabot</code></a>
in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2029">valyala/fasthttp#2029</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/viralkansarav"><code>@​viralkansarav</code></a>
made their first contribution in <a
href="https://redirect.github.com/valyala/fasthttp/pull/2008">valyala/fasthttp#2008</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/valyala/fasthttp/compare/v1.62.0...v1.63.0">https://github.com/valyala/fasthttp/compare/v1.62.0...v1.63.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/valyala/fasthttp/commit/8b512b7dae68ffb700b3240bcb81bed5f5c9e6e8"><code>8b512b7</code></a>
chore(deps): bump github.com/andybalholm/brotli from 1.1.1 to 1.2.0 (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2029">#2029</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/d356cacd848d92e7f25f06ec64c29f43e033e369"><code>d356cac</code></a>
Implement io.StringWriter on some more types (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2023">#2023</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/641dd96586089dd225652745cb1f67492509dd1c"><code>641dd96</code></a>
chore(deps): bump securego/gosec from 2.22.4 to 2.22.5 (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2025">#2025</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/28ebbd9bf1300bc7d763a0f02facad70ee60190f"><code>28ebbd9</code></a>
Drop support before go1.20 (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2022">#2022</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/75d2192d37d5cd444850d9d857437fc83165e351"><code>75d2192</code></a>
chore(deps): bump golang.org/x/net from 0.40.0 to 0.41.0 (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2018">#2018</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/46ae933953a610c389f33c1058b8c2b901113e55"><code>46ae933</code></a>
Proposal : To add Unsafe Zero-Allocation Conversions Sections in main
docume...</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/74f3d4cfc825c095c1c1630bd69e0b8da3cd8755"><code>74f3d4c</code></a>
Removed old information from main documentation as these functions does
not e...</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/a1783ffacc6269de7d37a3a99da1005f404a7a82"><code>a1783ff</code></a>
feat: Add iter.Seq2 iterator <a
href="https://redirect.github.com/valyala/fasthttp/issues/2010">#2010</a>
(<a
href="https://redirect.github.com/valyala/fasthttp/issues/2011">#2011</a>)</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/246634464811c0389369f7a5bd298b85f63670e4"><code>2466344</code></a>
Remove unused file</li>
<li><a
href="https://github.com/valyala/fasthttp/commit/d856840619aa61cff3274ad8403a8f34f15957c7"><code>d856840</code></a>
fix: removed resolved issue link from readme file, issue no longer
exists (<a
href="https://redirect.github.com/valyala/fasthttp/issues/2">#2</a>...</li>
<li>Additional commits viewable in <a
href="https://github.com/valyala/fasthttp/compare/v1.62.0...v1.63.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/valyala/fasthttp&package-manager=go_modules&previous-version=1.62.0&new-version=1.63.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-07 13:59:45 +00:00
dependabot[bot] 52ff531d1f chore: bump github.com/go-playground/validator/v10 from 10.26.0 to 10.27.0 (#18772)
Bumps
[github.com/go-playground/validator/v10](https://github.com/go-playground/validator)
from 10.26.0 to 10.27.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/go-playground/validator/releases">github.com/go-playground/validator/v10's
releases</a>.</em></p>
<blockquote>
<h2>Release 10.27.0</h2>
<h2>What's Changed</h2>
<ul>
<li>Fix Release version badge on README page by <a
href="https://github.com/nodivbyzero"><code>@​nodivbyzero</code></a> in
<a
href="https://redirect.github.com/go-playground/validator/pull/1406">go-playground/validator#1406</a></li>
<li>fix russian E.164 error message by <a
href="https://github.com/prigornitskiy"><code>@​prigornitskiy</code></a>
in <a
href="https://redirect.github.com/go-playground/validator/pull/1349">go-playground/validator#1349</a></li>
<li>chore: remove unnecessary statement by <a
href="https://github.com/qshuai"><code>@​qshuai</code></a> in <a
href="https://redirect.github.com/go-playground/validator/pull/1200">go-playground/validator#1200</a></li>
<li>Re-enable several linters by <a
href="https://github.com/nodivbyzero"><code>@​nodivbyzero</code></a> in
<a
href="https://redirect.github.com/go-playground/validator/pull/1412">go-playground/validator#1412</a></li>
<li>add support to tag validateFn by <a
href="https://github.com/peczenyj"><code>@​peczenyj</code></a> in <a
href="https://redirect.github.com/go-playground/validator/pull/1363">go-playground/validator#1363</a></li>
<li>Bump golang.org/x/crypto from 0.33.0 to 0.35.0 in
/_examples/validate_fn by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-playground/validator/pull/1418">go-playground/validator#1418</a></li>
<li>Bump golang.org/x/net from 0.34.0 to 0.38.0 in
/_examples/validate_fn by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-playground/validator/pull/1419">go-playground/validator#1419</a></li>
<li>Align required_without with the contract stated in the documentation
by <a href="https://github.com/jmfrees"><code>@​jmfrees</code></a> in <a
href="https://redirect.github.com/go-playground/validator/pull/1422">go-playground/validator#1422</a></li>
<li>Add translation example by <a
href="https://github.com/cxlblm"><code>@​cxlblm</code></a> in <a
href="https://redirect.github.com/go-playground/validator/pull/1394">go-playground/validator#1394</a></li>
<li>doc(errors): mention RegisterTagNameFunc for FieldError.Field by <a
href="https://github.com/khan-ajamal"><code>@​khan-ajamal</code></a> in
<a
href="https://redirect.github.com/go-playground/validator/pull/1358">go-playground/validator#1358</a></li>
<li>Bump golangci/golangci-lint-action from 7 to 8 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-playground/validator/pull/1425">go-playground/validator#1425</a></li>
<li>feat(translation): add en translation for urn_rfc2141 by <a
href="https://github.com/ryanmalesic"><code>@​ryanmalesic</code></a> in
<a
href="https://redirect.github.com/go-playground/validator/pull/1431">go-playground/validator#1431</a></li>
<li>fix: panics when private field is validated by <a
href="https://github.com/ykalchevskiy"><code>@​ykalchevskiy</code></a>
in <a
href="https://redirect.github.com/go-playground/validator/pull/1423">go-playground/validator#1423</a></li>
<li>Fix: support validation for map values with struct types by <a
href="https://github.com/JunaidIslam2105"><code>@​JunaidIslam2105</code></a>
in <a
href="https://redirect.github.com/go-playground/validator/pull/1433">go-playground/validator#1433</a></li>
<li>Omitzero does not work with slice and map bug by <a
href="https://github.com/JunaidIslam2105"><code>@​JunaidIslam2105</code></a>
in <a
href="https://redirect.github.com/go-playground/validator/pull/1436">go-playground/validator#1436</a></li>
<li>Fix: Validator panics when 'nil' is used along with required if for
slices and maps by <a
href="https://github.com/JunaidIslam2105"><code>@​JunaidIslam2105</code></a>
in <a
href="https://redirect.github.com/go-playground/validator/pull/1442">go-playground/validator#1442</a></li>
<li>docs: typos by <a
href="https://github.com/eqsdxr"><code>@​eqsdxr</code></a> in <a
href="https://redirect.github.com/go-playground/validator/pull/1440">go-playground/validator#1440</a></li>
<li>fix: make &quot;file://&quot; fail <code>url</code> validation by <a
href="https://github.com/bfabio"><code>@​bfabio</code></a> in <a
href="https://redirect.github.com/go-playground/validator/pull/1444">go-playground/validator#1444</a></li>
<li>disable way too aggressive and disagreeable linters by <a
href="https://github.com/deankarn"><code>@​deankarn</code></a> in <a
href="https://redirect.github.com/go-playground/validator/pull/1445">go-playground/validator#1445</a></li>
<li>use golangci lint file for disables by <a
href="https://github.com/deankarn"><code>@​deankarn</code></a> in <a
href="https://redirect.github.com/go-playground/validator/pull/1447">go-playground/validator#1447</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/prigornitskiy"><code>@​prigornitskiy</code></a>
made their first contribution in <a
href="https://redirect.github.com/go-playground/validator/pull/1349">go-playground/validator#1349</a></li>
<li><a href="https://github.com/qshuai"><code>@​qshuai</code></a> made
their first contribution in <a
href="https://redirect.github.com/go-playground/validator/pull/1200">go-playground/validator#1200</a></li>
<li><a href="https://github.com/peczenyj"><code>@​peczenyj</code></a>
made their first contribution in <a
href="https://redirect.github.com/go-playground/validator/pull/1363">go-playground/validator#1363</a></li>
<li><a href="https://github.com/jmfrees"><code>@​jmfrees</code></a> made
their first contribution in <a
href="https://redirect.github.com/go-playground/validator/pull/1422">go-playground/validator#1422</a></li>
<li><a href="https://github.com/cxlblm"><code>@​cxlblm</code></a> made
their first contribution in <a
href="https://redirect.github.com/go-playground/validator/pull/1394">go-playground/validator#1394</a></li>
<li><a
href="https://github.com/khan-ajamal"><code>@​khan-ajamal</code></a>
made their first contribution in <a
href="https://redirect.github.com/go-playground/validator/pull/1358">go-playground/validator#1358</a></li>
<li><a
href="https://github.com/ryanmalesic"><code>@​ryanmalesic</code></a>
made their first contribution in <a
href="https://redirect.github.com/go-playground/validator/pull/1431">go-playground/validator#1431</a></li>
<li><a
href="https://github.com/ykalchevskiy"><code>@​ykalchevskiy</code></a>
made their first contribution in <a
href="https://redirect.github.com/go-playground/validator/pull/1423">go-playground/validator#1423</a></li>
<li><a
href="https://github.com/JunaidIslam2105"><code>@​JunaidIslam2105</code></a>
made their first contribution in <a
href="https://redirect.github.com/go-playground/validator/pull/1433">go-playground/validator#1433</a></li>
<li><a href="https://github.com/eqsdxr"><code>@​eqsdxr</code></a> made
their first contribution in <a
href="https://redirect.github.com/go-playground/validator/pull/1440">go-playground/validator#1440</a></li>
<li><a href="https://github.com/bfabio"><code>@​bfabio</code></a> made
their first contribution in <a
href="https://redirect.github.com/go-playground/validator/pull/1444">go-playground/validator#1444</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/go-playground/validator/compare/v10.26.0...v10.27.0">https://github.com/go-playground/validator/compare/v10.26.0...v10.27.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/go-playground/validator/commit/bc77d03bfbd951ad1299267754e230b0af36a5aa"><code>bc77d03</code></a>
use golangci lint file for disables (<a
href="https://redirect.github.com/go-playground/validator/issues/1447">#1447</a>)</li>
<li><a
href="https://github.com/go-playground/validator/commit/4a1bc2f2628506a2cab2e3fe88d0cb57ccedbb6a"><code>4a1bc2f</code></a>
disable way too aggressive and disagreeable linters (<a
href="https://redirect.github.com/go-playground/validator/issues/1445">#1445</a>)</li>
<li><a
href="https://github.com/go-playground/validator/commit/cf2267f30e617916a42e6217cd5d3c837100b374"><code>cf2267f</code></a>
fix: make &quot;file://&quot; fail <code>url</code> validation (<a
href="https://redirect.github.com/go-playground/validator/issues/1444">#1444</a>)</li>
<li><a
href="https://github.com/go-playground/validator/commit/3fd4678e4a0346d57ac1ebcb81ceb86a87ed59f0"><code>3fd4678</code></a>
docs: typos (<a
href="https://redirect.github.com/go-playground/validator/issues/1440">#1440</a>)</li>
<li><a
href="https://github.com/go-playground/validator/commit/ec374ef02d93322f9d337c47678fbb45ac055323"><code>ec374ef</code></a>
Fix: Validator panics when 'nil' is used along with required if for
slices an...</li>
<li><a
href="https://github.com/go-playground/validator/commit/0e3e2f997385102062275f226e825b4a109f4833"><code>0e3e2f9</code></a>
Omitzero does not work with slice and map bug (<a
href="https://redirect.github.com/go-playground/validator/issues/1436">#1436</a>)</li>
<li><a
href="https://github.com/go-playground/validator/commit/dfc7ccd4d817cfd6f065273e37d83f7ae7815cce"><code>dfc7ccd</code></a>
Fix: support validation for map values with struct types (<a
href="https://redirect.github.com/go-playground/validator/issues/1433">#1433</a>)</li>
<li><a
href="https://github.com/go-playground/validator/commit/5b9542b93487972cdfa75ed03ebe4286c3f44c01"><code>5b9542b</code></a>
fix: panics when private field is validated (<a
href="https://redirect.github.com/go-playground/validator/issues/1423">#1423</a>)</li>
<li><a
href="https://github.com/go-playground/validator/commit/f9a5a1fa1e61028e09df895cd92dfd31673e245f"><code>f9a5a1f</code></a>
feat(translation): add en translation for urn_rfc2141 (<a
href="https://redirect.github.com/go-playground/validator/issues/1431">#1431</a>)</li>
<li><a
href="https://github.com/go-playground/validator/commit/20f7df64bdd443294349535a5da244ad0b2af71a"><code>20f7df6</code></a>
Bump golangci/golangci-lint-action from 7 to 8 (<a
href="https://redirect.github.com/go-playground/validator/issues/1425">#1425</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/go-playground/validator/compare/v10.26.0...v10.27.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/go-playground/validator/v10&package-manager=go_modules&previous-version=10.26.0&new-version=10.27.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-07 13:59:25 +00:00
Edward Angert e3627fd562 docs: fix markdown in Windsurf doc (#18753)
hotfix


[preview](https://coder.com/docs/@18705-windsurf-md/user-guides/workspace-access/windsurf)

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
2025-07-07 18:52:19 +05:00
dependabot[bot] ededcd0c37 chore: bump go.nhat.io/otelsql from 0.15.0 to 0.16.0 (#18768)
Bumps [go.nhat.io/otelsql](https://github.com/nhatthm/otelsql) from
0.15.0 to 0.16.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/nhatthm/otelsql/releases">go.nhat.io/otelsql's
releases</a>.</em></p>
<blockquote>
<h2>v0.16.0</h2>
<h2>What's Changed</h2>
<ul>
<li>Bump the otel group with 7 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/334">nhatthm/otelsql#334</a></li>
<li>Bump golang.org/x/net from 0.23.0 to 0.33.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/335">nhatthm/otelsql#335</a></li>
<li>Bump github.com/go-sql-driver/mysql from 1.8.1 to 1.9.0 in
/tests/mysql by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/336">nhatthm/otelsql#336</a></li>
<li>Bump github.com/prometheus/client_golang from 1.20.5 to 1.21.0 in
/tests/suite by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/337">nhatthm/otelsql#337</a></li>
<li>Bump github.com/prometheus/client_golang from 1.21.0 to 1.21.1 in
/tests/suite by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/338">nhatthm/otelsql#338</a></li>
<li>Bump the otel group with 7 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/339">nhatthm/otelsql#339</a></li>
<li>Bump golang.org/x/net from 0.33.0 to 0.36.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/340">nhatthm/otelsql#340</a></li>
<li>Bump github.com/golang-jwt/jwt/v4 from 4.5.1 to 4.5.2 in
/tests/mssql by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/342">nhatthm/otelsql#342</a></li>
<li>Bump github.com/go-sql-driver/mysql from 1.9.0 to 1.9.1 in
/tests/mysql by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/341">nhatthm/otelsql#341</a></li>
<li>Bump github.com/jackc/pgx/v5 from 5.7.2 to 5.7.3 in /tests/postgres
by <a href="https://github.com/dependabot"><code>@​dependabot</code></a>
in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/343">nhatthm/otelsql#343</a></li>
<li>Bump dependencies by <a
href="https://github.com/nhatthm"><code>@​nhatthm</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/347">nhatthm/otelsql#347</a></li>
<li>Bump github.com/jackc/pgx/v5 from 5.7.3 to 5.7.4 in /tests/postgres
by <a href="https://github.com/dependabot"><code>@​dependabot</code></a>
in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/344">nhatthm/otelsql#344</a></li>
<li>Bump github.com/go-sql-driver/mysql from 1.9.1 to 1.9.2 in
/tests/mysql by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/345">nhatthm/otelsql#345</a></li>
<li>Bump golang.org/x/net from 0.36.0 to 0.38.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/348">nhatthm/otelsql#348</a></li>
<li>Bump the otel group with 7 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/350">nhatthm/otelsql#350</a></li>
<li>Bump github.com/jackc/pgx/v5 from 5.7.4 to 5.7.5 in /tests/postgres
by <a href="https://github.com/dependabot"><code>@​dependabot</code></a>
in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/349">nhatthm/otelsql#349</a></li>
<li>Bump github.com/bool64/sqluct from 0.2.4 to 0.2.5 in /tests/suite by
<a href="https://github.com/dependabot"><code>@​dependabot</code></a> in
<a
href="https://redirect.github.com/nhatthm/otelsql/pull/351">nhatthm/otelsql#351</a></li>
<li>Bump github.com/bool64/sqluct from 0.2.5 to 0.2.6 in /tests/suite by
<a href="https://github.com/dependabot"><code>@​dependabot</code></a> in
<a
href="https://redirect.github.com/nhatthm/otelsql/pull/353">nhatthm/otelsql#353</a></li>
<li>Bump github.com/go-sql-driver/mysql from 1.9.2 to 1.9.3 in
/tests/mysql by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/352">nhatthm/otelsql#352</a></li>
<li>avoid allocating attributes when the span is not recording by <a
href="https://github.com/boekkooi-impossiblecloud"><code>@​boekkooi-impossiblecloud</code></a>
in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/354">nhatthm/otelsql#354</a></li>
<li>Bump the otel group with 7 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/nhatthm/otelsql/pull/355">nhatthm/otelsql#355</a></li>
<li>Bump github.com/bool64/sqluct from 0.2.6 to 0.2.7 in /tests/suite by
<a href="https://github.com/dependabot"><code>@​dependabot</code></a> in
<a
href="https://redirect.github.com/nhatthm/otelsql/pull/356">nhatthm/otelsql#356</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/nhatthm/otelsql/compare/v0.15.0...v0.16.0">https://github.com/nhatthm/otelsql/compare/v0.15.0...v0.16.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/nhatthm/otelsql/commit/9213586ccd31a41f9a70507245f1970397502d00"><code>9213586</code></a>
Bump github.com/bool64/sqluct from 0.2.6 to 0.2.7 in /tests/suite (<a
href="https://redirect.github.com/nhatthm/otelsql/issues/356">#356</a>)</li>
<li><a
href="https://github.com/nhatthm/otelsql/commit/ff42240692792e9aa1277be17324937d8bbe0f6e"><code>ff42240</code></a>
Bump the otel group with 7 updates (<a
href="https://redirect.github.com/nhatthm/otelsql/issues/355">#355</a>)</li>
<li><a
href="https://github.com/nhatthm/otelsql/commit/324b3bc0c37ff441deddfb4b1c02840f02c45cae"><code>324b3bc</code></a>
avoid allocating attributes when the span is not recording (<a
href="https://redirect.github.com/nhatthm/otelsql/issues/354">#354</a>)</li>
<li><a
href="https://github.com/nhatthm/otelsql/commit/7cf081467d8c0457fe3c4528654a81084b8b569a"><code>7cf0814</code></a>
Bump github.com/go-sql-driver/mysql from 1.9.2 to 1.9.3 in /tests/mysql
(<a
href="https://redirect.github.com/nhatthm/otelsql/issues/352">#352</a>)</li>
<li><a
href="https://github.com/nhatthm/otelsql/commit/c5bf99ad7971c12f4909f103bd026b3592675e0b"><code>c5bf99a</code></a>
Bump github.com/bool64/sqluct from 0.2.5 to 0.2.6 in /tests/suite (<a
href="https://redirect.github.com/nhatthm/otelsql/issues/353">#353</a>)</li>
<li><a
href="https://github.com/nhatthm/otelsql/commit/f7d72a363f1fa3db072c9e6e02955a4221fcc3d7"><code>f7d72a3</code></a>
Bump github.com/bool64/sqluct from 0.2.4 to 0.2.5 in /tests/suite (<a
href="https://redirect.github.com/nhatthm/otelsql/issues/351">#351</a>)</li>
<li><a
href="https://github.com/nhatthm/otelsql/commit/ff0e5865586ec909643aff7cbbccb90d61bbbcbf"><code>ff0e586</code></a>
Bump github.com/jackc/pgx/v5 from 5.7.4 to 5.7.5 in /tests/postgres (<a
href="https://redirect.github.com/nhatthm/otelsql/issues/349">#349</a>)</li>
<li><a
href="https://github.com/nhatthm/otelsql/commit/fb7f15c94a1309d85f67db46114f5a52e6677606"><code>fb7f15c</code></a>
Bump the otel group with 7 updates (<a
href="https://redirect.github.com/nhatthm/otelsql/issues/350">#350</a>)</li>
<li><a
href="https://github.com/nhatthm/otelsql/commit/00a194983cdd2f291e8106da75a210249c5b5ff8"><code>00a1949</code></a>
Bump golang.org/x/net from 0.36.0 to 0.38.0 (<a
href="https://redirect.github.com/nhatthm/otelsql/issues/348">#348</a>)</li>
<li><a
href="https://github.com/nhatthm/otelsql/commit/ebcac0a7fc58469868c9dbfaa8b7ad7cb8fbf0e6"><code>ebcac0a</code></a>
Bump github.com/go-sql-driver/mysql from 1.9.1 to 1.9.2 in /tests/mysql
(<a
href="https://redirect.github.com/nhatthm/otelsql/issues/345">#345</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/nhatthm/otelsql/compare/v0.15.0...v0.16.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=go.nhat.io/otelsql&package-manager=go_modules&previous-version=0.15.0&new-version=0.16.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-07 13:45:01 +00:00
dependabot[bot] 3477ed67a5 ci: bump the github-actions group with 6 updates (#18769)
Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-07 13:44:06 +00:00
Hugo Dutka 1e715e2f66 chore: add suggestions to the tasks docs (#18766) 2025-07-07 09:15:53 -04:00
Ben Potter b26c9e2432 feat: update tasks docs (#18659)
Preview: https://coder.com/docs/@tasks-docs/ai-coder

---------

Co-authored-by: Hugo Dutka <hugo@coder.com>
2025-07-07 08:21:59 -04:00
blink-so[bot] 65809710e5 feat: make readinessProbe and livenessProbe initialDelaySeconds configurable (#18756)
Makes `initialDelaySeconds` configurable for both `readinessProbe` and
`livenessProbe` in the Helm chart.

**Changes:**
- Added `coder.readinessProbe.initialDelaySeconds` and
`coder.livenessProbe.initialDelaySeconds` to `values.yaml`
- Updated `_coder.tpl` template to use these configurable values
- Defaults to 0 seconds to maintain existing behavior

**Testing:**
- Verified template rendering with default values (0)
- Verified template rendering with custom values (30, 60)
- Both probes correctly use the configured `initialDelaySeconds`

---------

Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: kylecarbs <7122116+kylecarbs@users.noreply.github.com>
2025-07-07 08:37:19 +01:00
Ethan a1c77e36be fix: handle sql/driver.Valuer types properly in json logs (#18760)
This bumps `slog` to incorporate https://github.com/coder/slog/pull/219.

Before:
```json
{
  "fields": {
      "Code": "{Int32:0 Valid:false}",
      "ValidCode": "{Int32:12 Valid:true}"
  }
}
```

After:
```json
{
  "fields": {
      "Code": null,
      "ValidCode": 12
  }
}
```
2025-07-07 13:39:18 +10:00
Atif Ali aad14b8a6b docs: add RDP desktop button gif (#18758)
Forgot to add this in #18716
2025-07-06 20:15:37 +05:00
Atif Ali ca13b58d57 docs: reorganize remote desktop docs (#18716)
- Reorganize each option in two sections: Web and Desktop Client
- Moves the warning about UDP connections to the bottom
- Move Coder Desktop as the first option
- Links the Coder Desktop RDP module

Preview:
https://coder.com/docs/@remote-desktop-module/user-guides/workspace-access/remote-desktops
2025-07-06 15:46:15 +05:00
Edward Angert 02372caf92 docs: align feature stages for July release (#18752)
some of these changes might also be in other PRs, but hopefully this
doesn't cause any merge conflicts

closes #18197

---------

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
2025-07-04 09:34:49 -04:00
Bruno Quaresma 369bccd52a feat: establish terminal reconnection foundation (#18693)
Adds a new hook called `useWithRetry` as part of
https://github.com/coder/internal/issues/659

---------

Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: BrunoQuaresma <3165839+BrunoQuaresma@users.noreply.github.com>
Co-authored-by: Claude <noreply@anthropic.com>
2025-07-03 17:49:52 -03:00
blink-so[bot] 5ad1847c42 fix: add manual confirmation for release calendar update (#18748)
Add a confirmation dialog to the release script that prompts the user to
manually update the release calendar documentation before proceeding
with the release.

## Changes

- Added a confirmation prompt that asks users to update the release
calendar documentation
- Provides the URL to the documentation
(https://coder.com/docs/install/releases#release-schedule)
- Suggests running the `./scripts/update-release-calendar.sh` script
- Requires explicit confirmation before proceeding with the release
- Exits the script if the user hasn't updated the documentation

## Testing

- [x] Script syntax validation passes (`bash -n scripts/release.sh`)
- [x] Changes are placed at the appropriate point in the release flow
(after release notes editing, before actual release creation)

This addresses the issue where the release calendar documentation was
getting out of date. While automation can be added later, this ensures
users manually confirm the documentation is updated before each release.

Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: bpmct <22407953+bpmct@users.noreply.github.com>
2025-07-03 19:45:12 +00:00
Steven Masley a099a8a25c feat: use preview to compute workspace tags from terraform (#18720)
If using dynamic parameters, workspace tags are extracted using
`coder/preview`.
2025-07-03 14:35:44 -05:00
Thomas Kosiewski 4607e5113b refactor: organize OAuth2 provider tests into dedicated packages (#18747)
# OAuth2 Provider Code Reorganization

This PR reorganizes the OAuth2 provider code to improve separation of concerns and maintainability. The changes include:

1. Migrating OAuth2 provider app validation tests from `coderd/oauth2_test.go` to `oauth2provider/provider_test.go`
2. Moving OAuth2 client registration validation tests to `oauth2provider/validation_test.go`
3. Adding new comprehensive test files for metadata and validation edge cases
4. Renaming `OAuth2ProviderAppSecret` to `AppSecret` for better naming consistency
5. Simplifying the main integration test in `oauth2_test.go` to focus on core functionality

The PR maintains all existing test coverage while organizing the code more logically, making it easier to understand and maintain the OAuth2 provider implementation. This reorganization will help with future enhancements to the OAuth2 provider functionality.
2025-07-03 20:41:47 +02:00
Thomas Kosiewski c65013384a refactor: move OAuth2 provider code to dedicated package (#18746)
# Refactor OAuth2 Provider Code into Dedicated Package

This PR refactors the OAuth2 provider functionality by moving it from the main `coderd` package into a dedicated `oauth2provider` package. The change improves code organization and maintainability without changing functionality.

Key changes:

- Created a new `oauth2provider` package to house all OAuth2 provider-related code
- Moved existing OAuth2 provider functionality from `coderd/identityprovider` to the new package
- Refactored handler functions to follow a consistent pattern of returning `http.HandlerFunc` instead of being handlers directly
- Split large files into smaller, more focused files organized by functionality:
  - `app_secrets.go` - Manages OAuth2 application secrets
  - `apps.go` - Handles OAuth2 application CRUD operations
  - `authorize.go` - Implements the authorization flow
  - `metadata.go` - Provides OAuth2 metadata endpoints
  - `registration.go` - Handles dynamic client registration
  - `revoke.go` - Implements token revocation
  - `secrets.go` - Manages secret generation and validation
  - `tokens.go` - Handles token issuance and validation

This refactoring improves code organization and makes the OAuth2 provider functionality more maintainable while preserving all existing behavior.
2025-07-03 20:24:45 +02:00
Thomas Kosiewski 7fbb3ced5b feat: add MCP HTTP server experiment and improve experiment middleware (#18712)
# Add MCP HTTP Server Experiment

This PR adds a new experiment flag `mcp-server-http` to enable the MCP HTTP server functionality. The changes include:

1. Added a new experiment constant `ExperimentMCPServerHTTP` with the value "mcp-server-http"
2. Added display name and documentation for the new experiment
3. Improved the experiment middleware to:
   - Support requiring multiple experiments
   - Provide better error messages with experiment display names
   - Add a development mode bypass option
4. Applied the new experiment requirement to the MCP HTTP endpoint
5. Replaced the custom OAuth2 middleware with the standard experiment middleware

The PR also improves the `Enabled()` method on the `Experiments` type by using `slices.Contains()` for better readability.
2025-07-03 20:09:18 +02:00
Thomas Kosiewski 15551541e8 feat: add OAuth2 provider functionality as an experiment (#18692)
# Add OAuth2 Provider Functionality as an Experiment

This PR adds a new experiment flag `oauth2` that enables OAuth2 provider functionality in Coder. When enabled, this experiment allows Coder to act as an OAuth2 provider.

The changes include:
- Added the new `ExperimentOAuth2` constant with appropriate documentation
- Updated the OAuth2 provider middleware to check for the experiment flag
- Modified the error message to indicate that the OAuth2 provider requires enabling the experiment
- Added the new experiment to the known experiments list in the SDK

Previously, OAuth2 provider functionality was only available in development mode. With this change, it can be enabled in production environments by activating the experiment.
2025-07-03 19:44:29 +02:00
blink-so[bot] 2c95a1dd71 chore: update gofumpt from v0.4.0 to v0.8.0 (#18652) 2025-07-03 11:28:00 -06:00
Thomas Kosiewski 494dccc510 feat: implement MCP HTTP server endpoint with authentication (#18670)
# Add MCP HTTP server with streamable transport support

- Add MCP HTTP server with streamable transport support
- Integrate with existing toolsdk for Coder workspace operations
- Add comprehensive E2E tests with OAuth2 bearer token support
- Register MCP endpoint at /api/experimental/mcp/http with authentication
- Support RFC 6750 Bearer token authentication for MCP clients

Change-Id: Ib9024569ae452729908797c42155006aa04330af
Signed-off-by: Thomas Kosiewski <tk@coder.com>
2025-07-03 19:27:41 +02:00
Thomas Kosiewski 60b08f0960 fix: remove unique constraint on OAuth2 provider app names (#18669)
# Remove unique constraint on OAuth2 provider app names

This PR removes the unique constraint on the `name` field in the `oauth2_provider_apps` table to comply with RFC 7591, which only requires unique client IDs, not unique client names.

Changes include:
- Removing the unique constraint from the database schema
- Adding migration files for both up and down migrations
- Removing the name uniqueness check in the in-memory database implementation
- Updating the unique constraint constants

Change-Id: Iae7a1a06546fbc8de541a52e291f8a4510d57e8a
Signed-off-by: Thomas Kosiewski <tk@coder.com>
2025-07-03 19:13:13 +02:00
Jaayden Halko 90a875d916 chore: implement tests for dynamic parameter component (#18745) 2025-07-03 13:09:59 -04:00
Thomas Kosiewski 4dcf0c3e7e docs: add comprehensive development documentation (#18646)
# Organize Development Documentation into Separate Files

This PR reorganizes the development documentation by splitting the monolithic CLAUDE.md file into multiple focused documents. The main file now provides a concise overview with essential commands and critical patterns, while importing detailed content from specialized guides.

Key improvements:
- Created separate documentation files for specific domains:
  - Database development patterns
  - OAuth2 implementation guidelines
  - Testing best practices
  - Troubleshooting common issues
  - Development workflows and guidelines
- Restructured the main CLAUDE.md to be more scannable with improved formatting
- Added quick-reference tables for common commands
- Maintained all existing content while making it more accessible
- Highlighted critical patterns that must be followed

This organization makes the documentation more maintainable and easier to navigate, allowing developers to quickly find relevant information for their specific tasks.
2025-07-03 18:51:23 +02:00
Thomas Kosiewski 74e1d5c4b6 feat: implement OAuth2 dynamic client registration (RFC 7591/7592) (#18645)
# Implement OAuth2 Dynamic Client Registration (RFC 7591/7592)

This PR implements OAuth2 Dynamic Client Registration according to RFC 7591 and Client Configuration Management according to RFC 7592. These standards allow OAuth2 clients to register themselves programmatically with Coder as an authorization server.

Key changes include:

1. Added database schema extensions to support RFC 7591/7592 fields in the `oauth2_provider_apps` table
2. Implemented `/oauth2/register` endpoint for dynamic client registration (RFC 7591)
3. Added client configuration management endpoints (RFC 7592):
   - GET/PUT/DELETE `/oauth2/clients/{client_id}`
   - Registration access token validation middleware

4. Added comprehensive validation for OAuth2 client metadata:
   - URI validation with support for custom schemes for native apps
   - Grant type and response type validation
   - Token endpoint authentication method validation

5. Enhanced developer documentation with:
   - RFC compliance guidelines
   - Testing best practices to avoid race conditions
   - Systematic debugging approaches for OAuth2 implementations

The implementation follows security best practices from the RFCs, including proper token handling, secure defaults, and appropriate error responses. This enables third-party applications to integrate with Coder's OAuth2 provider capabilities programmatically.
2025-07-03 18:33:47 +02:00
Steven Masley 699dd8e554 chore: create interface for pkgs to return codersdk errors (#18719)
This interface allows it to create rich codersdk errors and pass them up to the `wsbuilder` error handling.
2025-07-03 08:33:45 -05:00
Mathias Fredriksson 7d412c2272 feat(examples/templates): add docker-devcontainer template and rename envbuilder template (#18741)
This change adds a new `docker-devcontainer` template which allows you
to provision a workspace running in Docker, that also creates workspaces
via Docker running inside (DinD).

- **chore(examples/templates): rename `docker-devcontainer` to
`docker-envbuilder`**
- **feat(examples/templates): add `docker-devcontainer` example
template**
2025-07-03 15:50:08 +03:00
Mathias Fredriksson 8b6d70bf1f fix(site): update vs code dev container button URLs (#18696) 2025-07-03 15:03:05 +03:00
Atif Ali 351745752b docs: update release calendar with 2.24 release (#18742) 2025-07-03 11:20:16 +00:00
Jaayden Halko 61b6562f9a feat: display descriptions in multi-select component (#18730)
<img width="528" alt="Screenshot 2025-07-02 at 23 06 51"
src="https://github.com/user-attachments/assets/d6223d99-bc1b-4325-8eb6-d87a687bcec8"
/>
2025-07-03 05:55:20 -04:00
Atif Ali db8ed007f9 chore: add rdp icon (#18736) 2025-07-03 08:22:02 +02:00
Ethan 7500aa4d6c fix(cli): calculate coder ping max correctly (#18734)
Embarassing mistake I made months ago 😦 

*Doesn't effect schmoder, since we don't parse that max, it calculates it itself
2025-07-03 13:22:54 +10:00
Rowan Smith 6db6f48300 chore: fix broken link in docs (#18733)
Fixes the "Helm README" link on
https://coder.com/docs/install/kubernetes so it goes to the right path.

Side note: I don't see any content in
https://coder.com/docs/about/contributing/documentation about to whom
such a PR should be assigned, if any. Edward was suggested and I see
you've worked on other PR's with the `docs` label, so going with that.
2025-07-02 22:34:29 -04:00
Thomas Kosiewski 09c50559f3 feat: implement RFC 6750 Bearer token authentication (#18644)
# Add RFC 6750 Bearer Token Authentication Support

This PR implements RFC 6750 Bearer Token authentication as an additional authentication method for Coder's API. This allows clients to authenticate using standard OAuth 2.0 Bearer tokens in two ways:

1. Using the `Authorization: Bearer <token>` header
2. Using the `access_token` query parameter

Key changes:

- Added support for extracting tokens from both Bearer headers and access_token query parameters
- Implemented proper WWW-Authenticate headers for 401/403 responses with appropriate error descriptions
- Added comprehensive test coverage for the new authentication methods
- Updated the OAuth2 protected resource metadata endpoint to advertise Bearer token support
- Enhanced the OAuth2 testing script to verify Bearer token functionality

These authentication methods are added as fallback options, maintaining backward compatibility with Coder's existing authentication mechanisms. The existing authentication methods (cookies, session token header, etc.) still take precedence.

This implementation follows the OAuth 2.0 Bearer Token specification (RFC 6750) and improves interoperability with standard OAuth 2.0 clients.
2025-07-02 19:14:54 +02:00
Hugo Dutka eade5b019b fix: handle null response from the template presets endpoint (#18723)
The template presets endpoint returns a null response when a template
version does not define any presets.
2025-07-02 19:08:33 +02:00
Thomas Kosiewski 33bbf18a4b feat: add OAuth2 protected resource metadata endpoint for RFC 9728 (#18643)
# Add OAuth2 Protected Resource Metadata Endpoint

This PR implements the OAuth2 Protected Resource Metadata endpoint according to RFC 9728. The endpoint is available at `/.well-known/oauth-protected-resource` and provides information about Coder as an OAuth2 protected resource.

Key changes:
- Added a new endpoint at `/.well-known/oauth-protected-resource` that returns metadata about Coder as an OAuth2 protected resource
- Created a new `OAuth2ProtectedResourceMetadata` struct in the SDK
- Added tests to verify the endpoint functionality
- Updated API documentation to include the new endpoint

The implementation currently returns basic metadata including the resource identifier and authorization server URL. The `scopes_supported` field is empty until a scope system based on RBAC permissions is implemented. The `bearer_methods_supported` field is omitted as Coder uses custom authentication methods rather than standard RFC 6750 bearer tokens.

A TODO has been added to implement RFC 6750 bearer token support in the future.
2025-07-02 18:58:41 +02:00
Thomas Kosiewski 1b73b1a12f docs: add Go LSP MCP configs and tools guide for code navigation (#18613)
# Add Code Navigation and Investigation Guide for Go LSP Tools

Added a new section to the CLAUDE.md documentation that explains how to use Go Language Server Protocol (LSP) tools when working with the Coder codebase. The guide includes:

- Commands for finding function definitions, symbol references, and getting symbol information
- Examples of LSP usage with specific commands
- Guidance on when to use LSP versus other tools like grep or bash
- A structured investigation strategy for navigating the codebase, starting with route registration and tracing through to implementations

This documentation helps developers more efficiently explore and understand the codebase structure.
2025-07-02 18:43:35 +02:00
Cian Johnston 630804ec92 chore: fix duplicate migration 000345 (#18721)
Fixes duplicate migration introduced by
https://github.com/coder/coder/pull/18575
2025-07-02 16:15:10 +00:00
Thomas Kosiewski f0c9c4dbcd feat: oauth2 - add RFC 8707 resource indicators and audience validation (#18575)
This pull request implements RFC 8707, Resource Indicators for OAuth 2.0 (https://datatracker.ietf.org/doc/html/rfc8707), to enhance the security of our OAuth 2.0 provider. 

This change enables proper audience validation and binds access tokens to their intended resource, which is crucial
  for preventing token misuse in multi-tenant environments or deployments with multiple resource servers.

##  Key Changes:


   * Resource Parameter Support: Adds support for the resource parameter in both the authorization (`/oauth2/authorize`) and token (`/oauth2/token`) endpoints, allowing clients to specify the intended resource server.
   * Audience Validation: Implements server-side validation to ensure that the resource parameter provided during the token exchange matches the one from the authorization request.
   * API Middleware Enforcement: Introduces a new validation step in the API authentication middleware (`coderd/httpmw/apikey.go`) to verify that the audience of the access token matches the resource server being accessed.
   * Database Schema Updates:
       * Adds a `resource_uri` column to the `oauth2_provider_app_codes` table to store the resource requested during authorization.
       * Adds an `audience` column to the `oauth2_provider_app_tokens` table to bind the issued token to a specific audience.
   * Enhanced PKCE: Includes a minor enhancement to the PKCE implementation to protect against timing attacks.
   * Comprehensive Testing: Adds extensive new tests to `coderd/oauth2_test.go` to cover various RFC 8707 scenarios, including valid flows, mismatched resources, and refresh token validation.

##  How it Works:


   1. An OAuth2 client specifies the target resource (e.g., https://coder.example.com) using the resource parameter in the authorization request.
   2. The authorization server stores this resource URI with the authorization code.
   3. During the token exchange, the server validates that the client provides the same resource parameter.
   4. The server issues an access token with an audience claim set to the validated resource URI.
   5. When the client uses the access token to call an API endpoint, the middleware verifies that the token's audience matches the URL of the Coder deployment, rejecting any tokens intended for a different resource.


  This ensures that a token issued for one Coder deployment cannot be used to access another, significantly strengthening our authentication security.

---

Change-Id: I3924cb2139e837e3ac0b0bd40a5aeb59637ebc1b
Signed-off-by: Thomas Kosiewski <tk@coder.com>
2025-07-02 17:49:00 +02:00
Sas Swart 01163ea57b feat: allow users to pause prebuilt workspace reconciliation (#18700)
This PR provides two commands:
* `coder prebuilds pause`
* `coder prebuilds resume`

These allow the suspension of all prebuilds activity, intended for use
if prebuilds are misbehaving.
2025-07-02 15:05:42 +00:00
Steven Masley 4072d228c5 feat: support dynamic parameters on create template request (#18636)
Future work is to add this checkbox to the UI to opt into dynamic
parameters from the first template create.
2025-07-02 09:44:01 -05:00
blink-so[bot] 91aa583ea4 docs: mention Windsurf module in Windsurf documentation (#18715)
Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: bpmct <22407953+bpmct@users.noreply.github.com>
2025-07-02 19:13:35 +05:00
Spike Curtis 59c8b560fa test: add test that we close stdin on SSH session close (#18711)
closes #18519

Adds a unit test that verifies that we close the stdin to a non-TTY process when the SSH session connected to it exits.

c.f. https://github.com/coder/coder/issues/18519#issuecomment-3027609871

Validates that we match OpenSSH behavior.
2025-07-02 16:23:07 +04:00
Mathias Fredriksson 8a69f6af17 fix(agent/agentcontainers): avoid logspam in API updaterLoop (#18710)
Fixes #18709
2025-07-02 14:29:45 +03:00
Atif Ali 0b8ed9c2bd docs: move the duplicate Coder Desktop install warning to Troubleshooting (#18691)
Co-authored-by: Edward Angert <EdwardAngert@users.noreply.github.com>
2025-07-02 11:22:58 +00:00
ケイラ 0b82f41a24 feat: allow masking workspace parameter inputs (#18595) 2025-07-01 16:27:43 -06:00
ケイラ d22ac1cf65 chore: don't cache errors in file cache (#18555) 2025-07-01 13:50:37 -06:00
Edward Angert ab254adfb9 docs: add section about how to disable path based apps to security best practices (#18419)
add a new section specifically about how to disable path-based apps to
the security best practices doc

## todo

- [x] copy review
- [x] cross-linking

---------

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
Co-authored-by: Dean Sheather <dean@deansheather.com>
2025-07-01 13:18:47 -04:00
Garrett Delfosse d14e9be0fe feat: add Coder registry links to template creation and editing (#18680)
## Summary
- Add "Browse Templates" card to starter templates page
- Add "Browse Modules" button to template editor topbar
- Both link to https://registry.coder.com as requested in #18141

<img width="1248" alt="Screenshot 2025-07-01 at 9 29 26 AM"
src="https://github.com/user-attachments/assets/2295e45c-2056-41cd-a39e-48d4379295be"
/>
<img width="943" alt="Screenshot 2025-07-01 at 9 29 45 AM"
src="https://github.com/user-attachments/assets/e0652b76-43bf-4794-825d-72b4fe7c5e5f"
/>



🤖 Generated with [Claude Code](https://claude.ai/code)

---------

Co-authored-by: Claude <noreply@anthropic.com>
2025-07-01 13:18:27 -04:00
Mathias Fredriksson 1158ca25bf fix(dogfood/coder): run go clean cache at workspace shutdown (#18685)
The Go build cache has a tendency to accumulate and waste space
(typically in the realm of 10-70 GB). This change automatically cleans
up the cache on shutdown to prevent accumulation.
2025-07-01 15:22:26 +01:00
Thomas Kosiewski 6f2834f62a feat: oauth2 - add authorization server metadata endpoint and PKCE support (#18548)
## Summary

  This PR implements critical MCP OAuth2 compliance features for Coder's authorization server, adding PKCE support, resource parameter handling, and OAuth2 server metadata discovery. This brings Coder's OAuth2 implementation significantly closer to production readiness for MCP (Model Context Protocol)
  integrations.

  ## What's Added

  ### OAuth2 Authorization Server Metadata (RFC 8414)
  - Add `/.well-known/oauth-authorization-server` endpoint for automatic client discovery
  - Returns standardized metadata including supported grant types, response types, and PKCE methods
  - Essential for MCP client compatibility and OAuth2 standards compliance

  ### PKCE Support (RFC 7636)
  - Implement Proof Key for Code Exchange with S256 challenge method
  - Add `code_challenge` and `code_challenge_method` parameters to authorization flow
  - Add `code_verifier` validation in token exchange
  - Provides enhanced security for public clients (mobile apps, CLIs)

  ### Resource Parameter Support (RFC 8707)
  - Add `resource` parameter to authorization and token endpoints
  - Store resource URI and bind tokens to specific audiences
  - Critical for MCP's resource-bound token model

  ### Enhanced OAuth2 Error Handling
  - Add OAuth2-compliant error responses with proper error codes
  - Use standard error format: `{"error": "code", "error_description": "details"}`
  - Improve error consistency across OAuth2 endpoints

  ### Authorization UI Improvements
  - Fix authorization flow to use POST-based consent instead of GET redirects
  - Remove dependency on referer headers for security decisions
  - Improve CSRF protection with proper state parameter validation

  ## Why This Matters

  **For MCP Integration:** MCP requires OAuth2 authorization servers to support PKCE, resource parameters, and metadata discovery. Without these features, MCP clients cannot securely authenticate with Coder.

  **For Security:** PKCE prevents authorization code interception attacks, especially critical for public clients. Resource binding ensures tokens are only valid for intended services.

  **For Standards Compliance:** These are widely adopted OAuth2 extensions that improve interoperability with modern OAuth2 clients.

  ## Database Changes

  - **Migration 000343:** Adds `code_challenge`, `code_challenge_method`, `resource_uri` to `oauth2_provider_app_codes`
  - **Migration 000343:** Adds `audience` field to `oauth2_provider_app_tokens` for resource binding
  - **Audit Updates:** New OAuth2 fields properly tracked in audit system
  - **Backward Compatibility:** All changes maintain compatibility with existing OAuth2 flows

  ## Test Coverage

  - Comprehensive PKCE test suite in `coderd/identityprovider/pkce_test.go`
  - OAuth2 metadata endpoint tests in `coderd/oauth2_metadata_test.go`
  - Integration tests covering PKCE + resource parameter combinations
  - Negative tests for invalid PKCE verifiers and malformed requests

  ## Testing Instructions

  ```bash
  # Run the comprehensive OAuth2 test suite
  ./scripts/oauth2/test-mcp-oauth2.sh

  Manual Testing with Interactive Server

  # Start Coder in development mode
  ./scripts/develop.sh

  # In another terminal, set up test app and run interactive flow
  eval $(./scripts/oauth2/setup-test-app.sh)
  ./scripts/oauth2/test-manual-flow.sh
  # Opens browser with OAuth2 flow, handles callback automatically

  # Clean up when done
  ./scripts/oauth2/cleanup-test-app.sh

  Individual Component Testing

  # Test metadata endpoint
  curl -s http://localhost:3000/.well-known/oauth-authorization-server | jq .

  # Test PKCE generation
  ./scripts/oauth2/generate-pkce.sh

  # Run specific test suites
  go test -v ./coderd/identityprovider -run TestVerifyPKCE
  go test -v ./coderd -run TestOAuth2AuthorizationServerMetadata
```

  ### Breaking Changes

  None. All changes maintain backward compatibility with existing OAuth2 flows.

---

Change-Id: Ifbd0d9a543d545f9f56ecaa77ff2238542ff954a
Signed-off-by: Thomas Kosiewski <tk@coder.com>
2025-07-01 15:39:29 +02:00
Cian Johnston dbfbef6ecb chore(cli): increase reconciliation interval to 1 minute (#18690)
Increase prebuilds reconciliation and backoff interval to 1 minute by
default.
2025-07-01 14:35:02 +01:00
Susana Ferreira 57a6d59d8d docs: add warning about prebuilds incompatibility with certain features (#18689)
## Description

This PR adds a warning to the prebuilds documentation about
incompatibility with Workspace schedule (autostart/autostop), dormancy,
and DevContainers. These configurations can interfere with prebuild
behavior and should be avoided for now.

Preview:
![Screenshot 2025-07-01 at 12 58
02](https://github.com/user-attachments/assets/e1a837de-b66c-4414-bd0b-471474b43b84)
2025-07-01 13:59:07 +01:00
Cian Johnston 4e95b1d20e fix: revert changes to GetRunningPrebuiltWorkspaces (#18688)
… (#18588)"

This reverts commit 258a839d27.
2025-07-01 10:11:43 +00:00
Hugo Dutka 3d22e27f4e fix: handle task sidebar app health check disabled correctly (#18687)
Previously, by mistake, the task sidebar would not display workspace
apps that don't have a health check configured.
2025-07-01 12:01:17 +02:00
Danielle Maywood 7e372f7a35 fix(agent/agentcontainers): reset error at start of rebuild (#18686)
Reset the error associated with a devcontainer when a rebuild is requested.
2025-07-01 10:57:43 +01:00
Cian Johnston 258a839d27 chore(coderd/database): optimize GetRunningPrebuiltWorkspaces (#18588)
Fixes https://github.com/coder/internal/issues/715

After this change, the only use of the `workspace_prebuilds` view is the
`ClaimPrebuiltWorkspace` query. A subsequent PR will update the view.

Before: ~44ms https://explain.dalibo.com/plan/76cbe21d1a4c9329#plan

After: 7.3ms https://explain.dalibo.com/plan/5abbdf926315677e#plan
2025-07-01 09:42:01 +01:00
Danny Kopping 0f56f0029b chore: add which-release script (#18657) 2025-07-01 08:05:44 +00:00
Kacper Sawicki 695de6e0c0 chore(coderd/database): optimize AuditLogs queries (#18600)
Closes #17689

This PR optimizes the audit logs query performance by extracting the
count operation into a separate query and replacing the OR-based
workspace_builds with conditional joins.

## Query changes
* Extracted count query to separate one
* Replaced single `workspace_builds` join with OR conditions with
separate conditional joins
* Added conditional joins
* `wb_build` for workspace_build audit logs (which is a direct lookup)
    * `wb_workspace` for workspace create audit logs (via workspace)

Optimized AuditLogsOffset query:
https://explain.dalibo.com/plan/4g1hbedg4a564bg8

New CountAuditLogs query:
https://explain.dalibo.com/plan/ga2fbcecb9efbce3
2025-07-01 07:31:14 +02:00
Perdjesk 74e1953619 docs: bitnami/postgresql primary prefix for persistence.size config key (#18446)
The `bitnami/postgresql`chart doesn't have a value with key
`persistence.size`. The correct value key which control the size of the
PVC is `primary.persistence.size`.

See:
-
https://github.com/bitnami/charts/blob/postgresql/16.7.12/bitnami/postgresql/values.yaml
- The JSON schema,
[`values.schema.json`](https://github.com/bitnami/charts/blob/postgresql/16.7.12/bitnami/postgresql/values.schema.json)
of the
[`values.yaml`](https://github.com/bitnami/charts/blob/postgresql/16.7.12/bitnami/postgresql/values.yaml)
included in the chart is out of sync.
https://github.com/bitnami/readme-generator-for-helm/issues/142
2025-06-30 16:55:57 -04:00
Danielle Maywood 4756080eb2 feat(site): display devcontainer start error (#18637)
Fixes https://github.com/coder/internal/issues/705

Surface errors on the UI when a devcontainer agent is unable to be
injected.
2025-06-30 21:34:29 +01:00
Asher fc7700a62f fix: improve reliability of app statuses (#18622)
We were discarding all "working" updates from the screen watcher because
we cannot tell the difference between the agent or user changing the
screen, but it makes sense to accept it as the very first update,
because the agent could be working but neglected to report that fact, so
you would never get an initial "working" update (it would just
eventually go straight to "idle").

Also messages can start at zero, so I made a fix for that as well,
although the first message will be from the LLM and we ignore
those anyway, so this probably has no actual effect, but seems more
technically correct.

And it seems I forgot to actually update the last message ID, which 
also does not actually matter for user messages (since I think the
SSE endpoint will not re-emit a user message it has already emitted),
but seems more technically correct to check.

Lastly, if we have the screen watcher, ignore the agent's self-reported
state and always use "working" since it is unreliable.  The idle state will
eventually be caught by the watcher.
2025-06-30 12:12:20 -08:00
Jaayden Halko ad6773360c fix: display error message on delete workspace error (#18654)
resolves coder/preview#155

When deleting a workspace, show an error dialog if deleting the
workspace is not possible.

![Screenshot 2025-06-28 at 10 06
47](https://github.com/user-attachments/assets/650bfb54-6ed9-4f41-a410-1333afeee0a4)
2025-06-30 15:09:51 -04:00
Hugo Dutka 22c5e84a7e fix: handle health status when displaying task apps (#18675)
Previously, we displayed apps in iframes on the task page without
waiting for them to initialize. This would result in 502 errors shown to
the user. This PR makes sure that we only display the app after it
initializes.

### Before
<img width="1920" alt="Screenshot 2025-06-30 at 14 59 07 (2)"
src="https://github.com/user-attachments/assets/63564ac9-abce-4a0c-b58e-b988772fae82"
/>
2025-06-30 20:46:28 +02:00
Spike Curtis b7cb275d7e fix: stop tearing down non-TTY processes on SSH session end (#18673)
(possibly temporary) fix for #18519

Matches OpenSSH for non-tty sessions, where we don't actively terminate
the process.

Adds explicit tracking to the SSH server for these processes so that if
we are shutting down we terminate them: this ensures that we can shut
down quickly to allow shutdown scripts to run. It also ensures our tests
don't leak system resources.
2025-06-30 22:06:05 +04:00
Mathias Fredriksson 9ccaf86099 fix(agent/agentcontainers): always derive devcontainer name from workspace folder (#18666) 2025-06-30 20:56:39 +03:00
Vladislav Rudskoy 715c7b0c24 chore: correct RD limitation comment (#18668)
subj
2025-06-30 22:46:00 +05:00
Atif Ali b1e8d5d5e0 docs: remove beta label from Coder Desktop (#18651)
Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: Edward Angert <EdwardAngert@users.noreply.github.com>
2025-06-30 21:23:09 +05:00
dependabot[bot] 851cda55d6 ci: bump the github-actions group with 3 updates (#18665)
Bumps the github-actions group with 3 updates:
[step-security/harden-runner](https://github.com/step-security/harden-runner),
[fluxcd/flux2](https://github.com/fluxcd/flux2) and
[github/codeql-action](https://github.com/github/codeql-action).

Updates `step-security/harden-runner` from 2.12.1 to 2.12.2
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/step-security/harden-runner/releases">step-security/harden-runner's
releases</a>.</em></p>
<blockquote>
<h2>v2.12.2</h2>
<h2>What's Changed</h2>
<p>Added HTTPS Monitoring for additional destinations -
*.githubusercontent.com
Bug fixes:</p>
<ul>
<li>Implicitly allow local multicast, local unicast and broadcast IP
addresses in block mode</li>
<li>Increased policy map size for block mode</li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/step-security/harden-runner/compare/v2...v2.12.2">https://github.com/step-security/harden-runner/compare/v2...v2.12.2</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/step-security/harden-runner/commit/6c439dc8bdf85cadbbce9ed30d1c7b959517bc49"><code>6c439dc</code></a>
Merge pull request <a
href="https://redirect.github.com/step-security/harden-runner/issues/562">#562</a>
from step-security/rc-22</li>
<li><a
href="https://github.com/step-security/harden-runner/commit/bf5688696d0b2cf8221eadb38e4232386015763a"><code>bf56886</code></a>
update agent</li>
<li><a
href="https://github.com/step-security/harden-runner/commit/5436dac7b5fa76a1a179168f5f4de86c00e22c84"><code>5436dac</code></a>
update agent</li>
<li><a
href="https://github.com/step-security/harden-runner/commit/88d305a3530acfa6d1939000baaa571e520df9c8"><code>88d305a</code></a>
update agent</li>
<li><a
href="https://github.com/step-security/harden-runner/commit/b976878278dbe3bc16039f7165b8faf809c50297"><code>b976878</code></a>
update agent</li>
<li><a
href="https://github.com/step-security/harden-runner/commit/875cc92db280a03598e7492a3e6c165c689f7af6"><code>875cc92</code></a>
Update agent</li>
<li>See full diff in <a
href="https://github.com/step-security/harden-runner/compare/002fdce3c6a235733a90a27c80493a3241e56863...6c439dc8bdf85cadbbce9ed30d1c7b959517bc49">compare
view</a></li>
</ul>
</details>
<br />

Updates `fluxcd/flux2` from 2.6.2 to 2.6.3
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/fluxcd/flux2/releases">fluxcd/flux2's
releases</a>.</em></p>
<blockquote>
<h2>v2.6.3</h2>
<h2>Highlights</h2>
<p>Flux v2.6.3 is a patch release that comes with various fixes. Users
are encouraged to upgrade for the best experience.</p>
<p>Fixes:</p>
<ul>
<li>Fix for <code>rsa-sha2-512</code> and <code>rsa-sha2-256</code>
algorithms not being prioritized for <code>ssh-rsa</code> host keys in
source-controller, image-automation-controller and Flux CLI
bootstrap.</li>
</ul>
<h2>Components changelog</h2>
<ul>
<li>source-controller <a
href="https://github.com/fluxcd/source-controller/blob/v1.6.2/CHANGELOG.md">v1.6.2</a></li>
<li>image-automation-controller <a
href="https://github.com/fluxcd/image-automation-controller/blob/v0.41.2/CHANGELOG.md">v0.41.2</a></li>
</ul>
<h2>CLI changed</h2>
<ul>
<li>[release/v2.6.x] Update toolkit components by <a
href="https://github.com/fluxcdbot"><code>@​fluxcdbot</code></a> in <a
href="https://redirect.github.com/fluxcd/flux2/pull/5427">fluxcd/flux2#5427</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/fluxcd/flux2/compare/v2.6.2...v2.6.3">https://github.com/fluxcd/flux2/compare/v2.6.2...v2.6.3</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/fluxcd/flux2/commit/bda4c8187e436462be0d072e728b67afa215c593"><code>bda4c81</code></a>
Merge pull request <a
href="https://redirect.github.com/fluxcd/flux2/issues/5427">#5427</a>
from fluxcd/backport-5426-to-release/v2.6.x</li>
<li><a
href="https://github.com/fluxcd/flux2/commit/3f281da7381e3984913244d78b9768e4fa5fbb65"><code>3f281da</code></a>
Fix: Prioritize sha2-512 and sha2-256 for ssh-rsa host keys</li>
<li><a
href="https://github.com/fluxcd/flux2/commit/963e99188cb0a77dfbe70a3db7a34c0f6e159dd3"><code>963e991</code></a>
Update toolkit components</li>
<li>See full diff in <a
href="https://github.com/fluxcd/flux2/compare/a48f81a66c4ca9fbd993233ab99dd03a7cfbe09a...bda4c8187e436462be0d072e728b67afa215c593">compare
view</a></li>
</ul>
</details>
<br />

Updates `github/codeql-action` from 3.29.0 to 3.29.1
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/github/codeql-action/releases">github/codeql-action's
releases</a>.</em></p>
<blockquote>
<h2>v3.29.1</h2>
<h1>CodeQL Action Changelog</h1>
<p>See the <a
href="https://github.com/github/codeql-action/releases">releases
page</a> for the relevant changes to the CodeQL CLI and language
packs.</p>
<h2>3.29.1 - 27 Jun 2025</h2>
<ul>
<li>Fix bug in PR analysis where user-provided <code>include</code>
query filter fails to exclude non-included queries. <a
href="https://redirect.github.com/github/codeql-action/pull/2938">#2938</a></li>
<li>Update default CodeQL bundle version to 2.22.1. <a
href="https://redirect.github.com/github/codeql-action/pull/2950">#2950</a></li>
</ul>
<p>See the full <a
href="https://github.com/github/codeql-action/blob/v3.29.1/CHANGELOG.md">CHANGELOG.md</a>
for more information.</p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/github/codeql-action/blob/main/CHANGELOG.md">github/codeql-action's
changelog</a>.</em></p>
<blockquote>
<h1>CodeQL Action Changelog</h1>
<p>See the <a
href="https://github.com/github/codeql-action/releases">releases
page</a> for the relevant changes to the CodeQL CLI and language
packs.</p>
<h2>[UNRELEASED]</h2>
<ul>
<li>Experimental: When the <code>quality-queries</code> input for the
<code>init</code> action is provided with an argument, separate
<code>.quality.sarif</code> files are produced and uploaded for each
language with the results of the specified queries. Do not use this in
production as it is part of an internal experiment and subject to change
at any time. <a
href="https://redirect.github.com/github/codeql-action/pull/2935">#2376</a></li>
</ul>
<h2>3.29.1 - 27 Jun 2025</h2>
<ul>
<li>Fix bug in PR analysis where user-provided <code>include</code>
query filter fails to exclude non-included queries. <a
href="https://redirect.github.com/github/codeql-action/pull/2938">#2938</a></li>
<li>Update default CodeQL bundle version to 2.22.1. <a
href="https://redirect.github.com/github/codeql-action/pull/2950">#2950</a></li>
</ul>
<h2>3.29.0 - 11 Jun 2025</h2>
<ul>
<li>Update default CodeQL bundle version to 2.22.0. <a
href="https://redirect.github.com/github/codeql-action/pull/2925">#2925</a></li>
<li>Bump minimum CodeQL bundle version to 2.16.6. <a
href="https://redirect.github.com/github/codeql-action/pull/2912">#2912</a></li>
</ul>
<h2>3.28.19 - 03 Jun 2025</h2>
<ul>
<li>The CodeQL Action no longer includes its own copy of the extractor
for the <code>actions</code> language, which is currently in public
preview.
The <code>actions</code> extractor has been included in the CodeQL CLI
since v2.20.6. If your workflow has enabled the <code>actions</code>
language <em>and</em> you have pinned
your <code>tools:</code> property to a specific version of the CodeQL
CLI earlier than v2.20.6, you will need to update to at least CodeQL
v2.20.6 or disable
<code>actions</code> analysis.</li>
<li>Update default CodeQL bundle version to 2.21.4. <a
href="https://redirect.github.com/github/codeql-action/pull/2910">#2910</a></li>
</ul>
<h2>3.28.18 - 16 May 2025</h2>
<ul>
<li>Update default CodeQL bundle version to 2.21.3. <a
href="https://redirect.github.com/github/codeql-action/pull/2893">#2893</a></li>
<li>Skip validating SARIF produced by CodeQL for improved performance.
<a
href="https://redirect.github.com/github/codeql-action/pull/2894">#2894</a></li>
<li>The number of threads and amount of RAM used by CodeQL can now be
set via the <code>CODEQL_THREADS</code> and <code>CODEQL_RAM</code>
runner environment variables. If set, these environment variables
override the <code>threads</code> and <code>ram</code> inputs
respectively. <a
href="https://redirect.github.com/github/codeql-action/pull/2891">#2891</a></li>
</ul>
<h2>3.28.17 - 02 May 2025</h2>
<ul>
<li>Update default CodeQL bundle version to 2.21.2. <a
href="https://redirect.github.com/github/codeql-action/pull/2872">#2872</a></li>
</ul>
<h2>3.28.16 - 23 Apr 2025</h2>
<ul>
<li>Update default CodeQL bundle version to 2.21.1. <a
href="https://redirect.github.com/github/codeql-action/pull/2863">#2863</a></li>
</ul>
<h2>3.28.15 - 07 Apr 2025</h2>
<ul>
<li>Fix bug where the action would fail if it tried to produce a debug
artifact with more than 65535 files. <a
href="https://redirect.github.com/github/codeql-action/pull/2842">#2842</a></li>
</ul>
<h2>3.28.14 - 07 Apr 2025</h2>
<ul>
<li>Update default CodeQL bundle version to 2.21.0. <a
href="https://redirect.github.com/github/codeql-action/pull/2838">#2838</a></li>
</ul>
<h2>3.28.13 - 24 Mar 2025</h2>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/github/codeql-action/commit/39edc492dbe16b1465b0cafca41432d857bdb31a"><code>39edc49</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2953">#2953</a>
from github/update-v3.29.1-428aea55f</li>
<li><a
href="https://github.com/github/codeql-action/commit/27c4fb1eef772029c0bbeed96d8538a2af79e541"><code>27c4fb1</code></a>
Update changelog for v3.29.1</li>
<li><a
href="https://github.com/github/codeql-action/commit/428aea55f52aac0db14530fe4e5c97462c533f7d"><code>428aea5</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2952">#2952</a>
from github/redsun82/fix-swift-test</li>
<li><a
href="https://github.com/github/codeql-action/commit/973250f3d233f50890a597fef853ae3b2a538a31"><code>973250f</code></a>
Swift: recreate a default Swift package to fix test</li>
<li><a
href="https://github.com/github/codeql-action/commit/8ef17824cfb2a3f40cbc7f41bac7e055e53b8164"><code>8ef1782</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2950">#2950</a>
from github/update-bundle/codeql-bundle-v2.22.1</li>
<li><a
href="https://github.com/github/codeql-action/commit/f3bfb9860305f6e80e048f4785d6bee33bf77356"><code>f3bfb98</code></a>
Add changelog note</li>
<li><a
href="https://github.com/github/codeql-action/commit/2b4afc20b636de8884609ee2a501a68a67766f26"><code>2b4afc2</code></a>
Update default bundle to codeql-bundle-v2.22.1</li>
<li><a
href="https://github.com/github/codeql-action/commit/9b02dc2f60288b463e7a66e39c78829b62780db7"><code>9b02dc2</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2928">#2928</a>
from github/update-supported-enterprise-server-versions</li>
<li><a
href="https://github.com/github/codeql-action/commit/7ab92d0295a9b09eb653169acdb2c24f7c43614a"><code>7ab92d0</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2948">#2948</a>
from github/mbg/copilot-instructions</li>
<li><a
href="https://github.com/github/codeql-action/commit/2cae828745579fc9309404e09440d23bba2f7b79"><code>2cae828</code></a>
Merge pull request <a
href="https://redirect.github.com/github/codeql-action/issues/2947">#2947</a>
from github/dependency-proxy/codeql-bundle-v2.22.0</li>
<li>Additional commits viewable in <a
href="https://github.com/github/codeql-action/compare/ce28f5bb42b7a9f2c824e633a3f6ee835bab6858...39edc492dbe16b1465b0cafca41432d857bdb31a">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-30 15:37:51 +00:00
dependabot[bot] 7f23be3874 chore: bump github.com/andybalholm/brotli from 1.1.1 to 1.2.0 (#18661)
Bumps
[github.com/andybalholm/brotli](https://github.com/andybalholm/brotli)
from 1.1.1 to 1.2.0.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/andybalholm/brotli/commit/676a02057d90cd1e75ede54cdfa79d4cdb574dae"><code>676a020</code></a>
Pathfinder: improve cost calculation, and use it in NewWriterV2</li>
<li><a
href="https://github.com/andybalholm/brotli/commit/fc701daacf9eec30cae7a5cec6e5e38827894d4c"><code>fc701da</code></a>
Pathfinder: change how literals are represented in arrivals.</li>
<li><a
href="https://github.com/andybalholm/brotli/commit/10cf712196eeb5358c7c2dddf1f53c08b6500f38"><code>10cf712</code></a>
Pathfinder: enable starting in the middle of a match</li>
<li><a
href="https://github.com/andybalholm/brotli/commit/d6b3fe07ed7eb3cfe0c42ab708781034a326d7fa"><code>d6b3fe0</code></a>
Pathfinder: separate searching and parsing</li>
<li><a
href="https://github.com/andybalholm/brotli/commit/199839b04846152833e2446e39cf6234712163a2"><code>199839b</code></a>
Pathfinder: pre-compute hash chain (and use 32 bits)</li>
<li><a
href="https://github.com/andybalholm/brotli/commit/e819531509efd8c7d5e79efd9fcabc655c7fbebc"><code>e819531</code></a>
Start experimenting with an optimizing MatchFinder</li>
<li><a
href="https://github.com/andybalholm/brotli/commit/18ac46a8c3d6664cd158ad14ca2fb6ba29752377"><code>18ac46a</code></a>
M4: use 32-bit hash chain</li>
<li><a
href="https://github.com/andybalholm/brotli/commit/1383db2f0e5a87e62c33bb5adf22351ee2acf50a"><code>1383db2</code></a>
M4: When shortening a match, look for a closer option</li>
<li><a
href="https://github.com/andybalholm/brotli/commit/c036c35cb06f667df542773635b0972cd794d2ea"><code>c036c35</code></a>
M4: look for repeat matches</li>
<li><a
href="https://github.com/andybalholm/brotli/commit/6a1a95ec91781f0eedba50cd865eb822ba7e90c7"><code>6a1a95e</code></a>
Add arm64 to GOARCH switches</li>
<li>Additional commits viewable in <a
href="https://github.com/andybalholm/brotli/compare/v1.1.1...v1.2.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/andybalholm/brotli&package-manager=go_modules&previous-version=1.1.1&new-version=1.2.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-30 14:08:44 +00:00
dependabot[bot] c8bc8d3865 chore: bump github.com/moby/moby from 28.2.2+incompatible to 28.3.0+incompatible (#18660)
Bumps [github.com/moby/moby](https://github.com/moby/moby) from
28.2.2+incompatible to 28.3.0+incompatible.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/moby/moby/releases">github.com/moby/moby's
releases</a>.</em></p>
<blockquote>
<h2>28.3.0</h2>
<p>For a full list of pull requests and changes in this release, refer
to the relevant GitHub milestones:</p>
<ul>
<li><a
href="https://github.com/docker/cli/issues?q=is%3Aclosed+milestone%3A28.3.0">docker/cli,
28.3.0 milestone</a></li>
<li><a
href="https://github.com/moby/moby/issues?q=is%3Aclosed+milestone%3A28.3.0">moby/moby,
28.3.0 milestone</a></li>
<li>Deprecated and removed features, see <a
href="https://github.com/docker/cli/blob/v28.3.0/docs/deprecated.md">Deprecated
Features</a>.</li>
<li>Changes to the Engine API, see <a
href="https://github.com/moby/moby/blob/v28.3.0/docs/api/version-history.md">API
version history</a>.</li>
</ul>
<h3>New</h3>
<ul>
<li>Add support for AMD GPUs in <code>docker run --gpus</code>. <a
href="https://redirect.github.com/moby/moby/pull/49952">moby/moby#49952</a></li>
<li>Use <code>DOCKER_AUTH_CONFIG</code> as a credential store. <a
href="https://redirect.github.com/docker/cli/pull/6008">docker/cli#6008</a></li>
</ul>
<h3>Bug fixes and enhancements</h3>
<ul>
<li>Ensure that the state of the container in the daemon database (used
by <a
href="https://docs.docker.com/reference/api/engine/version/v1.49/#tag/Container/operation/ContainerList">/containers/json</a>
API) is up to date when the container is stopped using the <a
href="https://docs.docker.com/reference/api/engine/version/v1.49/#tag/Container/operation/ContainerStop">/containers/{id}/stop</a>
API (before response of API). <a
href="https://redirect.github.com/moby/moby/pull/50136">moby/moby#50136</a></li>
<li>Fix <code>docker image inspect inspect</code> omitting empty fields.
<a
href="https://redirect.github.com/moby/moby/pull/50135">moby/moby#50135</a></li>
<li>Fix <code>docker images --tree</code> not marking images as in-use
when the containerd image store is disabled. <a
href="https://redirect.github.com/docker/cli/pull/6140">docker/cli#6140</a></li>
<li>Fix <code>docker pull/push</code> hang in non-interactive when
authentication is required caused by prompting for login credentials. <a
href="https://redirect.github.com/docker/cli/pull/6141">docker/cli#6141</a></li>
<li>Fix a potential resource leak when a node leaves a Swarm. <a
href="https://redirect.github.com/moby/moby/pull/50115">moby/moby#50115</a></li>
<li>Fix a regression where a login prompt on <code>docker pull</code>
would show Docker Hub-specific hints when logging in on other
registries. <a
href="https://redirect.github.com/docker/cli/pull/6135">docker/cli#6135</a></li>
<li>Fix an issue where all new tasks in the Swarm could get stuck in the
PENDING state forever after scaling up a service with placement
preferences. <a
href="https://redirect.github.com/moby/moby/pull/50211">moby/moby#50211</a></li>
<li>Remove an undocumented, hidden, top-level <code>docker remove</code>
command that was accidentally introduced in Docker 23.0. <a
href="https://redirect.github.com/docker/cli/pull/6144">docker/cli#6144</a></li>
<li>Validate registry-mirrors configuration as part of <code>dockerd
--validate</code> and improve error messages for invalid mirrors. <a
href="https://redirect.github.com/moby/moby/pull/50240">moby/moby#50240</a></li>
<li><code>dockerd-rootless-setuptool.sh</code>: Fix the script from
silently returning with no error message when subuid/subgid system
requirements are not satisfied. <a
href="https://redirect.github.com/moby/moby/pull/50059">moby/moby#50059</a></li>
<li>containerd image store: Fix <code>docker push</code> not creating a
tag on the remote repository. <a
href="https://redirect.github.com/moby/moby/pull/50199">moby/moby#50199</a></li>
<li>containerd image store: Improve handling of errors returned by the
token server during <code>docker pull/push</code>. <a
href="https://redirect.github.com/moby/moby/pull/50176">moby/moby#50176</a></li>
</ul>
<h3>Packaging updates</h3>
<ul>
<li>Allow customizing containerd service name for OpenRC. <a
href="https://redirect.github.com/moby/moby/pull/50156">moby/moby#50156</a></li>
<li>Update BuildKit to <a
href="https://github.com/moby/buildkit/releases/tag/v0.23.1">v0.23.1</a>.
<a
href="https://redirect.github.com/moby/moby/pull/50243">moby/moby#50243</a></li>
<li>Update Buildx to <a
href="https://github.com/docker/buildx/releases/tag/v0.25.0">v0.25.0</a>.
<a
href="https://redirect.github.com/docker/docker-ce-packaging/pull/1217">docker/docker-ce-packaging#1217</a></li>
<li>Update Compose to <a
href="https://github.com/docker/compose/releases/tag/v2.37.2">v2.37.2</a>.
<a
href="https://redirect.github.com/docker/docker-ce-packaging/pull/1219">docker/docker-ce-packaging#1219</a></li>
<li>Update Docker Model CLI plugin to <a
href="https://github.com/docker/model-cli/releases/tag/v0.1.30">v0.1.30</a>.
<a
href="https://redirect.github.com/docker/docker-ce-packaging/pull/1218">docker/docker-ce-packaging#1218</a></li>
<li>Update Go runtime to <a
href="https://go.dev/doc/devel/release#go1.24.4">1.24.4</a>. <a
href="https://redirect.github.com/docker/docker-ce-packaging/pull/1213">docker/docker-ce-packaging#1213</a>,
<a
href="https://redirect.github.com/moby/moby/pull/50153">moby/moby#50153</a>,
<a
href="https://redirect.github.com/docker/cli/pull/6124">docker/cli#6124</a></li>
</ul>
<h3>Networking</h3>
<ul>
<li>Revert Swarm related changes added in 28.2.x builds, due to a
regression reported in <a
href="https://redirect.github.com/moby/moby/issues/50129">moby/moby#50129</a>.
<a
href="https://redirect.github.com/moby/moby/pull/50169">moby/moby#50169</a>
<ul>
<li>Revert: Fix an issue where <code>docker network inspect
--verbose</code> could sometimes crash the daemon (<a
href="https://redirect.github.com/moby/moby/pull/49937">moby/moby#49937</a>).</li>
<li>Revert: Fix an issue where the load-balancer IP address for an
overlay network would not be released in certain cases if the Swarm was
lacking an ingress network (<a
href="https://redirect.github.com/moby/moby/pull/49948">moby/moby#49948</a>).</li>
<li>Revert: Improve the reliability of NetworkDB in busy clusters and
lossy networks (<a
href="https://redirect.github.com/moby/moby/pull/49932">moby/moby#49932</a>).</li>
<li>Revert: Improvements to the reliability and convergence speed of
NetworkDB (<a
href="https://redirect.github.com/moby/moby/pull/49939">moby/moby#49939</a>).</li>
</ul>
</li>
<li>Fix an issue that could cause container startup to fail, or lead to
failed UDP port mappings, when some container ports are mapped to
<code>0.0.0.0</code> and others are mapped to specific host addresses.
<a
href="https://redirect.github.com/moby/moby/pull/50054">moby/moby#50054</a></li>
<li>The <code>network inspect</code> response for an overlay network now
reports that <code>EnableIPv4</code> is true. <a
href="https://redirect.github.com/moby/moby/pull/50147">moby/moby#50147</a></li>
<li>Windows: Improve daemon startup time in cases where the host has
networks of type <code>&quot;Mirrored&quot;</code>. <a
href="https://redirect.github.com/moby/moby/pull/50155">moby/moby#50155</a></li>
<li>Windows: Make sure <code>docker system prune</code> and <code>docker
network prune</code> only remove networks created by Docker. <a
href="https://redirect.github.com/moby/moby/pull/50154">moby/moby#50154</a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/moby/moby/commit/265f709647947fb5a1adf7e4f96f2113dcc377bd"><code>265f709</code></a>
Merge pull request <a
href="https://redirect.github.com/moby/moby/issues/50247">#50247</a>
from vvoland/50245-28.x</li>
<li><a
href="https://github.com/moby/moby/commit/b2a9318a1e70deabdf9cda8c08caabd492b6b581"><code>b2a9318</code></a>
docs: cut api docs for v1.51</li>
<li><a
href="https://github.com/moby/moby/commit/b3e2e22b2adee0cff0a20134559074b9481ba2ba"><code>b3e2e22</code></a>
Merge pull request <a
href="https://redirect.github.com/moby/moby/issues/50244">#50244</a>
from vvoland/50177-28.x</li>
<li><a
href="https://github.com/moby/moby/commit/c571cd85133c8e25ce9c9b7eb3a1c8c54f88346e"><code>c571cd8</code></a>
Merge pull request <a
href="https://redirect.github.com/moby/moby/issues/50243">#50243</a>
from vvoland/50238-28.x</li>
<li><a
href="https://github.com/moby/moby/commit/8c713c1af4ad61a9faf8b55e7710b8a17e081275"><code>8c713c1</code></a>
gha: lower timeouts on &quot;build&quot; and &quot;merge&quot;
steps</li>
<li><a
href="https://github.com/moby/moby/commit/539c115023eb01f1dd65b019cd5d50dd36d34188"><code>539c115</code></a>
Merge pull request <a
href="https://redirect.github.com/moby/moby/issues/50240">#50240</a>
from thaJeztah/28.x_backport_validate_mirrors</li>
<li><a
href="https://github.com/moby/moby/commit/8e7ea470cf0720f1988fe9a0af6342d550d86cc3"><code>8e7ea47</code></a>
vendor: update buildkit to v0.23.1</li>
<li><a
href="https://github.com/moby/moby/commit/222baf4ccbcb216fe812ad0300d02dfec3f28a70"><code>222baf4</code></a>
vendor: github.com/moby/buildkit v0.23.0</li>
<li><a
href="https://github.com/moby/moby/commit/1627e828d7e5566ead2c69f63d661ef47f96e61a"><code>1627e82</code></a>
Merge pull request <a
href="https://redirect.github.com/moby/moby/issues/50241">#50241</a>
from thaJeztah/28.x_backport_update_cgroups</li>
<li><a
href="https://github.com/moby/moby/commit/4070ebda88cb8f6448d0725633dc40394e563705"><code>4070ebd</code></a>
Merge pull request <a
href="https://redirect.github.com/moby/moby/issues/50242">#50242</a>
from thaJeztah/28.x_backport_fix_event_ordering</li>
<li>Additional commits viewable in <a
href="https://github.com/moby/moby/compare/v28.2.2...v28.3.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/moby/moby&package-manager=go_modules&previous-version=28.2.2+incompatible&new-version=28.3.0+incompatible)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-30 14:03:08 +00:00
Danny Kopping f89e057c4c chore: add beta badge to tasks (#18656) 2025-06-30 10:51:42 +02:00
Mathias Fredriksson d814fdfa1c fix(.devcontainer): add home volume and fix code-server and filebrowser (#18648) 2025-06-30 09:32:17 +01:00
Spike Curtis e97540afbd chore: work around race in lib/pq (#18655)
Upgrade our lib/pq fork to work around the data race identified here:
https://github.com/coder/internal/issues/731
2025-06-30 12:00:46 +04:00
Bruno Quaresma 4095330041 fix: use only template version ID to create task workspace (#18642)
When creating a new task, the following error was getting returned:

**Error:**
```json
{
    "message": "Validation failed.",
    "validations": [
        {
            "field": "template_id",
            "detail": "Validation failed for tag \"excluded_with\" with value: \"42205a38-845c-4186-8475-f002e0936d53\""
        },
        {
            "field": "template_version_id",
            "detail": "Validation failed for tag \"excluded_with\" with value: \"22b1c4b7-432d-4eb5-9341-cd8efacb8f46\""
        }
    ]
}
```

Caused by https://github.com/coder/coder/pull/18623
2025-06-27 15:07:54 -03:00
ケイラ d4208d23aa refactor: show icons for multi-select parameter options (#18594) 2025-06-27 10:54:47 -06:00
dependabot[bot] 5ae21517e0 chore: bump github.com/go-viper/mapstructure/v2 from 2.2.1 to 2.3.0 (#18647)
Bumps
[github.com/go-viper/mapstructure/v2](https://github.com/go-viper/mapstructure)
from 2.2.1 to 2.3.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/go-viper/mapstructure/releases">github.com/go-viper/mapstructure/v2's
releases</a>.</em></p>
<blockquote>
<h2>v2.3.0</h2>
<h2>What's Changed</h2>
<ul>
<li>build(deps): bump actions/checkout from 4.1.7 to 4.2.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/46">go-viper/mapstructure#46</a></li>
<li>build(deps): bump golangci/golangci-lint-action from 6.1.0 to 6.1.1
by <a href="https://github.com/dependabot"><code>@​dependabot</code></a>
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/47">go-viper/mapstructure#47</a></li>
<li>[enhancement] Add check for <code>reflect.Value</code> in
<code>ComposeDecodeHookFunc</code> by <a
href="https://github.com/mahadzaryab1"><code>@​mahadzaryab1</code></a>
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/52">go-viper/mapstructure#52</a></li>
<li>build(deps): bump actions/setup-go from 5.0.2 to 5.1.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/51">go-viper/mapstructure#51</a></li>
<li>build(deps): bump actions/checkout from 4.2.0 to 4.2.2 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/50">go-viper/mapstructure#50</a></li>
<li>build(deps): bump actions/setup-go from 5.1.0 to 5.2.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/55">go-viper/mapstructure#55</a></li>
<li>build(deps): bump actions/setup-go from 5.2.0 to 5.3.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/58">go-viper/mapstructure#58</a></li>
<li>ci: add Go 1.24 to the test matrix by <a
href="https://github.com/sagikazarmark"><code>@​sagikazarmark</code></a>
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/74">go-viper/mapstructure#74</a></li>
<li>build(deps): bump golangci/golangci-lint-action from 6.1.1 to 6.5.0
by <a href="https://github.com/dependabot"><code>@​dependabot</code></a>
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/72">go-viper/mapstructure#72</a></li>
<li>build(deps): bump golangci/golangci-lint-action from 6.5.0 to 6.5.1
by <a href="https://github.com/dependabot"><code>@​dependabot</code></a>
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/76">go-viper/mapstructure#76</a></li>
<li>build(deps): bump actions/setup-go from 5.3.0 to 5.4.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/78">go-viper/mapstructure#78</a></li>
<li>feat: add decode hook for netip.Prefix by <a
href="https://github.com/tklauser"><code>@​tklauser</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/85">go-viper/mapstructure#85</a></li>
<li>Updates by <a
href="https://github.com/sagikazarmark"><code>@​sagikazarmark</code></a>
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/86">go-viper/mapstructure#86</a></li>
<li>build(deps): bump github/codeql-action from 2.13.4 to 3.28.15 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/87">go-viper/mapstructure#87</a></li>
<li>build(deps): bump actions/setup-go from 5.4.0 to 5.5.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/93">go-viper/mapstructure#93</a></li>
<li>build(deps): bump github/codeql-action from 3.28.15 to 3.28.17 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/92">go-viper/mapstructure#92</a></li>
<li>build(deps): bump github/codeql-action from 3.28.17 to 3.28.19 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/97">go-viper/mapstructure#97</a></li>
<li>build(deps): bump ossf/scorecard-action from 2.4.1 to 2.4.2 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/96">go-viper/mapstructure#96</a></li>
<li>Update README.md by <a
href="https://github.com/peczenyj"><code>@​peczenyj</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/90">go-viper/mapstructure#90</a></li>
<li>Add omitzero tag. by <a
href="https://github.com/Crystalix007"><code>@​Crystalix007</code></a>
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/98">go-viper/mapstructure#98</a></li>
<li>Use error structs instead of duplicated strings by <a
href="https://github.com/m1k1o"><code>@​m1k1o</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/102">go-viper/mapstructure#102</a></li>
<li>build(deps): bump github/codeql-action from 3.28.19 to 3.29.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/101">go-viper/mapstructure#101</a></li>
<li>feat: add common error interface by <a
href="https://github.com/sagikazarmark"><code>@​sagikazarmark</code></a>
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/105">go-viper/mapstructure#105</a></li>
<li>update linter by <a
href="https://github.com/sagikazarmark"><code>@​sagikazarmark</code></a>
in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/106">go-viper/mapstructure#106</a></li>
<li>Feature allow unset pointer by <a
href="https://github.com/rostislaved"><code>@​rostislaved</code></a> in
<a
href="https://redirect.github.com/go-viper/mapstructure/pull/80">go-viper/mapstructure#80</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/tklauser"><code>@​tklauser</code></a>
made their first contribution in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/85">go-viper/mapstructure#85</a></li>
<li><a href="https://github.com/peczenyj"><code>@​peczenyj</code></a>
made their first contribution in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/90">go-viper/mapstructure#90</a></li>
<li><a
href="https://github.com/Crystalix007"><code>@​Crystalix007</code></a>
made their first contribution in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/98">go-viper/mapstructure#98</a></li>
<li><a
href="https://github.com/rostislaved"><code>@​rostislaved</code></a>
made their first contribution in <a
href="https://redirect.github.com/go-viper/mapstructure/pull/80">go-viper/mapstructure#80</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/go-viper/mapstructure/compare/v2.2.1...v2.3.0">https://github.com/go-viper/mapstructure/compare/v2.2.1...v2.3.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/go-viper/mapstructure/commit/8c61ec1924fcfa522f9fc6b4618c672db61d1a38"><code>8c61ec1</code></a>
Merge pull request <a
href="https://redirect.github.com/go-viper/mapstructure/issues/80">#80</a>
from rostislaved/feature-allow-unset-pointer</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/df765f469ad16a1996fd0f0ae6a32b20535b966a"><code>df765f4</code></a>
Merge pull request <a
href="https://redirect.github.com/go-viper/mapstructure/issues/106">#106</a>
from go-viper/update-linter</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/5f34b05aa12639380ef7c2af69eb6f8fd629dbd0"><code>5f34b05</code></a>
update linter</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/36de1e1d74f55681536097ff8467a8ce952ef183"><code>36de1e1</code></a>
Merge pull request <a
href="https://redirect.github.com/go-viper/mapstructure/issues/105">#105</a>
from go-viper/error-refactor</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/6a283a390ee7bc0f9331f58199db234902e0739f"><code>6a283a3</code></a>
chore: update error type doc</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/599cb73236404c044abcf278a45c3928d7480dd0"><code>599cb73</code></a>
Merge pull request <a
href="https://redirect.github.com/go-viper/mapstructure/issues/101">#101</a>
from go-viper/dependabot/github_actions/github/codeql...</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/ed3f92181528ff776a0324107b8b55026e93766a"><code>ed3f921</code></a>
feat: remove value from error messages</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/a3f8b227dcdae324c070d389152837f0aa635f4b"><code>a3f8b22</code></a>
revert: error message change</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/9661f6d07c319da00ae0508d99df5f3f0c3953bd"><code>9661f6d</code></a>
feat: add common error interface</li>
<li><a
href="https://github.com/go-viper/mapstructure/commit/f12f6c76fe743c8e4cc6465c6a9f16fcd8cede57"><code>f12f6c7</code></a>
Merge pull request <a
href="https://redirect.github.com/go-viper/mapstructure/issues/102">#102</a>
from m1k1o/prettify-errors2</li>
<li>Additional commits viewable in <a
href="https://github.com/go-viper/mapstructure/compare/v2.2.1...v2.3.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/go-viper/mapstructure/v2&package-manager=go_modules&previous-version=2.2.1&new-version=2.3.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts page](https://github.com/coder/coder/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-27 16:52:24 +00:00
blink-so[bot] ff3ff0170a chore: update logo description to specify maximum 3:1 aspect ratio (#18641)
Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
Co-authored-by: matifali <10648092+matifali@users.noreply.github.com>
2025-06-27 16:38:44 +00:00
Bruno Quaresma 8eebb4fa4c feat: make task panels resizable (#18590)
**Demo:**

https://github.com/user-attachments/assets/cc80b768-197e-42a0-9326-f30c9d9038e3
2025-06-27 13:34:04 -03:00
Mathias Fredriksson 0f3a1e9849 fix(agent/agentcontainers): split Init into Init and Start for early API responses (#18640)
Previously in #18635 we delayed the containers API `Init` to avoid producing
errors due to Docker and `@devcontainers/cli` not yet being installed by startup
scripts. This had an adverse effect on the UX via UI responsiveness as the
detection of devcontainers was greatly delayed.

This change splits `Init` into `Init` and `Start` so that we can immediately
after `Init` start serving known devcontainers (defined in Terraform), improving
the UX.

Related #18635
Related #18640
2025-06-27 19:01:50 +03:00
Mathias Fredriksson e46d892c29 fix(.devcontainer): remove double slash from zed path (#18639) 2025-06-27 18:34:08 +03:00
Mathias Fredriksson b4aa643dfa fix(agent/agentcontainers): ensure proper channel closure for updateTrigger (#18631) 2025-06-27 18:05:48 +03:00
Bruno Quaresma 6d305df67d fix: use default preset when creating a workspace for task (#18623) 2025-06-27 12:01:21 -03:00
Bruno Quaresma 29ef3a8ed6 feat: redirect to the task page after creation (#18626)
Close https://github.com/coder/coder/issues/18184
2025-06-27 14:45:42 +00:00
Bruno Quaresma 1c87796b33 refactor: show the apps as soon as possible (#18625)
Close https://github.com/coder/coder/issues/18617
2025-06-27 14:00:18 +00:00
Mathias Fredriksson 8ee2668b39 fix(agent): fix script filtering for devcontainers (#18635) 2025-06-27 16:59:31 +03:00
Bruno Quaresma 59a65415b4 refactor: move required external auth buttons to the submit side (#18586)
**Before:**
![Screenshot 2025-06-25 at 14 40
16](https://github.com/user-attachments/assets/cbc558f5-6eee-4133-afc9-2474f04a8a67)

**After:**
![Screenshot 2025-06-25 at 14 53
53](https://github.com/user-attachments/assets/3a638f60-d1e4-40a4-a066-8d69fe96c198)
2025-06-27 10:44:39 -03:00
Bruno Quaresma 2d44add81f feat: add task link in the workspace page when it is running a task (#18591)
![image](https://github.com/user-attachments/assets/4db64031-17a9-405c-a233-df2b758ddef5)
2025-06-27 10:32:57 -03:00
Spike Curtis f0251dfc91 chore: retry postgres connection on reset by peer in tests (#18632)
Fixes https://github.com/coder/internal/issues/695

Retries initial connection to postgres in testing up to 3 seconds if we
see "reset by peer", which probably means that some other test proc just
started the container.

---------

Co-authored-by: Hugo Dutka <hugo@coder.com>
2025-06-27 13:03:32 +00:00
Edward Angert d26d0fc269 docs: edit descriptions in ai-coder section (#18373)
Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
2025-06-27 12:09:02 +00:00
Spike Curtis a02d5a69e7 chore: update X11 forward session usage when there is a connection (#18567)
fixes #18263

Adds support to bump `usedAt` for X11 forwarding sessions whenever an application connects over the TCP socket. This should help avoid evicting sessions that are actually in use.
2025-06-27 15:41:45 +04:00
Spike Curtis 73c742a3ce chore: test eviction with used ports (#18566)
relates to #18263

Modifies the eviction unit test to include a port that is already claimed by an external process.
2025-06-27 15:27:38 +04:00
Spike Curtis 66f22d7588 chore: add unit test for X11 eviction (#18565)
relates to #18263


Adds a unit test for X11 listener eviction when all ports in the allowed range are in use.
2025-06-27 15:13:30 +04:00
Mathias Fredriksson 7e99fb7d7e fix(agent): delay containerAPI init to ensure startup scripts run before (#18630) 2025-06-27 14:10:35 +03:00
Susana Ferreira 3cb9b20b11 chore: improve rbac and add benchmark tooling (#18584)
## Description

This PR improves the RBAC package by refactoring the policy, enhancing
documentation, and adding utility scripts.

## Changes

* Refactored `policy.rego` for clarity and readability
* Updated README with OPA section
* Added `benchmark_authz.sh` script for authz performance testing and
comparison
* Added `gen_input.go` to generate input for `opa eval` testing
2025-06-27 12:05:34 +01:00
Spike Curtis a5bfb200fc chore: refactor TestServer_X11 to use inproc networking (#18564)
relates to #18263


Refactors the x11Forwarder to accept a networking `interface` that we can fake out for testing. This isolates the unit tests from other processes listening in the port range used by X11 forwarding. This will become extremely important in up-stack PRs where we listen on every port in the range and need to control which ports have conflicts.
2025-06-27 14:56:33 +04:00
Spike Curtis abcf3df71a chore: move InProcNet to testutil (#18563)
Moves `InProcNet` to `testutil` so that it can be reused by X11 forwarding tests (see up stack PRs).
2025-06-27 14:42:22 +04:00
Spike Curtis 6bebfd0ec6 fix: use memmap file system for TestServer_X11 (#18562)
Changes the TestServer_X11 test to use a memmapped file system, so we don't pollute the XAuthority file of the person running the test.
2025-06-27 14:24:07 +04:00
Spike Curtis 9e1cf1693b fix: cap max X11 forwarding ports and evict old (#18561)
partial for #18263

Caps the X11 forwarding sessions at a maximum port of 6200, and evicts the oldest session if we create new sessions while at the max.

Unit tests included higher in the stack.
2025-06-27 14:05:42 +04:00
Ethan 9ab9c52de8 chore(site): set server.allowedHosts in storybook config to .coder (#18598)
This lets you browse storybook using a Coder Desktop hostname (i.e. `workspace.coder:6006`). The default configuration (including `localhost`) will still work.
2025-06-27 12:59:58 +10:00
Asher 05f6d69455 chore: parse app status link (#18439)
No actual exploit here as far as I can tell, but doing a string check
without parsing was flagged by a scanner.
2025-06-26 13:04:11 -08:00
Mathias Fredriksson d5e34195b0 revert: fix(agent/agentcontainers): refresh containers before status change (#18624)
Reverts coder/coder#18620

This fix exacerbated the problem, reverting until a better fix can be made.
2025-06-26 20:51:06 +00:00
Mathias Fredriksson 7b0b6498fb fix(.devcontainer): start docker and install devcontainer CLI (#18621)
This change starts the Docker daemon in the devcontainer and install
`@devcontainers/cli`.
2025-06-26 20:17:59 +00:00
Mathias Fredriksson 73879056f9 fix(agent/agentcontainers): refresh containers before status change (#18620)
The previous method of refreshing after we change the devcontainer
status introduced an intermediary state where the devcontainer might not
yet have been assigned a container and will flicker as stopped before
going into running.
2025-06-26 20:12:50 +00:00
Jon Ayers 7a3a6d4d26 chore: update README logos (#18619) 2025-06-26 19:27:17 +00:00
Mathias Fredriksson 4f44dd08a9 fix(agent/agentcontainers): prevent reassigning proc.agent until successful (#18609) 2025-06-26 21:30:21 +03:00
ケイラ 09cc906981 chore: remove unnecessary redeclarations in for loops (part 2) (#18593) 2025-06-26 12:28:00 -06:00
Mathias Fredriksson e03d13211c test(agent): fix TestAgent_DevcontainerRecreate (#18618) 2025-06-26 17:50:53 +00:00
Thomas Kosiewski 1b1d09158d fix: pin Nix version to 2.28.4 to avoid JSON type error (#18612)
Pin Nix version to 2.28.4 in dogfood workflow

Pins the Nix version in the dogfood workflow to 2.28.4 to avoid a JSON type error that occurs with Nix 2.29 and above.

Change-Id: Ie024d5070dbe5901952fc52463c6602363ef8886
Signed-off-by: Thomas Kosiewski <tk@coder.com>
2025-06-26 18:33:44 +02:00
Danielle Maywood 98c77fece5 fix(agent/agentcontainers): stop logging empty lines (#18605)
This PR makes the devcontainer logs have fewer whitespace lines.
2025-06-26 15:58:10 +00:00
Danielle Maywood 5ae320e79e fix(agent/agentcontainers): chown coder binary (#18611)
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-06-26 16:42:43 +01:00
Mathias Fredriksson 87d052ea93 feat(.devcontainer): add cursor, filebrowser, windsurf and zed (#18608) 2025-06-26 14:09:31 +00:00
Sas Swart c6e0ba12d3 feat: graduate prebuilds to general availability (#18607)
This PR removes the prebuilds experiment and allows the use of prebuilds
without opting into an experiment.
2025-06-26 15:54:52 +02:00
Mathias Fredriksson 872aef3af9 feat(.devcontainer): install dotfiles if present (#18606) 2025-06-26 12:49:58 +00:00
Danielle Maywood f2d229eed3 fix!: use devcontainer ID when rebuilding a devcontainer (#18604)
This PR replaces the use of the **container** ID with the
**devcontainer** ID. This is a breaking change. This allows rebuilding a
devcontainer when there is no valid container ID.
2025-06-26 11:41:57 +01:00
Mathias Fredriksson eca6381314 feat(agent/agentcontainers): add more envs to readconfig for app URL building (#18603) 2025-06-26 09:33:58 +00:00
Sas Swart 634144f94a fix: hide the preset parameter visibility switch when it has no effect (#18574)
When no preset is selected:
<img width="1097" alt="Screenshot 2025-06-25 at 15 49 51"
src="https://github.com/user-attachments/assets/96f1244a-58f1-4e59-b6ac-9319339c764f"
/>

When a preset is selected:
<img width="1097" alt="Screenshot 2025-06-25 at 15 50 00"
src="https://github.com/user-attachments/assets/d0853169-ff93-4b1a-beaf-11012a9a02fb"
/>

Existing frontend stories provide enough validation to cover this
feature. No further testing is required.

---------

Co-authored-by: Susana Ferreira <susana@coder.com>
2025-06-26 11:23:10 +02:00
Atif Ali fb0e7a21a7 docs: add Coder Desktop to remote desktop docs (#18326)
Co-authored-by: Spike Curtis <spike@coder.com>
2025-06-26 11:16:41 +05:00
Bruno Quaresma fdf458eb19 refactor: remove beta label from 'select a preset' menu (#18538) 2025-06-25 17:09:49 -03:00
Mathias Fredriksson 09e1a8ad99 feat(.devcontainer): add code-server feature to devcontainer.json (#18589) 2025-06-25 21:35:43 +03:00
Asher 48bb534a51 chore: fix idle state icon when disabled (#18554)
When the workspace is off, we set a disabled text/stroke color, but for
the idle icon that also needs a fill, this only changed the outline
making it look weird. Instead, move the disabled logic into the
component so we can apply a matching fill.

I felt it looked too thick with both the outline and fill, so I also
removed the outline.

Really I think maybe the workspace status should be a separate column
rather than disabling these icons, but this maintains the status quo.


Before with mismatching stroke and fill color:


![screenshot](https://github.com/user-attachments/assets/961014b7-1e26-49f0-aa87-834f2f367618)


After with disabled fill and stroke removal:


![screenshot](https://github.com/user-attachments/assets/205e4515-dc01-4437-87ec-a0f8a546da3b)


Enabled fill and stroke removal:


![screenshot](https://github.com/user-attachments/assets/04f5914e-f96c-4c75-8873-e3fc9c854d95)
2025-06-25 10:06:57 -08:00
Danielle Maywood 6c713d5c20 fix(coderd/agentapi): make sub agent slugs more unique (#18581)
The incorrect assumption that slugs were unique per-agent was made when
the subagent API was implemented. Whilst this PR doesn't completely
enforce that, we instead compute a stable hash to prefix the slug that
should provide a reasonable level of probability that the slug will be
unique.
2025-06-25 17:36:23 +01:00
dependabot[bot] aef101ffd3 chore: bump google.golang.org/genai from 0.7.0 to 1.12.0 (#18496)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=google.golang.org/genai&package-manager=go_modules&previous-version=0.7.0&new-version=1.12.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-25 16:01:53 +00:00
dependabot[bot] 9d2f8dc274 chore: bump github.com/openai/openai-go from 0.1.0-beta.10 to 1.6.0 (#18493)
[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/openai/openai-go&package-manager=go_modules&previous-version=0.1.0-beta.10&new-version=1.6.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-25 16:01:29 +00:00
Danny Kopping 8e0b6f8157 chore: upgrade aisdk-go lib, remove vestigial code (#18577) 2025-06-25 17:47:42 +02:00
Steven Masley e396b06c25 feat: allow new immutable parameters for existing workspaces (#18579)
Closes https://github.com/coder/coder/issues/18578
2025-06-25 15:41:53 +00:00
Edward Angert 072c81cd73 docs: remove nested alerts (#18580)
hotfix

removes nested gfm alerts, which is a known ~issue~ feature
https://github.com/orgs/community/discussions/16925#discussioncomment-12043928

Co-authored-by: EdwardAngert <17991901+EdwardAngert@users.noreply.github.com>
2025-06-25 15:17:49 +00:00
Mathias Fredriksson 3c4d9206bc feat(agent/agentcontainers): add feature options as envs (#18576) 2025-06-25 14:41:36 +00:00
Danny Kopping 688d2ee3eb chore: remove chats experiment (#18535) 2025-06-25 13:03:32 +00:00
Mathias Fredriksson 9fde8353ad test(agent/agentcontainers): add is a test ignore label to integration tests (#18570) 2025-06-25 11:20:14 +00:00
Mathias Fredriksson 434b54657a fix(agent/agentcontainers): filter out "is test run" devcontainers (#18568) 2025-06-25 11:06:20 +00:00
Cian Johnston 42fd1c1291 ci: cache embedded postgres downloaded binaries (#18477)
Updates CI job definitions to cache downloaded binaries for embedded-postgres.
2025-06-25 12:00:20 +01:00
Danielle Maywood c4e4fe85f9 fix(agent): start devcontainers through agentcontainers package (#18471)
Fixes https://github.com/coder/internal/issues/706

Context for the implementation here
https://github.com/coder/internal/issues/706#issuecomment-2990490282

Synchronously starts dev containers defined in terraform with our
`DevcontainerCLI` abstraction, instead of piggybacking off of our
`agentscripts` package. This gives us more control over logs, instead of
being reliant on packages which may or may not exist in the
user-provided image.
2025-06-25 11:52:50 +01:00
Marcin Tojek f6d9765daf fix(site): storybook: move spyOn to beforeEach (#18559)
Fixes: https://github.com/coder/internal/issues/741
2025-06-25 08:45:55 +00:00
Atif Ali b5316d2b42 docs: fix a warning alert type on toolbox docs (#18560) 2025-06-25 08:21:12 +00:00
Emmanuel Ferdman 312d2a46b4 docs: update Claude's guide (#18523)
## PR Summary
Commit 5df70a613d added by mistake the the
following old line to `CLAUDE.md`:
```
For building Frontend refer to [this document](docs/contributing/frontend.md)
```
This PR removes it.

Signed-off-by: Emmanuel Ferdman <emmanuelferdman@gmail.com>
2025-06-25 05:39:26 +00:00
1646 changed files with 82123 additions and 32000 deletions
+218
View File
@@ -0,0 +1,218 @@
# Database Development Patterns
## Database Work Overview
### Database Generation Process
1. Modify SQL files in `coderd/database/queries/`
2. Run `make gen`
3. If errors about audit table, update `enterprise/audit/table.go`
4. Run `make gen` again
5. Run `make lint` to catch any remaining issues
## Migration Guidelines
### Creating Migration Files
**Location**: `coderd/database/migrations/`
**Format**: `{number}_{description}.{up|down}.sql`
- Number must be unique and sequential
- Always include both up and down migrations
### Helper Scripts
| Script | Purpose |
|---------------------------------------------------------------------|-----------------------------------------|
| `./coderd/database/migrations/create_migration.sh "migration name"` | Creates new migration files |
| `./coderd/database/migrations/fix_migration_numbers.sh` | Renumbers migrations to avoid conflicts |
| `./coderd/database/migrations/create_fixture.sh "fixture name"` | Creates test fixtures for migrations |
### Database Query Organization
- **MUST DO**: Any changes to database - adding queries, modifying queries should be done in the `coderd/database/queries/*.sql` files
- **MUST DO**: Queries are grouped in files relating to context - e.g. `prebuilds.sql`, `users.sql`, `oauth2.sql`
- After making changes to any `coderd/database/queries/*.sql` files you must run `make gen` to generate respective ORM changes
## Handling Nullable Fields
Use `sql.NullString`, `sql.NullBool`, etc. for optional database fields:
```go
CodeChallenge: sql.NullString{
String: params.codeChallenge,
Valid: params.codeChallenge != "",
}
```
Set `.Valid = true` when providing values.
## Audit Table Updates
If adding fields to auditable types:
1. Update `enterprise/audit/table.go`
2. Add each new field with appropriate action:
- `ActionTrack`: Field should be tracked in audit logs
- `ActionIgnore`: Field should be ignored in audit logs
- `ActionSecret`: Field contains sensitive data
3. Run `make gen` to verify no audit errors
## Database Architecture
### Core Components
- **PostgreSQL 13+** recommended for production
- **Migrations** managed with `migrate`
- **Database authorization** through `dbauthz` package
### Authorization Patterns
```go
// Public endpoints needing system access (OAuth2 registration)
app, err := api.Database.GetOAuth2ProviderAppByClientID(dbauthz.AsSystemRestricted(ctx), clientID)
// Authenticated endpoints with user context
app, err := api.Database.GetOAuth2ProviderAppByClientID(ctx, clientID)
// System operations in middleware
roles, err := db.GetAuthorizationUserRoles(dbauthz.AsSystemRestricted(ctx), userID)
```
## Common Database Issues
### Migration Issues
1. **Migration conflicts**: Use `fix_migration_numbers.sh` to renumber
2. **Missing down migration**: Always create both up and down files
3. **Schema inconsistencies**: Verify against existing schema
### Field Handling Issues
1. **Nullable field errors**: Use `sql.Null*` types consistently
2. **Missing audit entries**: Update `enterprise/audit/table.go`
### Query Issues
1. **Query organization**: Group related queries in appropriate files
2. **Generated code errors**: Run `make gen` after query changes
3. **Performance issues**: Add appropriate indexes in migrations
## Database Testing
### Test Database Setup
```go
func TestDatabaseFunction(t *testing.T) {
db := dbtestutil.NewDB(t)
// Test with real database
result, err := db.GetSomething(ctx, param)
require.NoError(t, err)
require.Equal(t, expected, result)
}
```
## Best Practices
### Schema Design
1. **Use appropriate data types**: VARCHAR for strings, TIMESTAMP for times
2. **Add constraints**: NOT NULL, UNIQUE, FOREIGN KEY as appropriate
3. **Create indexes**: For frequently queried columns
4. **Consider performance**: Normalize appropriately but avoid over-normalization
### Query Writing
1. **Use parameterized queries**: Prevent SQL injection
2. **Handle errors appropriately**: Check for specific error types
3. **Use transactions**: For related operations that must succeed together
4. **Optimize queries**: Use EXPLAIN to understand query performance
### Migration Writing
1. **Make migrations reversible**: Always include down migration
2. **Test migrations**: On copy of production data if possible
3. **Keep migrations small**: One logical change per migration
4. **Document complex changes**: Add comments explaining rationale
## Advanced Patterns
### Complex Queries
```sql
-- Example: Complex join with aggregation
SELECT
u.id,
u.username,
COUNT(w.id) as workspace_count
FROM users u
LEFT JOIN workspaces w ON u.id = w.owner_id
WHERE u.created_at > $1
GROUP BY u.id, u.username
ORDER BY workspace_count DESC;
```
### Conditional Queries
```sql
-- Example: Dynamic filtering
SELECT * FROM oauth2_provider_apps
WHERE
($1::text IS NULL OR name ILIKE '%' || $1 || '%')
AND ($2::uuid IS NULL OR organization_id = $2)
ORDER BY created_at DESC;
```
### Audit Patterns
```go
// Example: Auditable database operation
func (q *sqlQuerier) UpdateUser(ctx context.Context, arg UpdateUserParams) (User, error) {
// Implementation here
// Audit the change
if auditor := audit.FromContext(ctx); auditor != nil {
auditor.Record(audit.UserUpdate{
UserID: arg.ID,
Old: oldUser,
New: newUser,
})
}
return newUser, nil
}
```
## Debugging Database Issues
### Common Debug Commands
```bash
# Check database connection
make test-postgres
# Run specific database tests
go test ./coderd/database/... -run TestSpecificFunction
# Check query generation
make gen
# Verify audit table
make lint
```
### Debug Techniques
1. **Enable query logging**: Set appropriate log levels
2. **Use database tools**: pgAdmin, psql for direct inspection
3. **Check constraints**: UNIQUE, FOREIGN KEY violations
4. **Analyze performance**: Use EXPLAIN ANALYZE for slow queries
### Troubleshooting Checklist
- [ ] Migration files exist (both up and down)
- [ ] `make gen` run after query changes
- [ ] Audit table updated for new fields
- [ ] Nullable fields use `sql.Null*` types
- [ ] Authorization context appropriate for endpoint type
+157
View File
@@ -0,0 +1,157 @@
# OAuth2 Development Guide
## RFC Compliance Development
### Implementing Standard Protocols
When implementing standard protocols (OAuth2, OpenID Connect, etc.):
1. **Fetch and Analyze Official RFCs**:
- Always read the actual RFC specifications before implementation
- Use WebFetch tool to get current RFC content for compliance verification
- Document RFC requirements in code comments
2. **Default Values Matter**:
- Pay close attention to RFC-specified default values
- Example: RFC 7591 specifies `client_secret_basic` as default, not `client_secret_post`
- Ensure consistency between database migrations and application code
3. **Security Requirements**:
- Follow RFC security considerations precisely
- Example: RFC 7592 prohibits returning registration access tokens in GET responses
- Implement proper error responses per protocol specifications
4. **Validation Compliance**:
- Implement comprehensive validation per RFC requirements
- Support protocol-specific features (e.g., custom schemes for native OAuth2 apps)
- Test edge cases defined in specifications
## OAuth2 Provider Implementation
### OAuth2 Spec Compliance
1. **Follow RFC 6749 for token responses**
- Use `expires_in` (seconds) not `expiry` (timestamp) in token responses
- Return proper OAuth2 error format: `{"error": "code", "error_description": "details"}`
2. **Error Response Format**
- Create OAuth2-compliant error responses for token endpoint
- Use standard error codes: `invalid_client`, `invalid_grant`, `invalid_request`
- Avoid generic error responses for OAuth2 endpoints
### PKCE Implementation
- Support both with and without PKCE for backward compatibility
- Use S256 method for code challenge
- Properly validate code_verifier against stored code_challenge
### UI Authorization Flow
- Use POST requests for consent, not GET with links
- Avoid dependency on referer headers for security decisions
- Support proper state parameter validation
### RFC 8707 Resource Indicators
- Store resource parameters in database for server-side validation (opaque tokens)
- Validate resource consistency between authorization and token requests
- Support audience validation in refresh token flows
- Resource parameter is optional but must be consistent when provided
## OAuth2 Error Handling Pattern
```go
// Define specific OAuth2 errors
var (
errInvalidPKCE = xerrors.New("invalid code_verifier")
)
// Use OAuth2-compliant error responses
type OAuth2Error struct {
Error string `json:"error"`
ErrorDescription string `json:"error_description,omitempty"`
}
// Return proper OAuth2 errors
if errors.Is(err, errInvalidPKCE) {
writeOAuth2Error(ctx, rw, http.StatusBadRequest, "invalid_grant", "The PKCE code verifier is invalid")
return
}
```
## Testing OAuth2 Features
### Test Scripts
Located in `./scripts/oauth2/`:
- `test-mcp-oauth2.sh` - Full automated test suite
- `setup-test-app.sh` - Create test OAuth2 app
- `cleanup-test-app.sh` - Remove test app
- `generate-pkce.sh` - Generate PKCE parameters
- `test-manual-flow.sh` - Manual browser testing
Always run the full test suite after OAuth2 changes:
```bash
./scripts/oauth2/test-mcp-oauth2.sh
```
### RFC Protocol Testing
1. **Compliance Test Coverage**:
- Test all RFC-defined error codes and responses
- Validate proper HTTP status codes for different scenarios
- Test protocol-specific edge cases (URI formats, token formats, etc.)
2. **Security Boundary Testing**:
- Test client isolation and privilege separation
- Verify information disclosure protections
- Test token security and proper invalidation
## Common OAuth2 Issues
1. **OAuth2 endpoints returning wrong error format** - Ensure OAuth2 endpoints return RFC 6749 compliant errors
2. **Resource indicator validation failing** - Ensure database stores and retrieves resource parameters correctly
3. **PKCE tests failing** - Verify both authorization code storage and token exchange handle PKCE fields
4. **RFC compliance failures** - Verify against actual RFC specifications, not assumptions
5. **Authorization context errors in public endpoints** - Use `dbauthz.AsSystemRestricted(ctx)` pattern
6. **Default value mismatches** - Ensure database migrations match application code defaults
7. **Bearer token authentication issues** - Check token extraction precedence and format validation
8. **URI validation failures** - Support both standard schemes and custom schemes per protocol requirements
## Authorization Context Patterns
```go
// Public endpoints needing system access (OAuth2 registration)
app, err := api.Database.GetOAuth2ProviderAppByClientID(dbauthz.AsSystemRestricted(ctx), clientID)
// Authenticated endpoints with user context
app, err := api.Database.GetOAuth2ProviderAppByClientID(ctx, clientID)
// System operations in middleware
roles, err := db.GetAuthorizationUserRoles(dbauthz.AsSystemRestricted(ctx), userID)
```
## OAuth2/Authentication Work Patterns
- Types go in `codersdk/oauth2.go` or similar
- Handlers go in `coderd/oauth2.go` or `coderd/identityprovider/`
- Database fields need migration + audit table updates
- Always support backward compatibility
## Protocol Implementation Checklist
Before completing OAuth2 or authentication feature work:
- [ ] Verify RFC compliance by reading actual specifications
- [ ] Implement proper error response formats per protocol
- [ ] Add comprehensive validation for all protocol fields
- [ ] Test security boundaries and token handling
- [ ] Update RBAC permissions for new resources
- [ ] Add audit logging support if applicable
- [ ] Create database migrations with proper defaults
- [ ] Add comprehensive test coverage including edge cases
- [ ] Verify linting compliance
- [ ] Test both positive and negative scenarios
- [ ] Document protocol-specific patterns and requirements
+212
View File
@@ -0,0 +1,212 @@
# Testing Patterns and Best Practices
## Testing Best Practices
### Avoiding Race Conditions
1. **Unique Test Identifiers**:
- Never use hardcoded names in concurrent tests
- Use `time.Now().UnixNano()` or similar for unique identifiers
- Example: `fmt.Sprintf("test-client-%s-%d", t.Name(), time.Now().UnixNano())`
2. **Database Constraint Awareness**:
- Understand unique constraints that can cause test conflicts
- Generate unique values for all constrained fields
- Test name isolation prevents cross-test interference
### Testing Patterns
- Use table-driven tests for comprehensive coverage
- Mock external dependencies
- Test both positive and negative cases
- Use `testutil.WaitLong` for timeouts in tests
### Test Package Naming
- **Test packages**: Use `package_test` naming (e.g., `identityprovider_test`) for black-box testing
## RFC Protocol Testing
### Compliance Test Coverage
1. **Test all RFC-defined error codes and responses**
2. **Validate proper HTTP status codes for different scenarios**
3. **Test protocol-specific edge cases** (URI formats, token formats, etc.)
### Security Boundary Testing
1. **Test client isolation and privilege separation**
2. **Verify information disclosure protections**
3. **Test token security and proper invalidation**
## Test Organization
### Test File Structure
```
coderd/
├── oauth2.go # Implementation
├── oauth2_test.go # Main tests
├── oauth2_test_helpers.go # Test utilities
└── oauth2_validation.go # Validation logic
```
### Test Categories
1. **Unit Tests**: Test individual functions in isolation
2. **Integration Tests**: Test API endpoints with database
3. **End-to-End Tests**: Full workflow testing
4. **Race Tests**: Concurrent access testing
## Test Commands
### Running Tests
| Command | Purpose |
|---------|---------|
| `make test` | Run all Go tests |
| `make test RUN=TestFunctionName` | Run specific test |
| `go test -v ./path/to/package -run TestFunctionName` | Run test with verbose output |
| `make test-postgres` | Run tests with Postgres database |
| `make test-race` | Run tests with Go race detector |
| `make test-e2e` | Run end-to-end tests |
### Frontend Testing
| Command | Purpose |
|---------|---------|
| `pnpm test` | Run frontend tests |
| `pnpm check` | Run code checks |
## Common Testing Issues
### Database-Related
1. **SQL type errors** - Use `sql.Null*` types for nullable fields
2. **Race conditions in tests** - Use unique identifiers instead of hardcoded names
### OAuth2 Testing
1. **PKCE tests failing** - Verify both authorization code storage and token exchange handle PKCE fields
2. **Resource indicator validation failing** - Ensure database stores and retrieves resource parameters correctly
### General Issues
1. **Missing newlines** - Ensure files end with newline character
2. **Package naming errors** - Use `package_test` naming for test files
3. **Log message formatting errors** - Use lowercase, descriptive messages without special characters
## Systematic Testing Approach
### Multi-Issue Problem Solving
When facing multiple failing tests or complex integration issues:
1. **Identify Root Causes**:
- Run failing tests individually to isolate issues
- Use LSP tools to trace through call chains
- Check both compilation and runtime errors
2. **Fix in Logical Order**:
- Address compilation issues first (imports, syntax)
- Fix authorization and RBAC issues next
- Resolve business logic and validation issues
- Handle edge cases and race conditions last
3. **Verification Strategy**:
- Test each fix individually before moving to next issue
- Use `make lint` and `make gen` after database changes
- Verify RFC compliance with actual specifications
- Run comprehensive test suites before considering complete
## Test Data Management
### Unique Test Data
```go
// Good: Unique identifiers prevent conflicts
clientName := fmt.Sprintf("test-client-%s-%d", t.Name(), time.Now().UnixNano())
// Bad: Hardcoded names cause race conditions
clientName := "test-client"
```
### Test Cleanup
```go
func TestSomething(t *testing.T) {
// Setup
client := coderdtest.New(t, nil)
// Test code here
// Cleanup happens automatically via t.Cleanup() in coderdtest
}
```
## Test Utilities
### Common Test Patterns
```go
// Table-driven tests
tests := []struct {
name string
input InputType
expected OutputType
wantErr bool
}{
{
name: "valid input",
input: validInput,
expected: expectedOutput,
wantErr: false,
},
// ... more test cases
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
result, err := functionUnderTest(tt.input)
if tt.wantErr {
require.Error(t, err)
return
}
require.NoError(t, err)
require.Equal(t, tt.expected, result)
})
}
```
### Test Assertions
```go
// Use testify/require for assertions
require.NoError(t, err)
require.Equal(t, expected, actual)
require.NotNil(t, result)
require.True(t, condition)
```
## Performance Testing
### Load Testing
- Use `scaletest/` directory for load testing scenarios
- Run `./scaletest/scaletest.sh` for performance testing
### Benchmarking
```go
func BenchmarkFunction(b *testing.B) {
for i := 0; i < b.N; i++ {
// Function call to benchmark
_ = functionUnderTest(input)
}
}
```
Run benchmarks with:
```bash
go test -bench=. -benchmem ./package/path
```
+231
View File
@@ -0,0 +1,231 @@
# Troubleshooting Guide
## Common Issues
### Database Issues
1. **"Audit table entry missing action"**
- **Solution**: Update `enterprise/audit/table.go`
- Add each new field with appropriate action (ActionTrack, ActionIgnore, ActionSecret)
- Run `make gen` to verify no audit errors
2. **SQL type errors**
- **Solution**: Use `sql.Null*` types for nullable fields
- Set `.Valid = true` when providing values
- Example:
```go
CodeChallenge: sql.NullString{
String: params.codeChallenge,
Valid: params.codeChallenge != "",
}
```
### Testing Issues
3. **"package should be X_test"**
- **Solution**: Use `package_test` naming for test files
- Example: `identityprovider_test` for black-box testing
4. **Race conditions in tests**
- **Solution**: Use unique identifiers instead of hardcoded names
- Example: `fmt.Sprintf("test-client-%s-%d", t.Name(), time.Now().UnixNano())`
- Never use hardcoded names in concurrent tests
5. **Missing newlines**
- **Solution**: Ensure files end with newline character
- Most editors can be configured to add this automatically
### OAuth2 Issues
6. **OAuth2 endpoints returning wrong error format**
- **Solution**: Ensure OAuth2 endpoints return RFC 6749 compliant errors
- Use standard error codes: `invalid_client`, `invalid_grant`, `invalid_request`
- Format: `{"error": "code", "error_description": "details"}`
7. **Resource indicator validation failing**
- **Solution**: Ensure database stores and retrieves resource parameters correctly
- Check both authorization code storage and token exchange handling
8. **PKCE tests failing**
- **Solution**: Verify both authorization code storage and token exchange handle PKCE fields
- Check `CodeChallenge` and `CodeChallengeMethod` field handling
### RFC Compliance Issues
9. **RFC compliance failures**
- **Solution**: Verify against actual RFC specifications, not assumptions
- Use WebFetch tool to get current RFC content for compliance verification
- Read the actual RFC specifications before implementation
10. **Default value mismatches**
- **Solution**: Ensure database migrations match application code defaults
- Example: RFC 7591 specifies `client_secret_basic` as default, not `client_secret_post`
### Authorization Issues
11. **Authorization context errors in public endpoints**
- **Solution**: Use `dbauthz.AsSystemRestricted(ctx)` pattern
- Example:
```go
// Public endpoints needing system access
app, err := api.Database.GetOAuth2ProviderAppByClientID(dbauthz.AsSystemRestricted(ctx), clientID)
```
### Authentication Issues
12. **Bearer token authentication issues**
- **Solution**: Check token extraction precedence and format validation
- Ensure proper RFC 6750 Bearer Token Support implementation
13. **URI validation failures**
- **Solution**: Support both standard schemes and custom schemes per protocol requirements
- Native OAuth2 apps may use custom schemes
### General Development Issues
14. **Log message formatting errors**
- **Solution**: Use lowercase, descriptive messages without special characters
- Follow Go logging conventions
## Systematic Debugging Approach
### Multi-Issue Problem Solving
When facing multiple failing tests or complex integration issues:
1. **Identify Root Causes**:
- Run failing tests individually to isolate issues
- Use LSP tools to trace through call chains
- Check both compilation and runtime errors
2. **Fix in Logical Order**:
- Address compilation issues first (imports, syntax)
- Fix authorization and RBAC issues next
- Resolve business logic and validation issues
- Handle edge cases and race conditions last
3. **Verification Strategy**:
- Test each fix individually before moving to next issue
- Use `make lint` and `make gen` after database changes
- Verify RFC compliance with actual specifications
- Run comprehensive test suites before considering complete
## Debug Commands
### Useful Debug Commands
| Command | Purpose |
|----------------------------------------------|---------------------------------------|
| `make lint` | Run all linters |
| `make gen` | Generate mocks, database queries |
| `go test -v ./path/to/package -run TestName` | Run specific test with verbose output |
| `go test -race ./...` | Run tests with race detector |
### LSP Debugging
#### Go LSP (Backend)
| Command | Purpose |
|----------------------------------------------------|------------------------------|
| `mcp__go-language-server__definition symbolName` | Find function definition |
| `mcp__go-language-server__references symbolName` | Find all references |
| `mcp__go-language-server__diagnostics filePath` | Check for compilation errors |
| `mcp__go-language-server__hover filePath line col` | Get type information |
#### TypeScript LSP (Frontend)
| Command | Purpose |
|----------------------------------------------------------------------------|------------------------------------|
| `mcp__typescript-language-server__definition symbolName` | Find component/function definition |
| `mcp__typescript-language-server__references symbolName` | Find all component/type usages |
| `mcp__typescript-language-server__diagnostics filePath` | Check for TypeScript errors |
| `mcp__typescript-language-server__hover filePath line col` | Get type information |
| `mcp__typescript-language-server__rename_symbol filePath line col newName` | Rename across codebase |
## Common Error Messages
### Database Errors
**Error**: `pq: relation "oauth2_provider_app_codes" does not exist`
- **Cause**: Missing database migration
- **Solution**: Run database migrations, check migration files
**Error**: `audit table entry missing action for field X`
- **Cause**: New field added without audit table update
- **Solution**: Update `enterprise/audit/table.go`
### Go Compilation Errors
**Error**: `package should be identityprovider_test`
- **Cause**: Test package naming convention violation
- **Solution**: Use `package_test` naming for black-box tests
**Error**: `cannot use X (type Y) as type Z`
- **Cause**: Type mismatch, often with nullable fields
- **Solution**: Use appropriate `sql.Null*` types
### OAuth2 Errors
**Error**: `invalid_client` but client exists
- **Cause**: Authorization context issue
- **Solution**: Use `dbauthz.AsSystemRestricted(ctx)` for public endpoints
**Error**: PKCE validation failing
- **Cause**: Missing PKCE fields in database operations
- **Solution**: Ensure `CodeChallenge` and `CodeChallengeMethod` are handled
## Prevention Strategies
### Before Making Changes
1. **Read the relevant documentation**
2. **Check if similar patterns exist in codebase**
3. **Understand the authorization context requirements**
4. **Plan database changes carefully**
### During Development
1. **Run tests frequently**: `make test`
2. **Use LSP tools for navigation**: Avoid manual searching
3. **Follow RFC specifications precisely**
4. **Update audit tables when adding database fields**
### Before Committing
1. **Run full test suite**: `make test`
2. **Check linting**: `make lint`
3. **Test with race detector**: `make test-race`
## Getting Help
### Internal Resources
- Check existing similar implementations in codebase
- Use LSP tools to understand code relationships
- For Go code: Use `mcp__go-language-server__*` commands
- For TypeScript/React code: Use `mcp__typescript-language-server__*` commands
- Read related test files for expected behavior
### External Resources
- Official RFC specifications for protocol compliance
- Go documentation for language features
- PostgreSQL documentation for database issues
### Debug Information Collection
When reporting issues, include:
1. **Exact error message**
2. **Steps to reproduce**
3. **Relevant code snippets**
4. **Test output (if applicable)**
5. **Environment information** (OS, Go version, etc.)
+223
View File
@@ -0,0 +1,223 @@
# Development Workflows and Guidelines
## Quick Start Checklist for New Features
### Before Starting
- [ ] Run `git pull` to ensure you're on latest code
- [ ] Check if feature touches database - you'll need migrations
- [ ] Check if feature touches audit logs - update `enterprise/audit/table.go`
## Development Server
### Starting Development Mode
- **Use `./scripts/develop.sh` to start Coder in development mode**
- This automatically builds and runs with `--dev` flag and proper access URL
- **⚠️ Do NOT manually run `make build && ./coder server --dev` - use the script instead**
### Development Workflow
1. **Always start with the development script**: `./scripts/develop.sh`
2. **Make changes** to your code
3. **The script will automatically rebuild** and restart as needed
4. **Access the development server** at the URL provided by the script
## Code Style Guidelines
### Go Style
- Follow [Effective Go](https://go.dev/doc/effective_go) and [Go's Code Review Comments](https://github.com/golang/go/wiki/CodeReviewComments)
- Create packages when used during implementation
- Validate abstractions against implementations
- **Test packages**: Use `package_test` naming (e.g., `identityprovider_test`) for black-box testing
### Error Handling
- Use descriptive error messages
- Wrap errors with context
- Propagate errors appropriately
- Use proper error types
- Pattern: `xerrors.Errorf("failed to X: %w", err)`
### Naming Conventions
- Use clear, descriptive names
- Abbreviate only when obvious
- Follow Go and TypeScript naming conventions
### Comments
- Document exported functions, types, and non-obvious logic
- Follow JSDoc format for TypeScript
- Use godoc format for Go code
## Database Migration Workflows
### Migration Guidelines
1. **Create migration files**:
- Location: `coderd/database/migrations/`
- Format: `{number}_{description}.{up|down}.sql`
- Number must be unique and sequential
- Always include both up and down migrations
2. **Use helper scripts**:
- `./coderd/database/migrations/create_migration.sh "migration name"` - Creates new migration files
- `./coderd/database/migrations/fix_migration_numbers.sh` - Renumbers migrations to avoid conflicts
- `./coderd/database/migrations/create_fixture.sh "fixture name"` - Creates test fixtures for migrations
3. **Update database queries**:
- **MUST DO**: Any changes to database - adding queries, modifying queries should be done in the `coderd/database/queries/*.sql` files
- **MUST DO**: Queries are grouped in files relating to context - e.g. `prebuilds.sql`, `users.sql`, `oauth2.sql`
- After making changes to any `coderd/database/queries/*.sql` files you must run `make gen` to generate respective ORM changes
4. **Handle nullable fields**:
- Use `sql.NullString`, `sql.NullBool`, etc. for optional database fields
- Set `.Valid = true` when providing values
5. **Audit table updates**:
- If adding fields to auditable types, update `enterprise/audit/table.go`
- Add each new field with appropriate action (ActionTrack, ActionIgnore, ActionSecret)
- Run `make gen` to verify no audit errors
### Database Generation Process
1. Modify SQL files in `coderd/database/queries/`
2. Run `make gen`
3. If errors about audit table, update `enterprise/audit/table.go`
4. Run `make gen` again
5. Run `make lint` to catch any remaining issues
## API Development Workflow
### Adding New API Endpoints
1. **Define types** in `codersdk/` package
2. **Add handler** in appropriate `coderd/` file
3. **Register route** in `coderd/coderd.go`
4. **Add tests** in `coderd/*_test.go` files
5. **Update OpenAPI** by running `make gen`
## Testing Workflows
### Test Execution
- Run full test suite: `make test`
- Run specific test: `make test RUN=TestFunctionName`
- Run with Postgres: `make test-postgres`
- Run with race detector: `make test-race`
- Run end-to-end tests: `make test-e2e`
### Test Development
- Use table-driven tests for comprehensive coverage
- Mock external dependencies
- Test both positive and negative cases
- Use `testutil.WaitLong` for timeouts in tests
- Always use `t.Parallel()` in tests
## Commit Style
- Follow [Conventional Commits 1.0.0](https://www.conventionalcommits.org/en/v1.0.0/)
- Format: `type(scope): message`
- Types: `feat`, `fix`, `docs`, `style`, `refactor`, `test`, `chore`
- Keep message titles concise (~70 characters)
- Use imperative, present tense in commit titles
## Code Navigation and Investigation
### Using LSP Tools (STRONGLY RECOMMENDED)
**IMPORTANT**: Always use LSP tools for code navigation and understanding. These tools provide accurate, real-time analysis of the codebase and should be your first choice for code investigation.
#### Go LSP Tools (for backend code)
1. **Find function definitions** (USE THIS FREQUENTLY):
- `mcp__go-language-server__definition symbolName`
- Example: `mcp__go-language-server__definition getOAuth2ProviderAppAuthorize`
- Quickly jump to function implementations across packages
2. **Find symbol references** (ESSENTIAL FOR UNDERSTANDING IMPACT):
- `mcp__go-language-server__references symbolName`
- Locate all usages of functions, types, or variables
- Critical for refactoring and understanding data flow
3. **Get symbol information**:
- `mcp__go-language-server__hover filePath line column`
- Get type information and documentation at specific positions
#### TypeScript LSP Tools (for frontend code in site/)
1. **Find component/function definitions** (USE THIS FREQUENTLY):
- `mcp__typescript-language-server__definition symbolName`
- Example: `mcp__typescript-language-server__definition LoginPage`
- Quickly navigate to React components, hooks, and utility functions
2. **Find symbol references** (ESSENTIAL FOR UNDERSTANDING IMPACT):
- `mcp__typescript-language-server__references symbolName`
- Locate all usages of components, types, or functions
- Critical for refactoring React components and understanding prop usage
3. **Get type information**:
- `mcp__typescript-language-server__hover filePath line column`
- Get TypeScript type information and JSDoc documentation
4. **Rename symbols safely**:
- `mcp__typescript-language-server__rename_symbol filePath line column newName`
- Rename components, props, or functions across the entire codebase
5. **Check for TypeScript errors**:
- `mcp__typescript-language-server__diagnostics filePath`
- Get compilation errors and warnings for a specific file
### Investigation Strategy (LSP-First Approach)
#### Backend Investigation (Go)
1. **Start with route registration** in `coderd/coderd.go` to understand API endpoints
2. **Use Go LSP `definition` lookup** to trace from route handlers to actual implementations
3. **Use Go LSP `references`** to understand how functions are called throughout the codebase
4. **Follow the middleware chain** using LSP tools to understand request processing flow
5. **Check test files** for expected behavior and error patterns
#### Frontend Investigation (TypeScript/React)
1. **Start with route definitions** in `site/src/App.tsx` or router configuration
2. **Use TypeScript LSP `definition`** to navigate to React components and hooks
3. **Use TypeScript LSP `references`** to find all component usages and prop drilling
4. **Follow the component hierarchy** using LSP tools to understand data flow
5. **Check for TypeScript errors** with `diagnostics` before making changes
6. **Examine test files** (`.test.tsx`) for component behavior and expected props
## Troubleshooting Development Issues
### Common Issues
1. **Development server won't start** - Use `./scripts/develop.sh` instead of manual commands
2. **Database migration errors** - Check migration file format and use helper scripts
3. **Audit table errors** - Update `enterprise/audit/table.go` with new fields
4. **OAuth2 compliance issues** - Ensure RFC-compliant error responses
### Debug Commands
- Check linting: `make lint`
- Generate code: `make gen`
- Clean build: `make clean`
## Development Environment Setup
### Prerequisites
- Go (version specified in go.mod)
- Node.js and pnpm for frontend development
- PostgreSQL for database testing
- Docker for containerized testing
### First Time Setup
1. Clone the repository
2. Run `./scripts/develop.sh` to start development server
3. Access the development URL provided
4. Create admin user as prompted
5. Begin development
+133
View File
@@ -0,0 +1,133 @@
#!/bin/bash
# Claude Code hook script for file formatting
# This script integrates with the centralized Makefile formatting targets
# and supports the Claude Code hooks system for automatic file formatting.
set -euo pipefail
# A variable to memoize the command for canonicalizing paths.
_CANONICALIZE_CMD=""
# canonicalize_path resolves a path to its absolute, canonical form.
# It tries 'realpath' and 'readlink -f' in order.
# The chosen command is memoized to avoid repeated checks.
# If none of these are available, it returns an empty string.
canonicalize_path() {
local path_to_resolve="$1"
# If we haven't determined a command yet, find one.
if [[ -z "$_CANONICALIZE_CMD" ]]; then
if command -v realpath >/dev/null 2>&1; then
_CANONICALIZE_CMD="realpath"
elif command -v readlink >/dev/null 2>&1 && readlink -f . >/dev/null 2>&1; then
_CANONICALIZE_CMD="readlink"
else
# No command found, so we can't resolve.
# We set a "none" value to prevent re-checking.
_CANONICALIZE_CMD="none"
fi
fi
# Now, execute the command.
case "$_CANONICALIZE_CMD" in
realpath)
realpath "$path_to_resolve" 2>/dev/null
;;
readlink)
readlink -f "$path_to_resolve" 2>/dev/null
;;
*)
# This handles the "none" case or any unexpected error.
echo ""
;;
esac
}
# Read JSON input from stdin
input=$(cat)
# Extract the file path from the JSON input
# Expected format: {"tool_input": {"file_path": "/absolute/path/to/file"}} or {"tool_response": {"filePath": "/absolute/path/to/file"}}
file_path=$(echo "$input" | jq -r '.tool_input.file_path // .tool_response.filePath // empty')
# Secure path canonicalization to prevent path traversal attacks
# Resolve repo root to an absolute, canonical path.
repo_root_raw="$(cd "$(dirname "$0")/../.." && pwd)"
repo_root="$(canonicalize_path "$repo_root_raw")"
if [[ -z "$repo_root" ]]; then
# Fallback if canonicalization fails
repo_root="$repo_root_raw"
fi
# Resolve the input path to an absolute path
if [[ "$file_path" = /* ]]; then
# Already absolute
abs_file_path="$file_path"
else
# Make relative paths absolute from repo root
abs_file_path="$repo_root/$file_path"
fi
# Canonicalize the path (resolve symlinks and ".." segments)
canonical_file_path="$(canonicalize_path "$abs_file_path")"
# Check if canonicalization failed or if the resolved path is outside the repo
if [[ -z "$canonical_file_path" ]] || { [[ "$canonical_file_path" != "$repo_root" ]] && [[ "$canonical_file_path" != "$repo_root"/* ]]; }; then
echo "Error: File path is outside repository or invalid: $file_path" >&2
exit 1
fi
# Handle the case where the file path is the repository root itself.
if [[ "$canonical_file_path" == "$repo_root" ]]; then
echo "Warning: Formatting the repository root is not a supported operation. Skipping." >&2
exit 0
fi
# Convert back to relative path from repo root for consistency
file_path="${canonical_file_path#"$repo_root"/}"
if [[ -z "$file_path" ]]; then
echo "Error: No file path provided in input" >&2
exit 1
fi
# Check if file exists
if [[ ! -f "$file_path" ]]; then
echo "Error: File does not exist: $file_path" >&2
exit 1
fi
# Get the file extension to determine the appropriate formatter
file_ext="${file_path##*.}"
# Change to the project root directory (where the Makefile is located)
cd "$(dirname "$0")/../.."
# Call the appropriate Makefile target based on file extension
case "$file_ext" in
go)
make fmt/go FILE="$file_path"
echo "✓ Formatted Go file: $file_path"
;;
js | jsx | ts | tsx)
make fmt/ts FILE="$file_path"
echo "✓ Formatted TypeScript/JavaScript file: $file_path"
;;
tf | tfvars)
make fmt/terraform FILE="$file_path"
echo "✓ Formatted Terraform file: $file_path"
;;
sh)
make fmt/shfmt FILE="$file_path"
echo "✓ Formatted shell script: $file_path"
;;
md)
make fmt/markdown FILE="$file_path"
echo "✓ Formatted Markdown file: $file_path"
;;
*)
echo "No formatter available for file extension: $file_ext"
exit 0
;;
esac
+15
View File
@@ -0,0 +1,15 @@
{
"hooks": {
"PostToolUse": [
{
"matcher": "Edit|Write|MultiEdit",
"hooks": [
{
"type": "command",
"command": ".claude/scripts/format.sh"
}
]
}
]
}
}
+67 -3
View File
@@ -1,11 +1,16 @@
{
"name": "Development environments on your infrastructure",
"image": "codercom/oss-dogfood:latest",
"features": {
// See all possible options here https://github.com/devcontainers/features/tree/main/src/docker-in-docker
"ghcr.io/devcontainers/features/docker-in-docker:2": {
"moby": "false"
},
"ghcr.io/coder/devcontainer-features/code-server:1": {
"auth": "none",
"port": 13337
},
"./filebrowser": {
"folder": "${containerWorkspaceFolder}"
}
},
// SYS_PTRACE to enable go debugging
@@ -13,6 +18,65 @@
"customizations": {
"vscode": {
"extensions": ["biomejs.biome"]
},
"coder": {
"apps": [
{
"slug": "cursor",
"displayName": "Cursor Desktop",
"url": "cursor://coder.coder-remote/openDevContainer?owner=${localEnv:CODER_WORKSPACE_OWNER_NAME}&workspace=${localEnv:CODER_WORKSPACE_NAME}&agent=${localEnv:CODER_WORKSPACE_PARENT_AGENT_NAME}&url=${localEnv:CODER_URL}&token=$SESSION_TOKEN&devContainerName=${localEnv:CONTAINER_ID}&devContainerFolder=${containerWorkspaceFolder}&localWorkspaceFolder=${localWorkspaceFolder}",
"external": true,
"icon": "/icon/cursor.svg",
"order": 1
},
{
"slug": "windsurf",
"displayName": "Windsurf Editor",
"url": "windsurf://coder.coder-remote/openDevContainer?owner=${localEnv:CODER_WORKSPACE_OWNER_NAME}&workspace=${localEnv:CODER_WORKSPACE_NAME}&agent=${localEnv:CODER_WORKSPACE_PARENT_AGENT_NAME}&url=${localEnv:CODER_URL}&token=$SESSION_TOKEN&devContainerName=${localEnv:CONTAINER_ID}&devContainerFolder=${containerWorkspaceFolder}&localWorkspaceFolder=${localWorkspaceFolder}",
"external": true,
"icon": "/icon/windsurf.svg",
"order": 4
},
{
"slug": "zed",
"displayName": "Zed Editor",
"url": "zed://ssh/${localEnv:CODER_WORKSPACE_AGENT_NAME}.${localEnv:CODER_WORKSPACE_NAME}.${localEnv:CODER_WORKSPACE_OWNER_NAME}.coder${containerWorkspaceFolder}",
"external": true,
"icon": "/icon/zed.svg",
"order": 5
},
// Reproduce `code-server` app here from the code-server
// feature so that we can set the correct folder and order.
// Currently, the order cannot be specified via option because
// we parse it as a number whereas variable interpolation
// results in a string. Additionally we set health check which
// is not yet set in the feature.
{
"slug": "code-server",
"displayName": "code-server",
"url": "http://${localEnv:FEATURE_CODE_SERVER_OPTION_HOST:127.0.0.1}:${localEnv:FEATURE_CODE_SERVER_OPTION_PORT:8080}/?folder=${containerWorkspaceFolder}",
"openIn": "${localEnv:FEATURE_CODE_SERVER_OPTION_APPOPENIN:slim-window}",
"share": "${localEnv:FEATURE_CODE_SERVER_OPTION_APPSHARE:owner}",
"icon": "/icon/code.svg",
"group": "${localEnv:FEATURE_CODE_SERVER_OPTION_APPGROUP:Web Editors}",
"order": 3,
"healthCheck": {
"url": "http://${localEnv:FEATURE_CODE_SERVER_OPTION_HOST:127.0.0.1}:${localEnv:FEATURE_CODE_SERVER_OPTION_PORT:8080}/healthz",
"interval": 5,
"threshold": 2
}
}
]
}
}
},
"mounts": [
// Add a volume for the Coder home directory to persist shell history,
// and speed up dotfiles init and/or personalization.
"source=coder-coder-devcontainer-home,target=/home/coder,type=volume",
// Mount the entire home because conditional mounts are not supported.
// See: https://github.com/devcontainers/spec/issues/132
"source=${localEnv:HOME},target=/mnt/home/coder,type=bind,readonly"
],
"postCreateCommand": ["./.devcontainer/scripts/post_create.sh"],
"postStartCommand": ["./.devcontainer/scripts/post_start.sh"]
}
@@ -0,0 +1,46 @@
{
"id": "filebrowser",
"version": "0.0.1",
"name": "File Browser",
"description": "A web-based file browser for your development container",
"options": {
"port": {
"type": "string",
"default": "13339",
"description": "The port to run filebrowser on"
},
"folder": {
"type": "string",
"default": "",
"description": "The root directory for filebrowser to serve"
},
"baseUrl": {
"type": "string",
"default": "",
"description": "The base URL for filebrowser (e.g., /filebrowser)"
}
},
"entrypoint": "/usr/local/bin/filebrowser-entrypoint",
"dependsOn": {
"ghcr.io/devcontainers/features/common-utils:2": {}
},
"customizations": {
"coder": {
"apps": [
{
"slug": "filebrowser",
"displayName": "File Browser",
"url": "http://localhost:${localEnv:FEATURE_FILEBROWSER_OPTION_PORT:13339}",
"icon": "/icon/filebrowser.svg",
"order": 3,
"subdomain": true,
"healthcheck": {
"url": "http://localhost:${localEnv:FEATURE_FILEBROWSER_OPTION_PORT:13339}/health",
"interval": 5,
"threshold": 2
}
}
]
}
}
}
+54
View File
@@ -0,0 +1,54 @@
#!/usr/bin/env bash
set -euo pipefail
BOLD='\033[0;1m'
printf "%sInstalling filebrowser\n\n" "${BOLD}"
# Check if filebrowser is installed.
if ! command -v filebrowser &>/dev/null; then
VERSION="v2.42.1"
EXPECTED_HASH="7d83c0f077df10a8ec9bfd9bf6e745da5d172c3c768a322b0e50583a6bc1d3cc"
curl -fsSL "https://github.com/filebrowser/filebrowser/releases/download/${VERSION}/linux-amd64-filebrowser.tar.gz" -o /tmp/filebrowser.tar.gz
echo "${EXPECTED_HASH} /tmp/filebrowser.tar.gz" | sha256sum -c
tar -xzf /tmp/filebrowser.tar.gz -C /tmp
sudo mv /tmp/filebrowser /usr/local/bin/
sudo chmod +x /usr/local/bin/filebrowser
rm /tmp/filebrowser.tar.gz
fi
# Create entrypoint.
cat >/usr/local/bin/filebrowser-entrypoint <<EOF
#!/usr/bin/env bash
PORT="${PORT}"
FOLDER="${FOLDER:-}"
FOLDER="\${FOLDER:-\$(pwd)}"
BASEURL="${BASEURL:-}"
LOG_PATH=/tmp/filebrowser.log
export FB_DATABASE="\${HOME}/.filebrowser.db"
printf "🛠️ Configuring filebrowser\n\n"
# Check if filebrowser db exists.
if [[ ! -f "\${FB_DATABASE}" ]]; then
filebrowser config init >>\${LOG_PATH} 2>&1
filebrowser users add admin "" --perm.admin=true --viewMode=mosaic >>\${LOG_PATH} 2>&1
fi
filebrowser config set --baseurl=\${BASEURL} --port=\${PORT} --auth.method=noauth --root=\${FOLDER} >>\${LOG_PATH} 2>&1
printf "👷 Starting filebrowser...\n\n"
printf "📂 Serving \${FOLDER} at http://localhost:\${PORT}\n\n"
filebrowser >>\${LOG_PATH} 2>&1 &
printf "📝 Logs at \${LOG_PATH}\n\n"
EOF
chmod +x /usr/local/bin/filebrowser-entrypoint
printf "🥳 Installation complete!\n\n"
+59
View File
@@ -0,0 +1,59 @@
#!/bin/sh
install_devcontainer_cli() {
npm install -g @devcontainers/cli@0.80.0 --integrity=sha512-w2EaxgjyeVGyzfA/KUEZBhyXqu/5PyWNXcnrXsZOBrt3aN2zyGiHrXoG54TF6K0b5DSCF01Rt5fnIyrCeFzFKw==
}
install_ssh_config() {
echo "🔑 Installing SSH configuration..."
rsync -a /mnt/home/coder/.ssh/ ~/.ssh/
chmod 0700 ~/.ssh
}
install_git_config() {
echo "📂 Installing Git configuration..."
if [ -f /mnt/home/coder/git/config ]; then
rsync -a /mnt/home/coder/git/ ~/.config/git/
elif [ -d /mnt/home/coder/.gitconfig ]; then
rsync -a /mnt/home/coder/.gitconfig ~/.gitconfig
else
echo "⚠️ Git configuration directory not found."
fi
}
install_dotfiles() {
if [ ! -d /mnt/home/coder/.config/coderv2/dotfiles ]; then
echo "⚠️ Dotfiles directory not found."
return
fi
cd /mnt/home/coder/.config/coderv2/dotfiles || return
for script in install.sh install bootstrap.sh bootstrap script/bootstrap setup.sh setup script/setup; do
if [ -x $script ]; then
echo "📦 Installing dotfiles..."
./$script || {
echo "❌ Error running $script. Please check the script for issues."
return
}
echo "✅ Dotfiles installed successfully."
return
fi
done
echo "⚠️ No install script found in dotfiles directory."
}
personalize() {
# Allow script to continue as Coder dogfood utilizes a hack to
# synchronize startup script execution.
touch /tmp/.coder-startup-script.done
if [ -x /mnt/home/coder/personalize ]; then
echo "🎨 Personalizing environment..."
/mnt/home/coder/personalize
fi
}
install_devcontainer_cli
install_ssh_config
install_dotfiles
personalize
+4
View File
@@ -0,0 +1,4 @@
#!/bin/sh
# Start Docker service if not already running.
sudo service docker start
+9 -1
View File
@@ -7,7 +7,7 @@ trim_trailing_whitespace = true
insert_final_newline = true
indent_style = tab
[*.{yaml,yml,tf,tfvars,nix}]
[*.{yaml,yml,tf,tftpl,tfvars,nix}]
indent_style = space
indent_size = 2
@@ -18,3 +18,11 @@ indent_size = 2
[coderd/database/dump.sql]
indent_style = space
indent_size = 4
[coderd/database/queries/*.sql]
indent_style = tab
indent_size = 4
[coderd/database/migrations/*.sql]
indent_style = tab
indent_size = 4
+3 -1
View File
@@ -15,6 +15,8 @@ provisionersdk/proto/*.go linguist-generated=true
*.tfstate.json linguist-generated=true
*.tfstate.dot linguist-generated=true
*.tfplan.dot linguist-generated=true
site/e2e/google/protobuf/timestampGenerated.ts
site/e2e/provisionerGenerated.ts linguist-generated=true
site/src/api/countriesGenerated.tsx linguist-generated=true
site/src/api/rbacresourcesGenerated.tsx linguist-generated=true
site/src/api/typesGenerated.ts linguist-generated=true
site/src/pages/SetupPage/countries.tsx linguist-generated=true
+1
View File
@@ -25,5 +25,6 @@ ignorePatterns:
- pattern: "docs.github.com"
- pattern: "claude.ai"
- pattern: "splunk.com"
- pattern: "stackoverflow.com/questions"
aliveStatusCodes:
- 200
@@ -0,0 +1,49 @@
name: "Download Embedded Postgres Cache"
description: |
Downloads the embedded postgres cache and outputs today's cache key.
A PR job can use a cache if it was created by its base branch, its current
branch, or the default branch.
https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/caching-dependencies-to-speed-up-workflows#restrictions-for-accessing-a-cache
outputs:
cache-key:
description: "Today's cache key"
value: ${{ steps.vars.outputs.cache-key }}
inputs:
key-prefix:
description: "Prefix for the cache key"
required: true
cache-path:
description: "Path to the cache directory"
required: true
runs:
using: "composite"
steps:
- name: Get date values and cache key
id: vars
shell: bash
run: |
export YEAR_MONTH=$(date +'%Y-%m')
export PREV_YEAR_MONTH=$(date -d 'last month' +'%Y-%m')
export DAY=$(date +'%d')
echo "year-month=$YEAR_MONTH" >> "$GITHUB_OUTPUT"
echo "prev-year-month=$PREV_YEAR_MONTH" >> "$GITHUB_OUTPUT"
echo "cache-key=${INPUTS_KEY_PREFIX}-${YEAR_MONTH}-${DAY}" >> "$GITHUB_OUTPUT"
env:
INPUTS_KEY_PREFIX: ${{ inputs.key-prefix }}
# By default, depot keeps caches for 14 days. This is plenty for embedded
# postgres, which changes infrequently.
# https://depot.dev/docs/github-actions/overview#cache-retention-policy
- name: Download embedded Postgres cache
uses: actions/cache/restore@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
with:
path: ${{ inputs.cache-path }}
key: ${{ steps.vars.outputs.cache-key }}
# > If there are multiple partial matches for a restore key, the action returns the most recently created cache.
# https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/caching-dependencies-to-speed-up-workflows#matching-a-cache-key
# The second restore key allows non-main branches to use the cache from the previous month.
# This prevents PRs from rebuilding the cache on the first day of the month.
# It also makes sure that once a month, the cache is fully reset.
restore-keys: |
${{ inputs.key-prefix }}-${{ steps.vars.outputs.year-month }}-
${{ github.ref != 'refs/heads/main' && format('{0}-{1}-', inputs.key-prefix, steps.vars.outputs.prev-year-month) || '' }}
@@ -0,0 +1,18 @@
name: "Upload Embedded Postgres Cache"
description: Uploads the embedded Postgres cache. This only runs on the main branch.
inputs:
cache-key:
description: "Cache key"
required: true
cache-path:
description: "Path to the cache directory"
required: true
runs:
using: "composite"
steps:
- name: Upload Embedded Postgres cache
if: ${{ github.ref == 'refs/heads/main' }}
uses: actions/cache/save@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
with:
path: ${{ inputs.cache-path }}
key: ${{ inputs.cache-key }}
@@ -0,0 +1,33 @@
name: "Setup Embedded Postgres Cache Paths"
description: Sets up a path for cached embedded postgres binaries.
outputs:
embedded-pg-cache:
description: "Value of EMBEDDED_PG_CACHE_DIR"
value: ${{ steps.paths.outputs.embedded-pg-cache }}
cached-dirs:
description: "directories that should be cached between CI runs"
value: ${{ steps.paths.outputs.cached-dirs }}
runs:
using: "composite"
steps:
- name: Override Go paths
id: paths
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7
with:
script: |
const path = require('path');
// RUNNER_TEMP should be backed by a RAM disk on Windows if
// coder/setup-ramdisk-action was used
const runnerTemp = process.env.RUNNER_TEMP;
const embeddedPgCacheDir = path.join(runnerTemp, 'embedded-pg-cache');
core.exportVariable('EMBEDDED_PG_CACHE_DIR', embeddedPgCacheDir);
core.setOutput('embedded-pg-cache', embeddedPgCacheDir);
const cachedDirs = `${embeddedPgCacheDir}`;
core.setOutput('cached-dirs', cachedDirs);
- name: Create directories
shell: bash
run: |
set -e
mkdir -p "$EMBEDDED_PG_CACHE_DIR"
+1 -1
View File
@@ -4,7 +4,7 @@ description: |
inputs:
version:
description: "The Go version to use."
default: "1.24.4"
default: "1.24.10"
use-preinstalled-go:
description: "Whether to use preinstalled Go."
default: "false"
+1 -1
View File
@@ -16,7 +16,7 @@ runs:
- name: Setup Node
uses: actions/setup-node@0a44ba7841725637a19e28fa30b79a866c81b0a6 # v4.0.4
with:
node-version: 20.16.0
node-version: 20.19.4
# See https://github.com/actions/setup-node#caching-global-packages-data
cache: "pnpm"
cache-dependency-path: ${{ inputs.directory }}/pnpm-lock.yaml
+1 -1
View File
@@ -7,5 +7,5 @@ runs:
- name: Install Terraform
uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd # v3.1.2
with:
terraform_version: 1.12.2
terraform_version: 1.13.0
terraform_wrapper: false
@@ -27,9 +27,11 @@ runs:
export YEAR_MONTH=$(date +'%Y-%m')
export PREV_YEAR_MONTH=$(date -d 'last month' +'%Y-%m')
export DAY=$(date +'%d')
echo "year-month=$YEAR_MONTH" >> $GITHUB_OUTPUT
echo "prev-year-month=$PREV_YEAR_MONTH" >> $GITHUB_OUTPUT
echo "cache-key=${{ inputs.key-prefix }}-${YEAR_MONTH}-${DAY}" >> $GITHUB_OUTPUT
echo "year-month=$YEAR_MONTH" >> "$GITHUB_OUTPUT"
echo "prev-year-month=$PREV_YEAR_MONTH" >> "$GITHUB_OUTPUT"
echo "cache-key=${INPUTS_KEY_PREFIX}-${YEAR_MONTH}-${DAY}" >> "$GITHUB_OUTPUT"
env:
INPUTS_KEY_PREFIX: ${{ inputs.key-prefix }}
# TODO: As a cost optimization, we could remove caches that are older than
# a day or two. By default, depot keeps caches for 14 days, which isn't
+14 -14
View File
@@ -12,13 +12,12 @@ runs:
run: |
set -e
owner=${{ github.repository_owner }}
echo "owner: $owner"
if [[ $owner != "coder" ]]; then
echo "owner: $REPO_OWNER"
if [[ "$REPO_OWNER" != "coder" ]]; then
echo "Not a pull request from the main repo, skipping..."
exit 0
fi
if [[ -z "${{ inputs.api-key }}" ]]; then
if [[ -z "${DATADOG_API_KEY}" ]]; then
# This can happen for dependabot.
echo "No API key provided, skipping..."
exit 0
@@ -31,37 +30,38 @@ runs:
TMP_DIR=$(mktemp -d)
if [[ "${{ runner.os }}" == "Windows" ]]; then
if [[ "${RUNNER_OS}" == "Windows" ]]; then
BINARY_PATH="${TMP_DIR}/datadog-ci.exe"
BINARY_URL="https://github.com/DataDog/datadog-ci/releases/download/${BINARY_VERSION}/datadog-ci_win-x64"
elif [[ "${{ runner.os }}" == "macOS" ]]; then
elif [[ "${RUNNER_OS}" == "macOS" ]]; then
BINARY_PATH="${TMP_DIR}/datadog-ci"
BINARY_URL="https://github.com/DataDog/datadog-ci/releases/download/${BINARY_VERSION}/datadog-ci_darwin-arm64"
elif [[ "${{ runner.os }}" == "Linux" ]]; then
elif [[ "${RUNNER_OS}" == "Linux" ]]; then
BINARY_PATH="${TMP_DIR}/datadog-ci"
BINARY_URL="https://github.com/DataDog/datadog-ci/releases/download/${BINARY_VERSION}/datadog-ci_linux-x64"
else
echo "Unsupported OS: ${{ runner.os }}"
echo "Unsupported OS: $RUNNER_OS"
exit 1
fi
echo "Downloading DataDog CI binary version ${BINARY_VERSION} for ${{ runner.os }}..."
echo "Downloading DataDog CI binary version ${BINARY_VERSION} for $RUNNER_OS..."
curl -sSL "$BINARY_URL" -o "$BINARY_PATH"
if [[ "${{ runner.os }}" == "Windows" ]]; then
if [[ "${RUNNER_OS}" == "Windows" ]]; then
echo "$BINARY_HASH_WINDOWS $BINARY_PATH" | sha256sum --check
elif [[ "${{ runner.os }}" == "macOS" ]]; then
elif [[ "${RUNNER_OS}" == "macOS" ]]; then
echo "$BINARY_HASH_MACOS $BINARY_PATH" | shasum -a 256 --check
elif [[ "${{ runner.os }}" == "Linux" ]]; then
elif [[ "${RUNNER_OS}" == "Linux" ]]; then
echo "$BINARY_HASH_LINUX $BINARY_PATH" | sha256sum --check
fi
# Make binary executable (not needed for Windows)
if [[ "${{ runner.os }}" != "Windows" ]]; then
if [[ "${RUNNER_OS}" != "Windows" ]]; then
chmod +x "$BINARY_PATH"
fi
"$BINARY_PATH" junit upload --service coder ./gotests.xml \
--tags os:${{runner.os}} --tags runner_name:${{runner.name}}
--tags "os:${RUNNER_OS}" --tags "runner_name:${RUNNER_NAME}"
env:
REPO_OWNER: ${{ github.repository_owner }}
DATADOG_API_KEY: ${{ inputs.api-key }}
+1
View File
@@ -33,6 +33,7 @@ updates:
- dependency-name: "*"
update-types:
- version-update:semver-patch
- dependency-name: "github.com/mark3labs/mcp-go"
# Update our Dockerfile.
- package-ecosystem: "docker"
+1
View File
@@ -0,0 +1 @@
If you have used AI to produce some or all of this PR, please ensure you have read our [AI Contribution guidelines](https://coder.com/docs/about/contributing/AI_CONTRIBUTING) before submitting.
+242 -254
View File
File diff suppressed because it is too large Load Diff
+1
View File
@@ -3,6 +3,7 @@ name: contrib
on:
issue_comment:
types: [created, edited]
# zizmor: ignore[dangerous-triggers] We explicitly want to run on pull_request_target.
pull_request_target:
types:
- opened
+10 -9
View File
@@ -15,7 +15,7 @@ jobs:
github.event_name == 'pull_request' &&
github.event.action == 'opened' &&
github.event.pull_request.user.login == 'dependabot[bot]' &&
github.actor_id == 49699333 &&
github.event.pull_request.user.id == 49699333 &&
github.repository == 'coder/coder'
permissions:
pull-requests: write
@@ -44,10 +44,6 @@ jobs:
GH_TOKEN: ${{secrets.GITHUB_TOKEN}}
- name: Send Slack notification
env:
PR_URL: ${{github.event.pull_request.html_url}}
PR_TITLE: ${{github.event.pull_request.title}}
PR_NUMBER: ${{github.event.pull_request.number}}
run: |
curl -X POST -H 'Content-type: application/json' \
--data '{
@@ -58,7 +54,7 @@ jobs:
"type": "header",
"text": {
"type": "plain_text",
"text": ":pr-merged: Auto merge enabled for Dependabot PR #${{ env.PR_NUMBER }}",
"text": ":pr-merged: Auto merge enabled for Dependabot PR #'"${PR_NUMBER}"'",
"emoji": true
}
},
@@ -67,7 +63,7 @@ jobs:
"fields": [
{
"type": "mrkdwn",
"text": "${{ env.PR_TITLE }}"
"text": "'"${PR_TITLE}"'"
}
]
},
@@ -80,9 +76,14 @@ jobs:
"type": "plain_text",
"text": "View PR"
},
"url": "${{ env.PR_URL }}"
"url": "'"${PR_URL}"'"
}
]
}
]
}' ${{ secrets.DEPENDABOT_PRS_SLACK_WEBHOOK }}
}' "${{ secrets.DEPENDABOT_PRS_SLACK_WEBHOOK }}"
env:
SLACK_WEBHOOK: ${{ secrets.DEPENDABOT_PRS_SLACK_WEBHOOK }}
PR_NUMBER: ${{ github.event.pull_request.number }}
PR_TITLE: ${{ github.event.pull_request.title }}
PR_URL: ${{ github.event.pull_request.html_url }}
+5 -3
View File
@@ -38,15 +38,17 @@ jobs:
if: github.repository_owner == 'coder'
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
persist-credentials: false
- name: Docker login
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0
uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0
with:
registry: ghcr.io
username: ${{ github.actor }}
+12 -4
View File
@@ -23,12 +23,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
persist-credentials: false
- name: Setup Node
uses: ./.github/actions/setup-node
- uses: tj-actions/changed-files@666c9d29007687c52e3c7aa2aac6c0ffcadeadc3 # v45.0.7
- uses: tj-actions/changed-files@f963b3f3562b00b6d2dd25efc390eb04e51ef6c6 # v45.0.7
id: changed-files
with:
files: |
@@ -39,10 +41,16 @@ jobs:
- name: lint
if: steps.changed-files.outputs.any_changed == 'true'
run: |
pnpm exec markdownlint-cli2 ${{ steps.changed-files.outputs.all_changed_files }}
# shellcheck disable=SC2086
pnpm exec markdownlint-cli2 $ALL_CHANGED_FILES
env:
ALL_CHANGED_FILES: ${{ steps.changed-files.outputs.all_changed_files }}
- name: fmt
if: steps.changed-files.outputs.any_changed == 'true'
run: |
# markdown-table-formatter requires a space separated list of files
echo ${{ steps.changed-files.outputs.all_changed_files }} | tr ',' '\n' | pnpm exec markdown-table-formatter --check
# shellcheck disable=SC2086
echo $ALL_CHANGED_FILES | tr ',' '\n' | pnpm exec markdown-table-formatter --check
env:
ALL_CHANGED_FILES: ${{ steps.changed-files.outputs.all_changed_files }}
+35 -21
View File
@@ -18,8 +18,7 @@ on:
workflow_dispatch:
permissions:
# Necessary for GCP authentication (https://github.com/google-github-actions/setup-gcloud#usage)
id-token: write
contents: read
jobs:
build_image:
@@ -27,15 +26,21 @@ jobs:
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-4' || 'ubuntu-latest' }}
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
persist-credentials: false
- name: Setup Nix
uses: nixbuild/nix-quick-install-action@889f3180bb5f064ee9e3201428d04ae9e41d54ad # v31
uses: nixbuild/nix-quick-install-action@63ca48f939ee3b8d835f4126562537df0fee5b91 # v32
with:
# Pinning to 2.28 here, as Nix gets a "error: [json.exception.type_error.302] type must be array, but is string"
# on version 2.29 and above.
nix_version: "2.28.4"
- uses: nix-community/cache-nix-action@135667ec418502fa5a3598af6fb9eb733888ce6a # v6.1.3
with:
@@ -58,15 +63,16 @@ jobs:
- name: Get branch name
id: branch-name
uses: tj-actions/branch-names@dde14ac574a8b9b1cedc59a1cf312788af43d8d8 # v8.2.1
uses: tj-actions/branch-names@5250492686b253f06fa55861556d1027b067aeb5 # v9.0.2
- name: "Branch name to Docker tag name"
id: docker-tag-name
run: |
tag=${{ steps.branch-name.outputs.current_branch }}
# Replace / with --, e.g. user/feature => user--feature.
tag=${tag//\//--}
echo "tag=${tag}" >> $GITHUB_OUTPUT
tag=${BRANCH_NAME//\//--}
echo "tag=${tag}" >> "$GITHUB_OUTPUT"
env:
BRANCH_NAME: ${{ steps.branch-name.outputs.current_branch }}
- name: Set up Depot CLI
uses: depot/setup-action@b0b1ea4f69e92ebf5dea3f8713a1b0c37b2126a5 # v1.6.0
@@ -76,7 +82,7 @@ jobs:
- name: Login to DockerHub
if: github.ref == 'refs/heads/main'
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0
uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
@@ -103,32 +109,39 @@ jobs:
CURRENT_SYSTEM=$(nix eval --impure --raw --expr 'builtins.currentSystem')
docker image tag codercom/oss-dogfood-nix:latest-$CURRENT_SYSTEM codercom/oss-dogfood-nix:${{ steps.docker-tag-name.outputs.tag }}
docker image push codercom/oss-dogfood-nix:${{ steps.docker-tag-name.outputs.tag }}
docker image tag "codercom/oss-dogfood-nix:latest-$CURRENT_SYSTEM" "codercom/oss-dogfood-nix:${DOCKER_TAG}"
docker image push "codercom/oss-dogfood-nix:${DOCKER_TAG}"
docker image tag codercom/oss-dogfood-nix:latest-$CURRENT_SYSTEM codercom/oss-dogfood-nix:latest
docker image push codercom/oss-dogfood-nix:latest
docker image tag "codercom/oss-dogfood-nix:latest-$CURRENT_SYSTEM" "codercom/oss-dogfood-nix:latest"
docker image push "codercom/oss-dogfood-nix:latest"
env:
DOCKER_TAG: ${{ steps.docker-tag-name.outputs.tag }}
deploy_template:
needs: build_image
runs-on: ubuntu-latest
permissions:
# Necessary for GCP authentication (https://github.com/google-github-actions/setup-gcloud#usage)
id-token: write
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
persist-credentials: false
- name: Setup Terraform
uses: ./.github/actions/setup-tf
- name: Authenticate to Google Cloud
uses: google-github-actions/auth@ba79af03959ebeac9769e648f473a284504d9193 # v2.1.10
uses: google-github-actions/auth@b7593ed2efd1c1617e1b0254da33b86225adb2a5 # v2.1.12
with:
workload_identity_provider: projects/573722524737/locations/global/workloadIdentityPools/github/providers/github
service_account: coder-ci@coder-dogfood.iam.gserviceaccount.com
workload_identity_provider: ${{ vars.GCP_WORKLOAD_ID_PROVIDER }}
service_account: ${{ vars.GCP_SERVICE_ACCOUNT }}
- name: Terraform init and validate
run: |
@@ -148,12 +161,12 @@ jobs:
- name: Get short commit SHA
if: github.ref == 'refs/heads/main'
id: vars
run: echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
run: echo "sha_short=$(git rev-parse --short HEAD)" >> "$GITHUB_OUTPUT"
- name: Get latest commit title
if: github.ref == 'refs/heads/main'
id: message
run: echo "pr_title=$(git log --format=%s -n 1 ${{ github.sha }})" >> $GITHUB_OUTPUT
run: echo "pr_title=$(git log --format=%s -n 1 ${{ github.sha }})" >> "$GITHUB_OUTPUT"
- name: "Push template"
if: github.ref == 'refs/heads/main'
@@ -165,6 +178,7 @@ jobs:
CODER_URL: https://dev.coder.com
CODER_SESSION_TOKEN: ${{ secrets.CODER_SESSION_TOKEN }}
# Template source & details
TF_VAR_CODER_DOGFOOD_ANTHROPIC_API_KEY: ${{ secrets.CODER_DOGFOOD_ANTHROPIC_API_KEY }}
TF_VAR_CODER_TEMPLATE_NAME: ${{ secrets.CODER_TEMPLATE_NAME }}
TF_VAR_CODER_TEMPLATE_VERSION: ${{ steps.vars.outputs.sha_short }}
TF_VAR_CODER_TEMPLATE_DIR: ./coder
+219
View File
@@ -0,0 +1,219 @@
# The nightly-gauntlet runs tests that are either too flaky or too slow to block
# every PR.
name: nightly-gauntlet
on:
schedule:
# Every day at 4AM
- cron: "0 4 * * 1-5"
workflow_dispatch:
permissions:
contents: read
jobs:
test-go-pg:
# make sure to adjust NUM_PARALLEL_PACKAGES and NUM_PARALLEL_TESTS below
# when changing runner sizes
runs-on: ${{ matrix.os == 'macos-latest' && github.repository_owner == 'coder' && 'depot-macos-latest' || matrix.os == 'windows-2022' && github.repository_owner == 'coder' && 'depot-windows-2022-16' || matrix.os }}
# This timeout must be greater than the timeout set by `go test` in
# `make test-postgres` to ensure we receive a trace of running
# goroutines. Setting this to the timeout +5m should work quite well
# even if some of the preceding steps are slow.
timeout-minutes: 25
strategy:
matrix:
os:
- macos-latest
- windows-2022
steps:
- name: Harden Runner
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
# macOS indexes all new files in the background. Our Postgres tests
# create and destroy thousands of databases on disk, and Spotlight
# tries to index all of them, seriously slowing down the tests.
- name: Disable Spotlight Indexing
if: runner.os == 'macOS'
run: |
enabled=$(sudo mdutil -a -s | { grep -Fc "Indexing enabled" || true; })
if [ "$enabled" -eq 0 ]; then
echo "Spotlight indexing is already disabled"
exit 0
fi
sudo mdutil -a -i off
sudo mdutil -X /
sudo launchctl bootout system /System/Library/LaunchDaemons/com.apple.metadata.mds.plist
# Set up RAM disks to speed up the rest of the job. This action is in
# a separate repository to allow its use before actions/checkout.
- name: Setup RAM Disks
if: runner.os == 'Windows'
uses: coder/setup-ramdisk-action@e1100847ab2d7bcd9d14bcda8f2d1b0f07b36f1b # v0.1.0
- name: Checkout
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
fetch-depth: 1
persist-credentials: false
- name: Setup Go
uses: ./.github/actions/setup-go
with:
# Runners have Go baked-in and Go will automatically
# download the toolchain configured in go.mod, so we don't
# need to reinstall it. It's faster on Windows runners.
use-preinstalled-go: ${{ runner.os == 'Windows' }}
- name: Setup Terraform
uses: ./.github/actions/setup-tf
- name: Setup Embedded Postgres Cache Paths
id: embedded-pg-cache
uses: ./.github/actions/setup-embedded-pg-cache-paths
- name: Download Embedded Postgres Cache
id: download-embedded-pg-cache
uses: ./.github/actions/embedded-pg-cache/download
with:
key-prefix: embedded-pg-${{ runner.os }}-${{ runner.arch }}
cache-path: ${{ steps.embedded-pg-cache.outputs.cached-dirs }}
- name: Test with PostgreSQL Database
env:
POSTGRES_VERSION: "13"
TS_DEBUG_DISCO: "true"
LC_CTYPE: "en_US.UTF-8"
LC_ALL: "en_US.UTF-8"
shell: bash
run: |
set -o errexit
set -o pipefail
if [ "${{ runner.os }}" == "Windows" ]; then
# Create a temp dir on the R: ramdisk drive for Windows. The default
# C: drive is extremely slow: https://github.com/actions/runner-images/issues/8755
mkdir -p "R:/temp/embedded-pg"
go run scripts/embedded-pg/main.go -path "R:/temp/embedded-pg" -cache "${EMBEDDED_PG_CACHE_DIR}"
elif [ "${{ runner.os }}" == "macOS" ]; then
# Postgres runs faster on a ramdisk on macOS too
mkdir -p /tmp/tmpfs
sudo mount_tmpfs -o noowners -s 8g /tmp/tmpfs
go run scripts/embedded-pg/main.go -path /tmp/tmpfs/embedded-pg -cache "${EMBEDDED_PG_CACHE_DIR}"
elif [ "${{ runner.os }}" == "Linux" ]; then
make test-postgres-docker
fi
# if macOS, install google-chrome for scaletests
# As another concern, should we really have this kind of external dependency
# requirement on standard CI?
if [ "${{ matrix.os }}" == "macos-latest" ]; then
brew install google-chrome
fi
# macOS will output "The default interactive shell is now zsh"
# intermittently in CI...
if [ "${{ matrix.os }}" == "macos-latest" ]; then
touch ~/.bash_profile && echo "export BASH_SILENCE_DEPRECATION_WARNING=1" >> ~/.bash_profile
fi
if [ "${{ runner.os }}" == "Windows" ]; then
# Our Windows runners have 16 cores.
# On Windows Postgres chokes up when we have 16x16=256 tests
# running in parallel, and dbtestutil.NewDB starts to take more than
# 10s to complete sometimes causing test timeouts. With 16x8=128 tests
# Postgres tends not to choke.
NUM_PARALLEL_PACKAGES=8
NUM_PARALLEL_TESTS=16
elif [ "${{ runner.os }}" == "macOS" ]; then
# Our macOS runners have 8 cores. We set NUM_PARALLEL_TESTS to 16
# because the tests complete faster and Postgres doesn't choke. It seems
# that macOS's tmpfs is faster than the one on Windows.
NUM_PARALLEL_PACKAGES=8
NUM_PARALLEL_TESTS=16
elif [ "${{ runner.os }}" == "Linux" ]; then
# Our Linux runners have 8 cores.
NUM_PARALLEL_PACKAGES=8
NUM_PARALLEL_TESTS=8
fi
# run tests without cache
TESTCOUNT="-count=1"
DB=ci gotestsum \
--format standard-quiet --packages "./..." \
-- -timeout=20m -v -p $NUM_PARALLEL_PACKAGES -parallel=$NUM_PARALLEL_TESTS $TESTCOUNT
- name: Upload Embedded Postgres Cache
uses: ./.github/actions/embedded-pg-cache/upload
# We only use the embedded Postgres cache on macOS and Windows runners.
if: runner.OS == 'macOS' || runner.OS == 'Windows'
with:
cache-key: ${{ steps.download-embedded-pg-cache.outputs.cache-key }}
cache-path: "${{ steps.embedded-pg-cache.outputs.embedded-pg-cache }}"
- name: Upload test stats to Datadog
timeout-minutes: 1
continue-on-error: true
uses: ./.github/actions/upload-datadog
if: success() || failure()
with:
api-key: ${{ secrets.DATADOG_API_KEY }}
notify-slack-on-failure:
needs:
- test-go-pg
runs-on: ubuntu-latest
if: failure() && github.ref == 'refs/heads/main'
steps:
- name: Send Slack notification
run: |
curl -X POST -H 'Content-type: application/json' \
--data '{
"blocks": [
{
"type": "header",
"text": {
"type": "plain_text",
"text": "❌ Nightly gauntlet failed",
"emoji": true
}
},
{
"type": "section",
"fields": [
{
"type": "mrkdwn",
"text": "*Workflow:*\n'"${GITHUB_WORKFLOW}"'"
},
{
"type": "mrkdwn",
"text": "*Committer:*\n'"${GITHUB_ACTOR}"'"
},
{
"type": "mrkdwn",
"text": "*Commit:*\n'"${GITHUB_SHA}"'"
}
]
},
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "*View failure:* <'"${RUN_URL}"'|Click here>"
}
},
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "<@U08TJ4YNCA3> investigate this CI failure. Check logs, search for existing issues, use git blame to find who last modified failing tests, create issue in coder/internal (not public repo), use title format \"flake: TestName\" for flaky tests, and assign to the person from git blame."
}
}
]
}' "${SLACK_WEBHOOK}"
env:
SLACK_WEBHOOK: ${{ secrets.CI_FAILURE_SLACK_WEBHOOK }}
RUN_URL: "${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"
+2 -1
View File
@@ -3,6 +3,7 @@
name: PR Auto Assign
on:
# zizmor: ignore[dangerous-triggers] We explicitly want to run on pull_request_target.
pull_request_target:
types: [opened]
@@ -14,7 +15,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
+17 -7
View File
@@ -19,7 +19,7 @@ jobs:
packages: write
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
@@ -27,10 +27,12 @@ jobs:
id: pr_number
run: |
if [ -n "${{ github.event.pull_request.number }}" ]; then
echo "PR_NUMBER=${{ github.event.pull_request.number }}" >> $GITHUB_OUTPUT
echo "PR_NUMBER=${{ github.event.pull_request.number }}" >> "$GITHUB_OUTPUT"
else
echo "PR_NUMBER=${{ github.event.inputs.pr_number }}" >> $GITHUB_OUTPUT
echo "PR_NUMBER=${PR_NUMBER}" >> "$GITHUB_OUTPUT"
fi
env:
PR_NUMBER: ${{ github.event.inputs.pr_number }}
- name: Delete image
continue-on-error: true
@@ -51,17 +53,21 @@ jobs:
- name: Delete helm release
run: |
set -euo pipefail
helm delete --namespace "pr${{ steps.pr_number.outputs.PR_NUMBER }}" "pr${{ steps.pr_number.outputs.PR_NUMBER }}" || echo "helm release not found"
helm delete --namespace "pr${PR_NUMBER}" "pr${PR_NUMBER}" || echo "helm release not found"
env:
PR_NUMBER: ${{ steps.pr_number.outputs.PR_NUMBER }}
- name: "Remove PR namespace"
run: |
kubectl delete namespace "pr${{ steps.pr_number.outputs.PR_NUMBER }}" || echo "namespace not found"
kubectl delete namespace "pr${PR_NUMBER}" || echo "namespace not found"
env:
PR_NUMBER: ${{ steps.pr_number.outputs.PR_NUMBER }}
- name: "Remove DNS records"
run: |
set -euo pipefail
# Get identifier for the record
record_id=$(curl -X GET "https://api.cloudflare.com/client/v4/zones/${{ secrets.PR_DEPLOYMENTS_ZONE_ID }}/dns_records?name=%2A.pr${{ steps.pr_number.outputs.PR_NUMBER }}.${{ secrets.PR_DEPLOYMENTS_DOMAIN }}" \
record_id=$(curl -X GET "https://api.cloudflare.com/client/v4/zones/${{ secrets.PR_DEPLOYMENTS_ZONE_ID }}/dns_records?name=%2A.pr${PR_NUMBER}.${{ secrets.PR_DEPLOYMENTS_DOMAIN }}" \
-H "Authorization: Bearer ${{ secrets.PR_DEPLOYMENTS_CLOUDFLARE_API_TOKEN }}" \
-H "Content-Type:application/json" | jq -r '.result[0].id') || echo "DNS record not found"
@@ -73,9 +79,13 @@ jobs:
-H "Authorization: Bearer ${{ secrets.PR_DEPLOYMENTS_CLOUDFLARE_API_TOKEN }}" \
-H "Content-Type:application/json" | jq -r '.success'
) || echo "DNS record not found"
env:
PR_NUMBER: ${{ steps.pr_number.outputs.PR_NUMBER }}
- name: "Delete certificate"
if: ${{ github.event.pull_request.merged == true }}
run: |
set -euxo pipefail
kubectl delete certificate "pr${{ steps.pr_number.outputs.PR_NUMBER }}-tls" -n pr-deployment-certs || echo "certificate not found"
kubectl delete certificate "pr${PR_NUMBER}-tls" -n pr-deployment-certs || echo "certificate not found"
env:
PR_NUMBER: ${{ steps.pr_number.outputs.PR_NUMBER }}
+80 -64
View File
@@ -39,12 +39,14 @@ jobs:
PR_OPEN: ${{ steps.check_pr.outputs.pr_open }}
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
persist-credentials: false
- name: Check if PR is open
id: check_pr
@@ -55,7 +57,7 @@ jobs:
echo "PR doesn't exist or is closed."
pr_open=false
fi
echo "pr_open=$pr_open" >> $GITHUB_OUTPUT
echo "pr_open=$pr_open" >> "$GITHUB_OUTPUT"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -74,14 +76,15 @@ jobs:
runs-on: "ubuntu-latest"
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
fetch-depth: 0
persist-credentials: false
- name: Get PR number, title, and branch name
id: pr_info
@@ -90,9 +93,11 @@ jobs:
PR_NUMBER=$(gh pr view --json number | jq -r '.number')
PR_TITLE=$(gh pr view --json title | jq -r '.title')
PR_URL=$(gh pr view --json url | jq -r '.url')
echo "PR_URL=$PR_URL" >> $GITHUB_OUTPUT
echo "PR_NUMBER=$PR_NUMBER" >> $GITHUB_OUTPUT
echo "PR_TITLE=$PR_TITLE" >> $GITHUB_OUTPUT
{
echo "PR_URL=$PR_URL"
echo "PR_NUMBER=$PR_NUMBER"
echo "PR_TITLE=$PR_TITLE"
} >> "$GITHUB_OUTPUT"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -100,8 +105,8 @@ jobs:
id: set_tags
run: |
set -euo pipefail
echo "CODER_BASE_IMAGE_TAG=$CODER_BASE_IMAGE_TAG" >> $GITHUB_OUTPUT
echo "CODER_IMAGE_TAG=$CODER_IMAGE_TAG" >> $GITHUB_OUTPUT
echo "CODER_BASE_IMAGE_TAG=$CODER_BASE_IMAGE_TAG" >> "$GITHUB_OUTPUT"
echo "CODER_IMAGE_TAG=$CODER_IMAGE_TAG" >> "$GITHUB_OUTPUT"
env:
CODER_BASE_IMAGE_TAG: ghcr.io/coder/coder-preview-base:pr${{ steps.pr_info.outputs.PR_NUMBER }}
CODER_IMAGE_TAG: ghcr.io/coder/coder-preview:pr${{ steps.pr_info.outputs.PR_NUMBER }}
@@ -118,14 +123,16 @@ jobs:
id: check_deployment
run: |
set -euo pipefail
if helm status "pr${{ steps.pr_info.outputs.PR_NUMBER }}" --namespace "pr${{ steps.pr_info.outputs.PR_NUMBER }}" > /dev/null 2>&1; then
if helm status "pr${PR_NUMBER}" --namespace "pr${PR_NUMBER}" > /dev/null 2>&1; then
echo "Deployment already exists. Skipping deployment."
NEW=false
else
echo "Deployment doesn't exist."
NEW=true
fi
echo "NEW=$NEW" >> $GITHUB_OUTPUT
echo "NEW=$NEW" >> "$GITHUB_OUTPUT"
env:
PR_NUMBER: ${{ steps.pr_info.outputs.PR_NUMBER }}
- name: Check changed files
uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
@@ -154,17 +161,20 @@ jobs:
- name: Print number of changed files
run: |
set -euo pipefail
echo "Total number of changed files: ${{ steps.filter.outputs.all_count }}"
echo "Number of ignored files: ${{ steps.filter.outputs.ignored_count }}"
echo "Total number of changed files: ${ALL_COUNT}"
echo "Number of ignored files: ${IGNORED_COUNT}"
env:
ALL_COUNT: ${{ steps.filter.outputs.all_count }}
IGNORED_COUNT: ${{ steps.filter.outputs.ignored_count }}
- name: Build conditionals
id: build_conditionals
run: |
set -euo pipefail
# build if the workflow is manually triggered and the deployment doesn't exist (first build or force rebuild)
echo "first_or_force_build=${{ (github.event_name == 'workflow_dispatch' && steps.check_deployment.outputs.NEW == 'true') || github.event.inputs.build == 'true' }}" >> $GITHUB_OUTPUT
echo "first_or_force_build=${{ (github.event_name == 'workflow_dispatch' && steps.check_deployment.outputs.NEW == 'true') || github.event.inputs.build == 'true' }}" >> "$GITHUB_OUTPUT"
# build if the deployment already exist and there are changes in the files that we care about (automatic updates)
echo "automatic_rebuild=${{ steps.check_deployment.outputs.NEW == 'false' && steps.filter.outputs.all_count > steps.filter.outputs.ignored_count }}" >> $GITHUB_OUTPUT
echo "automatic_rebuild=${{ steps.check_deployment.outputs.NEW == 'false' && steps.filter.outputs.all_count > steps.filter.outputs.ignored_count }}" >> "$GITHUB_OUTPUT"
comment-pr:
needs: get_info
@@ -174,7 +184,7 @@ jobs:
pull-requests: write # needed for commenting on PRs
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
@@ -218,14 +228,15 @@ jobs:
CODER_IMAGE_TAG: ${{ needs.get_info.outputs.CODER_IMAGE_TAG }}
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
fetch-depth: 0
persist-credentials: false
- name: Setup Node
uses: ./.github/actions/setup-node
@@ -237,7 +248,7 @@ jobs:
uses: ./.github/actions/setup-sqlc
- name: GHCR Login
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0
uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0
with:
registry: ghcr.io
username: ${{ github.actor }}
@@ -250,12 +261,13 @@ jobs:
make gen/mark-fresh
export DOCKER_IMAGE_NO_PREREQUISITES=true
version="$(./scripts/version.sh)"
export CODER_IMAGE_BUILD_BASE_TAG="$(CODER_IMAGE_BASE=coder-base ./scripts/image_tag.sh --version "$version")"
CODER_IMAGE_BUILD_BASE_TAG="$(CODER_IMAGE_BASE=coder-base ./scripts/image_tag.sh --version "$version")"
export CODER_IMAGE_BUILD_BASE_TAG
make -j build/coder_linux_amd64
./scripts/build_docker.sh \
--arch amd64 \
--target ${{ env.CODER_IMAGE_TAG }} \
--version $version \
--target "${CODER_IMAGE_TAG}" \
--version "$version" \
--push \
build/coder_linux_amd64
@@ -276,7 +288,7 @@ jobs:
PR_HOSTNAME: "pr${{ needs.get_info.outputs.PR_NUMBER }}.${{ secrets.PR_DEPLOYMENTS_DOMAIN }}"
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
@@ -293,13 +305,13 @@ jobs:
set -euo pipefail
foundTag=$(
gh api /orgs/coder/packages/container/coder-preview/versions |
jq -r --arg tag "pr${{ env.PR_NUMBER }}" '.[] |
jq -r --arg tag "pr${PR_NUMBER}" '.[] |
select(.metadata.container.tags == [$tag]) |
.metadata.container.tags[0]'
)
if [ -z "$foundTag" ]; then
echo "Image not found"
echo "${{ env.CODER_IMAGE_TAG }} not found in ghcr.io/coder/coder-preview"
echo "${CODER_IMAGE_TAG} not found in ghcr.io/coder/coder-preview"
exit 1
else
echo "Image found"
@@ -314,40 +326,42 @@ jobs:
curl -X POST "https://api.cloudflare.com/client/v4/zones/${{ secrets.PR_DEPLOYMENTS_ZONE_ID }}/dns_records" \
-H "Authorization: Bearer ${{ secrets.PR_DEPLOYMENTS_CLOUDFLARE_API_TOKEN }}" \
-H "Content-Type:application/json" \
--data '{"type":"CNAME","name":"*.${{ env.PR_HOSTNAME }}","content":"${{ env.PR_HOSTNAME }}","ttl":1,"proxied":false}'
--data '{"type":"CNAME","name":"*.'"${PR_HOSTNAME}"'","content":"'"${PR_HOSTNAME}"'","ttl":1,"proxied":false}'
- name: Create PR namespace
if: needs.get_info.outputs.NEW == 'true' || github.event.inputs.deploy == 'true'
run: |
set -euo pipefail
# try to delete the namespace, but don't fail if it doesn't exist
kubectl delete namespace "pr${{ env.PR_NUMBER }}" || true
kubectl create namespace "pr${{ env.PR_NUMBER }}"
kubectl delete namespace "pr${PR_NUMBER}" || true
kubectl create namespace "pr${PR_NUMBER}"
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
persist-credentials: false
- name: Check and Create Certificate
if: needs.get_info.outputs.NEW == 'true' || github.event.inputs.deploy == 'true'
run: |
# Using kubectl to check if a Certificate resource already exists
# we are doing this to avoid letsenrypt rate limits
if ! kubectl get certificate pr${{ env.PR_NUMBER }}-tls -n pr-deployment-certs > /dev/null 2>&1; then
if ! kubectl get certificate "pr${PR_NUMBER}-tls" -n pr-deployment-certs > /dev/null 2>&1; then
echo "Certificate doesn't exist. Creating a new one."
envsubst < ./.github/pr-deployments/certificate.yaml | kubectl apply -f -
else
echo "Certificate exists. Skipping certificate creation."
fi
echo "Copy certificate from pr-deployment-certs to pr${{ env.PR_NUMBER }} namespace"
until kubectl get secret pr${{ env.PR_NUMBER }}-tls -n pr-deployment-certs &> /dev/null
echo "Copy certificate from pr-deployment-certs to pr${PR_NUMBER} namespace"
until kubectl get secret "pr${PR_NUMBER}-tls" -n pr-deployment-certs &> /dev/null
do
echo "Waiting for secret pr${{ env.PR_NUMBER }}-tls to be created..."
echo "Waiting for secret pr${PR_NUMBER}-tls to be created..."
sleep 5
done
(
kubectl get secret pr${{ env.PR_NUMBER }}-tls -n pr-deployment-certs -o json |
kubectl get secret "pr${PR_NUMBER}-tls" -n pr-deployment-certs -o json |
jq 'del(.metadata.namespace,.metadata.creationTimestamp,.metadata.resourceVersion,.metadata.selfLink,.metadata.uid,.metadata.managedFields)' |
kubectl -n pr${{ env.PR_NUMBER }} apply -f -
kubectl -n "pr${PR_NUMBER}" apply -f -
)
- name: Set up PostgreSQL database
@@ -355,13 +369,13 @@ jobs:
run: |
helm repo add bitnami https://charts.bitnami.com/bitnami
helm install coder-db bitnami/postgresql \
--namespace pr${{ env.PR_NUMBER }} \
--namespace "pr${PR_NUMBER}" \
--set auth.username=coder \
--set auth.password=coder \
--set auth.database=coder \
--set persistence.size=10Gi
kubectl create secret generic coder-db-url -n pr${{ env.PR_NUMBER }} \
--from-literal=url="postgres://coder:coder@coder-db-postgresql.pr${{ env.PR_NUMBER }}.svc.cluster.local:5432/coder?sslmode=disable"
kubectl create secret generic coder-db-url -n "pr${PR_NUMBER}" \
--from-literal=url="postgres://coder:coder@coder-db-postgresql.pr${PR_NUMBER}.svc.cluster.local:5432/coder?sslmode=disable"
- name: Create a service account, role, and rolebinding for the PR namespace
if: needs.get_info.outputs.NEW == 'true' || github.event.inputs.deploy == 'true'
@@ -383,8 +397,8 @@ jobs:
run: |
set -euo pipefail
helm dependency update --skip-refresh ./helm/coder
helm upgrade --install "pr${{ env.PR_NUMBER }}" ./helm/coder \
--namespace "pr${{ env.PR_NUMBER }}" \
helm upgrade --install "pr${PR_NUMBER}" ./helm/coder \
--namespace "pr${PR_NUMBER}" \
--values ./pr-deploy-values.yaml \
--force
@@ -393,8 +407,8 @@ jobs:
run: |
helm repo add coder-logstream-kube https://helm.coder.com/logstream-kube
helm upgrade --install coder-logstream-kube coder-logstream-kube/coder-logstream-kube \
--namespace "pr${{ env.PR_NUMBER }}" \
--set url="https://${{ env.PR_HOSTNAME }}"
--namespace "pr${PR_NUMBER}" \
--set url="https://${PR_HOSTNAME}"
- name: Get Coder binary
if: needs.get_info.outputs.NEW == 'true' || github.event.inputs.deploy == 'true'
@@ -402,16 +416,16 @@ jobs:
set -euo pipefail
DEST="${HOME}/coder"
URL="https://${{ env.PR_HOSTNAME }}/bin/coder-linux-amd64"
URL="https://${PR_HOSTNAME}/bin/coder-linux-amd64"
mkdir -p "$(dirname ${DEST})"
mkdir -p "$(dirname "$DEST")"
COUNT=0
until $(curl --output /dev/null --silent --head --fail "$URL"); do
until curl --output /dev/null --silent --head --fail "$URL"; do
printf '.'
sleep 5
COUNT=$((COUNT+1))
if [ $COUNT -ge 60 ]; then
if [ "$COUNT" -ge 60 ]; then
echo "Timed out waiting for URL to be available"
exit 1
fi
@@ -420,7 +434,7 @@ jobs:
curl -fsSL "$URL" -o "${DEST}"
chmod +x "${DEST}"
"${DEST}" version
mv "${DEST}" /usr/local/bin/coder
sudo mv "${DEST}" /usr/local/bin/coder
- name: Create first user
if: needs.get_info.outputs.NEW == 'true' || github.event.inputs.deploy == 'true'
@@ -435,24 +449,24 @@ jobs:
# add mask so that the password is not printed to the logs
echo "::add-mask::$password"
echo "password=$password" >> $GITHUB_OUTPUT
echo "password=$password" >> "$GITHUB_OUTPUT"
coder login \
--first-user-username pr${{ env.PR_NUMBER }}-admin \
--first-user-email pr${{ env.PR_NUMBER }}@coder.com \
--first-user-password $password \
--first-user-username "pr${PR_NUMBER}-admin" \
--first-user-email "pr${PR_NUMBER}@coder.com" \
--first-user-password "$password" \
--first-user-trial=false \
--use-token-as-session \
https://${{ env.PR_HOSTNAME }}
"https://${PR_HOSTNAME}"
# Create a user for the github.actor
# TODO: update once https://github.com/coder/coder/issues/15466 is resolved
# coder users create \
# --username ${{ github.actor }} \
# --username ${GITHUB_ACTOR} \
# --login-type github
# promote the user to admin role
# coder org members edit-role ${{ github.actor }} organization-admin
# coder org members edit-role ${GITHUB_ACTOR} organization-admin
# TODO: update once https://github.com/coder/internal/issues/207 is resolved
- name: Send Slack notification
@@ -461,17 +475,19 @@ jobs:
curl -s -o /dev/null -X POST -H 'Content-type: application/json' \
-d \
'{
"pr_number": "'"${{ env.PR_NUMBER }}"'",
"pr_url": "'"${{ env.PR_URL }}"'",
"pr_title": "'"${{ env.PR_TITLE }}"'",
"pr_access_url": "'"https://${{ env.PR_HOSTNAME }}"'",
"pr_username": "'"pr${{ env.PR_NUMBER }}-admin"'",
"pr_email": "'"pr${{ env.PR_NUMBER }}@coder.com"'",
"pr_password": "'"${{ steps.setup_deployment.outputs.password }}"'",
"pr_actor": "'"${{ github.actor }}"'"
"pr_number": "'"${PR_NUMBER}"'",
"pr_url": "'"${PR_URL}"'",
"pr_title": "'"${PR_TITLE}"'",
"pr_access_url": "'"https://${PR_HOSTNAME}"'",
"pr_username": "'"pr${PR_NUMBER}-admin"'",
"pr_email": "'"pr${PR_NUMBER}@coder.com"'",
"pr_password": "'"${PASSWORD}"'",
"pr_actor": "'"${GITHUB_ACTOR}"'"
}' \
${{ secrets.PR_DEPLOYMENTS_SLACK_WEBHOOK }}
echo "Slack notification sent"
env:
PASSWORD: ${{ steps.setup_deployment.outputs.password }}
- name: Find Comment
uses: peter-evans/find-comment@3eae4d37986fb5a8592848f6a574fdf654e61f9e # v3.1.0
@@ -504,7 +520,7 @@ jobs:
run: |
set -euo pipefail
cd .github/pr-deployments/template
coder templates push -y --variable namespace=pr${{ env.PR_NUMBER }} kubernetes
coder templates push -y --variable "namespace=pr${PR_NUMBER}" kubernetes
# Create workspace
coder create --template="kubernetes" kube --parameter cpu=2 --parameter memory=4 --parameter home_disk_size=2 -y
+1 -1
View File
@@ -14,7 +14,7 @@ jobs:
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
+127 -60
View File
@@ -32,15 +32,43 @@ env:
CODER_RELEASE_NOTES: ${{ inputs.release_notes }}
jobs:
# Only allow maintainers/admins to release.
check-perms:
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
steps:
- name: Allow only maintainers/admins
uses: actions/github-script@v7.0.1
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const {data} = await github.rest.repos.getCollaboratorPermissionLevel({
owner: context.repo.owner,
repo: context.repo.repo,
username: context.actor
});
const role = data.role_name || data.user?.role_name || data.permission;
const perms = data.user?.permissions || {};
core.info(`Actor ${context.actor} permission=${data.permission}, role_name=${role}`);
const allowed =
role === 'admin' ||
role === 'maintain' ||
perms.admin === true ||
perms.maintain === true;
if (!allowed) core.setFailed('Denied: requires maintain or admin');
# build-dylib is a separate job to build the dylib on macOS.
build-dylib:
runs-on: ${{ github.repository_owner == 'coder' && 'depot-macos-latest' || 'macos-latest' }}
needs: check-perms
steps:
# Harden Runner doesn't work on macOS.
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
fetch-depth: 0
persist-credentials: false
# If the event that triggered the build was an annotated tag (which our
# tags are supposed to be), actions/checkout has a bug where the tag in
@@ -53,14 +81,16 @@ jobs:
- name: Setup build tools
run: |
brew install bash gnu-getopt make
echo "$(brew --prefix bash)/bin" >> $GITHUB_PATH
echo "$(brew --prefix gnu-getopt)/bin" >> $GITHUB_PATH
echo "$(brew --prefix make)/libexec/gnubin" >> $GITHUB_PATH
{
echo "$(brew --prefix bash)/bin"
echo "$(brew --prefix gnu-getopt)/bin"
echo "$(brew --prefix make)/libexec/gnubin"
} >> "$GITHUB_PATH"
- name: Switch XCode Version
uses: maxim-lobanov/setup-xcode@60606e260d2fc5762a71e64e74b2174e8ea3c8bd # v1.6.0
with:
xcode-version: "16.0.0"
xcode-version: "16.1.0"
- name: Setup Go
uses: ./.github/actions/setup-go
@@ -114,7 +144,7 @@ jobs:
release:
name: Build and publish
needs: build-dylib
needs: [build-dylib, check-perms]
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
permissions:
# Required to publish a release
@@ -134,14 +164,15 @@ jobs:
version: ${{ steps.version.outputs.version }}
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
fetch-depth: 0
persist-credentials: false
# If the event that triggered the build was an annotated tag (which our
# tags are supposed to be), actions/checkout has a bug where the tag in
@@ -156,9 +187,9 @@ jobs:
run: |
set -euo pipefail
version="$(./scripts/version.sh)"
echo "version=$version" >> $GITHUB_OUTPUT
echo "version=$version" >> "$GITHUB_OUTPUT"
# Speed up future version.sh calls.
echo "CODER_FORCE_VERSION=$version" >> $GITHUB_ENV
echo "CODER_FORCE_VERSION=$version" >> "$GITHUB_ENV"
echo "$version"
# Verify that all expectations for a release are met.
@@ -200,7 +231,7 @@ jobs:
release_notes_file="$(mktemp -t release_notes.XXXXXX)"
echo "$CODER_RELEASE_NOTES" > "$release_notes_file"
echo CODER_RELEASE_NOTES_FILE="$release_notes_file" >> $GITHUB_ENV
echo CODER_RELEASE_NOTES_FILE="$release_notes_file" >> "$GITHUB_ENV"
- name: Show release notes
run: |
@@ -208,7 +239,7 @@ jobs:
cat "$CODER_RELEASE_NOTES_FILE"
- name: Docker Login
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0
uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0
with:
registry: ghcr.io
username: ${{ github.actor }}
@@ -286,17 +317,17 @@ jobs:
# Setup GCloud for signing Windows binaries.
- name: Authenticate to Google Cloud
id: gcloud_auth
uses: google-github-actions/auth@ba79af03959ebeac9769e648f473a284504d9193 # v2.1.10
uses: google-github-actions/auth@b7593ed2efd1c1617e1b0254da33b86225adb2a5 # v2.1.12
with:
workload_identity_provider: ${{ secrets.GCP_CODE_SIGNING_WORKLOAD_ID_PROVIDER }}
service_account: ${{ secrets.GCP_CODE_SIGNING_SERVICE_ACCOUNT }}
workload_identity_provider: ${{ vars.GCP_CODE_SIGNING_WORKLOAD_ID_PROVIDER }}
service_account: ${{ vars.GCP_CODE_SIGNING_SERVICE_ACCOUNT }}
token_format: "access_token"
- name: Setup GCloud SDK
uses: google-github-actions/setup-gcloud@77e7a554d41e2ee56fc945c52dfd3f33d12def9a # v2.1.4
uses: google-github-actions/setup-gcloud@cb1e50a9932213ecece00a606661ae9ca44f3397 # v2.2.0
- name: Download dylibs
uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
uses: actions/download-artifact@634f93cb2916e3fdff6788551b99b062d0335ce0 # v5.0.0
with:
name: dylibs
path: ./build
@@ -350,9 +381,9 @@ jobs:
set -euo pipefail
if [[ "${CODER_RELEASE:-}" != *t* ]] || [[ "${CODER_DRY_RUN:-}" == *t* ]]; then
# Empty value means use the default and avoid building a fresh one.
echo "tag=" >> $GITHUB_OUTPUT
echo "tag=" >> "$GITHUB_OUTPUT"
else
echo "tag=$(CODER_IMAGE_BASE=ghcr.io/coder/coder-base ./scripts/image_tag.sh)" >> $GITHUB_OUTPUT
echo "tag=$(CODER_IMAGE_BASE=ghcr.io/coder/coder-base ./scripts/image_tag.sh)" >> "$GITHUB_OUTPUT"
fi
- name: Create empty base-build-context directory
@@ -387,7 +418,7 @@ jobs:
# available immediately
for i in {1..10}; do
rc=0
raw_manifests=$(docker buildx imagetools inspect --raw "${{ steps.image-base-tag.outputs.tag }}") || rc=$?
raw_manifests=$(docker buildx imagetools inspect --raw "${IMAGE_TAG}") || rc=$?
if [[ "$rc" -eq 0 ]]; then
break
fi
@@ -409,6 +440,8 @@ jobs:
echo "$manifests" | grep -q linux/amd64
echo "$manifests" | grep -q linux/arm64
echo "$manifests" | grep -q linux/arm/v7
env:
IMAGE_TAG: ${{ steps.image-base-tag.outputs.tag }}
# GitHub attestation provides SLSA provenance for Docker images, establishing a verifiable
# record that these images were built in GitHub Actions with specific inputs and environment.
@@ -476,7 +509,7 @@ jobs:
# Save multiarch image tag for attestation
multiarch_image="$(./scripts/image_tag.sh)"
echo "multiarch_image=${multiarch_image}" >> $GITHUB_OUTPUT
echo "multiarch_image=${multiarch_image}" >> "$GITHUB_OUTPUT"
# For debugging, print all docker image tags
docker images
@@ -484,16 +517,15 @@ jobs:
# if the current version is equal to the highest (according to semver)
# version in the repo, also create a multi-arch image as ":latest" and
# push it
created_latest_tag=false
if [[ "$(git tag | grep '^v' | grep -vE '(rc|dev|-|\+|\/)' | sort -r --version-sort | head -n1)" == "v$(./scripts/version.sh)" ]]; then
# shellcheck disable=SC2046
./scripts/build_docker_multiarch.sh \
--push \
--target "$(./scripts/image_tag.sh --version latest)" \
$(cat build/coder_"$version"_linux_{amd64,arm64,armv7}.tag)
created_latest_tag=true
echo "created_latest_tag=true" >> $GITHUB_OUTPUT
echo "created_latest_tag=true" >> "$GITHUB_OUTPUT"
else
echo "created_latest_tag=false" >> $GITHUB_OUTPUT
echo "created_latest_tag=false" >> "$GITHUB_OUTPUT"
fi
env:
CODER_BASE_IMAGE_TAG: ${{ steps.image-base-tag.outputs.tag }}
@@ -501,24 +533,27 @@ jobs:
- name: SBOM Generation and Attestation
if: ${{ !inputs.dry_run }}
env:
COSIGN_EXPERIMENTAL: "1"
COSIGN_EXPERIMENTAL: '1'
MULTIARCH_IMAGE: ${{ steps.build_docker.outputs.multiarch_image }}
VERSION: ${{ steps.version.outputs.version }}
CREATED_LATEST_TAG: ${{ steps.build_docker.outputs.created_latest_tag }}
run: |
set -euxo pipefail
# Generate SBOM for multi-arch image with version in filename
echo "Generating SBOM for multi-arch image: ${{ steps.build_docker.outputs.multiarch_image }}"
syft "${{ steps.build_docker.outputs.multiarch_image }}" -o spdx-json > coder_${{ steps.version.outputs.version }}_sbom.spdx.json
echo "Generating SBOM for multi-arch image: ${MULTIARCH_IMAGE}"
syft "${MULTIARCH_IMAGE}" -o spdx-json > "coder_${VERSION}_sbom.spdx.json"
# Attest SBOM to multi-arch image
echo "Attesting SBOM to multi-arch image: ${{ steps.build_docker.outputs.multiarch_image }}"
cosign clean --force=true "${{ steps.build_docker.outputs.multiarch_image }}"
echo "Attesting SBOM to multi-arch image: ${MULTIARCH_IMAGE}"
cosign clean --force=true "${MULTIARCH_IMAGE}"
cosign attest --type spdxjson \
--predicate coder_${{ steps.version.outputs.version }}_sbom.spdx.json \
--predicate "coder_${VERSION}_sbom.spdx.json" \
--yes \
"${{ steps.build_docker.outputs.multiarch_image }}"
"${MULTIARCH_IMAGE}"
# If latest tag was created, also attest it
if [[ "${{ steps.build_docker.outputs.created_latest_tag }}" == "true" ]]; then
if [[ "${CREATED_LATEST_TAG}" == "true" ]]; then
latest_tag="$(./scripts/image_tag.sh --version latest)"
echo "Generating SBOM for latest image: ${latest_tag}"
syft "${latest_tag}" -o spdx-json > coder_latest_sbom.spdx.json
@@ -572,7 +607,7 @@ jobs:
- name: Get latest tag name
id: latest_tag
if: ${{ !inputs.dry_run && steps.build_docker.outputs.created_latest_tag == 'true' }}
run: echo "tag=$(./scripts/image_tag.sh --version latest)" >> $GITHUB_OUTPUT
run: echo "tag=$(./scripts/image_tag.sh --version latest)" >> "$GITHUB_OUTPUT"
# If this is the highest version according to semver, also attest the "latest" tag
- name: GitHub Attestation for "latest" Docker image
@@ -615,7 +650,7 @@ jobs:
# Report attestation failures but don't fail the workflow
- name: Check attestation status
if: ${{ !inputs.dry_run }}
run: |
run: | # zizmor: ignore[template-injection] We're just reading steps.attest_x.outcome here, no risk of injection
if [[ "${{ steps.attest_base.outcome }}" == "failure" && "${{ steps.attest_base.conclusion }}" != "skipped" ]]; then
echo "::warning::GitHub attestation for base image failed"
fi
@@ -634,6 +669,30 @@ jobs:
- name: ls build
run: ls -lh build
- name: Publish Coder CLI binaries and detached signatures to GCS
if: ${{ !inputs.dry_run }}
run: |
set -euxo pipefail
version="$(./scripts/version.sh)"
# Source array of slim binaries
declare -A binaries
binaries["coder-darwin-amd64"]="coder-slim_${version}_darwin_amd64"
binaries["coder-darwin-arm64"]="coder-slim_${version}_darwin_arm64"
binaries["coder-linux-amd64"]="coder-slim_${version}_linux_amd64"
binaries["coder-linux-arm64"]="coder-slim_${version}_linux_arm64"
binaries["coder-linux-armv7"]="coder-slim_${version}_linux_armv7"
binaries["coder-windows-amd64.exe"]="coder-slim_${version}_windows_amd64.exe"
binaries["coder-windows-arm64.exe"]="coder-slim_${version}_windows_arm64.exe"
for cli_name in "${!binaries[@]}"; do
slim_binary="${binaries[$cli_name]}"
detached_signature="${slim_binary}.asc"
gcloud storage cp "./build/${slim_binary}" "gs://releases.coder.com/coder-cli/${version}/${cli_name}"
gcloud storage cp "./build/${detached_signature}" "gs://releases.coder.com/coder-cli/${version}/${cli_name}.asc"
done
- name: Publish release
run: |
set -euo pipefail
@@ -656,11 +715,11 @@ jobs:
./build/*.apk
./build/*.deb
./build/*.rpm
./coder_${{ steps.version.outputs.version }}_sbom.spdx.json
"./coder_${VERSION}_sbom.spdx.json"
)
# Only include the latest SBOM file if it was created
if [[ "${{ steps.build_docker.outputs.created_latest_tag }}" == "true" ]]; then
if [[ "${CREATED_LATEST_TAG}" == "true" ]]; then
files+=(./coder_latest_sbom.spdx.json)
fi
@@ -671,15 +730,17 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CODER_GPG_RELEASE_KEY_BASE64: ${{ secrets.GPG_RELEASE_KEY_BASE64 }}
VERSION: ${{ steps.version.outputs.version }}
CREATED_LATEST_TAG: ${{ steps.build_docker.outputs.created_latest_tag }}
- name: Authenticate to Google Cloud
uses: google-github-actions/auth@ba79af03959ebeac9769e648f473a284504d9193 # v2.1.10
uses: google-github-actions/auth@b7593ed2efd1c1617e1b0254da33b86225adb2a5 # v2.1.12
with:
workload_identity_provider: ${{ secrets.GCP_WORKLOAD_ID_PROVIDER }}
service_account: ${{ secrets.GCP_SERVICE_ACCOUNT }}
workload_identity_provider: ${{ vars.GCP_WORKLOAD_ID_PROVIDER }}
service_account: ${{ vars.GCP_SERVICE_ACCOUNT }}
- name: Setup GCloud SDK
uses: google-github-actions/setup-gcloud@77e7a554d41e2ee56fc945c52dfd3f33d12def9a # 2.1.4
uses: google-github-actions/setup-gcloud@cb1e50a9932213ecece00a606661ae9ca44f3397 # 2.2.0
- name: Publish Helm Chart
if: ${{ !inputs.dry_run }}
@@ -691,10 +752,12 @@ jobs:
cp "build/provisioner_helm_${version}.tgz" build/helm
gsutil cp gs://helm.coder.com/v2/index.yaml build/helm/index.yaml
helm repo index build/helm --url https://helm.coder.com/v2 --merge build/helm/index.yaml
gsutil -h "Cache-Control:no-cache,max-age=0" cp build/helm/coder_helm_${version}.tgz gs://helm.coder.com/v2
gsutil -h "Cache-Control:no-cache,max-age=0" cp build/helm/provisioner_helm_${version}.tgz gs://helm.coder.com/v2
gsutil -h "Cache-Control:no-cache,max-age=0" cp build/helm/index.yaml gs://helm.coder.com/v2
gsutil -h "Cache-Control:no-cache,max-age=0" cp helm/artifacthub-repo.yml gs://helm.coder.com/v2
gsutil -h "Cache-Control:no-cache,max-age=0" cp "build/helm/coder_helm_${version}.tgz" gs://helm.coder.com/v2
gsutil -h "Cache-Control:no-cache,max-age=0" cp "build/helm/provisioner_helm_${version}.tgz" gs://helm.coder.com/v2
gsutil -h "Cache-Control:no-cache,max-age=0" cp "build/helm/index.yaml" gs://helm.coder.com/v2
gsutil -h "Cache-Control:no-cache,max-age=0" cp "helm/artifacthub-repo.yml" gs://helm.coder.com/v2
helm push "build/coder_helm_${version}.tgz" oci://ghcr.io/coder/chart
helm push "build/provisioner_helm_${version}.tgz" oci://ghcr.io/coder/chart
- name: Upload artifacts to actions (if dry-run)
if: ${{ inputs.dry_run }}
@@ -739,18 +802,18 @@ jobs:
# TODO: skip this if it's not a new release (i.e. a backport). This is
# fine right now because it just makes a PR that we can close.
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: Update homebrew
env:
# Variables used by the `gh` command
GH_REPO: coder/homebrew-coder
GH_TOKEN: ${{ secrets.CDRCI_GITHUB_TOKEN }}
VERSION: ${{ needs.release.outputs.version }}
run: |
# Keep version number around for reference, removing any potential leading v
coder_version="$(echo "${{ needs.release.outputs.version }}" | tr -d v)"
coder_version="$(echo "${VERSION}" | tr -d v)"
set -euxo pipefail
@@ -769,9 +832,9 @@ jobs:
wget "$checksums_url" -O checksums.txt
# Get the SHAs
darwin_arm_sha="$(cat checksums.txt | grep "darwin_arm64.zip" | awk '{ print $1 }')"
darwin_intel_sha="$(cat checksums.txt | grep "darwin_amd64.zip" | awk '{ print $1 }')"
linux_sha="$(cat checksums.txt | grep "linux_amd64.tar.gz" | awk '{ print $1 }')"
darwin_arm_sha="$(grep "darwin_arm64.zip" checksums.txt | awk '{ print $1 }')"
darwin_intel_sha="$(grep "darwin_amd64.zip" checksums.txt | awk '{ print $1 }')"
linux_sha="$(grep "linux_amd64.tar.gz" checksums.txt | awk '{ print $1 }')"
echo "macOS arm64: $darwin_arm_sha"
echo "macOS amd64: $darwin_intel_sha"
@@ -784,7 +847,7 @@ jobs:
# Check if a PR already exists.
pr_count="$(gh pr list --search "head:$brew_branch" --json id,closed | jq -r ".[] | select(.closed == false) | .id" | wc -l)"
if [[ "$pr_count" > 0 ]]; then
if [ "$pr_count" -gt 0 ]; then
echo "Bailing out as PR already exists" 2>&1
exit 0
fi
@@ -803,8 +866,8 @@ jobs:
-B master -H "$brew_branch" \
-t "coder $coder_version" \
-b "" \
-r "${{ github.actor }}" \
-a "${{ github.actor }}" \
-r "${GITHUB_ACTOR}" \
-a "${GITHUB_ACTOR}" \
-b "This automatic PR was triggered by the release of Coder v$coder_version"
publish-winget:
@@ -815,7 +878,7 @@ jobs:
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
@@ -825,9 +888,10 @@ jobs:
GH_TOKEN: ${{ secrets.CDRCI_GITHUB_TOKEN }}
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
fetch-depth: 0
persist-credentials: false
# If the event that triggered the build was an annotated tag (which our
# tags are supposed to be), actions/checkout has a bug where the tag in
@@ -846,7 +910,7 @@ jobs:
# The package version is the same as the tag minus the leading "v".
# The version in this output already has the leading "v" removed but
# we do it again to be safe.
$version = "${{ needs.release.outputs.version }}".Trim('v')
$version = $env:VERSION.Trim('v')
$release_assets = gh release view --repo coder/coder "v${version}" --json assets | `
ConvertFrom-Json
@@ -878,13 +942,14 @@ jobs:
# For wingetcreate. We need a real token since we're pushing a commit
# to GitHub and then making a PR in a different repo.
WINGET_GH_TOKEN: ${{ secrets.CDRCI_GITHUB_TOKEN }}
VERSION: ${{ needs.release.outputs.version }}
- name: Comment on PR
run: |
# wait 30 seconds
Start-Sleep -Seconds 30.0
# Find the PR that wingetcreate just made.
$version = "${{ needs.release.outputs.version }}".Trim('v')
$version = $env:VERSION.Trim('v')
$pr_list = gh pr list --repo microsoft/winget-pkgs --search "author:cdrci Coder.Coder version ${version}" --limit 1 --json number | `
ConvertFrom-Json
$pr_number = $pr_list[0].number
@@ -895,6 +960,7 @@ jobs:
# For gh CLI. We need a real token since we're commenting on a PR in a
# different repo.
GH_TOKEN: ${{ secrets.CDRCI_GITHUB_TOKEN }}
VERSION: ${{ needs.release.outputs.version }}
# publish-sqlc pushes the latest schema to sqlc cloud.
# At present these pushes cannot be tagged, so the last push is always the latest.
@@ -905,14 +971,15 @@ jobs:
if: ${{ !inputs.dry_run }}
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
fetch-depth: 1
persist-credentials: false
# We need golang to run the migration main.go
- name: Setup Go
+3 -3
View File
@@ -20,12 +20,12 @@ jobs:
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: "Checkout code"
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
persist-credentials: false
@@ -47,6 +47,6 @@ jobs:
# Upload the results to GitHub's code scanning dashboard.
- name: "Upload to code-scanning"
uses: github/codeql-action/upload-sarif@ce28f5bb42b7a9f2c824e633a3f6ee835bab6858 # v3.29.0
uses: github/codeql-action/upload-sarif@76621b61decf072c1cee8dd1ce2d2a82d33c17ed # v3.29.5
with:
sarif_file: results.sarif
+14 -10
View File
@@ -27,18 +27,20 @@ jobs:
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
persist-credentials: false
- name: Setup Go
uses: ./.github/actions/setup-go
- name: Initialize CodeQL
uses: github/codeql-action/init@ce28f5bb42b7a9f2c824e633a3f6ee835bab6858 # v3.29.0
uses: github/codeql-action/init@76621b61decf072c1cee8dd1ce2d2a82d33c17ed # v3.29.5
with:
languages: go, javascript
@@ -48,7 +50,7 @@ jobs:
rm Makefile
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@ce28f5bb42b7a9f2c824e633a3f6ee835bab6858 # v3.29.0
uses: github/codeql-action/analyze@76621b61decf072c1cee8dd1ce2d2a82d33c17ed # v3.29.5
- name: Send Slack notification on failure
if: ${{ failure() }}
@@ -67,14 +69,15 @@ jobs:
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
fetch-depth: 0
persist-credentials: false
- name: Setup Go
uses: ./.github/actions/setup-go
@@ -134,15 +137,16 @@ jobs:
# This environment variables forces scripts/build_docker.sh to build
# the base image tag locally instead of using the cached version from
# the registry.
export CODER_IMAGE_BUILD_BASE_TAG="$(CODER_IMAGE_BASE=coder-base ./scripts/image_tag.sh --version "$version")"
CODER_IMAGE_BUILD_BASE_TAG="$(CODER_IMAGE_BASE=coder-base ./scripts/image_tag.sh --version "$version")"
export CODER_IMAGE_BUILD_BASE_TAG
# We would like to use make -j here, but it doesn't work with the some recent additions
# to our code generation.
make "$image_job"
echo "image=$(cat "$image_job")" >> $GITHUB_OUTPUT
echo "image=$(cat "$image_job")" >> "$GITHUB_OUTPUT"
- name: Run Trivy vulnerability scanner
uses: aquasecurity/trivy-action@76071ef0d7ec797419534a183b498b4d6366cf37
uses: aquasecurity/trivy-action@dc5a429b52fcf669ce959baa2c2dd26090d2a6c4
with:
image-ref: ${{ steps.build.outputs.image }}
format: sarif
@@ -150,7 +154,7 @@ jobs:
severity: "CRITICAL,HIGH"
- name: Upload Trivy scan results to GitHub Security tab
uses: github/codeql-action/upload-sarif@ce28f5bb42b7a9f2c824e633a3f6ee835bab6858 # v3.29.0
uses: github/codeql-action/upload-sarif@76621b61decf072c1cee8dd1ce2d2a82d33c17ed # v3.29.5
with:
sarif_file: trivy-results.sarif
category: "Trivy"
+6 -4
View File
@@ -18,7 +18,7 @@ jobs:
pull-requests: write
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
@@ -96,12 +96,14 @@ jobs:
contents: write
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
persist-credentials: false
- name: Run delete-old-branches-action
uses: beatlabs/delete-old-branches-action@4eeeb8740ff8b3cb310296ddd6b43c3387734588 # v0.0.11
with:
@@ -118,7 +120,7 @@ jobs:
actions: write
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
+1 -1
View File
@@ -19,7 +19,7 @@ jobs:
timeout-minutes: 5
steps:
- name: Start Coder workspace
uses: coder/start-workspace-action@35a4608cefc7e8cc56573cae7c3b85304575cb72
uses: coder/start-workspace-action@f97a681b4cc7985c9eef9963750c7cc6ebc93a19
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
github-username: >-
+2 -1
View File
@@ -28,6 +28,7 @@ HELO = "HELO"
LKE = "LKE"
byt = "byt"
typ = "typ"
Inferrable = "Inferrable"
[files]
extend-exclude = [
@@ -47,5 +48,5 @@ extend-exclude = [
"provisioner/terraform/testdata/**",
# notifications' golden files confuse the detector because of quoted-printable encoding
"coderd/notifications/testdata/**",
"agent/agentcontainers/testdata/devcontainercli/**"
"agent/agentcontainers/testdata/devcontainercli/**",
]
+9 -4
View File
@@ -21,15 +21,17 @@ jobs:
pull-requests: write # required to post PR review comments by the action
steps:
- name: Harden Runner
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
with:
persist-credentials: false
- name: Check Markdown links
uses: umbrelladocs/action-linkspector@e2ccef58c4b9eb89cd71ee23a8629744bba75aa6 # v1.3.5
uses: umbrelladocs/action-linkspector@874d01cae9fd488e3077b08952093235bd626977 # v1.3.7
id: markdown-link-check
# checks all markdown files from /docs including all subfolders
with:
@@ -41,7 +43,10 @@ jobs:
- name: Send Slack notification
if: failure() && github.event_name == 'schedule'
run: |
curl -X POST -H 'Content-type: application/json' -d '{"msg":"Broken links found in the documentation. Please check the logs at ${{ env.LOGS_URL }}"}' ${{ secrets.DOCS_LINK_SLACK_WEBHOOK }}
curl \
-X POST \
-H 'Content-type: application/json' \
-d '{"msg":"Broken links found in the documentation. Please check the logs at '"${LOGS_URL}"'"}' "${{ secrets.DOCS_LINK_SLACK_WEBHOOK }}"
echo "Sent Slack notification"
env:
LOGS_URL: https://github.com/coder/coder/actions/runs/${{ github.run_id }}
-1
View File
@@ -181,7 +181,6 @@ linters-settings:
issues:
exclude-dirs:
- coderd/database/dbmem
- node_modules
- .git
+36
View File
@@ -0,0 +1,36 @@
{
"mcpServers": {
"go-language-server": {
"type": "stdio",
"command": "go",
"args": [
"run",
"github.com/isaacphi/mcp-language-server@latest",
"-workspace",
"./",
"-lsp",
"go",
"--",
"run",
"golang.org/x/tools/gopls@latest"
],
"env": {}
},
"typescript-language-server": {
"type": "stdio",
"command": "go",
"args": [
"run",
"github.com/isaacphi/mcp-language-server@latest",
"-workspace",
"./site/",
"-lsp",
"pnpx",
"--",
"typescript-language-server",
"--stdio"
],
"env": {}
}
}
}
+1 -1
View File
@@ -49,7 +49,7 @@
"[javascript][javascriptreact][json][jsonc][typescript][typescriptreact]": {
"editor.defaultFormatter": "biomejs.biome",
"editor.codeActionsOnSave": {
"quickfix.biome": "explicit"
"source.fixAll.biome": "explicit"
// "source.organizeImports.biome": "explicit"
}
},
Symlink
+1
View File
@@ -0,0 +1 @@
CLAUDE.md
+99 -67
View File
@@ -1,21 +1,25 @@
# Coder Development Guidelines
Read [cursor rules](.cursorrules).
@.claude/docs/WORKFLOWS.md
@.cursorrules
@README.md
@package.json
## Build/Test/Lint Commands
## 🚀 Essential Commands
### Main Commands
- `make build` or `make build-fat` - Build all "fat" binaries (includes "server" functionality)
- `make build-slim` - Build "slim" binaries
- `make test` - Run Go tests
- `make test RUN=TestFunctionName` or `go test -v ./path/to/package -run TestFunctionName` - Test single
- `make test-postgres` - Run tests with Postgres database
- `make test-race` - Run tests with Go race detector
- `make test-e2e` - Run end-to-end tests
- `make lint` - Run all linters
- `make fmt` - Format all code
- `make gen` - Generates mocks, database queries and other auto-generated files
| Task | Command | Notes |
|-------------------|--------------------------|----------------------------------|
| **Development** | `./scripts/develop.sh` | ⚠️ Don't use manual build |
| **Build** | `make build` | Fat binaries (includes server) |
| **Build Slim** | `make build-slim` | Slim binaries |
| **Test** | `make test` | Full test suite |
| **Test Single** | `make test RUN=TestName` | Faster than full suite |
| **Test Postgres** | `make test-postgres` | Run tests with Postgres database |
| **Test Race** | `make test-race` | Run tests with Go race detector |
| **Lint** | `make lint` | Always run after changes |
| **Generate** | `make gen` | After database changes |
| **Format** | `make fmt` | Auto-format code |
| **Clean** | `make clean` | Clean build artifacts |
### Frontend Commands (site directory)
@@ -26,81 +30,109 @@ Read [cursor rules](.cursorrules).
- `pnpm lint` - Lint frontend code
- `pnpm test` - Run frontend tests
## Code Style Guidelines
### Documentation Commands
### Go
- `pnpm run format-docs` - Format markdown tables in docs
- `pnpm run lint-docs` - Lint and fix markdown files
- `pnpm run storybook` - Run Storybook (from site directory)
- Follow [Effective Go](https://go.dev/doc/effective_go) and [Go's Code Review Comments](https://github.com/golang/go/wiki/CodeReviewComments)
- Use `gofumpt` for formatting
- Create packages when used during implementation
- Validate abstractions against implementations
## 🔧 Critical Patterns
### Error Handling
### Database Changes (ALWAYS FOLLOW)
- Use descriptive error messages
- Wrap errors with context
- Propagate errors appropriately
- Use proper error types
- (`xerrors.Errorf("failed to X: %w", err)`)
1. Modify `coderd/database/queries/*.sql` files
2. Run `make gen`
3. If audit errors: update `enterprise/audit/table.go`
4. Run `make gen` again
### Naming
### LSP Navigation (USE FIRST)
- Use clear, descriptive names
- Abbreviate only when obvious
- Follow Go and TypeScript naming conventions
#### Go LSP (for backend code)
### Comments
- **Find definitions**: `mcp__go-language-server__definition symbolName`
- **Find references**: `mcp__go-language-server__references symbolName`
- **Get type info**: `mcp__go-language-server__hover filePath line column`
- **Rename symbol**: `mcp__go-language-server__rename_symbol filePath line column newName`
- Document exported functions, types, and non-obvious logic
- Follow JSDoc format for TypeScript
- Use godoc format for Go code
#### TypeScript LSP (for frontend code in site/)
## Commit Style
- **Find definitions**: `mcp__typescript-language-server__definition symbolName`
- **Find references**: `mcp__typescript-language-server__references symbolName`
- **Get type info**: `mcp__typescript-language-server__hover filePath line column`
- **Rename symbol**: `mcp__typescript-language-server__rename_symbol filePath line column newName`
- Follow [Conventional Commits 1.0.0](https://www.conventionalcommits.org/en/v1.0.0/)
- Format: `type(scope): message`
- Types: `feat`, `fix`, `docs`, `style`, `refactor`, `test`, `chore`
- Keep message titles concise (~70 characters)
- Use imperative, present tense in commit titles
### OAuth2 Error Handling
## Database queries
```go
// OAuth2-compliant error responses
writeOAuth2Error(ctx, rw, http.StatusBadRequest, "invalid_grant", "description")
```
- MUST DO! Any changes to database - adding queries, modifying queries should be done in the `coderd\database\queries\*.sql` files. Use `make gen` to generate necessary changes after.
- MUST DO! Queries are grouped in files relating to context - e.g. `prebuilds.sql`, `users.sql`, `provisionerjobs.sql`.
- After making changes to any `coderd\database\queries\*.sql` files you must run `make gen` to generate respective ORM changes.
### Authorization Context
## Architecture
```go
// Public endpoints needing system access
app, err := api.Database.GetOAuth2ProviderAppByClientID(dbauthz.AsSystemRestricted(ctx), clientID)
### Core Components
// Authenticated endpoints with user context
app, err := api.Database.GetOAuth2ProviderAppByClientID(ctx, clientID)
```
- **coderd**: Main API service connecting workspaces, provisioners, and users
- **provisionerd**: Execution context for infrastructure-modifying providers
- **Agents**: Services in remote workspaces providing features like SSH and port forwarding
- **Workspaces**: Cloud resources defined by Terraform
## 📋 Quick Reference
## Sub-modules
### Full workflows available in imported WORKFLOWS.md
### Template System
### New Feature Checklist
- Templates define infrastructure for workspaces using Terraform
- Environment variables pass context between Coder and templates
- Official modules extend development environments
- [ ] Run `git pull` to ensure latest code
- [ ] Check if feature touches database - you'll need migrations
- [ ] Check if feature touches audit logs - update `enterprise/audit/table.go`
### RBAC System
## 🏗️ Architecture
- Permissions defined at site, organization, and user levels
- Object-Action model protects resources
- Built-in roles: owner, member, auditor, templateAdmin
- Permission format: `<sign>?<level>.<object>.<id>.<action>`
- **coderd**: Main API service
- **provisionerd**: Infrastructure provisioning
- **Agents**: Workspace services (SSH, port forwarding)
- **Database**: PostgreSQL with `dbauthz` authorization
### Database
## 🧪 Testing
- PostgreSQL 13+ recommended for production
- Migrations managed with `migrate`
- Database authorization through `dbauthz` package
### Race Condition Prevention
## Frontend
- Use unique identifiers: `fmt.Sprintf("test-client-%s-%d", t.Name(), time.Now().UnixNano())`
- Never use hardcoded names in concurrent tests
The frontend is contained in the site folder.
### OAuth2 Testing
For building Frontend refer to [this document](docs/about/contributing/frontend.md)
- Full suite: `./scripts/oauth2/test-mcp-oauth2.sh`
- Manual testing: `./scripts/oauth2/test-manual-flow.sh`
### Timing Issues
NEVER use `time.Sleep` to mitigate timing issues. If an issue
seems like it should use `time.Sleep`, read through https://github.com/coder/quartz and specifically the [README](https://github.com/coder/quartz/blob/main/README.md) to better understand how to handle timing issues.
## 🎯 Code Style
### Detailed guidelines in imported WORKFLOWS.md
- Follow [Uber Go Style Guide](https://github.com/uber-go/guide/blob/master/style.md)
- Commit format: `type(scope): message`
## 📚 Detailed Development Guides
@.claude/docs/OAUTH2.md
@.claude/docs/TESTING.md
@.claude/docs/TROUBLESHOOTING.md
@.claude/docs/DATABASE.md
## 🚨 Common Pitfalls
1. **Audit table errors** → Update `enterprise/audit/table.go`
2. **OAuth2 errors** → Return RFC-compliant format
3. **Race conditions** → Use unique test identifiers
4. **Missing newlines** → Ensure files end with newline
---
*This file stays lean and actionable. Detailed workflows and explanations are imported automatically.*
+37 -4
View File
@@ -1,8 +1,41 @@
# These APIs are versioned, so any changes need to be carefully reviewed for whether
# to bump API major or minor versions.
# These APIs are versioned, so any changes need to be carefully reviewed for
# whether to bump API major or minor versions.
agent/proto/ @spikecurtis @johnstcn
provisionerd/proto/ @spikecurtis @johnstcn
provisionersdk/proto/ @spikecurtis @johnstcn
tailnet/proto/ @spikecurtis @johnstcn
vpn/vpn.proto @spikecurtis @johnstcn
vpn/version.go @spikecurtis @johnstcn
provisionerd/proto/ @spikecurtis @johnstcn
provisionersdk/proto/ @spikecurtis @johnstcn
# This caching code is particularly tricky, and one must be very careful when
# altering it.
coderd/files/ @aslilac
coderd/dynamicparameters/ @Emyrk
coderd/rbac/ @Emyrk
# Mainly dependent on coder/guts, which is maintained by @Emyrk
scripts/apitypings/ @Emyrk
scripts/gensite/ @aslilac
site/ @aslilac @Parkreiner
site/src/hooks/ @Parkreiner
# These rules intentionally do not specify any owners. More specific rules
# override less specific rules, so these files are "ignored" by the site/ rule.
site/e2e/google/protobuf/timestampGenerated.ts
site/e2e/provisionerGenerated.ts
site/src/api/countriesGenerated.ts
site/src/api/rbacresourcesGenerated.ts
site/src/api/typesGenerated.ts
site/src/testHelpers/entities.ts
site/CLAUDE.md
# The blood and guts of the autostop algorithm, which is quite complex and
# requires elite ball knowledge of most of the scheduling code to make changes
# without inadvertently affecting other parts of the codebase.
coderd/schedule/autostop.go @deansheather @DanielleMaywood
# Usage tracking code requires intimate knowledge of Tallyman and Metronome, as
# well as guidance from revenue.
coderd/usage/ @deansheather @spikecurtis
enterprise/coderd/usage/ @deansheather @spikecurtis
+97 -8
View File
@@ -460,16 +460,31 @@ fmt: fmt/ts fmt/go fmt/terraform fmt/shfmt fmt/biome fmt/markdown
.PHONY: fmt
fmt/go:
ifdef FILE
# Format single file
if [[ -f "$(FILE)" ]] && [[ "$(FILE)" == *.go ]] && ! grep -q "DO NOT EDIT" "$(FILE)"; then \
echo "$(GREEN)==>$(RESET) $(BOLD)fmt/go$(RESET) $(FILE)"; \
go run mvdan.cc/gofumpt@v0.8.0 -w -l "$(FILE)"; \
fi
else
go mod tidy
echo "$(GREEN)==>$(RESET) $(BOLD)fmt/go$(RESET)"
# VS Code users should check out
# https://github.com/mvdan/gofumpt#visual-studio-code
find . $(FIND_EXCLUSIONS) -type f -name '*.go' -print0 | \
xargs -0 grep --null -L "DO NOT EDIT" | \
xargs -0 go run mvdan.cc/gofumpt@v0.4.0 -w -l
xargs -0 grep -E --null -L '^// Code generated .* DO NOT EDIT\.$$' | \
xargs -0 go run mvdan.cc/gofumpt@v0.8.0 -w -l
endif
.PHONY: fmt/go
fmt/ts: site/node_modules/.installed
ifdef FILE
# Format single TypeScript/JavaScript file
if [[ -f "$(FILE)" ]] && [[ "$(FILE)" == *.ts ]] || [[ "$(FILE)" == *.tsx ]] || [[ "$(FILE)" == *.js ]] || [[ "$(FILE)" == *.jsx ]]; then \
echo "$(GREEN)==>$(RESET) $(BOLD)fmt/ts$(RESET) $(FILE)"; \
(cd site/ && pnpm exec biome format --write "../$(FILE)"); \
fi
else
echo "$(GREEN)==>$(RESET) $(BOLD)fmt/ts$(RESET)"
cd site
# Avoid writing files in CI to reduce file write activity
@@ -478,9 +493,17 @@ ifdef CI
else
pnpm run check:fix
endif
endif
.PHONY: fmt/ts
fmt/biome: site/node_modules/.installed
ifdef FILE
# Format single file with biome
if [[ -f "$(FILE)" ]] && [[ "$(FILE)" == *.ts ]] || [[ "$(FILE)" == *.tsx ]] || [[ "$(FILE)" == *.js ]] || [[ "$(FILE)" == *.jsx ]]; then \
echo "$(GREEN)==>$(RESET) $(BOLD)fmt/biome$(RESET) $(FILE)"; \
(cd site/ && pnpm exec biome format --write "../$(FILE)"); \
fi
else
echo "$(GREEN)==>$(RESET) $(BOLD)fmt/biome$(RESET)"
cd site/
# Avoid writing files in CI to reduce file write activity
@@ -489,14 +512,30 @@ ifdef CI
else
pnpm run format
endif
endif
.PHONY: fmt/biome
fmt/terraform: $(wildcard *.tf)
ifdef FILE
# Format single Terraform file
if [[ -f "$(FILE)" ]] && [[ "$(FILE)" == *.tf ]] || [[ "$(FILE)" == *.tfvars ]]; then \
echo "$(GREEN)==>$(RESET) $(BOLD)fmt/terraform$(RESET) $(FILE)"; \
terraform fmt "$(FILE)"; \
fi
else
echo "$(GREEN)==>$(RESET) $(BOLD)fmt/terraform$(RESET)"
terraform fmt -recursive
endif
.PHONY: fmt/terraform
fmt/shfmt: $(SHELL_SRC_FILES)
ifdef FILE
# Format single shell script
if [[ -f "$(FILE)" ]] && [[ "$(FILE)" == *.sh ]]; then \
echo "$(GREEN)==>$(RESET) $(BOLD)fmt/shfmt$(RESET) $(FILE)"; \
shfmt -w "$(FILE)"; \
fi
else
echo "$(GREEN)==>$(RESET) $(BOLD)fmt/shfmt$(RESET)"
# Only do diff check in CI, errors on diff.
ifdef CI
@@ -504,14 +543,25 @@ ifdef CI
else
shfmt -w $(SHELL_SRC_FILES)
endif
endif
.PHONY: fmt/shfmt
fmt/markdown: node_modules/.installed
ifdef FILE
# Format single markdown file
if [[ -f "$(FILE)" ]] && [[ "$(FILE)" == *.md ]]; then \
echo "$(GREEN)==>$(RESET) $(BOLD)fmt/markdown$(RESET) $(FILE)"; \
pnpm exec markdown-table-formatter "$(FILE)"; \
fi
else
echo "$(GREEN)==>$(RESET) $(BOLD)fmt/markdown$(RESET)"
pnpm format-docs
endif
.PHONY: fmt/markdown
lint: lint/shellcheck lint/go lint/ts lint/examples lint/helm lint/site-icons lint/markdown
# Note: we don't run zizmor in the lint target because it takes a while. CI
# runs it explicitly.
lint: lint/shellcheck lint/go lint/ts lint/examples lint/helm lint/site-icons lint/markdown lint/actions/actionlint
.PHONY: lint
lint/site-icons:
@@ -528,6 +578,7 @@ lint/go:
./scripts/check_codersdk_imports.sh
linter_ver=$(shell egrep -o 'GOLANGCI_LINT_VERSION=\S+' dogfood/coder/Dockerfile | cut -d '=' -f 2)
go run github.com/golangci/golangci-lint/cmd/golangci-lint@v$$linter_ver run
go run github.com/coder/paralleltestctx/cmd/paralleltestctx@v0.0.1 -custom-funcs="testutil.Context" ./...
.PHONY: lint/go
lint/examples:
@@ -549,13 +600,26 @@ lint/markdown: node_modules/.installed
pnpm lint-docs
.PHONY: lint/markdown
lint/actions: lint/actions/actionlint lint/actions/zizmor
.PHONY: lint/actions
lint/actions/actionlint:
go run github.com/rhysd/actionlint/cmd/actionlint@v1.7.7
.PHONY: lint/actions/actionlint
lint/actions/zizmor:
./scripts/zizmor.sh \
--strict-collection \
--persona=regular \
.
.PHONY: lint/actions/zizmor
# All files generated by the database should be added here, and this can be used
# as a target for jobs that need to run after the database is generated.
DB_GEN_FILES := \
coderd/database/dump.sql \
coderd/database/querier.go \
coderd/database/unique_constraint.go \
coderd/database/dbmem/dbmem.go \
coderd/database/dbmetrics/dbmetrics.go \
coderd/database/dbauthz/dbauthz.go \
coderd/database/dbmock/dbmock.go
@@ -588,7 +652,8 @@ GEN_FILES := \
coderd/database/pubsub/psmock/psmock.go \
agent/agentcontainers/acmock/acmock.go \
agent/agentcontainers/dcspec/dcspec_gen.go \
coderd/httpmw/loggermw/loggermock/loggermock.go
coderd/httpmw/loggermw/loggermock/loggermock.go \
codersdk/workspacesdk/agentconnmock/agentconnmock.go
# all gen targets should be added here and to gen/mark-fresh
gen: gen/db gen/golden-files $(GEN_FILES)
@@ -638,6 +703,7 @@ gen/mark-fresh:
agent/agentcontainers/acmock/acmock.go \
agent/agentcontainers/dcspec/dcspec_gen.go \
coderd/httpmw/loggermw/loggermock/loggermock.go \
codersdk/workspacesdk/agentconnmock/agentconnmock.go \
"
for file in $$files; do
@@ -681,6 +747,10 @@ coderd/httpmw/loggermw/loggermock/loggermock.go: coderd/httpmw/loggermw/logger.g
go generate ./coderd/httpmw/loggermw/loggermock/
touch "$@"
codersdk/workspacesdk/agentconnmock/agentconnmock.go: codersdk/workspacesdk/agentconn.go
go generate ./codersdk/workspacesdk/agentconnmock/
touch "$@"
agent/agentcontainers/dcspec/dcspec_gen.go: \
node_modules/.installed \
agent/agentcontainers/dcspec/devContainer.base.schema.json \
@@ -888,12 +958,31 @@ else
GOTESTSUM_RETRY_FLAGS :=
endif
# default to 8x8 parallelism to avoid overwhelming our workspaces. Hopefully we can remove these defaults
# when we get our test suite's resource utilization under control.
GOTEST_FLAGS := -v -p $(or $(TEST_NUM_PARALLEL_PACKAGES),"8") -parallel=$(or $(TEST_NUM_PARALLEL_TESTS),"8")
# The most common use is to set TEST_COUNT=1 to avoid Go's test cache.
ifdef TEST_COUNT
GOTEST_FLAGS += -count=$(TEST_COUNT)
endif
ifdef TEST_SHORT
GOTEST_FLAGS += -short
endif
ifdef RUN
GOTEST_FLAGS += -run $(RUN)
endif
TEST_PACKAGES ?= ./...
test:
$(GIT_FLAGS) gotestsum --format standard-quiet $(GOTESTSUM_RETRY_FLAGS) --packages="./..." -- -v -short -count=1 $(if $(RUN),-run $(RUN))
$(GIT_FLAGS) gotestsum --format standard-quiet $(GOTESTSUM_RETRY_FLAGS) --packages="$(TEST_PACKAGES)" -- $(GOTEST_FLAGS)
.PHONY: test
test-cli:
$(GIT_FLAGS) gotestsum --format standard-quiet $(GOTESTSUM_RETRY_FLAGS) --packages="./cli/..." -- -v -short -count=1
$(MAKE) test TEST_PACKAGES="./cli..."
.PHONY: test-cli
# sqlc-cloud-is-setup will fail if no SQLc auth token is set. Use this as a
@@ -929,7 +1018,7 @@ sqlc-vet: test-postgres-docker
test-postgres: test-postgres-docker
# The postgres test is prone to failure, so we limit parallelism for
# more consistent execution.
$(GIT_FLAGS) DB=ci gotestsum \
$(GIT_FLAGS) gotestsum \
--junitfile="gotests.xml" \
--jsonfile="gotests.json" \
$(GOTESTSUM_RETRY_FLAGS) \
+30 -24
View File
@@ -98,7 +98,7 @@ type Client interface {
ConnectRPC26(ctx context.Context) (
proto.DRPCAgentClient26, tailnetproto.DRPCTailnetClient26, error,
)
RewriteDERPMap(derpMap *tailcfg.DERPMap)
tailnet.DERPMapRewriter
}
type Agent interface {
@@ -336,18 +336,16 @@ func (a *agent) init() {
// will not report anywhere.
a.scriptRunner.RegisterMetrics(a.prometheusRegistry)
if a.devcontainers {
containerAPIOpts := []agentcontainers.Option{
agentcontainers.WithExecer(a.execer),
agentcontainers.WithCommandEnv(a.sshServer.CommandEnv),
agentcontainers.WithScriptLogger(func(logSourceID uuid.UUID) agentcontainers.ScriptLogger {
return a.logSender.GetScriptLogger(logSourceID)
}),
}
containerAPIOpts = append(containerAPIOpts, a.containerAPIOptions...)
a.containerAPI = agentcontainers.NewAPI(a.logger.Named("containers"), containerAPIOpts...)
containerAPIOpts := []agentcontainers.Option{
agentcontainers.WithExecer(a.execer),
agentcontainers.WithCommandEnv(a.sshServer.CommandEnv),
agentcontainers.WithScriptLogger(func(logSourceID uuid.UUID) agentcontainers.ScriptLogger {
return a.logSender.GetScriptLogger(logSourceID)
}),
}
containerAPIOpts = append(containerAPIOpts, a.containerAPIOptions...)
a.containerAPI = agentcontainers.NewAPI(a.logger.Named("containers"), containerAPIOpts...)
a.reconnectingPTYServer = reconnectingpty.NewServer(
a.logger.Named("reconnecting-pty"),
@@ -565,7 +563,6 @@ func (a *agent) reportMetadata(ctx context.Context, aAPI proto.DRPCAgentClient26
// channel to synchronize the results and avoid both messy
// mutex logic and overloading the API.
for _, md := range manifest.Metadata {
md := md
// We send the result to the channel in the goroutine to avoid
// sending the same result multiple times. So, we don't care about
// the return values.
@@ -793,11 +790,15 @@ func (a *agent) reportConnectionsLoop(ctx context.Context, aAPI proto.DRPCAgentC
logger.Debug(ctx, "reporting connection")
_, err := aAPI.ReportConnection(ctx, payload)
if err != nil {
return xerrors.Errorf("failed to report connection: %w", err)
// Do not fail the loop if we fail to report a connection, just
// log a warning.
// Related to https://github.com/coder/coder/issues/20194
logger.Warn(ctx, "failed to report connection to server", slog.Error(err))
// no continue here, we still need to remove it from the slice
} else {
logger.Debug(ctx, "successfully reported connection")
}
logger.Debug(ctx, "successfully reported connection")
// Remove the payload we sent.
a.reportConnectionsMu.Lock()
a.reportConnections[0] = nil // Release the pointer from the underlying array.
@@ -828,6 +829,13 @@ func (a *agent) reportConnection(id uuid.UUID, connectionType proto.Connection_T
ip = host
}
// If the IP is "localhost" (which it can be in some cases), set it to
// 127.0.0.1 instead.
// Related to https://github.com/coder/coder/issues/20194
if ip == "localhost" {
ip = "127.0.0.1"
}
a.reportConnectionsMu.Lock()
defer a.reportConnectionsMu.Unlock()
@@ -1089,7 +1097,7 @@ func (a *agent) handleManifest(manifestOK *checkpoint) func(ctx context.Context,
if err != nil {
return xerrors.Errorf("fetch metadata: %w", err)
}
a.logger.Info(ctx, "fetched manifest", slog.F("manifest", mp))
a.logger.Info(ctx, "fetched manifest")
manifest, err := agentsdk.ManifestFromProto(mp)
if err != nil {
a.logger.Critical(ctx, "failed to convert manifest", slog.F("manifest", mp), slog.Error(err))
@@ -1163,7 +1171,7 @@ func (a *agent) handleManifest(manifestOK *checkpoint) func(ctx context.Context,
scripts = manifest.Scripts
devcontainerScripts map[uuid.UUID]codersdk.WorkspaceAgentScript
)
if a.containerAPI != nil {
if a.devcontainers {
// Init the container API with the manifest and client so that
// we can start accepting requests. The final start of the API
// happens after the startup scripts have been executed to
@@ -1171,7 +1179,7 @@ func (a *agent) handleManifest(manifestOK *checkpoint) func(ctx context.Context,
// return existing devcontainers but actual container detection
// and creation will be deferred.
a.containerAPI.Init(
agentcontainers.WithManifestInfo(manifest.OwnerName, manifest.WorkspaceName, manifest.AgentName),
agentcontainers.WithManifestInfo(manifest.OwnerName, manifest.WorkspaceName, manifest.AgentName, manifest.Directory),
agentcontainers.WithDevcontainers(manifest.Devcontainers, manifest.Scripts),
agentcontainers.WithSubAgentClient(agentcontainers.NewSubAgentClientFromAPI(a.logger, aAPI)),
)
@@ -1198,7 +1206,7 @@ func (a *agent) handleManifest(manifestOK *checkpoint) func(ctx context.Context,
// autostarted devcontainer will be included in this time.
err := a.scriptRunner.Execute(a.gracefulCtx, agentscripts.ExecuteStartScripts)
if a.containerAPI != nil {
if a.devcontainers {
// Start the container API after the startup scripts have
// been executed to ensure that the required tools can be
// installed.
@@ -1929,10 +1937,8 @@ func (a *agent) Close() error {
a.logger.Error(a.hardCtx, "script runner close", slog.Error(err))
}
if a.containerAPI != nil {
if err := a.containerAPI.Close(); err != nil {
a.logger.Error(a.hardCtx, "container API close", slog.Error(err))
}
if err := a.containerAPI.Close(); err != nil {
a.logger.Error(a.hardCtx, "container API close", slog.Error(err))
}
// Wait for the graceful shutdown to complete, but don't wait forever so
+297 -72
View File
@@ -456,8 +456,6 @@ func TestAgent_GitSSH(t *testing.T) {
func TestAgent_SessionTTYShell(t *testing.T) {
t.Parallel()
ctx, cancel := context.WithTimeout(context.Background(), testutil.WaitLong)
t.Cleanup(cancel)
if runtime.GOOS == "windows" {
// This might be our implementation, or ConPTY itself.
// It's difficult to find extensive tests for it, so
@@ -468,6 +466,7 @@ func TestAgent_SessionTTYShell(t *testing.T) {
for _, port := range sshPorts {
t.Run(fmt.Sprintf("(%d)", port), func(t *testing.T) {
t.Parallel()
ctx := testutil.Context(t, testutil.WaitShort)
session := setupSSHSessionOnPort(t, agentsdk.Manifest{}, codersdk.ServiceBannerConfig{}, nil, port)
command := "sh"
@@ -2130,7 +2129,7 @@ func TestAgent_DevcontainerAutostart(t *testing.T) {
"name": "mywork",
"image": "ubuntu:latest",
"cmd": ["sleep", "infinity"],
"runArgs": ["--network=host"]
"runArgs": ["--network=host", "--label=`+agentcontainers.DevcontainerIsTestRunLabel+`=true"]
}`), 0o600)
require.NoError(t, err, "write devcontainer.json")
@@ -2167,6 +2166,7 @@ func TestAgent_DevcontainerAutostart(t *testing.T) {
// Only match this specific dev container.
agentcontainers.WithClock(mClock),
agentcontainers.WithContainerLabelIncludeFilter("devcontainer.local_folder", tempWorkspaceFolder),
agentcontainers.WithContainerLabelIncludeFilter(agentcontainers.DevcontainerIsTestRunLabel, "true"),
agentcontainers.WithSubAgentURL(srv.URL),
// The agent will copy "itself", but in the case of this test, the
// agent is actually this test binary. So we'll tell the test binary
@@ -2288,7 +2288,8 @@ func TestAgent_DevcontainerRecreate(t *testing.T) {
err = os.WriteFile(devcontainerFile, []byte(`{
"name": "mywork",
"image": "busybox:latest",
"cmd": ["sleep", "infinity"]
"cmd": ["sleep", "infinity"],
"runArgs": ["--label=`+agentcontainers.DevcontainerIsTestRunLabel+`=true"]
}`), 0o600)
require.NoError(t, err, "write devcontainer.json")
@@ -2315,6 +2316,7 @@ func TestAgent_DevcontainerRecreate(t *testing.T) {
o.Devcontainers = true
o.DevcontainerAPIOptions = append(o.DevcontainerAPIOptions,
agentcontainers.WithContainerLabelIncludeFilter("devcontainer.local_folder", workspaceFolder),
agentcontainers.WithContainerLabelIncludeFilter(agentcontainers.DevcontainerIsTestRunLabel, "true"),
)
})
@@ -2369,7 +2371,7 @@ func TestAgent_DevcontainerRecreate(t *testing.T) {
// devcontainer, we do it in a goroutine so we can process logs
// concurrently.
go func(container codersdk.WorkspaceAgentContainer) {
_, err := conn.RecreateDevcontainer(ctx, container.ID)
_, err := conn.RecreateDevcontainer(ctx, devcontainerID.String())
assert.NoError(t, err, "recreate devcontainer should succeed")
}(container)
@@ -2438,7 +2440,8 @@ func TestAgent_DevcontainersDisabledForSubAgent(t *testing.T) {
// Setup the agent with devcontainers enabled initially.
//nolint:dogsled
conn, _, _, _, _ := setupAgent(t, manifest, 0, func(*agenttest.Client, *agent.Options) {
conn, _, _, _, _ := setupAgent(t, manifest, 0, func(_ *agenttest.Client, o *agent.Options) {
o.Devcontainers = true
})
// Query the containers API endpoint. This should fail because
@@ -2450,8 +2453,214 @@ func TestAgent_DevcontainersDisabledForSubAgent(t *testing.T) {
require.Error(t, err)
// Verify the error message contains the expected text.
require.Contains(t, err.Error(), "The agent dev containers feature is experimental and not enabled by default.")
require.Contains(t, err.Error(), "To enable this feature, set CODER_AGENT_DEVCONTAINERS_ENABLE=true in your template.")
require.Contains(t, err.Error(), "Dev Container feature not supported.")
require.Contains(t, err.Error(), "Dev Container integration inside other Dev Containers is explicitly not supported.")
}
// TestAgent_DevcontainerPrebuildClaim tests that we correctly handle
// the claiming process for running devcontainers.
//
// You can run it manually as follows:
//
// CODER_TEST_USE_DOCKER=1 go test -count=1 ./agent -run TestAgent_DevcontainerPrebuildClaim
//
//nolint:paralleltest // This test sets an environment variable.
func TestAgent_DevcontainerPrebuildClaim(t *testing.T) {
if os.Getenv("CODER_TEST_USE_DOCKER") != "1" {
t.Skip("Set CODER_TEST_USE_DOCKER=1 to run this test")
}
if _, err := exec.LookPath("devcontainer"); err != nil {
t.Skip("This test requires the devcontainer CLI: npm install -g @devcontainers/cli")
}
pool, err := dockertest.NewPool("")
require.NoError(t, err, "Could not connect to docker")
var (
ctx = testutil.Context(t, testutil.WaitShort)
devcontainerID = uuid.New()
devcontainerLogSourceID = uuid.New()
workspaceFolder = filepath.Join(t.TempDir(), "project")
devcontainerPath = filepath.Join(workspaceFolder, ".devcontainer")
devcontainerConfig = filepath.Join(devcontainerPath, "devcontainer.json")
)
// Given: A devcontainer project.
t.Logf("Workspace folder: %s", workspaceFolder)
err = os.MkdirAll(devcontainerPath, 0o755)
require.NoError(t, err, "create dev container directory")
// Given: This devcontainer project specifies an app that uses the owner name and workspace name.
err = os.WriteFile(devcontainerConfig, []byte(`{
"name": "project",
"image": "busybox:latest",
"cmd": ["sleep", "infinity"],
"runArgs": ["--label=`+agentcontainers.DevcontainerIsTestRunLabel+`=true"],
"customizations": {
"coder": {
"apps": [{
"slug": "zed",
"url": "zed://ssh/${localEnv:CODER_WORKSPACE_AGENT_NAME}.${localEnv:CODER_WORKSPACE_NAME}.${localEnv:CODER_WORKSPACE_OWNER_NAME}.coder${containerWorkspaceFolder}"
}]
}
}
}`), 0o600)
require.NoError(t, err, "write devcontainer config")
// Given: A manifest with a prebuild username and workspace name.
manifest := agentsdk.Manifest{
OwnerName: "prebuilds",
WorkspaceName: "prebuilds-xyz-123",
Devcontainers: []codersdk.WorkspaceAgentDevcontainer{
{ID: devcontainerID, Name: "test", WorkspaceFolder: workspaceFolder},
},
Scripts: []codersdk.WorkspaceAgentScript{
{ID: devcontainerID, LogSourceID: devcontainerLogSourceID},
},
}
// When: We create an agent with devcontainers enabled.
//nolint:dogsled
conn, client, _, _, _ := setupAgent(t, manifest, 0, func(_ *agenttest.Client, o *agent.Options) {
o.Devcontainers = true
o.DevcontainerAPIOptions = append(o.DevcontainerAPIOptions,
agentcontainers.WithContainerLabelIncludeFilter(agentcontainers.DevcontainerLocalFolderLabel, workspaceFolder),
agentcontainers.WithContainerLabelIncludeFilter(agentcontainers.DevcontainerIsTestRunLabel, "true"),
)
})
testutil.Eventually(ctx, t, func(ctx context.Context) bool {
return slices.Contains(client.GetLifecycleStates(), codersdk.WorkspaceAgentLifecycleReady)
}, testutil.IntervalMedium, "agent not ready")
var dcPrebuild codersdk.WorkspaceAgentDevcontainer
testutil.Eventually(ctx, t, func(ctx context.Context) bool {
resp, err := conn.ListContainers(ctx)
require.NoError(t, err)
for _, dc := range resp.Devcontainers {
if dc.Container == nil {
continue
}
v, ok := dc.Container.Labels[agentcontainers.DevcontainerLocalFolderLabel]
if ok && v == workspaceFolder {
dcPrebuild = dc
return true
}
}
return false
}, testutil.IntervalMedium, "devcontainer not found")
defer func() {
pool.Client.RemoveContainer(docker.RemoveContainerOptions{
ID: dcPrebuild.Container.ID,
RemoveVolumes: true,
Force: true,
})
}()
// Then: We expect a sub agent to have been created.
subAgents := client.GetSubAgents()
require.Len(t, subAgents, 1)
subAgent := subAgents[0]
subAgentID, err := uuid.FromBytes(subAgent.GetId())
require.NoError(t, err)
// And: We expect there to be 1 app.
subAgentApps, err := client.GetSubAgentApps(subAgentID)
require.NoError(t, err)
require.Len(t, subAgentApps, 1)
// And: This app should contain the prebuild workspace name and owner name.
subAgentApp := subAgentApps[0]
require.Equal(t, "zed://ssh/project.prebuilds-xyz-123.prebuilds.coder/workspaces/project", subAgentApp.GetUrl())
// Given: We close the client and connection
client.Close()
conn.Close()
// Given: A new manifest with a regular user owner name and workspace name.
manifest = agentsdk.Manifest{
OwnerName: "user",
WorkspaceName: "user-workspace",
Devcontainers: []codersdk.WorkspaceAgentDevcontainer{
{ID: devcontainerID, Name: "test", WorkspaceFolder: workspaceFolder},
},
Scripts: []codersdk.WorkspaceAgentScript{
{ID: devcontainerID, LogSourceID: devcontainerLogSourceID},
},
}
// When: We create an agent with devcontainers enabled.
//nolint:dogsled
conn, client, _, _, _ = setupAgent(t, manifest, 0, func(_ *agenttest.Client, o *agent.Options) {
o.Devcontainers = true
o.DevcontainerAPIOptions = append(o.DevcontainerAPIOptions,
agentcontainers.WithContainerLabelIncludeFilter(agentcontainers.DevcontainerLocalFolderLabel, workspaceFolder),
agentcontainers.WithContainerLabelIncludeFilter(agentcontainers.DevcontainerIsTestRunLabel, "true"),
)
})
testutil.Eventually(ctx, t, func(ctx context.Context) bool {
return slices.Contains(client.GetLifecycleStates(), codersdk.WorkspaceAgentLifecycleReady)
}, testutil.IntervalMedium, "agent not ready")
var dcClaimed codersdk.WorkspaceAgentDevcontainer
testutil.Eventually(ctx, t, func(ctx context.Context) bool {
resp, err := conn.ListContainers(ctx)
require.NoError(t, err)
for _, dc := range resp.Devcontainers {
if dc.Container == nil {
continue
}
v, ok := dc.Container.Labels[agentcontainers.DevcontainerLocalFolderLabel]
if ok && v == workspaceFolder {
dcClaimed = dc
return true
}
}
return false
}, testutil.IntervalMedium, "devcontainer not found")
defer func() {
if dcClaimed.Container.ID != dcPrebuild.Container.ID {
pool.Client.RemoveContainer(docker.RemoveContainerOptions{
ID: dcClaimed.Container.ID,
RemoveVolumes: true,
Force: true,
})
}
}()
// Then: We expect the claimed devcontainer and prebuild devcontainer
// to be using the same underlying container.
require.Equal(t, dcPrebuild.Container.ID, dcClaimed.Container.ID)
// And: We expect there to be a sub agent created.
subAgents = client.GetSubAgents()
require.Len(t, subAgents, 1)
subAgent = subAgents[0]
subAgentID, err = uuid.FromBytes(subAgent.GetId())
require.NoError(t, err)
// And: We expect there to be an app.
subAgentApps, err = client.GetSubAgentApps(subAgentID)
require.NoError(t, err)
require.Len(t, subAgentApps, 1)
// And: We expect this app to have the user's owner name and workspace name.
subAgentApp = subAgentApps[0]
require.Equal(t, "zed://ssh/project.user-workspace.user.coder/workspaces/project", subAgentApp.GetUrl())
}
func TestAgent_Dial(t *testing.T) {
@@ -2459,11 +2668,11 @@ func TestAgent_Dial(t *testing.T) {
cases := []struct {
name string
setup func(t *testing.T) net.Listener
setup func(t testing.TB) net.Listener
}{
{
name: "TCP",
setup: func(t *testing.T) net.Listener {
setup: func(t testing.TB) net.Listener {
l, err := net.Listen("tcp", "127.0.0.1:0")
require.NoError(t, err, "create TCP listener")
return l
@@ -2471,7 +2680,7 @@ func TestAgent_Dial(t *testing.T) {
},
{
name: "UDP",
setup: func(t *testing.T) net.Listener {
setup: func(t testing.TB) net.Listener {
addr := net.UDPAddr{
IP: net.ParseIP("127.0.0.1"),
Port: 0,
@@ -2489,57 +2698,69 @@ func TestAgent_Dial(t *testing.T) {
// The purpose of this test is to ensure that a client can dial a
// listener in the workspace over tailnet.
l := c.setup(t)
done := make(chan struct{})
defer func() {
l.Close()
<-done
}()
//
// The OS sometimes drops packets if the system can't keep up with
// them. For TCP packets, it's typically fine due to
// retransmissions, but for UDP packets, it can fail this test.
//
// The OS gets involved for the Wireguard traffic (either via DERP
// or direct UDP), and also for the traffic between the agent and
// the listener in the "workspace".
//
// To avoid this, we'll retry this test up to 3 times.
//nolint:gocritic // This test is flaky due to uncontrollable OS packet drops under heavy load.
testutil.RunRetry(t, 3, func(t testing.TB) {
ctx := testutil.Context(t, testutil.WaitLong)
ctx, cancel := context.WithTimeout(context.Background(), testutil.WaitLong)
defer cancel()
l := c.setup(t)
done := make(chan struct{})
defer func() {
l.Close()
<-done
}()
go func() {
defer close(done)
for range 2 {
c, err := l.Accept()
if assert.NoError(t, err, "accept connection") {
testAccept(ctx, t, c)
_ = c.Close()
go func() {
defer close(done)
for range 2 {
c, err := l.Accept()
if assert.NoError(t, err, "accept connection") {
testAccept(ctx, t, c)
_ = c.Close()
}
}
}()
agentID := uuid.UUID{0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 7, 8}
//nolint:dogsled
agentConn, _, _, _, _ := setupAgent(t, agentsdk.Manifest{
AgentID: agentID,
}, 0)
require.True(t, agentConn.AwaitReachable(ctx))
conn, err := agentConn.DialContext(ctx, l.Addr().Network(), l.Addr().String())
require.NoError(t, err)
testDial(ctx, t, conn)
err = conn.Close()
require.NoError(t, err)
// also connect via the CoderServicePrefix, to test that we can reach the agent on this
// IP. This will be required for CoderVPN.
_, rawPort, _ := net.SplitHostPort(l.Addr().String())
port, _ := strconv.ParseUint(rawPort, 10, 16)
ipp := netip.AddrPortFrom(tailnet.CoderServicePrefix.AddrFromUUID(agentID), uint16(port))
switch l.Addr().Network() {
case "tcp":
conn, err = agentConn.TailnetConn().DialContextTCP(ctx, ipp)
case "udp":
conn, err = agentConn.TailnetConn().DialContextUDP(ctx, ipp)
default:
t.Fatalf("unknown network: %s", l.Addr().Network())
}
}()
agentID := uuid.UUID{0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 7, 8}
//nolint:dogsled
agentConn, _, _, _, _ := setupAgent(t, agentsdk.Manifest{
AgentID: agentID,
}, 0)
require.True(t, agentConn.AwaitReachable(ctx))
conn, err := agentConn.DialContext(ctx, l.Addr().Network(), l.Addr().String())
require.NoError(t, err)
testDial(ctx, t, conn)
err = conn.Close()
require.NoError(t, err)
// also connect via the CoderServicePrefix, to test that we can reach the agent on this
// IP. This will be required for CoderVPN.
_, rawPort, _ := net.SplitHostPort(l.Addr().String())
port, _ := strconv.ParseUint(rawPort, 10, 16)
ipp := netip.AddrPortFrom(tailnet.CoderServicePrefix.AddrFromUUID(agentID), uint16(port))
switch l.Addr().Network() {
case "tcp":
conn, err = agentConn.Conn.DialContextTCP(ctx, ipp)
case "udp":
conn, err = agentConn.Conn.DialContextUDP(ctx, ipp)
default:
t.Fatalf("unknown network: %s", l.Addr().Network())
}
require.NoError(t, err)
testDial(ctx, t, conn)
err = conn.Close()
require.NoError(t, err)
require.NoError(t, err)
testDial(ctx, t, conn)
err = conn.Close()
require.NoError(t, err)
})
})
}
}
@@ -2590,7 +2811,7 @@ func TestAgent_UpdatedDERP(t *testing.T) {
})
// Setup a client connection.
newClientConn := func(derpMap *tailcfg.DERPMap, name string) *workspacesdk.AgentConn {
newClientConn := func(derpMap *tailcfg.DERPMap, name string) workspacesdk.AgentConn {
conn, err := tailnet.NewConn(&tailnet.Options{
Addresses: []netip.Prefix{tailnet.TailscaleServicePrefix.RandomPrefix()},
DERPMap: derpMap,
@@ -2670,13 +2891,13 @@ func TestAgent_UpdatedDERP(t *testing.T) {
// Connect from a second client and make sure it uses the new DERP map.
conn2 := newClientConn(newDerpMap, "client2")
require.Equal(t, []int{2}, conn2.DERPMap().RegionIDs())
require.Equal(t, []int{2}, conn2.TailnetConn().DERPMap().RegionIDs())
t.Log("conn2 got the new DERPMap")
// If the first client gets a DERP map update, it should be able to
// reconnect just fine.
conn1.SetDERPMap(newDerpMap)
require.Equal(t, []int{2}, conn1.DERPMap().RegionIDs())
conn1.TailnetConn().SetDERPMap(newDerpMap)
require.Equal(t, []int{2}, conn1.TailnetConn().DERPMap().RegionIDs())
t.Log("set the new DERPMap on conn1")
ctx, cancel := context.WithTimeout(context.Background(), testutil.WaitLong)
defer cancel()
@@ -3042,8 +3263,8 @@ func setupSSHSessionOnPort(
return session
}
func setupAgent(t *testing.T, metadata agentsdk.Manifest, ptyTimeout time.Duration, opts ...func(*agenttest.Client, *agent.Options)) (
*workspacesdk.AgentConn,
func setupAgent(t testing.TB, metadata agentsdk.Manifest, ptyTimeout time.Duration, opts ...func(*agenttest.Client, *agent.Options)) (
workspacesdk.AgentConn,
*agenttest.Client,
<-chan *proto.Stats,
afero.Fs,
@@ -3140,7 +3361,7 @@ func setupAgent(t *testing.T, metadata agentsdk.Manifest, ptyTimeout time.Durati
var dialTestPayload = []byte("dean-was-here123")
func testDial(ctx context.Context, t *testing.T, c net.Conn) {
func testDial(ctx context.Context, t testing.TB, c net.Conn) {
t.Helper()
if deadline, ok := ctx.Deadline(); ok {
@@ -3156,7 +3377,7 @@ func testDial(ctx context.Context, t *testing.T, c net.Conn) {
assertReadPayload(t, c, dialTestPayload)
}
func testAccept(ctx context.Context, t *testing.T, c net.Conn) {
func testAccept(ctx context.Context, t testing.TB, c net.Conn) {
t.Helper()
defer c.Close()
@@ -3173,7 +3394,7 @@ func testAccept(ctx context.Context, t *testing.T, c net.Conn) {
assertWritePayload(t, c, dialTestPayload)
}
func assertReadPayload(t *testing.T, r io.Reader, payload []byte) {
func assertReadPayload(t testing.TB, r io.Reader, payload []byte) {
t.Helper()
b := make([]byte, len(payload)+16)
n, err := r.Read(b)
@@ -3182,11 +3403,11 @@ func assertReadPayload(t *testing.T, r io.Reader, payload []byte) {
assert.Equal(t, payload, b[:n])
}
func assertWritePayload(t *testing.T, w io.Writer, payload []byte) {
func assertWritePayload(t testing.TB, w io.Writer, payload []byte) {
t.Helper()
n, err := w.Write(payload)
assert.NoError(t, err, "write payload")
assert.Equal(t, len(payload), n, "payload length does not match")
assert.Equal(t, len(payload), n, "written payload length does not match")
}
func testSessionOutput(t *testing.T, session *ssh.Session, expected, unexpected []string, expectedRe *regexp.Regexp) {
@@ -3249,7 +3470,11 @@ func TestAgent_Metrics_SSH(t *testing.T) {
registry := prometheus.NewRegistry()
//nolint:dogsled
conn, _, _, _, _ := setupAgent(t, agentsdk.Manifest{}, 0, func(_ *agenttest.Client, o *agent.Options) {
conn, _, _, _, _ := setupAgent(t, agentsdk.Manifest{
// Make sure we always get a DERP connection for
// currently_reachable_peers.
DisableDirectConnections: true,
}, 0, func(_ *agenttest.Client, o *agent.Options) {
o.PrometheusRegistry = registry
})
@@ -3303,7 +3528,7 @@ func TestAgent_Metrics_SSH(t *testing.T) {
{
Name: "coderd_agentstats_currently_reachable_peers",
Type: proto.Stats_Metric_GAUGE,
Value: 0,
Value: 1,
Labels: []*proto.Stats_Metric_Label{
{
Name: "connection_type",
@@ -3314,7 +3539,7 @@ func TestAgent_Metrics_SSH(t *testing.T) {
{
Name: "coderd_agentstats_currently_reachable_peers",
Type: proto.Stats_Metric_GAUGE,
Value: 1,
Value: 0,
Labels: []*proto.Stats_Metric_Label{
{
Name: "connection_type",
+351 -16
View File
@@ -2,8 +2,11 @@ package agentcontainers
import (
"context"
"encoding/json"
"errors"
"fmt"
"io/fs"
"maps"
"net/http"
"os"
"path"
@@ -18,10 +21,13 @@ import (
"github.com/fsnotify/fsnotify"
"github.com/go-chi/chi/v5"
"github.com/go-git/go-git/v5/plumbing/format/gitignore"
"github.com/google/uuid"
"github.com/spf13/afero"
"golang.org/x/xerrors"
"cdr.dev/slog"
"github.com/coder/coder/v2/agent/agentcontainers/ignore"
"github.com/coder/coder/v2/agent/agentcontainers/watcher"
"github.com/coder/coder/v2/agent/agentexec"
"github.com/coder/coder/v2/agent/usershell"
@@ -30,6 +36,7 @@ import (
"github.com/coder/coder/v2/codersdk/agentsdk"
"github.com/coder/coder/v2/provisioner"
"github.com/coder/quartz"
"github.com/coder/websocket"
)
const (
@@ -53,10 +60,12 @@ type API struct {
cancel context.CancelFunc
watcherDone chan struct{}
updaterDone chan struct{}
discoverDone chan struct{}
updateTrigger chan chan error // Channel to trigger manual refresh.
updateInterval time.Duration // Interval for periodic container updates.
logger slog.Logger
watcher watcher.Watcher
fs afero.Fs
execer agentexec.Execer
commandEnv CommandEnv
ccli ContainerCLI
@@ -68,12 +77,17 @@ type API struct {
subAgentURL string
subAgentEnv []string
ownerName string
workspaceName string
parentAgent string
projectDiscovery bool // If we should perform project discovery or not.
discoveryAutostart bool // If we should autostart discovered projects.
ownerName string
workspaceName string
parentAgent string
agentDirectory string
mu sync.RWMutex // Protects the following fields.
initDone chan struct{} // Closed by Init.
updateChans []chan struct{}
closed bool
containers codersdk.WorkspaceAgentListContainersResponse // Output from the last list operation.
containersErr error // Error from the last list operation.
@@ -130,7 +144,9 @@ func WithCommandEnv(ce CommandEnv) Option {
strings.HasPrefix(s, "CODER_WORKSPACE_AGENT_URL=") ||
strings.HasPrefix(s, "CODER_AGENT_TOKEN=") ||
strings.HasPrefix(s, "CODER_AGENT_AUTH=") ||
strings.HasPrefix(s, "CODER_AGENT_DEVCONTAINERS_ENABLE=")
strings.HasPrefix(s, "CODER_AGENT_DEVCONTAINERS_ENABLE=") ||
strings.HasPrefix(s, "CODER_AGENT_DEVCONTAINERS_PROJECT_DISCOVERY_ENABLE=") ||
strings.HasPrefix(s, "CODER_AGENT_DEVCONTAINERS_DISCOVERY_AUTOSTART_ENABLE=")
})
return shell, dir, env, nil
}
@@ -147,8 +163,8 @@ func WithContainerCLI(ccli ContainerCLI) Option {
// WithContainerLabelIncludeFilter sets a label filter for containers.
// This option can be given multiple times to filter by multiple labels.
// The behavior is such that only containers matching one or more of the
// provided labels will be included.
// The behavior is such that only containers matching all of the provided
// labels will be included.
func WithContainerLabelIncludeFilter(label, value string) Option {
return func(api *API) {
api.containerLabelIncludeFilter[label] = value
@@ -188,11 +204,12 @@ func WithSubAgentEnv(env ...string) Option {
// WithManifestInfo sets the owner name, and workspace name
// for the sub-agent.
func WithManifestInfo(owner, workspace, parentAgent string) Option {
func WithManifestInfo(owner, workspace, parentAgent, agentDirectory string) Option {
return func(api *API) {
api.ownerName = owner
api.workspaceName = workspace
api.parentAgent = parentAgent
api.agentDirectory = agentDirectory
}
}
@@ -257,6 +274,29 @@ func WithWatcher(w watcher.Watcher) Option {
}
}
// WithFileSystem sets the file system used for discovering projects.
func WithFileSystem(fileSystem afero.Fs) Option {
return func(api *API) {
api.fs = fileSystem
}
}
// WithProjectDiscovery sets if the API should attempt to discover
// projects on the filesystem.
func WithProjectDiscovery(projectDiscovery bool) Option {
return func(api *API) {
api.projectDiscovery = projectDiscovery
}
}
// WithDiscoveryAutostart sets if the API should attempt to autostart
// projects that have been discovered
func WithDiscoveryAutostart(discoveryAutostart bool) Option {
return func(api *API) {
api.discoveryAutostart = discoveryAutostart
}
}
// ScriptLogger is an interface for sending devcontainer logs to the
// controlplane.
type ScriptLogger interface {
@@ -327,6 +367,9 @@ func NewAPI(logger slog.Logger, options ...Option) *API {
api.watcher = watcher.NewNoop()
}
}
if api.fs == nil {
api.fs = afero.NewOsFs()
}
if api.subAgentClient.Load() == nil {
var c SubAgentClient = noopSubAgentClient{}
api.subAgentClient.Store(&c)
@@ -368,6 +411,12 @@ func (api *API) Start() {
return
}
if api.projectDiscovery && api.agentDirectory != "" {
api.discoverDone = make(chan struct{})
go api.discover()
}
api.watcherDone = make(chan struct{})
api.updaterDone = make(chan struct{})
@@ -375,6 +424,162 @@ func (api *API) Start() {
go api.updaterLoop()
}
func (api *API) discover() {
defer close(api.discoverDone)
defer api.logger.Debug(api.ctx, "project discovery finished")
api.logger.Debug(api.ctx, "project discovery started")
if err := api.discoverDevcontainerProjects(); err != nil {
api.logger.Error(api.ctx, "discovering dev container projects", slog.Error(err))
}
if err := api.RefreshContainers(api.ctx); err != nil {
api.logger.Error(api.ctx, "refreshing containers after discovery", slog.Error(err))
}
}
func (api *API) discoverDevcontainerProjects() error {
isGitProject, err := afero.DirExists(api.fs, filepath.Join(api.agentDirectory, ".git"))
if err != nil {
return xerrors.Errorf(".git dir exists: %w", err)
}
// If the agent directory is a git project, we'll search
// the project for any `.devcontainer/devcontainer.json`
// files.
if isGitProject {
return api.discoverDevcontainersInProject(api.agentDirectory)
}
// The agent directory is _not_ a git project, so we'll
// search the top level of the agent directory for any
// git projects, and search those.
entries, err := afero.ReadDir(api.fs, api.agentDirectory)
if err != nil {
return xerrors.Errorf("read agent directory: %w", err)
}
for _, entry := range entries {
if !entry.IsDir() {
continue
}
isGitProject, err = afero.DirExists(api.fs, filepath.Join(api.agentDirectory, entry.Name(), ".git"))
if err != nil {
return xerrors.Errorf(".git dir exists: %w", err)
}
// If this directory is a git project, we'll search
// it for any `.devcontainer/devcontainer.json` files.
if isGitProject {
if err := api.discoverDevcontainersInProject(filepath.Join(api.agentDirectory, entry.Name())); err != nil {
return err
}
}
}
return nil
}
func (api *API) discoverDevcontainersInProject(projectPath string) error {
logger := api.logger.
Named("project-discovery").
With(slog.F("project_path", projectPath))
globalPatterns, err := ignore.LoadGlobalPatterns(api.fs)
if err != nil {
return xerrors.Errorf("read global git ignore patterns: %w", err)
}
patterns, err := ignore.ReadPatterns(api.ctx, logger, api.fs, projectPath)
if err != nil {
return xerrors.Errorf("read git ignore patterns: %w", err)
}
matcher := gitignore.NewMatcher(append(globalPatterns, patterns...))
devcontainerConfigPaths := []string{
"/.devcontainer/devcontainer.json",
"/.devcontainer.json",
}
return afero.Walk(api.fs, projectPath, func(path string, info fs.FileInfo, err error) error {
if err != nil {
logger.Error(api.ctx, "encountered error while walking for dev container projects",
slog.F("path", path),
slog.Error(err))
return nil
}
pathParts := ignore.FilePathToParts(path)
// We know that a directory entry cannot be a `devcontainer.json` file, so we
// always skip processing directories. If the directory happens to be ignored
// by git then we'll make sure to ignore all of the children of that directory.
if info.IsDir() {
if matcher.Match(pathParts, true) {
return fs.SkipDir
}
return nil
}
if matcher.Match(pathParts, false) {
return nil
}
for _, relativeConfigPath := range devcontainerConfigPaths {
if !strings.HasSuffix(path, relativeConfigPath) {
continue
}
workspaceFolder := strings.TrimSuffix(path, relativeConfigPath)
logger := logger.With(slog.F("workspace_folder", workspaceFolder))
logger.Debug(api.ctx, "discovered dev container project")
api.mu.Lock()
if _, found := api.knownDevcontainers[workspaceFolder]; !found {
logger.Debug(api.ctx, "adding dev container project")
dc := codersdk.WorkspaceAgentDevcontainer{
ID: uuid.New(),
Name: "", // Updated later based on container state.
WorkspaceFolder: workspaceFolder,
ConfigPath: path,
Status: codersdk.WorkspaceAgentDevcontainerStatusStopped,
Dirty: false, // Updated later based on config file changes.
Container: nil,
}
if api.discoveryAutostart {
config, err := api.dccli.ReadConfig(api.ctx, workspaceFolder, path, []string{})
if err != nil {
logger.Error(api.ctx, "read project configuration", slog.Error(err))
} else if config.Configuration.Customizations.Coder.AutoStart {
dc.Status = codersdk.WorkspaceAgentDevcontainerStatusStarting
}
}
api.knownDevcontainers[workspaceFolder] = dc
api.broadcastUpdatesLocked()
if dc.Status == codersdk.WorkspaceAgentDevcontainerStatusStarting {
api.asyncWg.Add(1)
go func() {
defer api.asyncWg.Done()
_ = api.CreateDevcontainer(dc.WorkspaceFolder, dc.ConfigPath)
}()
}
}
api.mu.Unlock()
}
return nil
})
}
func (api *API) watcherLoop() {
defer close(api.watcherDone)
defer api.logger.Debug(api.ctx, "watcher loop stopped")
@@ -449,6 +654,7 @@ func (api *API) updaterLoop() {
// We utilize a TickerFunc here instead of a regular Ticker so that
// we can guarantee execution of the updateContainers method after
// advancing the clock.
var prevErr error
ticker := api.clock.TickerFunc(api.ctx, api.updateInterval, func() error {
done := make(chan error, 1)
var sent bool
@@ -466,9 +672,15 @@ func (api *API) updaterLoop() {
if err != nil {
if errors.Is(err, context.Canceled) {
api.logger.Warn(api.ctx, "updater loop ticker canceled", slog.Error(err))
} else {
return nil
}
// Avoid excessive logging of the same error.
if prevErr == nil || prevErr.Error() != err.Error() {
api.logger.Error(api.ctx, "updater loop ticker failed", slog.Error(err))
}
prevErr = err
} else {
prevErr = nil
}
default:
api.logger.Debug(api.ctx, "updater loop ticker skipped, update in progress")
@@ -528,6 +740,7 @@ func (api *API) Routes() http.Handler {
r.Use(ensureInitDoneMW)
r.Get("/", api.handleList)
r.Get("/watch", api.watchContainers)
// TODO(mafredri): Simplify this route as the previous /devcontainers
// /-route was dropped. We can drop the /devcontainers prefix here too.
r.Route("/devcontainers/{devcontainer}", func(r chi.Router) {
@@ -537,6 +750,92 @@ func (api *API) Routes() http.Handler {
return r
}
func (api *API) broadcastUpdatesLocked() {
// Broadcast state changes to WebSocket listeners.
for _, ch := range api.updateChans {
select {
case ch <- struct{}{}:
default:
}
}
}
func (api *API) watchContainers(rw http.ResponseWriter, r *http.Request) {
ctx := r.Context()
conn, err := websocket.Accept(rw, r, &websocket.AcceptOptions{
// We want `NoContextTakeover` compression to balance improving
// bandwidth cost/latency with minimal memory usage overhead.
CompressionMode: websocket.CompressionNoContextTakeover,
})
if err != nil {
httpapi.Write(ctx, rw, http.StatusInternalServerError, codersdk.Response{
Message: "Failed to upgrade connection to websocket.",
Detail: err.Error(),
})
return
}
// Here we close the websocket for reading, so that the websocket library will handle pings and
// close frames.
_ = conn.CloseRead(context.Background())
ctx, wsNetConn := codersdk.WebsocketNetConn(ctx, conn, websocket.MessageText)
defer wsNetConn.Close()
go httpapi.Heartbeat(ctx, conn)
updateCh := make(chan struct{}, 1)
api.mu.Lock()
api.updateChans = append(api.updateChans, updateCh)
api.mu.Unlock()
defer func() {
api.mu.Lock()
api.updateChans = slices.DeleteFunc(api.updateChans, func(ch chan struct{}) bool {
return ch == updateCh
})
close(updateCh)
api.mu.Unlock()
}()
encoder := json.NewEncoder(wsNetConn)
ct, err := api.getContainers()
if err != nil {
api.logger.Error(ctx, "unable to get containers", slog.Error(err))
return
}
if err := encoder.Encode(ct); err != nil {
api.logger.Error(ctx, "encode container list", slog.Error(err))
return
}
for {
select {
case <-api.ctx.Done():
return
case <-ctx.Done():
return
case <-updateCh:
ct, err := api.getContainers()
if err != nil {
api.logger.Error(ctx, "unable to get containers", slog.Error(err))
continue
}
if err := encoder.Encode(ct); err != nil {
api.logger.Error(ctx, "encode container list", slog.Error(err))
return
}
}
}
}
// handleList handles the HTTP request to list containers.
func (api *API) handleList(rw http.ResponseWriter, r *http.Request) {
ct, err := api.getContainers()
@@ -576,8 +875,26 @@ func (api *API) updateContainers(ctx context.Context) error {
api.mu.Lock()
defer api.mu.Unlock()
var previouslyKnownDevcontainers map[string]codersdk.WorkspaceAgentDevcontainer
if len(api.updateChans) > 0 {
previouslyKnownDevcontainers = maps.Clone(api.knownDevcontainers)
}
api.processUpdatedContainersLocked(ctx, updated)
if len(api.updateChans) > 0 {
statesAreEqual := maps.EqualFunc(
previouslyKnownDevcontainers,
api.knownDevcontainers,
func(dc1, dc2 codersdk.WorkspaceAgentDevcontainer) bool {
return dc1.Equals(dc2)
})
if !statesAreEqual {
api.broadcastUpdatesLocked()
}
}
api.logger.Debug(ctx, "containers updated successfully", slog.F("container_count", len(api.containers.Containers)), slog.F("warning_count", len(api.containers.Warnings)), slog.F("devcontainer_count", len(api.knownDevcontainers)))
return nil
@@ -626,17 +943,22 @@ func (api *API) processUpdatedContainersLocked(ctx context.Context, updated code
slog.F("config_file", configFile),
)
// If we haven't set any include filters, we should explicitly ignore test devcontainers.
if len(api.containerLabelIncludeFilter) == 0 && container.Labels[DevcontainerIsTestRunLabel] == "true" {
continue
}
// Filter out devcontainer tests, unless explicitly set in include filters.
if len(api.containerLabelIncludeFilter) > 0 || container.Labels[DevcontainerIsTestRunLabel] == "true" {
var ok bool
if len(api.containerLabelIncludeFilter) > 0 {
includeContainer := true
for label, value := range api.containerLabelIncludeFilter {
if v, found := container.Labels[label]; found && v == value {
ok = true
}
v, found := container.Labels[label]
includeContainer = includeContainer && (found && v == value)
}
// Verbose debug logging is fine here since typically filters
// are only used in development or testing environments.
if !ok {
if !includeContainer {
logger.Debug(ctx, "container does not match include filter, ignoring devcontainer", slog.F("container_labels", container.Labels), slog.F("include_filter", api.containerLabelIncludeFilter))
continue
}
@@ -717,6 +1039,9 @@ func (api *API) processUpdatedContainersLocked(ctx context.Context, updated code
err := api.maybeInjectSubAgentIntoContainerLocked(ctx, dc)
if err != nil {
logger.Error(ctx, "inject subagent into container failed", slog.Error(err))
dc.Error = err.Error()
} else {
dc.Error = ""
}
}
@@ -943,7 +1268,10 @@ func (api *API) handleDevcontainerRecreate(w http.ResponseWriter, r *http.Reques
// devcontainer multiple times in parallel.
dc.Status = codersdk.WorkspaceAgentDevcontainerStatusStarting
dc.Container = nil
dc.Error = ""
api.knownDevcontainers[dc.WorkspaceFolder] = dc
api.broadcastUpdatesLocked()
go func() {
_ = api.CreateDevcontainer(dc.WorkspaceFolder, dc.ConfigPath, WithRemoveExistingContainer())
}()
@@ -1032,6 +1360,7 @@ func (api *API) CreateDevcontainer(workspaceFolder, configPath string, opts ...D
api.mu.Lock()
dc = api.knownDevcontainers[dc.WorkspaceFolder]
dc.Status = codersdk.WorkspaceAgentDevcontainerStatusError
dc.Error = err.Error()
api.knownDevcontainers[dc.WorkspaceFolder] = dc
api.recreateErrorTimes[dc.WorkspaceFolder] = api.clock.Now("agentcontainers", "recreate", "errorTimes")
api.mu.Unlock()
@@ -1055,8 +1384,10 @@ func (api *API) CreateDevcontainer(workspaceFolder, configPath string, opts ...D
}
}
dc.Dirty = false
dc.Error = ""
api.recreateSuccessTimes[dc.WorkspaceFolder] = api.clock.Now("agentcontainers", "recreate", "successTimes")
api.knownDevcontainers[dc.WorkspaceFolder] = dc
api.broadcastUpdatesLocked()
api.mu.Unlock()
// Ensure an immediate refresh to accurately reflect the
@@ -1523,7 +1854,9 @@ func (api *API) maybeInjectSubAgentIntoContainerLocked(ctx context.Context, dc c
originalName := subAgentConfig.Name
for attempt := 1; attempt <= maxAttemptsToNameAgent; attempt++ {
if proc.agent, err = client.Create(ctx, subAgentConfig); err == nil {
agent, err := client.Create(ctx, subAgentConfig)
if err == nil {
proc.agent = agent // Only reassign on success.
if api.usingWorkspaceFolderName[dc.WorkspaceFolder] {
api.devcontainerNames[dc.Name] = true
delete(api.usingWorkspaceFolderName, dc.WorkspaceFolder)
@@ -1531,7 +1864,6 @@ func (api *API) maybeInjectSubAgentIntoContainerLocked(ctx context.Context, dc c
break
}
// NOTE(DanielleMaywood):
// Ordinarily we'd use `errors.As` here, but it didn't appear to work. Not
// sure if this is because of the communication protocol? Instead I've opted
@@ -1686,6 +2018,9 @@ func (api *API) Close() error {
if api.updaterDone != nil {
<-api.updaterDone
}
if api.discoverDone != nil {
<-api.discoverDone
}
// Wait for all async tasks to complete.
api.asyncWg.Wait()
File diff suppressed because it is too large Load Diff
@@ -55,11 +55,11 @@ func TestIntegrationDockerCLI(t *testing.T) {
}, testutil.WaitShort, testutil.IntervalSlow, "Container did not start in time")
dcli := agentcontainers.NewDockerCLI(agentexec.DefaultExecer)
ctx := testutil.Context(t, testutil.WaitMedium) // Longer timeout for multiple subtests
containerName := strings.TrimPrefix(ct.Container.Name, "/")
t.Run("DetectArchitecture", func(t *testing.T) {
t.Parallel()
ctx := testutil.Context(t, testutil.WaitShort)
arch, err := dcli.DetectArchitecture(ctx, containerName)
require.NoError(t, err, "DetectArchitecture failed")
@@ -71,6 +71,7 @@ func TestIntegrationDockerCLI(t *testing.T) {
t.Run("Copy", func(t *testing.T) {
t.Parallel()
ctx := testutil.Context(t, testutil.WaitShort)
want := "Help, I'm trapped!"
tempFile := filepath.Join(t.TempDir(), "test-file.txt")
@@ -90,6 +91,7 @@ func TestIntegrationDockerCLI(t *testing.T) {
t.Run("ExecAs", func(t *testing.T) {
t.Parallel()
ctx := testutil.Context(t, testutil.WaitShort)
// Test ExecAs without specifying user (should use container's default).
want := "root"
+1 -1
View File
@@ -61,7 +61,7 @@ fi
exec 3>&-
# Format the generated code.
go run mvdan.cc/gofumpt@v0.4.0 -w -l "${TMPDIR}/${DEST_FILENAME}"
go run mvdan.cc/gofumpt@v0.8.0 -w -l "${TMPDIR}/${DEST_FILENAME}"
# Add a header so that Go recognizes this as a generated file.
if grep -q -- "\[-i extension\]" < <(sed -h 2>&1); then
+33 -32
View File
@@ -91,6 +91,7 @@ type CoderCustomization struct {
Apps []SubAgentApp `json:"apps,omitempty"`
Name string `json:"name,omitempty"`
Ignore bool `json:"ignore,omitempty"`
AutoStart bool `json:"autoStart,omitempty"`
}
type DevcontainerWorkspace struct {
@@ -106,63 +107,63 @@ type DevcontainerCLI interface {
// DevcontainerCLIUpOptions are options for the devcontainer CLI Up
// command.
type DevcontainerCLIUpOptions func(*devcontainerCLIUpConfig)
type DevcontainerCLIUpOptions func(*DevcontainerCLIUpConfig)
type devcontainerCLIUpConfig struct {
args []string // Additional arguments for the Up command.
stdout io.Writer
stderr io.Writer
type DevcontainerCLIUpConfig struct {
Args []string // Additional arguments for the Up command.
Stdout io.Writer
Stderr io.Writer
}
// WithRemoveExistingContainer is an option to remove the existing
// container.
func WithRemoveExistingContainer() DevcontainerCLIUpOptions {
return func(o *devcontainerCLIUpConfig) {
o.args = append(o.args, "--remove-existing-container")
return func(o *DevcontainerCLIUpConfig) {
o.Args = append(o.Args, "--remove-existing-container")
}
}
// WithUpOutput sets additional stdout and stderr writers for logs
// during Up operations.
func WithUpOutput(stdout, stderr io.Writer) DevcontainerCLIUpOptions {
return func(o *devcontainerCLIUpConfig) {
o.stdout = stdout
o.stderr = stderr
return func(o *DevcontainerCLIUpConfig) {
o.Stdout = stdout
o.Stderr = stderr
}
}
// DevcontainerCLIExecOptions are options for the devcontainer CLI Exec
// command.
type DevcontainerCLIExecOptions func(*devcontainerCLIExecConfig)
type DevcontainerCLIExecOptions func(*DevcontainerCLIExecConfig)
type devcontainerCLIExecConfig struct {
args []string // Additional arguments for the Exec command.
stdout io.Writer
stderr io.Writer
type DevcontainerCLIExecConfig struct {
Args []string // Additional arguments for the Exec command.
Stdout io.Writer
Stderr io.Writer
}
// WithExecOutput sets additional stdout and stderr writers for logs
// during Exec operations.
func WithExecOutput(stdout, stderr io.Writer) DevcontainerCLIExecOptions {
return func(o *devcontainerCLIExecConfig) {
o.stdout = stdout
o.stderr = stderr
return func(o *DevcontainerCLIExecConfig) {
o.Stdout = stdout
o.Stderr = stderr
}
}
// WithExecContainerID sets the container ID to target a specific
// container.
func WithExecContainerID(id string) DevcontainerCLIExecOptions {
return func(o *devcontainerCLIExecConfig) {
o.args = append(o.args, "--container-id", id)
return func(o *DevcontainerCLIExecConfig) {
o.Args = append(o.Args, "--container-id", id)
}
}
// WithRemoteEnv sets environment variables for the Exec command.
func WithRemoteEnv(env ...string) DevcontainerCLIExecOptions {
return func(o *devcontainerCLIExecConfig) {
return func(o *DevcontainerCLIExecConfig) {
for _, e := range env {
o.args = append(o.args, "--remote-env", e)
o.Args = append(o.Args, "--remote-env", e)
}
}
}
@@ -185,8 +186,8 @@ func WithReadConfigOutput(stdout, stderr io.Writer) DevcontainerCLIReadConfigOpt
}
}
func applyDevcontainerCLIUpOptions(opts []DevcontainerCLIUpOptions) devcontainerCLIUpConfig {
conf := devcontainerCLIUpConfig{stdout: io.Discard, stderr: io.Discard}
func applyDevcontainerCLIUpOptions(opts []DevcontainerCLIUpOptions) DevcontainerCLIUpConfig {
conf := DevcontainerCLIUpConfig{Stdout: io.Discard, Stderr: io.Discard}
for _, opt := range opts {
if opt != nil {
opt(&conf)
@@ -195,8 +196,8 @@ func applyDevcontainerCLIUpOptions(opts []DevcontainerCLIUpOptions) devcontainer
return conf
}
func applyDevcontainerCLIExecOptions(opts []DevcontainerCLIExecOptions) devcontainerCLIExecConfig {
conf := devcontainerCLIExecConfig{stdout: io.Discard, stderr: io.Discard}
func applyDevcontainerCLIExecOptions(opts []DevcontainerCLIExecOptions) DevcontainerCLIExecConfig {
conf := DevcontainerCLIExecConfig{Stdout: io.Discard, Stderr: io.Discard}
for _, opt := range opts {
if opt != nil {
opt(&conf)
@@ -241,7 +242,7 @@ func (d *devcontainerCLI) Up(ctx context.Context, workspaceFolder, configPath st
if configPath != "" {
args = append(args, "--config", configPath)
}
args = append(args, conf.args...)
args = append(args, conf.Args...)
cmd := d.execer.CommandContext(ctx, "devcontainer", args...)
// Capture stdout for parsing and stream logs for both default and provided writers.
@@ -251,14 +252,14 @@ func (d *devcontainerCLI) Up(ctx context.Context, workspaceFolder, configPath st
&devcontainerCLILogWriter{
ctx: ctx,
logger: logger.With(slog.F("stdout", true)),
writer: conf.stdout,
writer: conf.Stdout,
},
)
// Stream stderr logs and provided writer if any.
cmd.Stderr = &devcontainerCLILogWriter{
ctx: ctx,
logger: logger.With(slog.F("stderr", true)),
writer: conf.stderr,
writer: conf.Stderr,
}
if err := cmd.Run(); err != nil {
@@ -293,17 +294,17 @@ func (d *devcontainerCLI) Exec(ctx context.Context, workspaceFolder, configPath
if configPath != "" {
args = append(args, "--config", configPath)
}
args = append(args, conf.args...)
args = append(args, conf.Args...)
args = append(args, cmd)
args = append(args, cmdArgs...)
c := d.execer.CommandContext(ctx, "devcontainer", args...)
c.Stdout = io.MultiWriter(conf.stdout, &devcontainerCLILogWriter{
c.Stdout = io.MultiWriter(conf.Stdout, &devcontainerCLILogWriter{
ctx: ctx,
logger: logger.With(slog.F("stdout", true)),
writer: io.Discard,
})
c.Stderr = io.MultiWriter(conf.stderr, &devcontainerCLILogWriter{
c.Stderr = io.MultiWriter(conf.Stderr, &devcontainerCLILogWriter{
ctx: ctx,
logger: logger.With(slog.F("stderr", true)),
writer: io.Discard,
@@ -593,7 +593,7 @@ func setupDevcontainerWorkspace(t *testing.T, workspaceFolder string) string {
"containerEnv": {
"TEST_CONTAINER": "true"
},
"runArgs": ["--label", "com.coder.test=devcontainercli"]
"runArgs": ["--label=com.coder.test=devcontainercli", "--label=` + agentcontainers.DevcontainerIsTestRunLabel + `=true"]
}`
err = os.WriteFile(configPath, []byte(content), 0o600)
require.NoError(t, err, "create devcontainer.json file")
+124
View File
@@ -0,0 +1,124 @@
package ignore
import (
"bytes"
"context"
"errors"
"io/fs"
"os"
"path/filepath"
"strings"
"github.com/go-git/go-git/v5/plumbing/format/config"
"github.com/go-git/go-git/v5/plumbing/format/gitignore"
"github.com/spf13/afero"
"golang.org/x/xerrors"
"cdr.dev/slog"
)
const (
gitconfigFile = ".gitconfig"
gitignoreFile = ".gitignore"
gitInfoExcludeFile = ".git/info/exclude"
)
func FilePathToParts(path string) []string {
components := []string{}
if path == "" {
return components
}
for segment := range strings.SplitSeq(filepath.Clean(path), string(filepath.Separator)) {
if segment != "" {
components = append(components, segment)
}
}
return components
}
func readIgnoreFile(fileSystem afero.Fs, path, ignore string) ([]gitignore.Pattern, error) {
var ps []gitignore.Pattern
data, err := afero.ReadFile(fileSystem, filepath.Join(path, ignore))
if err != nil && !errors.Is(err, os.ErrNotExist) {
return nil, err
}
for s := range strings.SplitSeq(string(data), "\n") {
if !strings.HasPrefix(s, "#") && len(strings.TrimSpace(s)) > 0 {
ps = append(ps, gitignore.ParsePattern(s, FilePathToParts(path)))
}
}
return ps, nil
}
func ReadPatterns(ctx context.Context, logger slog.Logger, fileSystem afero.Fs, path string) ([]gitignore.Pattern, error) {
var ps []gitignore.Pattern
subPs, err := readIgnoreFile(fileSystem, path, gitInfoExcludeFile)
if err != nil {
return nil, err
}
ps = append(ps, subPs...)
if err := afero.Walk(fileSystem, path, func(path string, info fs.FileInfo, err error) error {
if err != nil {
logger.Error(ctx, "encountered error while walking for git ignore files",
slog.F("path", path),
slog.Error(err))
return nil
}
if !info.IsDir() {
return nil
}
subPs, err := readIgnoreFile(fileSystem, path, gitignoreFile)
if err != nil {
return err
}
ps = append(ps, subPs...)
return nil
}); err != nil {
return nil, err
}
return ps, nil
}
func loadPatterns(fileSystem afero.Fs, path string) ([]gitignore.Pattern, error) {
data, err := afero.ReadFile(fileSystem, path)
if err != nil && !errors.Is(err, os.ErrNotExist) {
return nil, err
}
decoder := config.NewDecoder(bytes.NewBuffer(data))
conf := config.New()
if err := decoder.Decode(conf); err != nil {
return nil, xerrors.Errorf("decode config: %w", err)
}
excludes := conf.Section("core").Options.Get("excludesfile")
if excludes == "" {
return nil, nil
}
return readIgnoreFile(fileSystem, "", excludes)
}
func LoadGlobalPatterns(fileSystem afero.Fs) ([]gitignore.Pattern, error) {
home, err := os.UserHomeDir()
if err != nil {
return nil, err
}
return loadPatterns(fileSystem, filepath.Join(home, gitconfigFile))
}
+38
View File
@@ -0,0 +1,38 @@
package ignore_test
import (
"fmt"
"testing"
"github.com/stretchr/testify/require"
"github.com/coder/coder/v2/agent/agentcontainers/ignore"
)
func TestFilePathToParts(t *testing.T) {
t.Parallel()
tests := []struct {
path string
expected []string
}{
{"", []string{}},
{"/", []string{}},
{"foo", []string{"foo"}},
{"/foo", []string{"foo"}},
{"./foo/bar", []string{"foo", "bar"}},
{"../foo/bar", []string{"..", "foo", "bar"}},
{"foo/bar/baz", []string{"foo", "bar", "baz"}},
{"/foo/bar/baz", []string{"foo", "bar", "baz"}},
{"foo/../bar", []string{"bar"}},
}
for _, tt := range tests {
t.Run(fmt.Sprintf("`%s`", tt.path), func(t *testing.T) {
t.Parallel()
parts := ignore.FilePathToParts(tt.path)
require.Equal(t, tt.expected, parts)
})
}
}
+16 -8
View File
@@ -188,7 +188,7 @@ func (a *subAgentAPIClient) List(ctx context.Context) ([]SubAgent, error) {
return agents, nil
}
func (a *subAgentAPIClient) Create(ctx context.Context, agent SubAgent) (SubAgent, error) {
func (a *subAgentAPIClient) Create(ctx context.Context, agent SubAgent) (_ SubAgent, err error) {
a.logger.Debug(ctx, "creating sub agent", slog.F("name", agent.Name), slog.F("directory", agent.Directory))
displayApps := make([]agentproto.CreateSubAgentRequest_DisplayApp, 0, len(agent.DisplayApps))
@@ -233,19 +233,27 @@ func (a *subAgentAPIClient) Create(ctx context.Context, agent SubAgent) (SubAgen
if err != nil {
return SubAgent{}, err
}
defer func() {
if err != nil {
// Best effort.
_, _ = a.api.DeleteSubAgent(ctx, &agentproto.DeleteSubAgentRequest{
Id: resp.GetAgent().GetId(),
})
}
}()
agent.Name = resp.Agent.Name
agent.ID, err = uuid.FromBytes(resp.Agent.Id)
agent.Name = resp.GetAgent().GetName()
agent.ID, err = uuid.FromBytes(resp.GetAgent().GetId())
if err != nil {
return agent, err
return SubAgent{}, err
}
agent.AuthToken, err = uuid.FromBytes(resp.Agent.AuthToken)
agent.AuthToken, err = uuid.FromBytes(resp.GetAgent().GetAuthToken())
if err != nil {
return agent, err
return SubAgent{}, err
}
for _, appError := range resp.AppCreationErrors {
app := apps[appError.Index]
for _, appError := range resp.GetAppCreationErrors() {
app := apps[appError.GetIndex()]
a.logger.Warn(ctx, "unable to create app",
slog.F("agent_name", agent.Name),
+26 -15
View File
@@ -4,6 +4,7 @@ import (
"context"
"os"
"path/filepath"
"runtime"
"testing"
"github.com/fsnotify/fsnotify"
@@ -88,24 +89,34 @@ func TestFSNotifyWatcher(t *testing.T) {
break
}
err = os.WriteFile(testFile+".atomic", []byte(`{"test": "atomic"}`), 0o600)
require.NoError(t, err, "write new atomic test file failed")
// TODO(DanielleMaywood):
// Unfortunately it appears this atomic-rename phase of the test is flakey on macOS.
//
// This test flake could be indicative of an issue that may present itself
// in a running environment. Fortunately, we only use this (as of 2025-07-29)
// for our dev container integration. We do not expect the host workspace
// (where this is used), to ever be run on macOS, as containers are a linux
// paradigm.
if runtime.GOOS != "darwin" {
err = os.WriteFile(testFile+".atomic", []byte(`{"test": "atomic"}`), 0o600)
require.NoError(t, err, "write new atomic test file failed")
err = os.Rename(testFile+".atomic", testFile)
require.NoError(t, err, "rename atomic test file failed")
err = os.Rename(testFile+".atomic", testFile)
require.NoError(t, err, "rename atomic test file failed")
// Verify that we receive the event we want.
for {
event, err := wut.Next(ctx)
require.NoError(t, err, "next event failed")
require.NotNil(t, event, "want non-nil event")
if !event.Has(fsnotify.Create) {
t.Logf("Ignoring event: %s", event)
continue
// Verify that we receive the event we want.
for {
event, err := wut.Next(ctx)
require.NoError(t, err, "next event failed")
require.NotNil(t, event, "want non-nil event")
if !event.Has(fsnotify.Create) {
t.Logf("Ignoring event: %s", event)
continue
}
require.Truef(t, event.Has(fsnotify.Create), "want create event: %s", event.String())
require.Equal(t, event.Name, testFile, "want event for test file")
break
}
require.Truef(t, event.Has(fsnotify.Create), "want create event: %s", event.String())
require.Equal(t, event.Name, testFile, "want event for test file")
break
}
// Test removing the file from the watcher.
-2
View File
@@ -149,7 +149,6 @@ func (r *Runner) Init(scripts []codersdk.WorkspaceAgentScript, scriptCompleted S
if script.Cron == "" {
continue
}
script := script
_, err := r.cron.AddFunc(script.Cron, func() {
err := r.trackRun(r.cronCtx, script, ExecuteCronScripts)
if err != nil {
@@ -224,7 +223,6 @@ func (r *Runner) Execute(ctx context.Context, option ExecuteOption) error {
continue
}
script := script
eg.Go(func() error {
err := r.trackRun(ctx, script, option)
if err != nil {
+31 -5
View File
@@ -46,6 +46,8 @@ const (
// MagicProcessCmdlineJetBrains is a string in a process's command line that
// uniquely identifies it as JetBrains software.
MagicProcessCmdlineJetBrains = "idea.vendor.name=JetBrains"
MagicProcessCmdlineToolbox = "com.jetbrains.toolbox"
MagicProcessCmdlineGateway = "remote-dev-server"
// BlockedFileTransferErrorCode indicates that SSH server restricted the raw command from performing
// the file transfer.
@@ -117,6 +119,10 @@ type Config struct {
// Note that this is different from the devcontainers feature, which uses
// subagents.
ExperimentalContainers bool
// X11Net allows overriding the networking implementation used for X11
// forwarding listeners. When nil, a default implementation backed by the
// standard library networking package is used.
X11Net X11Network
}
type Server struct {
@@ -131,9 +137,10 @@ type Server struct {
// a lock on mu but protected by closing.
wg sync.WaitGroup
Execer agentexec.Execer
logger slog.Logger
srv *ssh.Server
Execer agentexec.Execer
logger slog.Logger
srv *ssh.Server
x11Forwarder *x11Forwarder
config *Config
@@ -190,6 +197,20 @@ func NewServer(ctx context.Context, logger slog.Logger, prometheusRegistry *prom
config: config,
metrics: metrics,
x11Forwarder: &x11Forwarder{
logger: logger,
x11HandlerErrors: metrics.x11HandlerErrors,
fs: fs,
displayOffset: *config.X11DisplayOffset,
sessions: make(map[*x11Session]struct{}),
connections: make(map[net.Conn]struct{}),
network: func() X11Network {
if config.X11Net != nil {
return config.X11Net
}
return osNet{}
}(),
},
}
srv := &ssh.Server{
@@ -457,7 +478,7 @@ func (s *Server) sessionHandler(session ssh.Session) {
x11, hasX11 := session.X11()
if hasX11 {
display, handled := s.x11Handler(ctx, x11)
display, handled := s.x11Forwarder.x11Handler(ctx, session)
if !handled {
logger.Error(ctx, "x11 handler failed")
closeCause("x11 handler failed")
@@ -590,7 +611,9 @@ func (s *Server) startNonPTYSession(logger slog.Logger, session ssh.Session, mag
// and SSH server close may be delayed.
cmd.SysProcAttr = cmdSysProcAttr()
// to match OpenSSH, we don't actually tear a non-TTY command down, even if the session ends.
// to match OpenSSH, we don't actually tear a non-TTY command down, even if the session ends. OpenSSH closes the
// pipes to the process when the session ends; which is what happens here since we wire the command up to the
// session for I/O.
// c.f. https://github.com/coder/coder/issues/18519#issuecomment-3019118271
cmd.Cancel = nil
@@ -1154,6 +1177,9 @@ func (s *Server) Close() error {
s.mu.Unlock()
s.logger.Debug(ctx, "closing X11 forwarding")
_ = s.x11Forwarder.Close()
s.logger.Debug(ctx, "waiting for all goroutines to exit")
s.wg.Wait() // Wait for all goroutines to exit.
+88
View File
@@ -8,7 +8,9 @@ import (
"context"
"fmt"
"net"
"os"
"os/user"
"path/filepath"
"runtime"
"strings"
"sync"
@@ -403,6 +405,92 @@ func TestNewServer_Signal(t *testing.T) {
})
}
func TestSSHServer_ClosesStdin(t *testing.T) {
t.Parallel()
if runtime.GOOS == "windows" {
t.Skip("bash doesn't exist on Windows")
}
ctx := testutil.Context(t, testutil.WaitMedium)
logger := testutil.Logger(t)
s, err := agentssh.NewServer(ctx, logger.Named("ssh-server"), prometheus.NewRegistry(), afero.NewMemMapFs(), agentexec.DefaultExecer, nil)
require.NoError(t, err)
logger = logger.Named("test")
defer s.Close()
err = s.UpdateHostSigner(42)
assert.NoError(t, err)
ln, err := net.Listen("tcp", "127.0.0.1:0")
require.NoError(t, err)
done := make(chan struct{})
go func() {
defer close(done)
err := s.Serve(ln)
assert.Error(t, err) // Server is closed.
}()
defer func() {
err := s.Close()
require.NoError(t, err)
<-done
}()
c := sshClient(t, ln.Addr().String())
sess, err := c.NewSession()
require.NoError(t, err)
stdout, err := sess.StdoutPipe()
require.NoError(t, err)
stdin, err := sess.StdinPipe()
require.NoError(t, err)
defer stdin.Close()
dir := t.TempDir()
err = os.MkdirAll(dir, 0o755)
require.NoError(t, err)
filePath := filepath.Join(dir, "result.txt")
// the shell command `read` will block until data is written to stdin, or closed. It will return
// exit code 1 if it hits EOF, which is what we want to test.
cmdErrCh := make(chan error, 1)
go func() {
cmdErrCh <- sess.Start(fmt.Sprintf(`echo started; echo "read exit code: $(read && echo 0 || echo 1)" > %s`, filePath))
}()
cmdErr := testutil.RequireReceive(ctx, t, cmdErrCh)
require.NoError(t, cmdErr)
readCh := make(chan error, 1)
go func() {
buf := make([]byte, 8)
_, err := stdout.Read(buf)
assert.Equal(t, "started\n", string(buf))
readCh <- err
}()
err = testutil.RequireReceive(ctx, t, readCh)
require.NoError(t, err)
err = sess.Close()
require.NoError(t, err)
var content []byte
expected := []byte("read exit code: 1\n")
testutil.Eventually(ctx, t, func(_ context.Context) bool {
content, err = os.ReadFile(filePath)
if err != nil {
logger.Debug(ctx, "failed to read file; will retry", slog.Error(err))
return false
}
if len(content) != len(expected) {
logger.Debug(ctx, "file is partially written", slog.F("content", content))
return false
}
return true
}, testutil.IntervalFast)
require.NoError(t, err)
require.Equal(t, string(expected), string(content))
}
func sshClient(t *testing.T, addr string) *ssh.Client {
conn, err := net.Dial("tcp", addr)
require.NoError(t, err)
+16 -1
View File
@@ -53,7 +53,7 @@ func NewJetbrainsChannelWatcher(ctx ssh.Context, logger slog.Logger, reportConne
// If this is not JetBrains, then we do not need to do anything special. We
// attempt to match on something that appears unique to JetBrains software.
if !strings.Contains(strings.ToLower(cmdline), strings.ToLower(MagicProcessCmdlineJetBrains)) {
if !isJetbrainsProcess(cmdline) {
return newChannel
}
@@ -104,3 +104,18 @@ func (c *ChannelOnClose) Close() error {
c.once.Do(c.done)
return c.Channel.Close()
}
func isJetbrainsProcess(cmdline string) bool {
opts := []string{
MagicProcessCmdlineJetBrains,
MagicProcessCmdlineToolbox,
MagicProcessCmdlineGateway,
}
for _, opt := range opts {
if strings.Contains(strings.ToLower(cmdline), strings.ToLower(opt)) {
return true
}
}
return false
}
+291 -76
View File
@@ -7,15 +7,16 @@ import (
"errors"
"fmt"
"io"
"math"
"net"
"os"
"path/filepath"
"strconv"
"sync"
"time"
"github.com/gliderlabs/ssh"
"github.com/gofrs/flock"
"github.com/prometheus/client_golang/prometheus"
"github.com/spf13/afero"
gossh "golang.org/x/crypto/ssh"
"golang.org/x/xerrors"
@@ -29,8 +30,51 @@ const (
X11StartPort = 6000
// X11DefaultDisplayOffset is the default offset for X11 forwarding.
X11DefaultDisplayOffset = 10
X11MaxDisplays = 200
// X11MaxPort is the highest port we will ever use for X11 forwarding. This limits the total number of TCP sockets
// we will create. It seems more useful to have a maximum port number than a direct limit on sockets with no max
// port because we'd like to be able to tell users the exact range of ports the Agent might use.
X11MaxPort = X11StartPort + X11MaxDisplays
)
// X11Network abstracts the creation of network listeners for X11 forwarding.
// It is intended mainly for testing; production code uses the default
// implementation backed by the operating system networking stack.
type X11Network interface {
Listen(network, address string) (net.Listener, error)
}
// osNet is the default X11Network implementation that uses the standard
// library network stack.
type osNet struct{}
func (osNet) Listen(network, address string) (net.Listener, error) {
return net.Listen(network, address)
}
type x11Forwarder struct {
logger slog.Logger
x11HandlerErrors *prometheus.CounterVec
fs afero.Fs
displayOffset int
// network creates X11 listener sockets. Defaults to osNet{}.
network X11Network
mu sync.Mutex
sessions map[*x11Session]struct{}
connections map[net.Conn]struct{}
closing bool
wg sync.WaitGroup
}
type x11Session struct {
session ssh.Session
display int
listener net.Listener
usedAt time.Time
}
// x11Callback is called when the client requests X11 forwarding.
func (*Server) x11Callback(_ ssh.Context, _ ssh.X11) bool {
// Always allow.
@@ -39,115 +83,243 @@ func (*Server) x11Callback(_ ssh.Context, _ ssh.X11) bool {
// x11Handler is called when a session has requested X11 forwarding.
// It listens for X11 connections and forwards them to the client.
func (s *Server) x11Handler(ctx ssh.Context, x11 ssh.X11) (displayNumber int, handled bool) {
serverConn, valid := ctx.Value(ssh.ContextKeyConn).(*gossh.ServerConn)
if !valid {
s.logger.Warn(ctx, "failed to get server connection")
func (x *x11Forwarder) x11Handler(sshCtx ssh.Context, sshSession ssh.Session) (displayNumber int, handled bool) {
x11, hasX11 := sshSession.X11()
if !hasX11 {
return -1, false
}
serverConn, valid := sshCtx.Value(ssh.ContextKeyConn).(*gossh.ServerConn)
if !valid {
x.logger.Warn(sshCtx, "failed to get server connection")
return -1, false
}
ctx := slog.With(sshCtx, slog.F("session_id", fmt.Sprintf("%x", serverConn.SessionID())))
hostname, err := os.Hostname()
if err != nil {
s.logger.Warn(ctx, "failed to get hostname", slog.Error(err))
s.metrics.x11HandlerErrors.WithLabelValues("hostname").Add(1)
x.logger.Warn(ctx, "failed to get hostname", slog.Error(err))
x.x11HandlerErrors.WithLabelValues("hostname").Add(1)
return -1, false
}
ln, display, err := createX11Listener(ctx, *s.config.X11DisplayOffset)
x11session, err := x.createX11Session(ctx, sshSession)
if err != nil {
s.logger.Warn(ctx, "failed to create X11 listener", slog.Error(err))
s.metrics.x11HandlerErrors.WithLabelValues("listen").Add(1)
x.logger.Warn(ctx, "failed to create X11 listener", slog.Error(err))
x.x11HandlerErrors.WithLabelValues("listen").Add(1)
return -1, false
}
s.trackListener(ln, true)
defer func() {
if !handled {
s.trackListener(ln, false)
_ = ln.Close()
x.closeAndRemoveSession(x11session)
}
}()
err = addXauthEntry(ctx, s.fs, hostname, strconv.Itoa(display), x11.AuthProtocol, x11.AuthCookie)
err = addXauthEntry(ctx, x.fs, hostname, strconv.Itoa(x11session.display), x11.AuthProtocol, x11.AuthCookie)
if err != nil {
s.logger.Warn(ctx, "failed to add Xauthority entry", slog.Error(err))
s.metrics.x11HandlerErrors.WithLabelValues("xauthority").Add(1)
x.logger.Warn(ctx, "failed to add Xauthority entry", slog.Error(err))
x.x11HandlerErrors.WithLabelValues("xauthority").Add(1)
return -1, false
}
// clean up the X11 session if the SSH session completes.
go func() {
// Don't leave the listener open after the session is gone.
<-ctx.Done()
_ = ln.Close()
x.closeAndRemoveSession(x11session)
}()
go func() {
defer ln.Close()
defer s.trackListener(ln, false)
go x.listenForConnections(ctx, x11session, serverConn, x11)
x.logger.Debug(ctx, "X11 forwarding started", slog.F("display", x11session.display))
for {
conn, err := ln.Accept()
if err != nil {
if errors.Is(err, net.ErrClosed) {
return
}
s.logger.Warn(ctx, "failed to accept X11 connection", slog.Error(err))
return x11session.display, true
}
func (x *x11Forwarder) trackGoroutine() (closing bool, done func()) {
x.mu.Lock()
defer x.mu.Unlock()
if !x.closing {
x.wg.Add(1)
return false, func() { x.wg.Done() }
}
return true, func() {}
}
func (x *x11Forwarder) listenForConnections(
ctx context.Context, session *x11Session, serverConn *gossh.ServerConn, x11 ssh.X11,
) {
defer x.closeAndRemoveSession(session)
if closing, done := x.trackGoroutine(); closing {
return
} else { // nolint: revive
defer done()
}
for {
conn, err := session.listener.Accept()
if err != nil {
if errors.Is(err, net.ErrClosed) {
return
}
if x11.SingleConnection {
s.logger.Debug(ctx, "single connection requested, closing X11 listener")
_ = ln.Close()
}
tcpConn, ok := conn.(*net.TCPConn)
if !ok {
s.logger.Warn(ctx, fmt.Sprintf("failed to cast connection to TCPConn. got: %T", conn))
_ = conn.Close()
continue
}
tcpAddr, ok := tcpConn.LocalAddr().(*net.TCPAddr)
if !ok {
s.logger.Warn(ctx, fmt.Sprintf("failed to cast local address to TCPAddr. got: %T", tcpConn.LocalAddr()))
_ = conn.Close()
continue
}
channel, reqs, err := serverConn.OpenChannel("x11", gossh.Marshal(struct {
OriginatorAddress string
OriginatorPort uint32
}{
OriginatorAddress: tcpAddr.IP.String(),
// #nosec G115 - Safe conversion as TCP port numbers are within uint32 range (0-65535)
OriginatorPort: uint32(tcpAddr.Port),
}))
if err != nil {
s.logger.Warn(ctx, "failed to open X11 channel", slog.Error(err))
_ = conn.Close()
continue
}
go gossh.DiscardRequests(reqs)
if !s.trackConn(ln, conn, true) {
s.logger.Warn(ctx, "failed to track X11 connection")
_ = conn.Close()
continue
}
go func() {
defer s.trackConn(ln, conn, false)
Bicopy(ctx, conn, channel)
}()
x.logger.Warn(ctx, "failed to accept X11 connection", slog.Error(err))
return
}
}()
return display, true
// Update session usage time since a new X11 connection was forwarded.
x.mu.Lock()
session.usedAt = time.Now()
x.mu.Unlock()
if x11.SingleConnection {
x.logger.Debug(ctx, "single connection requested, closing X11 listener")
x.closeAndRemoveSession(session)
}
var originAddr string
var originPort uint32
if tcpConn, ok := conn.(*net.TCPConn); ok {
if tcpAddr, ok := tcpConn.LocalAddr().(*net.TCPAddr); ok {
originAddr = tcpAddr.IP.String()
// #nosec G115 - Safe conversion as TCP port numbers are within uint32 range (0-65535)
originPort = uint32(tcpAddr.Port)
}
}
// Fallback values for in-memory or non-TCP connections.
if originAddr == "" {
originAddr = "127.0.0.1"
}
channel, reqs, err := serverConn.OpenChannel("x11", gossh.Marshal(struct {
OriginatorAddress string
OriginatorPort uint32
}{
OriginatorAddress: originAddr,
OriginatorPort: originPort,
}))
if err != nil {
x.logger.Warn(ctx, "failed to open X11 channel", slog.Error(err))
_ = conn.Close()
continue
}
go gossh.DiscardRequests(reqs)
if !x.trackConn(conn, true) {
x.logger.Warn(ctx, "failed to track X11 connection")
_ = conn.Close()
continue
}
go func() {
defer x.trackConn(conn, false)
Bicopy(ctx, conn, channel)
}()
}
}
// closeAndRemoveSession closes and removes the session.
func (x *x11Forwarder) closeAndRemoveSession(x11session *x11Session) {
_ = x11session.listener.Close()
x.mu.Lock()
delete(x.sessions, x11session)
x.mu.Unlock()
}
// createX11Session creates an X11 forwarding session.
func (x *x11Forwarder) createX11Session(ctx context.Context, sshSession ssh.Session) (*x11Session, error) {
var (
ln net.Listener
display int
err error
)
// retry listener creation after evictions. Limit to 10 retries to prevent pathological cases looping forever.
const maxRetries = 10
for try := range maxRetries {
ln, display, err = x.createX11Listener(ctx)
if err == nil {
break
}
if try == maxRetries-1 {
return nil, xerrors.New("max retries exceeded while creating X11 session")
}
x.logger.Warn(ctx, "failed to create X11 listener; will evict an X11 forwarding session",
slog.F("num_current_sessions", x.numSessions()),
slog.Error(err))
x.evictLeastRecentlyUsedSession()
}
x.mu.Lock()
defer x.mu.Unlock()
if x.closing {
closeErr := ln.Close()
if closeErr != nil {
x.logger.Error(ctx, "error closing X11 listener", slog.Error(closeErr))
}
return nil, xerrors.New("server is closing")
}
x11Sess := &x11Session{
session: sshSession,
display: display,
listener: ln,
usedAt: time.Now(),
}
x.sessions[x11Sess] = struct{}{}
return x11Sess, nil
}
func (x *x11Forwarder) numSessions() int {
x.mu.Lock()
defer x.mu.Unlock()
return len(x.sessions)
}
func (x *x11Forwarder) popLeastRecentlyUsedSession() *x11Session {
x.mu.Lock()
defer x.mu.Unlock()
var lru *x11Session
for s := range x.sessions {
if lru == nil {
lru = s
continue
}
if s.usedAt.Before(lru.usedAt) {
lru = s
continue
}
}
if lru == nil {
x.logger.Debug(context.Background(), "tried to pop from empty set of X11 sessions")
return nil
}
delete(x.sessions, lru)
return lru
}
func (x *x11Forwarder) evictLeastRecentlyUsedSession() {
lru := x.popLeastRecentlyUsedSession()
if lru == nil {
return
}
err := lru.listener.Close()
if err != nil {
x.logger.Error(context.Background(), "failed to close evicted X11 session listener", slog.Error(err))
}
// when we evict, we also want to force the SSH session to be closed as well. This is because we intend to reuse
// the X11 TCP listener port for a new X11 forwarding session. If we left the SSH session up, then graphical apps
// started in that session could potentially connect to an unintended X11 Server (i.e. the display on a different
// computer than the one that started the SSH session). Most likely, this session is a zombie anyway if we've
// reached the maximum number of X11 forwarding sessions.
err = lru.session.Close()
if err != nil {
x.logger.Error(context.Background(), "failed to close evicted X11 SSH session", slog.Error(err))
}
}
// createX11Listener creates a listener for X11 forwarding, it will use
// the next available port starting from X11StartPort and displayOffset.
func createX11Listener(ctx context.Context, displayOffset int) (ln net.Listener, display int, err error) {
var lc net.ListenConfig
func (x *x11Forwarder) createX11Listener(ctx context.Context) (ln net.Listener, display int, err error) {
// Look for an open port to listen on.
for port := X11StartPort + displayOffset; port < math.MaxUint16; port++ {
ln, err = lc.Listen(ctx, "tcp", fmt.Sprintf("localhost:%d", port))
for port := X11StartPort + x.displayOffset; port <= X11MaxPort; port++ {
if ctx.Err() != nil {
return nil, -1, ctx.Err()
}
ln, err = x.network.Listen("tcp", fmt.Sprintf("localhost:%d", port))
if err == nil {
display = port - X11StartPort
return ln, display, nil
@@ -156,6 +328,49 @@ func createX11Listener(ctx context.Context, displayOffset int) (ln net.Listener,
return nil, -1, xerrors.Errorf("failed to find open port for X11 listener: %w", err)
}
// trackConn registers the connection with the x11Forwarder. If the server is
// closed, the connection is not registered and should be closed.
//
//nolint:revive
func (x *x11Forwarder) trackConn(c net.Conn, add bool) (ok bool) {
x.mu.Lock()
defer x.mu.Unlock()
if add {
if x.closing {
// Server or listener closed.
return false
}
x.wg.Add(1)
x.connections[c] = struct{}{}
return true
}
x.wg.Done()
delete(x.connections, c)
return true
}
func (x *x11Forwarder) Close() error {
x.mu.Lock()
x.closing = true
for s := range x.sessions {
sErr := s.listener.Close()
if sErr != nil {
x.logger.Debug(context.Background(), "failed to close X11 listener", slog.Error(sErr))
}
}
for c := range x.connections {
cErr := c.Close()
if cErr != nil {
x.logger.Debug(context.Background(), "failed to close X11 connection", slog.Error(cErr))
}
}
x.mu.Unlock()
x.wg.Wait()
return nil
}
// addXauthEntry adds an Xauthority entry to the Xauthority file.
// The Xauthority file is located at ~/.Xauthority.
func addXauthEntry(ctx context.Context, fs afero.Fs, host string, display string, authProtocol string, authCookie string) error {
+229 -14
View File
@@ -3,9 +3,9 @@ package agentssh_test
import (
"bufio"
"bytes"
"context"
"encoding/hex"
"fmt"
"io"
"net"
"os"
"path/filepath"
@@ -32,10 +32,19 @@ func TestServer_X11(t *testing.T) {
t.Skip("X11 forwarding is only supported on Linux")
}
ctx := context.Background()
ctx := testutil.Context(t, testutil.WaitShort)
logger := testutil.Logger(t)
fs := afero.NewOsFs()
s, err := agentssh.NewServer(ctx, logger, prometheus.NewRegistry(), fs, agentexec.DefaultExecer, &agentssh.Config{})
fs := afero.NewMemMapFs()
// Use in-process networking for X11 forwarding.
inproc := testutil.NewInProcNet()
// Create server config with custom X11 listener.
cfg := &agentssh.Config{
X11Net: inproc,
}
s, err := agentssh.NewServer(ctx, logger, prometheus.NewRegistry(), fs, agentexec.DefaultExecer, cfg)
require.NoError(t, err)
defer s.Close()
err = s.UpdateHostSigner(42)
@@ -93,17 +102,15 @@ func TestServer_X11(t *testing.T) {
x11Chans := c.HandleChannelOpen("x11")
payload := "hello world"
require.Eventually(t, func() bool {
conn, err := net.Dial("tcp", fmt.Sprintf("localhost:%d", agentssh.X11StartPort+displayNumber))
if err == nil {
_, err = conn.Write([]byte(payload))
assert.NoError(t, err)
_ = conn.Close()
}
return err == nil
}, testutil.WaitShort, testutil.IntervalFast)
go func() {
conn, err := inproc.Dial(ctx, testutil.NewAddr("tcp", fmt.Sprintf("localhost:%d", agentssh.X11StartPort+displayNumber)))
assert.NoError(t, err)
_, err = conn.Write([]byte(payload))
assert.NoError(t, err)
_ = conn.Close()
}()
x11 := <-x11Chans
x11 := testutil.RequireReceive(ctx, t, x11Chans)
ch, reqs, err := x11.Accept()
require.NoError(t, err)
go gossh.DiscardRequests(reqs)
@@ -121,3 +128,211 @@ func TestServer_X11(t *testing.T) {
_, err = fs.Stat(filepath.Join(home, ".Xauthority"))
require.NoError(t, err)
}
func TestServer_X11_EvictionLRU(t *testing.T) {
t.Parallel()
if runtime.GOOS != "linux" {
t.Skip("X11 forwarding is only supported on Linux")
}
ctx := testutil.Context(t, testutil.WaitSuperLong)
logger := testutil.Logger(t)
fs := afero.NewMemMapFs()
// Use in-process networking for X11 forwarding.
inproc := testutil.NewInProcNet()
cfg := &agentssh.Config{
X11Net: inproc,
}
s, err := agentssh.NewServer(ctx, logger, prometheus.NewRegistry(), fs, agentexec.DefaultExecer, cfg)
require.NoError(t, err)
defer s.Close()
err = s.UpdateHostSigner(42)
require.NoError(t, err)
ln, err := net.Listen("tcp", "127.0.0.1:0")
require.NoError(t, err)
done := testutil.Go(t, func() {
err := s.Serve(ln)
assert.Error(t, err)
})
c := sshClient(t, ln.Addr().String())
// block off one port to test x11Forwarder evicts at highest port, not number of listeners.
externalListener, err := inproc.Listen("tcp",
fmt.Sprintf("localhost:%d", agentssh.X11StartPort+agentssh.X11DefaultDisplayOffset+1))
require.NoError(t, err)
defer externalListener.Close()
// Calculate how many simultaneous X11 sessions we can create given the
// configured port range.
startPort := agentssh.X11StartPort + agentssh.X11DefaultDisplayOffset
maxSessions := agentssh.X11MaxPort - startPort + 1 - 1 // -1 for the blocked port
require.Greater(t, maxSessions, 0, "expected a positive maxSessions value")
// shellSession holds references to the session and its standard streams so
// that the test can keep them open (and optionally interact with them) for
// the lifetime of the test. If we don't start the Shell with pipes in place,
// the session will be torn down asynchronously during the test.
type shellSession struct {
sess *gossh.Session
stdin io.WriteCloser
stdout io.Reader
stderr io.Reader
// scanner is used to read the output of the session, line by line.
scanner *bufio.Scanner
}
sessions := make([]shellSession, 0, maxSessions)
for i := 0; i < maxSessions; i++ {
sess, err := c.NewSession()
require.NoError(t, err)
_, err = sess.SendRequest("x11-req", true, gossh.Marshal(ssh.X11{
AuthProtocol: "MIT-MAGIC-COOKIE-1",
AuthCookie: hex.EncodeToString([]byte(fmt.Sprintf("cookie%d", i))),
ScreenNumber: uint32(0),
}))
require.NoError(t, err)
stdin, err := sess.StdinPipe()
require.NoError(t, err)
stdout, err := sess.StdoutPipe()
require.NoError(t, err)
stderr, err := sess.StderrPipe()
require.NoError(t, err)
require.NoError(t, sess.Shell())
// The SSH server lazily starts the session. We need to write a command
// and read back to ensure the X11 forwarding is started.
scanner := bufio.NewScanner(stdout)
msg := fmt.Sprintf("ready-%d", i)
_, err = stdin.Write([]byte("echo " + msg + "\n"))
require.NoError(t, err)
// Read until we get the message (first token may be empty due to shell prompt)
for scanner.Scan() {
line := strings.TrimSpace(scanner.Text())
if strings.Contains(line, msg) {
break
}
}
require.NoError(t, scanner.Err())
sessions = append(sessions, shellSession{
sess: sess,
stdin: stdin,
stdout: stdout,
stderr: stderr,
scanner: scanner,
})
}
// Connect X11 forwarding to the first session. This is used to test that
// connecting counts as a use of the display.
x11Chans := c.HandleChannelOpen("x11")
payload := "hello world"
go func() {
conn, err := inproc.Dial(ctx, testutil.NewAddr("tcp", fmt.Sprintf("localhost:%d", agentssh.X11StartPort+agentssh.X11DefaultDisplayOffset)))
if !assert.NoError(t, err) {
return
}
_, err = conn.Write([]byte(payload))
assert.NoError(t, err)
_ = conn.Close()
}()
x11 := testutil.RequireReceive(ctx, t, x11Chans)
ch, reqs, err := x11.Accept()
require.NoError(t, err)
go gossh.DiscardRequests(reqs)
got := make([]byte, len(payload))
_, err = ch.Read(got)
require.NoError(t, err)
assert.Equal(t, payload, string(got))
_ = ch.Close()
// Create one more session which should evict a session and reuse the display.
// The first session was used to connect X11 forwarding, so it should not be evicted.
// Therefore, the second session should be evicted and its display reused.
extraSess, err := c.NewSession()
require.NoError(t, err)
_, err = extraSess.SendRequest("x11-req", true, gossh.Marshal(ssh.X11{
AuthProtocol: "MIT-MAGIC-COOKIE-1",
AuthCookie: hex.EncodeToString([]byte("extra")),
ScreenNumber: uint32(0),
}))
require.NoError(t, err)
// Ask the remote side for the DISPLAY value so we can extract the display
// number that was assigned to this session.
out, err := extraSess.Output("echo DISPLAY=$DISPLAY")
require.NoError(t, err)
// Example output line: "DISPLAY=localhost:10.0".
var newDisplayNumber int
{
sc := bufio.NewScanner(bytes.NewReader(out))
for sc.Scan() {
line := strings.TrimSpace(sc.Text())
if strings.HasPrefix(line, "DISPLAY=") {
parts := strings.SplitN(line, ":", 2)
require.Len(t, parts, 2)
displayPart := parts[1]
if strings.Contains(displayPart, ".") {
displayPart = strings.SplitN(displayPart, ".", 2)[0]
}
var convErr error
newDisplayNumber, convErr = strconv.Atoi(displayPart)
require.NoError(t, convErr)
break
}
}
require.NoError(t, sc.Err())
}
// The display number reused should correspond to the SECOND session (display offset 12)
expectedDisplay := agentssh.X11DefaultDisplayOffset + 2 // +1 was blocked port
assert.Equal(t, expectedDisplay, newDisplayNumber, "second session should have been evicted and its display reused")
// First session should still be alive: send cmd and read output.
msgFirst := "still-alive"
_, err = sessions[0].stdin.Write([]byte("echo " + msgFirst + "\n"))
require.NoError(t, err)
for sessions[0].scanner.Scan() {
line := strings.TrimSpace(sessions[0].scanner.Text())
if strings.Contains(line, msgFirst) {
break
}
}
require.NoError(t, sessions[0].scanner.Err())
// Second session should now be closed.
_, err = sessions[1].stdin.Write([]byte("echo dead\n"))
require.ErrorIs(t, err, io.EOF)
err = sessions[1].sess.Wait()
require.Error(t, err)
// Cleanup.
for i, sh := range sessions {
if i == 1 {
// already closed
continue
}
err = sh.stdin.Close()
require.NoError(t, err)
err = sh.sess.Wait()
require.NoError(t, err)
}
err = extraSess.Close()
require.ErrorIs(t, err, io.EOF)
err = s.Close()
require.NoError(t, err)
_ = testutil.TryReceive(ctx, t, done)
}
+10 -2
View File
@@ -6,6 +6,7 @@ import (
"time"
"github.com/go-chi/chi/v5"
"github.com/google/uuid"
"github.com/coder/coder/v2/coderd/httpapi"
"github.com/coder/coder/v2/codersdk"
@@ -36,12 +37,19 @@ func (a *agent) apiHandler() http.Handler {
cacheDuration: cacheDuration,
}
if a.containerAPI != nil {
if a.devcontainers {
r.Mount("/api/v0/containers", a.containerAPI.Routes())
} else if manifest := a.manifest.Load(); manifest != nil && manifest.ParentID != uuid.Nil {
r.HandleFunc("/api/v0/containers", func(w http.ResponseWriter, r *http.Request) {
httpapi.Write(r.Context(), w, http.StatusForbidden, codersdk.Response{
Message: "Dev Container feature not supported.",
Detail: "Dev Container integration inside other Dev Containers is explicitly not supported.",
})
})
} else {
r.HandleFunc("/api/v0/containers", func(w http.ResponseWriter, r *http.Request) {
httpapi.Write(r.Context(), w, http.StatusForbidden, codersdk.Response{
Message: "The agent dev containers feature is experimental and not enabled by default.",
Message: "Dev Container feature not enabled.",
Detail: "To enable this feature, set CODER_AGENT_DEVCONTAINERS_ENABLE=true in your template.",
})
})
+19
View File
@@ -0,0 +1,19 @@
package archivefs
import (
"archive/zip"
"io"
"io/fs"
"github.com/spf13/afero"
"github.com/spf13/afero/zipfs"
)
// FromZipReader creates a read-only in-memory FS
func FromZipReader(r io.ReaderAt, size int64) (fs.FS, error) {
zr, err := zip.NewReader(r, size)
if err != nil {
return nil, err
}
return afero.NewIOFS(zipfs.New(zr)), nil
}
+86
View File
@@ -0,0 +1,86 @@
{
"vcs": {
"enabled": true,
"clientKind": "git",
"useIgnoreFile": true,
"defaultBranch": "main"
},
"files": {
"includes": [
"**",
"!**/pnpm-lock.yaml"
],
"ignoreUnknown": true
},
"linter": {
"rules": {
"a11y": {
"noSvgWithoutTitle": "off",
"useButtonType": "off",
"useSemanticElements": "off",
"noStaticElementInteractions": "off"
},
"correctness": {
"noUnusedImports": "warn",
"useUniqueElementIds": "off", // TODO: This is new but we want to fix it
"noNestedComponentDefinitions": "off", // TODO: Investigate, since it is used by shadcn components
"noUnusedVariables": {
"level": "warn",
"options": {
"ignoreRestSiblings": true
}
}
},
"style": {
"noNonNullAssertion": "off",
"noParameterAssign": "off",
"useDefaultParameterLast": "off",
"useSelfClosingElements": "off",
"useAsConstAssertion": "error",
"useEnumInitializers": "error",
"useSingleVarDeclarator": "error",
"noUnusedTemplateLiteral": "error",
"useNumberNamespace": "error",
"noInferrableTypes": "error",
"noUselessElse": "error",
"noRestrictedImports": {
"level": "error",
"options": {
"paths": {
"@mui/material": "Use @mui/material/<name> instead. See: https://material-ui.com/guides/minimizing-bundle-size/.",
"@mui/icons-material": "Use @mui/icons-material/<name> instead. See: https://material-ui.com/guides/minimizing-bundle-size/.",
"@mui/material/Avatar": "Use components/Avatar/Avatar instead.",
"@mui/material/Alert": "Use components/Alert/Alert instead.",
"@mui/material/Popover": "Use components/Popover/Popover instead.",
"@mui/material/Typography": "Use native HTML elements instead. Eg: <span>, <p>, <h1>, etc.",
"@mui/material/Box": "Use a <div> instead.",
"@mui/material/styles": "Import from @emotion/react instead.",
"lodash": "Use lodash/<name> instead."
}
}
}
},
"suspicious": {
"noArrayIndexKey": "off",
"noThenProperty": "off",
"noTemplateCurlyInString": "off",
"useIterableCallbackReturn": "off",
"noUnknownAtRules": "off", // Allow Tailwind directives
"noConsole": {
"level": "error",
"options": {
"allow": [
"error",
"info",
"warn"
]
}
}
},
"complexity": {
"noImportantStyles": "off" // TODO: check and fix !important styles
}
}
},
"$schema": "https://biomejs.dev/schemas/2.2.0/schema.json"
}
+10
View File
@@ -0,0 +1,10 @@
apiVersion: backstage.io/v1alpha1
kind: Component
metadata:
name: coder
annotations:
github.com/project-slug: 'coder/coder'
spec:
type: service
lifecycle: production
owner: rd
+34 -16
View File
@@ -40,22 +40,24 @@ import (
func (r *RootCmd) workspaceAgent() *serpent.Command {
var (
auth string
logDir string
scriptDataDir string
pprofAddress string
noReap bool
sshMaxTimeout time.Duration
tailnetListenPort int64
prometheusAddress string
debugAddress string
slogHumanPath string
slogJSONPath string
slogStackdriverPath string
blockFileTransfer bool
agentHeaderCommand string
agentHeader []string
devcontainers bool
auth string
logDir string
scriptDataDir string
pprofAddress string
noReap bool
sshMaxTimeout time.Duration
tailnetListenPort int64
prometheusAddress string
debugAddress string
slogHumanPath string
slogJSONPath string
slogStackdriverPath string
blockFileTransfer bool
agentHeaderCommand string
agentHeader []string
devcontainers bool
devcontainerProjectDiscovery bool
devcontainerDiscoveryAutostart bool
)
cmd := &serpent.Command{
Use: "agent",
@@ -364,6 +366,8 @@ func (r *RootCmd) workspaceAgent() *serpent.Command {
Devcontainers: devcontainers,
DevcontainerAPIOptions: []agentcontainers.Option{
agentcontainers.WithSubAgentURL(r.agentURL.String()),
agentcontainers.WithProjectDiscovery(devcontainerProjectDiscovery),
agentcontainers.WithDiscoveryAutostart(devcontainerDiscoveryAutostart),
},
})
@@ -510,6 +514,20 @@ func (r *RootCmd) workspaceAgent() *serpent.Command {
Description: "Allow the agent to automatically detect running devcontainers.",
Value: serpent.BoolOf(&devcontainers),
},
{
Flag: "devcontainers-project-discovery-enable",
Default: "true",
Env: "CODER_AGENT_DEVCONTAINERS_PROJECT_DISCOVERY_ENABLE",
Description: "Allow the agent to search the filesystem for devcontainer projects.",
Value: serpent.BoolOf(&devcontainerProjectDiscovery),
},
{
Flag: "devcontainers-discovery-autostart-enable",
Default: "false",
Env: "CODER_AGENT_DEVCONTAINERS_DISCOVERY_AUTOSTART_ENABLE",
Description: "Allow the agent to autostart devcontainer projects it discovers based on their configuration.",
Value: serpent.BoolOf(&devcontainerDiscoveryAutostart),
},
}
return cmd
+19 -3
View File
@@ -21,6 +21,7 @@ import (
"github.com/coder/coder/v2/coderd/coderdtest"
"github.com/coder/coder/v2/coderd/database"
"github.com/coder/coder/v2/coderd/database/dbfake"
"github.com/coder/coder/v2/coderd/database/dbtestutil"
"github.com/coder/coder/v2/codersdk"
"github.com/coder/coder/v2/codersdk/workspacesdk"
"github.com/coder/coder/v2/provisionersdk/proto"
@@ -67,7 +68,12 @@ func TestWorkspaceAgent(t *testing.T) {
t.Parallel()
instanceID := "instanceidentifier"
certificates, metadataClient := coderdtest.NewAzureInstanceIdentity(t, instanceID)
client, db := coderdtest.NewWithDatabase(t, &coderdtest.Options{
db, ps := dbtestutil.NewDB(t,
dbtestutil.WithDumpOnFailure(),
)
client := coderdtest.New(t, &coderdtest.Options{
Database: db,
Pubsub: ps,
AzureCertificates: certificates,
})
user := coderdtest.CreateFirstUser(t, client)
@@ -106,7 +112,12 @@ func TestWorkspaceAgent(t *testing.T) {
t.Parallel()
instanceID := "instanceidentifier"
certificates, metadataClient := coderdtest.NewAWSInstanceIdentity(t, instanceID)
client, db := coderdtest.NewWithDatabase(t, &coderdtest.Options{
db, ps := dbtestutil.NewDB(t,
dbtestutil.WithDumpOnFailure(),
)
client := coderdtest.New(t, &coderdtest.Options{
Database: db,
Pubsub: ps,
AWSCertificates: certificates,
})
user := coderdtest.CreateFirstUser(t, client)
@@ -146,7 +157,12 @@ func TestWorkspaceAgent(t *testing.T) {
t.Parallel()
instanceID := "instanceidentifier"
validator, metadataClient := coderdtest.NewGoogleInstanceIdentity(t, instanceID, false)
client, db := coderdtest.NewWithDatabase(t, &coderdtest.Options{
db, ps := dbtestutil.NewDB(t,
dbtestutil.WithDumpOnFailure(),
)
client := coderdtest.New(t, &coderdtest.Options{
Database: db,
Pubsub: ps,
GoogleTokenValidator: validator,
})
owner := coderdtest.CreateFirstUser(t, client)
+6 -5
View File
@@ -38,15 +38,16 @@ func RichParameter(inv *serpent.Invocation, templateVersionParameter codersdk.Te
// Move the cursor up a single line for nicer display!
_, _ = fmt.Fprint(inv.Stdout, "\033[1A")
var options []string
err = json.Unmarshal([]byte(templateVersionParameter.DefaultValue), &options)
var defaults []string
err = json.Unmarshal([]byte(templateVersionParameter.DefaultValue), &defaults)
if err != nil {
return "", err
}
values, err := MultiSelect(inv, MultiSelectOptions{
Options: options,
Defaults: options,
values, err := RichMultiSelect(inv, RichMultiSelectOptions{
Options: templateVersionParameter.Options,
Defaults: defaults,
EnableCustomInput: templateVersionParameter.FormType == "tag-select",
})
if err == nil {
v, err := json.Marshal(&values)
+121 -28
View File
@@ -12,6 +12,7 @@ import (
"golang.org/x/mod/semver"
"github.com/coder/coder/v2/coderd/database/dbtime"
"github.com/coder/coder/v2/coderd/util/slice"
"github.com/coder/coder/v2/codersdk"
"github.com/coder/pretty"
)
@@ -29,6 +30,7 @@ type WorkspaceResourcesOptions struct {
ServerVersion string
ListeningPorts map[uuid.UUID]codersdk.WorkspaceAgentListeningPortsResponse
Devcontainers map[uuid.UUID]codersdk.WorkspaceAgentListContainersResponse
ShowDetails bool
}
// WorkspaceResources displays the connection status and tree-view of provided resources.
@@ -69,7 +71,11 @@ func WorkspaceResources(writer io.Writer, resources []codersdk.WorkspaceResource
totalAgents := 0
for _, resource := range resources {
totalAgents += len(resource.Agents)
for _, agent := range resource.Agents {
if !agent.ParentID.Valid {
totalAgents++
}
}
}
for _, resource := range resources {
@@ -94,12 +100,15 @@ func WorkspaceResources(writer io.Writer, resources []codersdk.WorkspaceResource
"",
})
// Display all agents associated with the resource.
for index, agent := range resource.Agents {
agents := slice.Filter(resource.Agents, func(agent codersdk.WorkspaceAgent) bool {
return !agent.ParentID.Valid
})
for index, agent := range agents {
tableWriter.AppendRow(renderAgentRow(agent, index, totalAgents, options))
for _, row := range renderListeningPorts(options, agent.ID, index, totalAgents) {
tableWriter.AppendRow(row)
}
for _, row := range renderDevcontainers(options, agent.ID, index, totalAgents) {
for _, row := range renderDevcontainers(resources, options, agent.ID, index, totalAgents) {
tableWriter.AppendRow(row)
}
}
@@ -125,7 +134,7 @@ func renderAgentRow(agent codersdk.WorkspaceAgent, index, totalAgents int, optio
}
if !options.HideAccess {
sshCommand := "coder ssh " + options.WorkspaceName
if totalAgents > 1 {
if totalAgents > 1 || len(options.Devcontainers) > 0 {
sshCommand += "." + agent.Name
}
sshCommand = pretty.Sprint(DefaultStyles.Code, sshCommand)
@@ -164,45 +173,129 @@ func renderPortRow(port codersdk.WorkspaceAgentListeningPort, idx, total int) ta
return table.Row{sb.String()}
}
func renderDevcontainers(wro WorkspaceResourcesOptions, agentID uuid.UUID, index, totalAgents int) []table.Row {
func renderDevcontainers(resources []codersdk.WorkspaceResource, wro WorkspaceResourcesOptions, agentID uuid.UUID, index, totalAgents int) []table.Row {
var rows []table.Row
if wro.Devcontainers == nil {
return []table.Row{}
}
dc, ok := wro.Devcontainers[agentID]
if !ok || len(dc.Containers) == 0 {
if !ok || len(dc.Devcontainers) == 0 {
return []table.Row{}
}
rows = append(rows, table.Row{
fmt.Sprintf(" %s─ %s", renderPipe(index, totalAgents), "Devcontainers"),
})
for idx, container := range dc.Containers {
rows = append(rows, renderDevcontainerRow(container, idx, len(dc.Containers)))
for idx, devcontainer := range dc.Devcontainers {
rows = append(rows, renderDevcontainerRow(resources, devcontainer, idx, len(dc.Devcontainers), wro)...)
}
return rows
}
func renderDevcontainerRow(container codersdk.WorkspaceAgentContainer, index, total int) table.Row {
var row table.Row
var sb strings.Builder
_, _ = sb.WriteString(" ")
_, _ = sb.WriteString(renderPipe(index, total))
_, _ = sb.WriteString("─ ")
_, _ = sb.WriteString(pretty.Sprintf(DefaultStyles.Code, "%s", container.FriendlyName))
row = append(row, sb.String())
sb.Reset()
if container.Running {
_, _ = sb.WriteString(pretty.Sprintf(DefaultStyles.Keyword, "(%s)", container.Status))
} else {
_, _ = sb.WriteString(pretty.Sprintf(DefaultStyles.Error, "(%s)", container.Status))
func renderDevcontainerRow(resources []codersdk.WorkspaceResource, devcontainer codersdk.WorkspaceAgentDevcontainer, index, total int, wro WorkspaceResourcesOptions) []table.Row {
var rows []table.Row
// If the devcontainer is running and has an associated agent, we want to
// display the agent's details. Otherwise, we just display the devcontainer
// name and status.
var subAgent *codersdk.WorkspaceAgent
displayName := devcontainer.Name
if devcontainer.Agent != nil && devcontainer.Status == codersdk.WorkspaceAgentDevcontainerStatusRunning {
for _, resource := range resources {
if agent, found := slice.Find(resource.Agents, func(agent codersdk.WorkspaceAgent) bool {
return agent.ID == devcontainer.Agent.ID
}); found {
subAgent = &agent
break
}
}
if subAgent != nil {
displayName = subAgent.Name
displayName += fmt.Sprintf(" (%s, %s)", subAgent.OperatingSystem, subAgent.Architecture)
}
}
if devcontainer.Container != nil {
displayName += " " + pretty.Sprint(DefaultStyles.Keyword, "["+devcontainer.Container.FriendlyName+"]")
}
// Build the main row.
row := table.Row{
fmt.Sprintf(" %s─ %s", renderPipe(index, total), displayName),
}
// Add status, health, and version columns.
if !wro.HideAgentState {
if subAgent != nil {
row = append(row, renderAgentStatus(*subAgent))
row = append(row, renderAgentHealth(*subAgent))
row = append(row, renderAgentVersion(subAgent.Version, wro.ServerVersion))
} else {
row = append(row, renderDevcontainerStatus(devcontainer.Status))
row = append(row, "") // No health for devcontainer without agent.
row = append(row, "") // No version for devcontainer without agent.
}
}
// Add access column.
if !wro.HideAccess {
if subAgent != nil {
accessString := fmt.Sprintf("coder ssh %s.%s", wro.WorkspaceName, subAgent.Name)
row = append(row, pretty.Sprint(DefaultStyles.Code, accessString))
} else {
row = append(row, "") // No access for devcontainers without agent.
}
}
rows = append(rows, row)
// Add error message if present.
if errorMessage := devcontainer.Error; errorMessage != "" {
// Cap error message length for display.
if !wro.ShowDetails && len(errorMessage) > 80 {
errorMessage = errorMessage[:79] + "…"
}
errorRow := table.Row{
" × " + pretty.Sprint(DefaultStyles.Error, errorMessage),
"",
"",
"",
}
if !wro.HideAccess {
errorRow = append(errorRow, "")
}
rows = append(rows, errorRow)
}
// Add listening ports for the devcontainer agent.
if subAgent != nil {
portRows := renderListeningPorts(wro, subAgent.ID, index, total)
for _, portRow := range portRows {
// Adjust indentation for ports under devcontainer agent.
if len(portRow) > 0 {
if str, ok := portRow[0].(string); ok {
portRow[0] = " " + str // Add extra indentation.
}
}
rows = append(rows, portRow)
}
}
return rows
}
func renderDevcontainerStatus(status codersdk.WorkspaceAgentDevcontainerStatus) string {
switch status {
case codersdk.WorkspaceAgentDevcontainerStatusRunning:
return pretty.Sprint(DefaultStyles.Keyword, "▶ running")
case codersdk.WorkspaceAgentDevcontainerStatusStopped:
return pretty.Sprint(DefaultStyles.Placeholder, "⏹ stopped")
case codersdk.WorkspaceAgentDevcontainerStatusStarting:
return pretty.Sprint(DefaultStyles.Warn, "⧗ starting")
case codersdk.WorkspaceAgentDevcontainerStatusError:
return pretty.Sprint(DefaultStyles.Error, "✘ error")
default:
return pretty.Sprint(DefaultStyles.Placeholder, "○ "+string(status))
}
row = append(row, sb.String())
sb.Reset()
// "health" is not applicable here.
row = append(row, sb.String())
_, _ = sb.WriteString(container.Image)
row = append(row, sb.String())
return row
}
func renderAgentStatus(agent codersdk.WorkspaceAgent) string {
+72
View File
@@ -5,6 +5,7 @@ import (
"fmt"
"os"
"os/signal"
"slices"
"strings"
"syscall"
@@ -299,6 +300,77 @@ func (m selectModel) filteredOptions() []string {
return options
}
type RichMultiSelectOptions struct {
Message string
Options []codersdk.TemplateVersionParameterOption
Defaults []string
EnableCustomInput bool
}
func RichMultiSelect(inv *serpent.Invocation, richOptions RichMultiSelectOptions) ([]string, error) {
var opts []string
var defaultOpts []string
asLine := func(option codersdk.TemplateVersionParameterOption) string {
line := option.Name
if len(option.Description) > 0 {
line += ": " + option.Description
}
return line
}
var predefinedOpts []string
for i, option := range richOptions.Options {
opts = append(opts, asLine(option)) // Some options may have description defined.
// Check if option is selected by default
if slices.Contains(richOptions.Defaults, option.Value) {
defaultOpts = append(defaultOpts, opts[i])
predefinedOpts = append(predefinedOpts, option.Value)
}
}
// Check if "defaults" contains extra/custom options, user could select them.
for _, def := range richOptions.Defaults {
if !slices.Contains(predefinedOpts, def) {
opts = append(opts, def)
defaultOpts = append(defaultOpts, def)
}
}
selected, err := MultiSelect(inv, MultiSelectOptions{
Message: richOptions.Message,
Options: opts,
Defaults: defaultOpts,
EnableCustomInput: richOptions.EnableCustomInput,
})
if err != nil {
return nil, err
}
// Check selected option, convert descriptions (line) to values
//
// The function must return an initialized empty array, since it is later marshaled
// into JSON. Otherwise, `var results []string` would be marshaled to "null".
// See: https://github.com/golang/go/issues/27589
results := []string{}
for _, sel := range selected {
custom := true
for i, option := range richOptions.Options {
if asLine(option) == sel {
results = append(results, richOptions.Options[i].Value)
custom = false
break
}
}
if custom {
results = append(results, sel)
}
}
return results, nil
}
type MultiSelectOptions struct {
Message string
Options []string
+116 -56
View File
@@ -52,15 +52,8 @@ func TestRichSelect(t *testing.T) {
go func() {
resp, err := newRichSelect(ptty, cliui.RichSelectOptions{
Options: []codersdk.TemplateVersionParameterOption{
{
Name: "A-Name",
Value: "A-Value",
Description: "A-Description.",
}, {
Name: "B-Name",
Value: "B-Value",
Description: "B-Description.",
},
{Name: "A-Name", Value: "A-Value", Description: "A-Description."},
{Name: "B-Name", Value: "B-Value", Description: "B-Description."},
},
})
assert.NoError(t, err)
@@ -86,44 +79,130 @@ func newRichSelect(ptty *ptytest.PTY, opts cliui.RichSelectOptions) (string, err
return value, inv.Run()
}
func TestMultiSelect(t *testing.T) {
func TestRichMultiSelect(t *testing.T) {
t.Parallel()
t.Run("MultiSelect", func(t *testing.T) {
items := []string{"aaa", "bbb", "ccc"}
t.Parallel()
ptty := ptytest.New(t)
msgChan := make(chan []string)
go func() {
resp, err := newMultiSelect(ptty, items)
assert.NoError(t, err)
msgChan <- resp
}()
require.Equal(t, items, <-msgChan)
})
tests := []struct {
name string
options []codersdk.TemplateVersionParameterOption
defaults []string
allowCustom bool
want []string
}{
{
name: "Predefined",
options: []codersdk.TemplateVersionParameterOption{
{Name: "AAA", Description: "This is AAA", Value: "aaa"},
{Name: "BBB", Description: "This is BBB", Value: "bbb"},
{Name: "CCC", Description: "This is CCC", Value: "ccc"},
},
defaults: []string{"bbb", "ccc"},
allowCustom: false,
want: []string{"bbb", "ccc"},
},
{
name: "Custom",
options: []codersdk.TemplateVersionParameterOption{
{Name: "AAA", Description: "This is AAA", Value: "aaa"},
{Name: "BBB", Description: "This is BBB", Value: "bbb"},
{Name: "CCC", Description: "This is CCC", Value: "ccc"},
},
defaults: []string{"aaa", "bbb"},
allowCustom: true,
want: []string{"aaa", "bbb"},
},
{
name: "NoOptionSelected",
options: []codersdk.TemplateVersionParameterOption{
{Name: "AAA", Description: "This is AAA", Value: "aaa"},
{Name: "BBB", Description: "This is BBB", Value: "bbb"},
{Name: "CCC", Description: "This is CCC", Value: "ccc"},
},
defaults: []string{},
allowCustom: false,
want: []string{},
},
}
t.Run("MultiSelectWithCustomInput", func(t *testing.T) {
t.Parallel()
items := []string{"Code", "Chairs", "Whale", "Diamond", "Carrot"}
ptty := ptytest.New(t)
msgChan := make(chan []string)
go func() {
resp, err := newMultiSelectWithCustomInput(ptty, items)
assert.NoError(t, err)
msgChan <- resp
}()
require.Equal(t, items, <-msgChan)
})
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
t.Parallel()
var selectedItems []string
var err error
cmd := &serpent.Command{
Handler: func(inv *serpent.Invocation) error {
selectedItems, err = cliui.RichMultiSelect(inv, cliui.RichMultiSelectOptions{
Options: tt.options,
Defaults: tt.defaults,
EnableCustomInput: tt.allowCustom,
})
return err
},
}
doneChan := make(chan struct{})
go func() {
defer close(doneChan)
err := cmd.Invoke().Run()
assert.NoError(t, err)
}()
<-doneChan
require.Equal(t, tt.want, selectedItems)
})
}
}
func newMultiSelectWithCustomInput(ptty *ptytest.PTY, items []string) ([]string, error) {
func TestMultiSelect(t *testing.T) {
t.Parallel()
tests := []struct {
name string
items []string
allowCustom bool
want []string
}{
{
name: "MultiSelect",
items: []string{"aaa", "bbb", "ccc"},
allowCustom: false,
want: []string{"aaa", "bbb", "ccc"},
},
{
name: "MultiSelectWithCustomInput",
items: []string{"Code", "Chairs", "Whale", "Diamond", "Carrot"},
allowCustom: true,
want: []string{"Code", "Chairs", "Whale", "Diamond", "Carrot"},
},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
t.Parallel()
ptty := ptytest.New(t)
msgChan := make(chan []string)
go func() {
resp, err := newMultiSelect(ptty, tt.items, tt.allowCustom)
assert.NoError(t, err)
msgChan <- resp
}()
require.Equal(t, tt.want, <-msgChan)
})
}
}
func newMultiSelect(pty *ptytest.PTY, items []string, custom bool) ([]string, error) {
var values []string
cmd := &serpent.Command{
Handler: func(inv *serpent.Invocation) error {
selectedItems, err := cliui.MultiSelect(inv, cliui.MultiSelectOptions{
Options: items,
Defaults: items,
EnableCustomInput: true,
EnableCustomInput: custom,
})
if err == nil {
values = selectedItems
@@ -132,25 +211,6 @@ func newMultiSelectWithCustomInput(ptty *ptytest.PTY, items []string) ([]string,
},
}
inv := cmd.Invoke()
ptty.Attach(inv)
return values, inv.Run()
}
func newMultiSelect(ptty *ptytest.PTY, items []string) ([]string, error) {
var values []string
cmd := &serpent.Command{
Handler: func(inv *serpent.Invocation) error {
selectedItems, err := cliui.MultiSelect(inv, cliui.MultiSelectOptions{
Options: items,
Defaults: items,
})
if err == nil {
values = selectedItems
}
return err
},
}
inv := cmd.Invoke()
ptty.Attach(inv)
pty.Attach(inv)
return values, inv.Run()
}
+1 -1
View File
@@ -446,7 +446,7 @@ func (r *RootCmd) configSSH() *serpent.Command {
if !bytes.Equal(configRaw, configModified) {
sshDir := filepath.Dir(sshConfigFile)
if err := os.MkdirAll(sshDir, 0700); err != nil {
if err := os.MkdirAll(sshDir, 0o700); err != nil {
return xerrors.Errorf("failed to create directory %q: %w", sshDir, err)
}
+7 -4
View File
@@ -204,10 +204,11 @@ func TestConfigSSH_MissingDirectory(t *testing.T) {
_, err = os.Stat(sshConfigPath)
require.NoError(t, err, "config file should exist")
// Check that the directory has proper permissions (0700)
// Check that the directory has proper permissions (rwx for owner, none for
// group and everyone)
sshDirInfo, err := os.Stat(sshDir)
require.NoError(t, err)
require.Equal(t, os.FileMode(0700), sshDirInfo.Mode().Perm(), "directory should have 0700 permissions")
require.Equal(t, os.FileMode(0o700), sshDirInfo.Mode().Perm(), "directory should have rwx------ permissions")
}
func TestConfigSSH_FileWriteAndOptionsFlow(t *testing.T) {
@@ -358,7 +359,8 @@ func TestConfigSSH_FileWriteAndOptionsFlow(t *testing.T) {
strings.Join([]string{
headerEnd,
"",
}, "\n")},
}, "\n"),
},
},
args: []string{"--ssh-option", "ForwardAgent=yes"},
matches: []match{
@@ -383,7 +385,8 @@ func TestConfigSSH_FileWriteAndOptionsFlow(t *testing.T) {
strings.Join([]string{
headerEnd,
"",
}, "\n")},
}, "\n"),
},
},
args: []string{"--ssh-option", "ForwardAgent=yes"},
matches: []match{
+149 -3
View File
@@ -2,6 +2,7 @@ package cli
import (
"context"
"errors"
"fmt"
"io"
"slices"
@@ -21,10 +22,23 @@ import (
"github.com/coder/serpent"
)
func (r *RootCmd) create() *serpent.Command {
// PresetNone represents the special preset value "none".
// It is used when a user runs `create --preset none`,
// indicating that the CLI should not apply any preset.
const PresetNone = "none"
var ErrNoPresetFound = xerrors.New("no preset found")
type CreateOptions struct {
BeforeCreate func(ctx context.Context, client *codersdk.Client, template codersdk.Template, templateVersionID uuid.UUID) error
AfterCreate func(ctx context.Context, inv *serpent.Invocation, client *codersdk.Client, workspace codersdk.Workspace) error
}
func (r *RootCmd) Create(opts CreateOptions) *serpent.Command {
var (
templateName string
templateVersion string
presetName string
startAt string
stopAfter time.Duration
workspaceName string
@@ -263,11 +277,52 @@ func (r *RootCmd) create() *serpent.Command {
}
}
// Get presets for the template version
tvPresets, err := client.TemplateVersionPresets(inv.Context(), templateVersionID)
if err != nil {
return xerrors.Errorf("failed to get presets: %w", err)
}
var preset *codersdk.Preset
var presetParameters []codersdk.WorkspaceBuildParameter
// If the template has no presets, or the user explicitly used --preset none,
// skip applying a preset
if len(tvPresets) > 0 && strings.ToLower(presetName) != PresetNone {
// Attempt to resolve which preset to use
preset, err = resolvePreset(tvPresets, presetName)
if err != nil {
if !errors.Is(err, ErrNoPresetFound) {
return xerrors.Errorf("unable to resolve preset: %w", err)
}
// If no preset found, prompt the user to choose a preset
if preset, err = promptPresetSelection(inv, tvPresets); err != nil {
return xerrors.Errorf("unable to prompt user for preset: %w", err)
}
}
// Convert preset parameters into workspace build parameters
presetParameters = presetParameterAsWorkspaceBuildParameters(preset.Parameters)
// Inform the user which preset was applied and its parameters
displayAppliedPreset(inv, preset, presetParameters)
} else {
// Inform the user that no preset was applied
_, _ = fmt.Fprintf(inv.Stdout, "%s", cliui.Bold("No preset applied."))
}
if opts.BeforeCreate != nil {
err = opts.BeforeCreate(inv.Context(), client, template, templateVersionID)
if err != nil {
return xerrors.Errorf("before create: %w", err)
}
}
richParameters, err := prepWorkspaceBuild(inv, client, prepWorkspaceBuildArgs{
Action: WorkspaceCreate,
TemplateVersionID: templateVersionID,
NewWorkspaceName: workspaceName,
PresetParameters: presetParameters,
RichParameterFile: parameterFlags.richParameterFile,
RichParameters: cliBuildParameters,
RichParameterDefaults: cliBuildParameterDefaults,
@@ -291,14 +346,21 @@ func (r *RootCmd) create() *serpent.Command {
ttlMillis = ptr.Ref(stopAfter.Milliseconds())
}
workspace, err := client.CreateUserWorkspace(inv.Context(), workspaceOwner, codersdk.CreateWorkspaceRequest{
req := codersdk.CreateWorkspaceRequest{
TemplateVersionID: templateVersionID,
Name: workspaceName,
AutostartSchedule: schedSpec,
TTLMillis: ttlMillis,
RichParameterValues: richParameters,
AutomaticUpdates: codersdk.AutomaticUpdates(autoUpdates),
})
}
// If a preset exists, update the create workspace request's preset ID
if preset != nil {
req.TemplateVersionPresetID = preset.ID
}
workspace, err := client.CreateUserWorkspace(inv.Context(), workspaceOwner, req)
if err != nil {
return xerrors.Errorf("create workspace: %w", err)
}
@@ -316,6 +378,14 @@ func (r *RootCmd) create() *serpent.Command {
cliui.Keyword(workspace.Name),
cliui.Timestamp(time.Now()),
)
if opts.AfterCreate != nil {
err = opts.AfterCreate(inv.Context(), inv, client, workspace)
if err != nil {
return err
}
}
return nil
},
}
@@ -333,6 +403,12 @@ func (r *RootCmd) create() *serpent.Command {
Description: "Specify a template version name.",
Value: serpent.StringOf(&templateVersion),
},
serpent.Option{
Flag: "preset",
Env: "CODER_PRESET_NAME",
Description: "Specify the name of a template version preset. Use 'none' to explicitly indicate that no preset should be used.",
Value: serpent.StringOf(&presetName),
},
serpent.Option{
Flag: "start-at",
Env: "CODER_WORKSPACE_START_AT",
@@ -377,12 +453,81 @@ type prepWorkspaceBuildArgs struct {
PromptEphemeralParameters bool
EphemeralParameters []codersdk.WorkspaceBuildParameter
PresetParameters []codersdk.WorkspaceBuildParameter
PromptRichParameters bool
RichParameters []codersdk.WorkspaceBuildParameter
RichParameterFile string
RichParameterDefaults []codersdk.WorkspaceBuildParameter
}
// resolvePreset returns the preset matching the given presetName (if specified),
// or the default preset (if any).
// Returns ErrNoPresetFound if no matching or default preset is found.
func resolvePreset(presets []codersdk.Preset, presetName string) (*codersdk.Preset, error) {
// If preset name is specified, find it
if presetName != "" {
for _, p := range presets {
if p.Name == presetName {
return &p, nil
}
}
return nil, xerrors.Errorf("preset %q not found", presetName)
}
// No preset name specified, search for the default preset
for _, p := range presets {
if p.Default {
return &p, nil
}
}
// No preset found
return nil, ErrNoPresetFound
}
// promptPresetSelection shows a CLI selection menu of the presets defined in the template version.
// Returns the selected preset
func promptPresetSelection(inv *serpent.Invocation, presets []codersdk.Preset) (*codersdk.Preset, error) {
presetMap := make(map[string]*codersdk.Preset)
var presetOptions []string
for _, preset := range presets {
var option string
if preset.Description == "" {
option = preset.Name
} else {
option = fmt.Sprintf("%s: %s", preset.Name, preset.Description)
}
presetOptions = append(presetOptions, option)
presetMap[option] = &preset
}
// Show selection UI
_, _ = fmt.Fprintln(inv.Stdout, pretty.Sprint(cliui.DefaultStyles.Wrap, "Select a preset below:"))
selected, err := cliui.Select(inv, cliui.SelectOptions{
Options: presetOptions,
HideSearch: true,
})
if err != nil {
return nil, xerrors.Errorf("failed to select preset: %w", err)
}
return presetMap[selected], nil
}
// displayAppliedPreset shows the user which preset was applied and its parameters
func displayAppliedPreset(inv *serpent.Invocation, preset *codersdk.Preset, parameters []codersdk.WorkspaceBuildParameter) {
label := fmt.Sprintf("Preset '%s'", preset.Name)
if preset.Default {
label += " (default)"
}
_, _ = fmt.Fprintf(inv.Stdout, "%s applied:\n", cliui.Bold(label))
for _, param := range parameters {
_, _ = fmt.Fprintf(inv.Stdout, " %s: '%s'\n", cliui.Bold(param.Name), param.Value)
}
}
// prepWorkspaceBuild will ensure a workspace build will succeed on the latest template version.
// Any missing params will be prompted to the user. It supports rich parameters.
func prepWorkspaceBuild(inv *serpent.Invocation, client *codersdk.Client, args prepWorkspaceBuildArgs) ([]codersdk.WorkspaceBuildParameter, error) {
@@ -411,6 +556,7 @@ func prepWorkspaceBuild(inv *serpent.Invocation, client *codersdk.Client, args p
WithSourceWorkspaceParameters(args.SourceWorkspaceParameters).
WithPromptEphemeralParameters(args.PromptEphemeralParameters).
WithEphemeralParameters(args.EphemeralParameters).
WithPresetParameters(args.PresetParameters).
WithPromptRichParameters(args.PromptRichParameters).
WithRichParameters(args.RichParameters).
WithRichParametersFile(parameterFile).
+639 -1
View File
@@ -12,6 +12,7 @@ import (
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
"github.com/coder/coder/v2/cli"
"github.com/coder/coder/v2/cli/clitest"
"github.com/coder/coder/v2/coderd/coderdtest"
"github.com/coder/coder/v2/coderd/externalauth"
@@ -298,7 +299,7 @@ func TestCreate(t *testing.T) {
})
}
func prepareEchoResponses(parameters []*proto.RichParameter) *echo.Responses {
func prepareEchoResponses(parameters []*proto.RichParameter, presets ...*proto.Preset) *echo.Responses {
return &echo.Responses{
Parse: echo.ParseComplete,
ProvisionPlan: []*proto.Response{
@@ -306,6 +307,7 @@ func prepareEchoResponses(parameters []*proto.RichParameter) *echo.Responses {
Type: &proto.Response_Plan{
Plan: &proto.PlanComplete{
Parameters: parameters,
Presets: presets,
},
},
},
@@ -663,6 +665,642 @@ func TestCreateWithRichParameters(t *testing.T) {
})
}
func TestCreateWithPreset(t *testing.T) {
t.Parallel()
const (
firstParameterName = "first_parameter"
firstParameterDisplayName = "First Parameter"
firstParameterDescription = "This is the first parameter"
firstParameterValue = "1"
firstOptionalParameterName = "first_optional_parameter"
firstOptionalParameterDescription = "This is the first optional parameter"
firstOptionalParameterValue = "1"
secondOptionalParameterName = "second_optional_parameter"
secondOptionalParameterDescription = "This is the second optional parameter"
secondOptionalParameterValue = "2"
thirdParameterName = "third_parameter"
thirdParameterDescription = "This is the third parameter"
thirdParameterValue = "3"
)
echoResponses := func(presets ...*proto.Preset) *echo.Responses {
return prepareEchoResponses([]*proto.RichParameter{
{
Name: firstParameterName,
DisplayName: firstParameterDisplayName,
Description: firstParameterDescription,
Mutable: true,
DefaultValue: firstParameterValue,
Options: []*proto.RichParameterOption{
{
Name: firstOptionalParameterName,
Description: firstOptionalParameterDescription,
Value: firstOptionalParameterValue,
},
{
Name: secondOptionalParameterName,
Description: secondOptionalParameterDescription,
Value: secondOptionalParameterValue,
},
},
},
{
Name: thirdParameterName,
Description: thirdParameterDescription,
DefaultValue: thirdParameterValue,
Mutable: true,
},
}, presets...)
}
// This test verifies that when a template has presets,
// including a default preset, and the user specifies a `--preset` flag,
// the CLI uses the specified preset instead of the default
t.Run("PresetFlag", func(t *testing.T) {
t.Parallel()
client := coderdtest.New(t, &coderdtest.Options{IncludeProvisionerDaemon: true})
owner := coderdtest.CreateFirstUser(t, client)
member, _ := coderdtest.CreateAnotherUser(t, client, owner.OrganizationID)
// Given: a template and a template version with two presets, including a default
defaultPreset := proto.Preset{
Name: "preset-default",
Default: true,
Parameters: []*proto.PresetParameter{
{Name: thirdParameterName, Value: thirdParameterValue},
},
}
preset := proto.Preset{
Name: "preset-test",
Parameters: []*proto.PresetParameter{
{Name: firstParameterName, Value: secondOptionalParameterValue},
{Name: thirdParameterName, Value: thirdParameterValue},
},
}
version := coderdtest.CreateTemplateVersion(t, client, owner.OrganizationID, echoResponses(&defaultPreset, &preset))
coderdtest.AwaitTemplateVersionJobCompleted(t, client, version.ID)
template := coderdtest.CreateTemplate(t, client, owner.OrganizationID, version.ID)
// When: running the create command with the specified preset
workspaceName := "my-workspace"
inv, root := clitest.New(t, "create", workspaceName, "--template", template.Name, "-y", "--preset", preset.Name)
clitest.SetupConfig(t, member, root)
pty := ptytest.New(t).Attach(inv)
inv.Stdout = pty.Output()
inv.Stderr = pty.Output()
err := inv.Run()
require.NoError(t, err)
// Should: display the selected preset as well as its parameters
presetName := fmt.Sprintf("Preset '%s' applied:", preset.Name)
pty.ExpectMatch(presetName)
pty.ExpectMatch(fmt.Sprintf("%s: '%s'", firstParameterName, secondOptionalParameterValue))
pty.ExpectMatch(fmt.Sprintf("%s: '%s'", thirdParameterName, thirdParameterValue))
// Verify if the new workspace uses expected parameters.
ctx, cancel := context.WithTimeout(context.Background(), testutil.WaitShort)
defer cancel()
tvPresets, err := client.TemplateVersionPresets(ctx, version.ID)
require.NoError(t, err)
require.Len(t, tvPresets, 2)
var selectedPreset *codersdk.Preset
for _, tvPreset := range tvPresets {
if tvPreset.Name == preset.Name {
selectedPreset = &tvPreset
}
}
require.NotNil(t, selectedPreset)
workspaces, err := client.Workspaces(ctx, codersdk.WorkspaceFilter{
Name: workspaceName,
})
require.NoError(t, err)
require.Len(t, workspaces.Workspaces, 1)
// Should: create a workspace using the expected template version and the preset-defined parameters
workspaceLatestBuild := workspaces.Workspaces[0].LatestBuild
require.Equal(t, version.ID, workspaceLatestBuild.TemplateVersionID)
require.Equal(t, selectedPreset.ID, *workspaceLatestBuild.TemplateVersionPresetID)
buildParameters, err := client.WorkspaceBuildParameters(ctx, workspaceLatestBuild.ID)
require.NoError(t, err)
require.Len(t, buildParameters, 2)
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: firstParameterName, Value: secondOptionalParameterValue})
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: thirdParameterName, Value: thirdParameterValue})
})
// This test verifies that when a template has presets,
// including a default preset, and the user does not specify the `--preset` flag,
// the CLI automatically uses the default preset to create the workspace
t.Run("DefaultPreset", func(t *testing.T) {
t.Parallel()
client := coderdtest.New(t, &coderdtest.Options{IncludeProvisionerDaemon: true})
owner := coderdtest.CreateFirstUser(t, client)
member, _ := coderdtest.CreateAnotherUser(t, client, owner.OrganizationID)
// Given: a template and a template version with two presets, including a default
defaultPreset := proto.Preset{
Name: "preset-default",
Default: true,
Parameters: []*proto.PresetParameter{
{Name: firstParameterName, Value: secondOptionalParameterValue},
{Name: thirdParameterName, Value: thirdParameterValue},
},
}
preset := proto.Preset{
Name: "preset-test",
Parameters: []*proto.PresetParameter{
{Name: thirdParameterName, Value: thirdParameterValue},
},
}
version := coderdtest.CreateTemplateVersion(t, client, owner.OrganizationID, echoResponses(&defaultPreset, &preset))
coderdtest.AwaitTemplateVersionJobCompleted(t, client, version.ID)
template := coderdtest.CreateTemplate(t, client, owner.OrganizationID, version.ID)
// When: running the create command without a preset
workspaceName := "my-workspace"
inv, root := clitest.New(t, "create", workspaceName, "--template", template.Name, "-y")
clitest.SetupConfig(t, member, root)
pty := ptytest.New(t).Attach(inv)
inv.Stdout = pty.Output()
inv.Stderr = pty.Output()
err := inv.Run()
require.NoError(t, err)
// Should: display the default preset as well as its parameters
presetName := fmt.Sprintf("Preset '%s' (default) applied:", defaultPreset.Name)
pty.ExpectMatch(presetName)
pty.ExpectMatch(fmt.Sprintf("%s: '%s'", firstParameterName, secondOptionalParameterValue))
pty.ExpectMatch(fmt.Sprintf("%s: '%s'", thirdParameterName, thirdParameterValue))
// Verify if the new workspace uses expected parameters.
ctx, cancel := context.WithTimeout(context.Background(), testutil.WaitShort)
defer cancel()
tvPresets, err := client.TemplateVersionPresets(ctx, version.ID)
require.NoError(t, err)
require.Len(t, tvPresets, 2)
var selectedPreset *codersdk.Preset
for _, tvPreset := range tvPresets {
if tvPreset.Default {
selectedPreset = &tvPreset
}
}
require.NotNil(t, selectedPreset)
workspaces, err := client.Workspaces(ctx, codersdk.WorkspaceFilter{
Name: workspaceName,
})
require.NoError(t, err)
require.Len(t, workspaces.Workspaces, 1)
// Should: create a workspace using the expected template version and the default preset parameters
workspaceLatestBuild := workspaces.Workspaces[0].LatestBuild
require.Equal(t, version.ID, workspaceLatestBuild.TemplateVersionID)
require.Equal(t, selectedPreset.ID, *workspaceLatestBuild.TemplateVersionPresetID)
buildParameters, err := client.WorkspaceBuildParameters(ctx, workspaceLatestBuild.ID)
require.NoError(t, err)
require.Len(t, buildParameters, 2)
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: firstParameterName, Value: secondOptionalParameterValue})
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: thirdParameterName, Value: thirdParameterValue})
})
// This test verifies that when a template has presets but no default preset,
// and the user does not provide the `--preset` flag,
// the CLI prompts the user to select a preset.
t.Run("NoDefaultPresetPromptUser", func(t *testing.T) {
t.Parallel()
client := coderdtest.New(t, &coderdtest.Options{IncludeProvisionerDaemon: true})
owner := coderdtest.CreateFirstUser(t, client)
member, _ := coderdtest.CreateAnotherUser(t, client, owner.OrganizationID)
// Given: a template and a template version with two presets
preset := proto.Preset{
Name: "preset-test",
Description: "Preset Test.",
Parameters: []*proto.PresetParameter{
{Name: firstParameterName, Value: secondOptionalParameterValue},
{Name: thirdParameterName, Value: thirdParameterValue},
},
}
version := coderdtest.CreateTemplateVersion(t, client, owner.OrganizationID, echoResponses(&preset))
coderdtest.AwaitTemplateVersionJobCompleted(t, client, version.ID)
template := coderdtest.CreateTemplate(t, client, owner.OrganizationID, version.ID)
// When: running the create command without specifying a preset
workspaceName := "my-workspace"
inv, root := clitest.New(t, "create", workspaceName, "--template", template.Name,
"--parameter", fmt.Sprintf("%s=%s", firstParameterName, firstOptionalParameterValue),
"--parameter", fmt.Sprintf("%s=%s", thirdParameterName, thirdParameterValue))
clitest.SetupConfig(t, member, root)
doneChan := make(chan struct{})
pty := ptytest.New(t).Attach(inv)
go func() {
defer close(doneChan)
err := inv.Run()
assert.NoError(t, err)
}()
// Should: prompt the user for the preset
pty.ExpectMatch("Select a preset below:")
pty.WriteLine("\n")
pty.ExpectMatch("Preset 'preset-test' applied")
pty.ExpectMatch("Confirm create?")
pty.WriteLine("yes")
<-doneChan
// Verify if the new workspace uses expected parameters.
ctx, cancel := context.WithTimeout(context.Background(), testutil.WaitShort)
defer cancel()
tvPresets, err := client.TemplateVersionPresets(ctx, version.ID)
require.NoError(t, err)
require.Len(t, tvPresets, 1)
workspaces, err := client.Workspaces(ctx, codersdk.WorkspaceFilter{
Name: workspaceName,
})
require.NoError(t, err)
require.Len(t, workspaces.Workspaces, 1)
// Should: create a workspace using the expected template version and the preset-defined parameters
workspaceLatestBuild := workspaces.Workspaces[0].LatestBuild
require.Equal(t, version.ID, workspaceLatestBuild.TemplateVersionID)
require.Equal(t, tvPresets[0].ID, *workspaceLatestBuild.TemplateVersionPresetID)
buildParameters, err := client.WorkspaceBuildParameters(ctx, workspaceLatestBuild.ID)
require.NoError(t, err)
require.Len(t, buildParameters, 2)
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: firstParameterName, Value: secondOptionalParameterValue})
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: thirdParameterName, Value: thirdParameterValue})
})
// This test verifies that when a template version has no presets,
// the CLI does not prompt the user to select a preset and proceeds
// with workspace creation without applying any preset.
t.Run("TemplateVersionWithoutPresets", func(t *testing.T) {
t.Parallel()
client := coderdtest.New(t, &coderdtest.Options{IncludeProvisionerDaemon: true})
owner := coderdtest.CreateFirstUser(t, client)
member, _ := coderdtest.CreateAnotherUser(t, client, owner.OrganizationID)
// Given: a template and a template version without presets
version := coderdtest.CreateTemplateVersion(t, client, owner.OrganizationID, echoResponses())
coderdtest.AwaitTemplateVersionJobCompleted(t, client, version.ID)
template := coderdtest.CreateTemplate(t, client, owner.OrganizationID, version.ID)
// When: running the create command without a preset
workspaceName := "my-workspace"
inv, root := clitest.New(t, "create", workspaceName, "--template", template.Name, "-y",
"--parameter", fmt.Sprintf("%s=%s", firstParameterName, firstOptionalParameterValue),
"--parameter", fmt.Sprintf("%s=%s", thirdParameterName, thirdParameterValue))
clitest.SetupConfig(t, member, root)
pty := ptytest.New(t).Attach(inv)
inv.Stdout = pty.Output()
inv.Stderr = pty.Output()
err := inv.Run()
require.NoError(t, err)
pty.ExpectMatch("No preset applied.")
// Verify if the new workspace uses expected parameters.
ctx, cancel := context.WithTimeout(context.Background(), testutil.WaitShort)
defer cancel()
workspaces, err := client.Workspaces(ctx, codersdk.WorkspaceFilter{
Name: workspaceName,
})
require.NoError(t, err)
require.Len(t, workspaces.Workspaces, 1)
// Should: create a workspace using the expected template version and no preset
workspaceLatestBuild := workspaces.Workspaces[0].LatestBuild
require.Equal(t, version.ID, workspaceLatestBuild.TemplateVersionID)
require.Nil(t, workspaceLatestBuild.TemplateVersionPresetID)
buildParameters, err := client.WorkspaceBuildParameters(ctx, workspaceLatestBuild.ID)
require.NoError(t, err)
require.Len(t, buildParameters, 2)
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: firstParameterName, Value: firstOptionalParameterValue})
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: thirdParameterName, Value: thirdParameterValue})
})
// This test verifies that when the user provides `--preset none`,
// the CLI skips applying any preset, even if the template version has a default preset.
// The workspace should be created without using any preset-defined parameters.
t.Run("PresetFlagNone", func(t *testing.T) {
t.Parallel()
client := coderdtest.New(t, &coderdtest.Options{IncludeProvisionerDaemon: true})
owner := coderdtest.CreateFirstUser(t, client)
member, _ := coderdtest.CreateAnotherUser(t, client, owner.OrganizationID)
// Given: a template and a template version with a default preset
preset := proto.Preset{
Name: "preset-test",
Default: true,
Parameters: []*proto.PresetParameter{
{Name: firstParameterName, Value: secondOptionalParameterValue},
{Name: thirdParameterName, Value: thirdParameterValue},
},
}
version := coderdtest.CreateTemplateVersion(t, client, owner.OrganizationID, echoResponses(&preset))
coderdtest.AwaitTemplateVersionJobCompleted(t, client, version.ID)
template := coderdtest.CreateTemplate(t, client, owner.OrganizationID, version.ID)
// When: running the create command with flag '--preset none'
workspaceName := "my-workspace"
inv, root := clitest.New(t, "create", workspaceName, "--template", template.Name, "-y", "--preset", cli.PresetNone,
"--parameter", fmt.Sprintf("%s=%s", firstParameterName, firstOptionalParameterValue),
"--parameter", fmt.Sprintf("%s=%s", thirdParameterName, thirdParameterValue))
clitest.SetupConfig(t, member, root)
pty := ptytest.New(t).Attach(inv)
inv.Stdout = pty.Output()
inv.Stderr = pty.Output()
err := inv.Run()
require.NoError(t, err)
pty.ExpectMatch("No preset applied.")
// Verify that the new workspace doesn't use the preset parameters.
ctx, cancel := context.WithTimeout(context.Background(), testutil.WaitShort)
defer cancel()
tvPresets, err := client.TemplateVersionPresets(ctx, version.ID)
require.NoError(t, err)
require.Len(t, tvPresets, 1)
workspaces, err := client.Workspaces(ctx, codersdk.WorkspaceFilter{
Name: workspaceName,
})
require.NoError(t, err)
require.Len(t, workspaces.Workspaces, 1)
// Should: create a workspace using the expected template version and no preset
workspaceLatestBuild := workspaces.Workspaces[0].LatestBuild
require.Equal(t, version.ID, workspaceLatestBuild.TemplateVersionID)
require.Nil(t, workspaceLatestBuild.TemplateVersionPresetID)
buildParameters, err := client.WorkspaceBuildParameters(ctx, workspaceLatestBuild.ID)
require.NoError(t, err)
require.Len(t, buildParameters, 2)
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: firstParameterName, Value: firstOptionalParameterValue})
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: thirdParameterName, Value: thirdParameterValue})
})
// This test verifies that the CLI returns an appropriate error
// when a user provides a `--preset` value that does not correspond
// to any existing preset in the template version.
t.Run("FailsWhenPresetDoesNotExist", func(t *testing.T) {
t.Parallel()
client := coderdtest.New(t, &coderdtest.Options{IncludeProvisionerDaemon: true})
owner := coderdtest.CreateFirstUser(t, client)
member, _ := coderdtest.CreateAnotherUser(t, client, owner.OrganizationID)
// Given: a template and a template version where the preset defines values for all required parameters
preset := proto.Preset{
Name: "preset-test",
Parameters: []*proto.PresetParameter{
{Name: firstParameterName, Value: secondOptionalParameterValue},
{Name: thirdParameterName, Value: thirdParameterValue},
},
}
version := coderdtest.CreateTemplateVersion(t, client, owner.OrganizationID, echoResponses(&preset))
coderdtest.AwaitTemplateVersionJobCompleted(t, client, version.ID)
template := coderdtest.CreateTemplate(t, client, owner.OrganizationID, version.ID)
// When: running the create command with a non-existent preset
workspaceName := "my-workspace"
inv, root := clitest.New(t, "create", workspaceName, "--template", template.Name, "-y", "--preset", "invalid-preset")
clitest.SetupConfig(t, member, root)
pty := ptytest.New(t).Attach(inv)
inv.Stdout = pty.Output()
inv.Stderr = pty.Output()
err := inv.Run()
// Should: fail with an error indicating the preset was not found
require.Contains(t, err.Error(), "preset \"invalid-preset\" not found")
})
// This test verifies that when both a preset and a user-provided
// `--parameter` flag define a value for the same parameter,
// the preset's value takes precedence over the user's.
//
// The preset defines one parameter (A), and two `--parameter` flags provide A and B.
// The workspace should be created using:
// - the value of parameter A from the preset (overriding the parameter flag's value),
// - and the value of parameter B from the parameter flag.
t.Run("PresetOverridesParameterFlagValues", func(t *testing.T) {
t.Parallel()
client := coderdtest.New(t, &coderdtest.Options{IncludeProvisionerDaemon: true})
owner := coderdtest.CreateFirstUser(t, client)
member, _ := coderdtest.CreateAnotherUser(t, client, owner.OrganizationID)
// Given: a template version with a preset that defines one parameter
preset := proto.Preset{
Name: "preset-test",
Parameters: []*proto.PresetParameter{
{Name: firstParameterName, Value: secondOptionalParameterValue},
},
}
version := coderdtest.CreateTemplateVersion(t, client, owner.OrganizationID, echoResponses(&preset))
coderdtest.AwaitTemplateVersionJobCompleted(t, client, version.ID)
template := coderdtest.CreateTemplate(t, client, owner.OrganizationID, version.ID)
// When: creating a workspace with a preset and passing overlapping and additional parameters via `--parameter`
workspaceName := "my-workspace"
inv, root := clitest.New(t, "create", workspaceName, "--template", template.Name, "-y",
"--preset", preset.Name,
"--parameter", fmt.Sprintf("%s=%s", firstParameterName, firstOptionalParameterValue),
"--parameter", fmt.Sprintf("%s=%s", thirdParameterName, thirdParameterValue))
clitest.SetupConfig(t, member, root)
pty := ptytest.New(t).Attach(inv)
inv.Stdout = pty.Output()
inv.Stderr = pty.Output()
err := inv.Run()
require.NoError(t, err)
// Should: display the selected preset as well as its parameter
presetName := fmt.Sprintf("Preset '%s' applied:", preset.Name)
pty.ExpectMatch(presetName)
pty.ExpectMatch(fmt.Sprintf("%s: '%s'", firstParameterName, secondOptionalParameterValue))
// Verify if the new workspace uses expected parameters.
ctx, cancel := context.WithTimeout(context.Background(), testutil.WaitShort)
defer cancel()
tvPresets, err := client.TemplateVersionPresets(ctx, version.ID)
require.NoError(t, err)
require.Len(t, tvPresets, 1)
workspaces, err := client.Workspaces(ctx, codersdk.WorkspaceFilter{
Name: workspaceName,
})
require.NoError(t, err)
require.Len(t, workspaces.Workspaces, 1)
// Should: include both parameters, one from the preset and one from the `--parameter` flag
workspaceLatestBuild := workspaces.Workspaces[0].LatestBuild
require.Equal(t, version.ID, workspaceLatestBuild.TemplateVersionID)
require.Equal(t, tvPresets[0].ID, *workspaceLatestBuild.TemplateVersionPresetID)
buildParameters, err := client.WorkspaceBuildParameters(ctx, workspaceLatestBuild.ID)
require.NoError(t, err)
require.Len(t, buildParameters, 2)
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: firstParameterName, Value: secondOptionalParameterValue})
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: thirdParameterName, Value: thirdParameterValue})
})
// This test verifies that when both a preset and a user-provided
// `--rich-parameter-file` define a value for the same parameter,
// the preset's value takes precedence over the one in the file.
//
// The preset defines one parameter (A), and the parameter file provides two parameters (A and B).
// The workspace should be created using:
// - the value of parameter A from the preset (overriding the file's value),
// - and the value of parameter B from the file.
t.Run("PresetOverridesParameterFileValues", func(t *testing.T) {
t.Parallel()
client := coderdtest.New(t, &coderdtest.Options{IncludeProvisionerDaemon: true})
owner := coderdtest.CreateFirstUser(t, client)
member, _ := coderdtest.CreateAnotherUser(t, client, owner.OrganizationID)
// Given: a template version with a preset that defines one parameter
preset := proto.Preset{
Name: "preset-test",
Parameters: []*proto.PresetParameter{
{Name: firstParameterName, Value: secondOptionalParameterValue},
},
}
version := coderdtest.CreateTemplateVersion(t, client, owner.OrganizationID, echoResponses(&preset))
coderdtest.AwaitTemplateVersionJobCompleted(t, client, version.ID)
template := coderdtest.CreateTemplate(t, client, owner.OrganizationID, version.ID)
// When: creating a workspace with the preset and passing the second required parameter via `--rich-parameter-file`
workspaceName := "my-workspace"
tempDir := t.TempDir()
removeTmpDirUntilSuccessAfterTest(t, tempDir)
parameterFile, _ := os.CreateTemp(tempDir, "testParameterFile*.yaml")
_, _ = parameterFile.WriteString(
firstParameterName + ": " + firstOptionalParameterValue + "\n" +
thirdParameterName + ": " + thirdParameterValue)
inv, root := clitest.New(t, "create", workspaceName, "--template", template.Name, "-y",
"--preset", preset.Name,
"--rich-parameter-file", parameterFile.Name())
clitest.SetupConfig(t, member, root)
pty := ptytest.New(t).Attach(inv)
inv.Stdout = pty.Output()
inv.Stderr = pty.Output()
err := inv.Run()
require.NoError(t, err)
// Should: display the selected preset as well as its parameter
presetName := fmt.Sprintf("Preset '%s' applied:", preset.Name)
pty.ExpectMatch(presetName)
pty.ExpectMatch(fmt.Sprintf("%s: '%s'", firstParameterName, secondOptionalParameterValue))
// Verify if the new workspace uses expected parameters.
ctx, cancel := context.WithTimeout(context.Background(), testutil.WaitShort)
defer cancel()
tvPresets, err := client.TemplateVersionPresets(ctx, version.ID)
require.NoError(t, err)
require.Len(t, tvPresets, 1)
workspaces, err := client.Workspaces(ctx, codersdk.WorkspaceFilter{
Name: workspaceName,
})
require.NoError(t, err)
require.Len(t, workspaces.Workspaces, 1)
// Should: include both parameters, one from the preset and one from the `--rich-parameter-file` flag
workspaceLatestBuild := workspaces.Workspaces[0].LatestBuild
require.Equal(t, version.ID, workspaceLatestBuild.TemplateVersionID)
require.Equal(t, tvPresets[0].ID, *workspaceLatestBuild.TemplateVersionPresetID)
buildParameters, err := client.WorkspaceBuildParameters(ctx, workspaceLatestBuild.ID)
require.NoError(t, err)
require.Len(t, buildParameters, 2)
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: firstParameterName, Value: secondOptionalParameterValue})
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: thirdParameterName, Value: thirdParameterValue})
})
// This test verifies that when a preset provides only some parameters,
// and the remaining ones are not provided via flags,
// the CLI prompts the user for input to fill in the missing parameters.
t.Run("PromptsForMissingParametersWhenPresetIsIncomplete", func(t *testing.T) {
t.Parallel()
client := coderdtest.New(t, &coderdtest.Options{IncludeProvisionerDaemon: true})
owner := coderdtest.CreateFirstUser(t, client)
member, _ := coderdtest.CreateAnotherUser(t, client, owner.OrganizationID)
// Given: a template version with a preset that defines one parameter
preset := proto.Preset{
Name: "preset-test",
Parameters: []*proto.PresetParameter{
{Name: firstParameterName, Value: secondOptionalParameterValue},
},
}
version := coderdtest.CreateTemplateVersion(t, client, owner.OrganizationID, echoResponses(&preset))
coderdtest.AwaitTemplateVersionJobCompleted(t, client, version.ID)
template := coderdtest.CreateTemplate(t, client, owner.OrganizationID, version.ID)
// When: running the create command with the specified preset
workspaceName := "my-workspace"
inv, root := clitest.New(t, "create", workspaceName, "--template", template.Name, "--preset", preset.Name)
clitest.SetupConfig(t, member, root)
doneChan := make(chan struct{})
pty := ptytest.New(t).Attach(inv)
go func() {
defer close(doneChan)
err := inv.Run()
assert.NoError(t, err)
}()
// Should: display the selected preset as well as its parameters
presetName := fmt.Sprintf("Preset '%s' applied:", preset.Name)
pty.ExpectMatch(presetName)
pty.ExpectMatch(fmt.Sprintf("%s: '%s'", firstParameterName, secondOptionalParameterValue))
// Should: prompt for the missing parameter
pty.ExpectMatch(thirdParameterDescription)
pty.WriteLine(thirdParameterValue)
pty.ExpectMatch("Confirm create?")
pty.WriteLine("yes")
<-doneChan
// Verify if the new workspace uses expected parameters.
ctx, cancel := context.WithTimeout(context.Background(), testutil.WaitLong)
defer cancel()
tvPresets, err := client.TemplateVersionPresets(ctx, version.ID)
require.NoError(t, err)
require.Len(t, tvPresets, 1)
workspaces, err := client.Workspaces(ctx, codersdk.WorkspaceFilter{
Name: workspaceName,
})
require.NoError(t, err)
require.Len(t, workspaces.Workspaces, 1)
// Should: create a workspace using the expected template version and the preset-defined parameters
workspaceLatestBuild := workspaces.Workspaces[0].LatestBuild
require.Equal(t, version.ID, workspaceLatestBuild.TemplateVersionID)
require.Equal(t, tvPresets[0].ID, *workspaceLatestBuild.TemplateVersionPresetID)
buildParameters, err := client.WorkspaceBuildParameters(ctx, workspaceLatestBuild.ID)
require.NoError(t, err)
require.Len(t, buildParameters, 2)
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: firstParameterName, Value: secondOptionalParameterValue})
require.Contains(t, buildParameters, codersdk.WorkspaceBuildParameter{Name: thirdParameterName, Value: thirdParameterValue})
})
}
func TestCreateValidateRichParameters(t *testing.T) {
t.Parallel()
+3 -4
View File
@@ -111,7 +111,6 @@ func TestDelete(t *testing.T) {
// The API checks if the user has any workspaces, so we cannot delete a user
// this way.
ctx := testutil.Context(t, testutil.WaitShort)
// nolint:gocritic // Unit test
err := api.Database.UpdateUserDeletedByID(dbauthz.AsSystemRestricted(ctx), deleteMeUser.ID)
require.NoError(t, err)
@@ -233,9 +232,6 @@ func TestDelete(t *testing.T) {
t.Skip("this test requires postgres")
}
clock := quartz.NewMock(t)
ctx := testutil.Context(t, testutil.WaitSuperLong)
// Setup
db, pb := dbtestutil.NewDB(t, dbtestutil.WithDumpOnFailure())
client, _ := coderdtest.NewWithProvisionerCloser(t, &coderdtest.Options{
@@ -301,6 +297,9 @@ func TestDelete(t *testing.T) {
t.Run(tc.name, func(t *testing.T) {
t.Parallel()
clock := quartz.NewMock(t)
ctx := testutil.Context(t, testutil.WaitSuperLong)
// Create one prebuilt workspace (owned by system user) and one normal workspace (owned by a user)
// Each workspace is persisted in the DB along with associated workspace jobs and builds.
dbPrebuiltWorkspace := setupTestDBWorkspace(t, clock, db, pb, orgID, database.PrebuildsSystemUserID, template.ID, version.ID, preset.ID)
+1
View File
@@ -16,6 +16,7 @@ func (r *RootCmd) expCmd() *serpent.Command {
r.mcpCommand(),
r.promptExample(),
r.rptyCommand(),
r.tasksCommand(),
},
}
return cmd
+17 -7
View File
@@ -127,6 +127,7 @@ func (r *RootCmd) mcpConfigureClaudeCode() *serpent.Command {
appStatusSlug string
testBinaryName string
aiAgentAPIURL url.URL
claudeUseBedrock string
deprecatedCoderMCPClaudeAPIKey string
)
@@ -154,14 +155,15 @@ func (r *RootCmd) mcpConfigureClaudeCode() *serpent.Command {
configureClaudeEnv[envAgentURL] = agentClient.SDK.URL.String()
configureClaudeEnv[envAgentToken] = agentClient.SDK.SessionToken()
}
if claudeAPIKey == "" {
if deprecatedCoderMCPClaudeAPIKey == "" {
cliui.Warnf(inv.Stderr, "CLAUDE_API_KEY is not set.")
} else {
cliui.Warnf(inv.Stderr, "CODER_MCP_CLAUDE_API_KEY is deprecated, use CLAUDE_API_KEY instead")
claudeAPIKey = deprecatedCoderMCPClaudeAPIKey
}
if deprecatedCoderMCPClaudeAPIKey != "" {
cliui.Warnf(inv.Stderr, "CODER_MCP_CLAUDE_API_KEY is deprecated, use CLAUDE_API_KEY instead")
claudeAPIKey = deprecatedCoderMCPClaudeAPIKey
}
if claudeAPIKey == "" && claudeUseBedrock != "1" {
cliui.Warnf(inv.Stderr, "CLAUDE_API_KEY is not set.")
}
if appStatusSlug != "" {
configureClaudeEnv[envAppStatusSlug] = appStatusSlug
}
@@ -280,6 +282,14 @@ func (r *RootCmd) mcpConfigureClaudeCode() *serpent.Command {
Value: serpent.StringOf(&testBinaryName),
Hidden: true,
},
{
Name: "claude-code-use-bedrock",
Description: "Use Amazon Bedrock.",
Env: "CLAUDE_CODE_USE_BEDROCK",
Flag: "claude-code-use-bedrock",
Value: serpent.StringOf(&claudeUseBedrock),
Hidden: true,
},
},
}
return cmd
+14
View File
@@ -174,6 +174,20 @@ func (RootCmd) promptExample() *serpent.Command {
_, _ = fmt.Fprintf(inv.Stdout, "%q are nice choices.\n", strings.Join(multiSelectValues, ", "))
return multiSelectError
}, useThingsOption, enableCustomInputOption),
promptCmd("rich-multi-select", func(inv *serpent.Invocation) error {
if len(multiSelectValues) == 0 {
multiSelectValues, multiSelectError = cliui.MultiSelect(inv, cliui.MultiSelectOptions{
Message: "Select some things:",
Options: []string{
"Apples", "Plums", "Grapes", "Oranges", "Bananas",
},
Defaults: []string{"Grapes", "Plums"},
EnableCustomInput: enableCustomInput,
})
}
_, _ = fmt.Fprintf(inv.Stdout, "%q are nice choices.\n", strings.Join(multiSelectValues, ", "))
return multiSelectError
}, useThingsOption, enableCustomInputOption),
promptCmd("rich-parameter", func(inv *serpent.Invocation) error {
value, err := cliui.RichSelect(inv, cliui.RichSelectOptions{
Options: []codersdk.TemplateVersionParameterOption{
+1 -1
View File
@@ -97,7 +97,7 @@ func handleRPTY(inv *serpent.Invocation, client *codersdk.Client, args handleRPT
reconnectID = uuid.New()
}
ws, agt, err := getWorkspaceAndAgent(ctx, inv, client, true, args.NamedWorkspace)
ws, agt, _, err := GetWorkspaceAndAgent(ctx, inv, client, true, args.NamedWorkspace)
if err != nil {
return err
}
+1
View File
@@ -118,6 +118,7 @@ func TestExpRpty(t *testing.T) {
_ = agenttest.New(t, client.URL, agentToken, func(o *agent.Options) {
o.Devcontainers = true
o.DevcontainerAPIOptions = append(o.DevcontainerAPIOptions,
agentcontainers.WithProjectDiscovery(false),
agentcontainers.WithContainerLabelIncludeFilter(wantLabel, "true"),
)
})
+22
View File
@@ -0,0 +1,22 @@
package cli
import (
"github.com/coder/serpent"
)
func (r *RootCmd) tasksCommand() *serpent.Command {
cmd := &serpent.Command{
Use: "task",
Aliases: []string{"tasks"},
Short: "Experimental task commands.",
Handler: func(i *serpent.Invocation) error {
return i.Command.HelpHandler(i)
},
Children: []*serpent.Command{
r.taskList(),
r.taskCreate(),
r.taskStatus(),
},
}
return cmd
}
+171
View File
@@ -0,0 +1,171 @@
package cli
import (
"fmt"
"strings"
"time"
"github.com/google/uuid"
"golang.org/x/xerrors"
"github.com/coder/coder/v2/cli/cliui"
"github.com/coder/coder/v2/codersdk"
"github.com/coder/serpent"
)
func (r *RootCmd) taskStatus() *serpent.Command {
var (
client = new(codersdk.Client)
formatter = cliui.NewOutputFormatter(
cliui.TableFormat(
[]taskStatusRow{},
[]string{
"state changed",
"status",
"state",
"message",
},
),
cliui.ChangeFormatterData(
cliui.JSONFormat(),
func(data any) (any, error) {
rows, ok := data.([]taskStatusRow)
if !ok {
return nil, xerrors.Errorf("expected []taskStatusRow, got %T", data)
}
if len(rows) != 1 {
return nil, xerrors.Errorf("expected exactly 1 row, got %d", len(rows))
}
return rows[0], nil
},
),
)
watchArg bool
watchIntervalArg time.Duration
)
cmd := &serpent.Command{
Short: "Show the status of a task.",
Use: "status",
Aliases: []string{"stat"},
Options: serpent.OptionSet{
{
Default: "false",
Description: "Watch the task status output. This will stream updates to the terminal until the underlying workspace is stopped.",
Flag: "watch",
Name: "watch",
Value: serpent.BoolOf(&watchArg),
},
{
Default: "1s",
Description: "Interval to poll the task for updates. Only used in tests.",
Hidden: true,
Flag: "watch-interval",
Name: "watch-interval",
Value: serpent.DurationOf(&watchIntervalArg),
},
},
Middleware: serpent.Chain(
serpent.RequireNArgs(1),
r.InitClient(client),
),
Handler: func(i *serpent.Invocation) error {
ctx := i.Context()
ec := codersdk.NewExperimentalClient(client)
identifier := i.Args[0]
taskID, err := uuid.Parse(identifier)
if err != nil {
// Try to resolve the task as a named workspace
// TODO: right now tasks are still "workspaces" under the hood.
// We should update this once we have a proper task model.
ws, err := namedWorkspace(ctx, client, identifier)
if err != nil {
return err
}
taskID = ws.ID
}
task, err := ec.TaskByID(ctx, taskID)
if err != nil {
return err
}
out, err := formatter.Format(ctx, toStatusRow(task))
if err != nil {
return xerrors.Errorf("format task status: %w", err)
}
_, _ = fmt.Fprintln(i.Stdout, out)
if !watchArg {
return nil
}
lastStatus := task.Status
lastState := task.CurrentState
t := time.NewTicker(watchIntervalArg)
defer t.Stop()
// TODO: implement streaming updates instead of polling
for range t.C {
task, err := ec.TaskByID(ctx, taskID)
if err != nil {
return err
}
if lastStatus == task.Status && taskStatusEqual(lastState, task.CurrentState) {
continue
}
out, err := formatter.Format(ctx, toStatusRow(task))
if err != nil {
return xerrors.Errorf("format task status: %w", err)
}
// hack: skip the extra column header from formatter
if formatter.FormatID() != cliui.JSONFormat().ID() {
out = strings.SplitN(out, "\n", 2)[1]
}
_, _ = fmt.Fprintln(i.Stdout, out)
if task.Status == codersdk.WorkspaceStatusStopped {
return nil
}
lastStatus = task.Status
lastState = task.CurrentState
}
return nil
},
}
formatter.AttachOptions(&cmd.Options)
return cmd
}
func taskStatusEqual(s1, s2 *codersdk.TaskStateEntry) bool {
if s1 == nil && s2 == nil {
return true
}
if s1 == nil || s2 == nil {
return false
}
return s1.State == s2.State
}
type taskStatusRow struct {
codersdk.Task `table:"-"`
ChangedAgo string `json:"-" table:"state changed,default_sort"`
Timestamp time.Time `json:"-" table:"-"`
TaskStatus string `json:"-" table:"status"`
TaskState string `json:"-" table:"state"`
Message string `json:"-" table:"message"`
}
func toStatusRow(task codersdk.Task) []taskStatusRow {
tsr := taskStatusRow{
Task: task,
ChangedAgo: time.Since(task.UpdatedAt).Truncate(time.Second).String() + " ago",
Timestamp: task.UpdatedAt,
TaskStatus: string(task.Status),
}
if task.CurrentState != nil {
tsr.ChangedAgo = time.Since(task.CurrentState.Timestamp).Truncate(time.Second).String() + " ago"
tsr.Timestamp = task.CurrentState.Timestamp
tsr.TaskState = string(task.CurrentState.State)
tsr.Message = task.CurrentState.Message
}
return []taskStatusRow{tsr}
}
+270
View File
@@ -0,0 +1,270 @@
package cli_test
import (
"context"
"net/http"
"net/http/httptest"
"strings"
"sync/atomic"
"testing"
"time"
"github.com/google/go-cmp/cmp"
"github.com/google/uuid"
"github.com/stretchr/testify/assert"
"golang.org/x/xerrors"
"github.com/coder/coder/v2/cli/clitest"
"github.com/coder/coder/v2/coderd/httpapi"
"github.com/coder/coder/v2/codersdk"
"github.com/coder/coder/v2/testutil"
)
func Test_TaskStatus(t *testing.T) {
t.Parallel()
for _, tc := range []struct {
args []string
expectOutput string
expectError string
hf func(context.Context, time.Time) func(http.ResponseWriter, *http.Request)
}{
{
args: []string{"doesnotexist"},
expectError: httpapi.ResourceNotFoundResponse.Message,
hf: func(ctx context.Context, _ time.Time) func(w http.ResponseWriter, r *http.Request) {
return func(w http.ResponseWriter, r *http.Request) {
switch r.URL.Path {
case "/api/v2/users/me/workspace/doesnotexist":
httpapi.ResourceNotFound(w)
default:
t.Errorf("unexpected path: %s", r.URL.Path)
}
}
},
},
{
args: []string{"err-fetching-workspace"},
expectError: assert.AnError.Error(),
hf: func(ctx context.Context, _ time.Time) func(w http.ResponseWriter, r *http.Request) {
return func(w http.ResponseWriter, r *http.Request) {
switch r.URL.Path {
case "/api/v2/users/me/workspace/err-fetching-workspace":
httpapi.Write(ctx, w, http.StatusOK, codersdk.Workspace{
ID: uuid.MustParse("11111111-1111-1111-1111-111111111111"),
})
case "/api/experimental/tasks/me/11111111-1111-1111-1111-111111111111":
httpapi.InternalServerError(w, assert.AnError)
default:
t.Errorf("unexpected path: %s", r.URL.Path)
}
}
},
},
{
args: []string{"exists"},
expectOutput: `STATE CHANGED STATUS STATE MESSAGE
0s ago running working Thinking furiously...`,
hf: func(ctx context.Context, now time.Time) func(w http.ResponseWriter, r *http.Request) {
return func(w http.ResponseWriter, r *http.Request) {
switch r.URL.Path {
case "/api/v2/users/me/workspace/exists":
httpapi.Write(ctx, w, http.StatusOK, codersdk.Workspace{
ID: uuid.MustParse("11111111-1111-1111-1111-111111111111"),
})
case "/api/experimental/tasks/me/11111111-1111-1111-1111-111111111111":
httpapi.Write(ctx, w, http.StatusOK, codersdk.Task{
ID: uuid.MustParse("11111111-1111-1111-1111-111111111111"),
Status: codersdk.WorkspaceStatusRunning,
CreatedAt: now,
UpdatedAt: now,
CurrentState: &codersdk.TaskStateEntry{
State: codersdk.TaskStateWorking,
Timestamp: now,
Message: "Thinking furiously...",
},
})
default:
t.Errorf("unexpected path: %s", r.URL.Path)
}
}
},
},
{
args: []string{"exists", "--watch"},
expectOutput: `
STATE CHANGED STATUS STATE MESSAGE
4s ago running
3s ago running working Reticulating splines...
2s ago running completed Splines reticulated successfully!
2s ago stopping completed Splines reticulated successfully!
2s ago stopped completed Splines reticulated successfully!`,
hf: func(ctx context.Context, now time.Time) func(http.ResponseWriter, *http.Request) {
var calls atomic.Int64
return func(w http.ResponseWriter, r *http.Request) {
defer calls.Add(1)
switch r.URL.Path {
case "/api/v2/users/me/workspace/exists":
httpapi.Write(ctx, w, http.StatusOK, codersdk.Workspace{
ID: uuid.MustParse("11111111-1111-1111-1111-111111111111"),
})
case "/api/experimental/tasks/me/11111111-1111-1111-1111-111111111111":
switch calls.Load() {
case 0:
httpapi.Write(ctx, w, http.StatusOK, codersdk.Task{
ID: uuid.MustParse("11111111-1111-1111-1111-111111111111"),
Status: codersdk.WorkspaceStatusPending,
CreatedAt: now.Add(-5 * time.Second),
UpdatedAt: now.Add(-5 * time.Second),
})
case 1:
httpapi.Write(ctx, w, http.StatusOK, codersdk.Task{
ID: uuid.MustParse("11111111-1111-1111-1111-111111111111"),
Status: codersdk.WorkspaceStatusRunning,
CreatedAt: now.Add(-5 * time.Second),
UpdatedAt: now.Add(-4 * time.Second),
})
case 2:
httpapi.Write(ctx, w, http.StatusOK, codersdk.Task{
ID: uuid.MustParse("11111111-1111-1111-1111-111111111111"),
Status: codersdk.WorkspaceStatusRunning,
CreatedAt: now.Add(-5 * time.Second),
UpdatedAt: now.Add(-4 * time.Second),
CurrentState: &codersdk.TaskStateEntry{
State: codersdk.TaskStateWorking,
Timestamp: now.Add(-3 * time.Second),
Message: "Reticulating splines...",
},
})
case 3:
httpapi.Write(ctx, w, http.StatusOK, codersdk.Task{
ID: uuid.MustParse("11111111-1111-1111-1111-111111111111"),
Status: codersdk.WorkspaceStatusRunning,
CreatedAt: now.Add(-5 * time.Second),
UpdatedAt: now.Add(-4 * time.Second),
CurrentState: &codersdk.TaskStateEntry{
State: codersdk.TaskStateCompleted,
Timestamp: now.Add(-2 * time.Second),
Message: "Splines reticulated successfully!",
},
})
case 4:
httpapi.Write(ctx, w, http.StatusOK, codersdk.Task{
ID: uuid.MustParse("11111111-1111-1111-1111-111111111111"),
Status: codersdk.WorkspaceStatusStopping,
CreatedAt: now.Add(-5 * time.Second),
UpdatedAt: now.Add(-1 * time.Second),
CurrentState: &codersdk.TaskStateEntry{
State: codersdk.TaskStateCompleted,
Timestamp: now.Add(-2 * time.Second),
Message: "Splines reticulated successfully!",
},
})
case 5:
httpapi.Write(ctx, w, http.StatusOK, codersdk.Task{
ID: uuid.MustParse("11111111-1111-1111-1111-111111111111"),
Status: codersdk.WorkspaceStatusStopped,
CreatedAt: now.Add(-5 * time.Second),
UpdatedAt: now,
CurrentState: &codersdk.TaskStateEntry{
State: codersdk.TaskStateCompleted,
Timestamp: now.Add(-2 * time.Second),
Message: "Splines reticulated successfully!",
},
})
default:
httpapi.InternalServerError(w, xerrors.New("too many calls!"))
return
}
default:
httpapi.InternalServerError(w, xerrors.Errorf("unexpected path: %q", r.URL.Path))
}
}
},
},
{
args: []string{"exists", "--output", "json"},
expectOutput: `{
"id": "11111111-1111-1111-1111-111111111111",
"organization_id": "00000000-0000-0000-0000-000000000000",
"owner_id": "00000000-0000-0000-0000-000000000000",
"name": "",
"template_id": "00000000-0000-0000-0000-000000000000",
"workspace_id": null,
"initial_prompt": "",
"status": "running",
"current_state": {
"timestamp": "2025-08-26T12:34:57Z",
"state": "working",
"message": "Thinking furiously...",
"uri": ""
},
"created_at": "2025-08-26T12:34:56Z",
"updated_at": "2025-08-26T12:34:56Z"
}`,
hf: func(ctx context.Context, _ time.Time) func(w http.ResponseWriter, r *http.Request) {
ts := time.Date(2025, 8, 26, 12, 34, 56, 0, time.UTC)
return func(w http.ResponseWriter, r *http.Request) {
switch r.URL.Path {
case "/api/v2/users/me/workspace/exists":
httpapi.Write(ctx, w, http.StatusOK, codersdk.Workspace{
ID: uuid.MustParse("11111111-1111-1111-1111-111111111111"),
})
case "/api/experimental/tasks/me/11111111-1111-1111-1111-111111111111":
httpapi.Write(ctx, w, http.StatusOK, codersdk.Task{
ID: uuid.MustParse("11111111-1111-1111-1111-111111111111"),
Status: codersdk.WorkspaceStatusRunning,
CreatedAt: ts,
UpdatedAt: ts,
CurrentState: &codersdk.TaskStateEntry{
State: codersdk.TaskStateWorking,
Timestamp: ts.Add(time.Second),
Message: "Thinking furiously...",
},
})
default:
t.Errorf("unexpected path: %s", r.URL.Path)
}
}
},
},
} {
t.Run(strings.Join(tc.args, ","), func(t *testing.T) {
t.Parallel()
var (
ctx = testutil.Context(t, testutil.WaitShort)
now = time.Now().UTC() // TODO: replace with quartz
srv = httptest.NewServer(http.HandlerFunc(tc.hf(ctx, now)))
client = new(codersdk.Client)
sb = strings.Builder{}
args = []string{"exp", "task", "status", "--watch-interval", testutil.IntervalFast.String()}
)
t.Cleanup(srv.Close)
client.URL = testutil.MustURL(t, srv.URL)
args = append(args, tc.args...)
inv, root := clitest.New(t, args...)
inv.Stdout = &sb
inv.Stderr = &sb
clitest.SetupConfig(t, client, root)
err := inv.WithContext(ctx).Run()
if tc.expectError == "" {
assert.NoError(t, err)
} else {
assert.ErrorContains(t, err, tc.expectError)
}
if diff := tableDiff(tc.expectOutput, sb.String()); diff != "" {
t.Errorf("unexpected output diff (-want +got):\n%s", diff)
}
})
}
}
func tableDiff(want, got string) string {
var gotTrimmed strings.Builder
for _, line := range strings.Split(got, "\n") {
_, _ = gotTrimmed.WriteString(strings.TrimRight(line, " ") + "\n")
}
return cmp.Diff(strings.TrimSpace(want), strings.TrimSpace(gotTrimmed.String()))
}
+128
View File
@@ -0,0 +1,128 @@
package cli
import (
"fmt"
"strings"
"github.com/google/uuid"
"golang.org/x/xerrors"
"github.com/coder/coder/v2/cli/cliui"
"github.com/coder/coder/v2/codersdk"
"github.com/coder/serpent"
)
func (r *RootCmd) taskCreate() *serpent.Command {
var (
orgContext = NewOrganizationContext()
client = new(codersdk.Client)
templateName string
templateVersionName string
presetName string
taskInput string
)
cmd := &serpent.Command{
Use: "create [template]",
Short: "Create an experimental task",
Middleware: serpent.Chain(
serpent.RequireRangeArgs(0, 1),
r.InitClient(client),
),
Options: serpent.OptionSet{
{
Flag: "input",
Env: "CODER_TASK_INPUT",
Value: serpent.StringOf(&taskInput),
Required: true,
},
{
Env: "CODER_TASK_TEMPLATE_NAME",
Value: serpent.StringOf(&templateName),
},
{
Env: "CODER_TASK_TEMPLATE_VERSION",
Value: serpent.StringOf(&templateVersionName),
},
{
Flag: "preset",
Env: "CODER_TASK_PRESET_NAME",
Value: serpent.StringOf(&presetName),
Default: PresetNone,
},
},
Handler: func(inv *serpent.Invocation) error {
var (
ctx = inv.Context()
expClient = codersdk.NewExperimentalClient(client)
templateVersionID uuid.UUID
templateVersionPresetID uuid.UUID
)
organization, err := orgContext.Selected(inv, client)
if err != nil {
return xerrors.Errorf("get current organization: %w", err)
}
if len(inv.Args) > 0 {
templateName, templateVersionName, _ = strings.Cut(inv.Args[0], "@")
}
if templateName == "" {
return xerrors.Errorf("template name not provided")
}
if templateVersionName != "" {
templateVersion, err := client.TemplateVersionByOrganizationAndName(ctx, organization.ID, templateName, templateVersionName)
if err != nil {
return xerrors.Errorf("get template version: %w", err)
}
templateVersionID = templateVersion.ID
} else {
template, err := client.TemplateByName(ctx, organization.ID, templateName)
if err != nil {
return xerrors.Errorf("get template: %w", err)
}
templateVersionID = template.ActiveVersionID
}
if presetName != PresetNone {
templatePresets, err := client.TemplateVersionPresets(ctx, templateVersionID)
if err != nil {
return xerrors.Errorf("get template presets: %w", err)
}
preset, err := resolvePreset(templatePresets, presetName)
if err != nil {
return xerrors.Errorf("resolve preset: %w", err)
}
templateVersionPresetID = preset.ID
}
workspace, err := expClient.CreateTask(ctx, codersdk.Me, codersdk.CreateTaskRequest{
TemplateVersionID: templateVersionID,
TemplateVersionPresetID: templateVersionPresetID,
Prompt: taskInput,
})
if err != nil {
return xerrors.Errorf("create task: %w", err)
}
_, _ = fmt.Fprintf(
inv.Stdout,
"The task %s has been created at %s!\n",
cliui.Keyword(workspace.Name),
cliui.Timestamp(workspace.CreatedAt),
)
return nil
},
}
orgContext.AttachOptions(cmd)
return cmd
}
+266
View File
@@ -0,0 +1,266 @@
package cli_test
import (
"context"
"fmt"
"net/http"
"net/http/httptest"
"net/url"
"strings"
"testing"
"time"
"github.com/google/uuid"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
"github.com/coder/coder/v2/cli/clitest"
"github.com/coder/coder/v2/cli/cliui"
"github.com/coder/coder/v2/coderd/httpapi"
"github.com/coder/coder/v2/codersdk"
"github.com/coder/coder/v2/testutil"
"github.com/coder/serpent"
)
func TestTaskCreate(t *testing.T) {
t.Parallel()
var (
taskCreatedAt = time.Now()
organizationID = uuid.New()
anotherOrganizationID = uuid.New()
templateID = uuid.New()
templateVersionID = uuid.New()
templateVersionPresetID = uuid.New()
)
templateAndVersionFoundHandler := func(t *testing.T, ctx context.Context, orgID uuid.UUID, templateName, templateVersionName, presetName, prompt string) http.HandlerFunc {
t.Helper()
return func(w http.ResponseWriter, r *http.Request) {
switch r.URL.Path {
case "/api/v2/users/me/organizations":
httpapi.Write(ctx, w, http.StatusOK, []codersdk.Organization{
{MinimalOrganization: codersdk.MinimalOrganization{
ID: orgID,
}},
})
case fmt.Sprintf("/api/v2/organizations/%s/templates/my-template/versions/my-template-version", orgID):
httpapi.Write(ctx, w, http.StatusOK, codersdk.TemplateVersion{
ID: templateVersionID,
})
case fmt.Sprintf("/api/v2/organizations/%s/templates/my-template", orgID):
httpapi.Write(ctx, w, http.StatusOK, codersdk.Template{
ID: templateID,
ActiveVersionID: templateVersionID,
})
case fmt.Sprintf("/api/v2/templateversions/%s/presets", templateVersionID):
httpapi.Write(ctx, w, http.StatusOK, []codersdk.Preset{
{
ID: templateVersionPresetID,
Name: presetName,
},
})
case "/api/experimental/tasks/me":
var req codersdk.CreateTaskRequest
if !httpapi.Read(ctx, w, r, &req) {
return
}
assert.Equal(t, prompt, req.Prompt, "prompt mismatch")
assert.Equal(t, templateVersionID, req.TemplateVersionID, "template version mismatch")
if presetName == "" {
assert.Equal(t, uuid.Nil, req.TemplateVersionPresetID, "expected no template preset id")
} else {
assert.Equal(t, templateVersionPresetID, req.TemplateVersionPresetID, "template version preset id mismatch")
}
httpapi.Write(ctx, w, http.StatusCreated, codersdk.Workspace{
Name: "task-wild-goldfish-27",
CreatedAt: taskCreatedAt,
})
default:
t.Errorf("unexpected path: %s", r.URL.Path)
}
}
}
tests := []struct {
args []string
env []string
expectError string
expectOutput string
handler func(t *testing.T, ctx context.Context) http.HandlerFunc
}{
{
args: []string{"my-template@my-template-version", "--input", "my custom prompt", "--org", organizationID.String()},
expectOutput: fmt.Sprintf("The task %s has been created at %s!", cliui.Keyword("task-wild-goldfish-27"), cliui.Timestamp(taskCreatedAt)),
handler: func(t *testing.T, ctx context.Context) http.HandlerFunc {
return templateAndVersionFoundHandler(t, ctx, organizationID, "my-template", "my-template-version", "", "my custom prompt")
},
},
{
args: []string{"my-template", "--input", "my custom prompt", "--org", organizationID.String()},
env: []string{"CODER_TASK_TEMPLATE_VERSION=my-template-version"},
expectOutput: fmt.Sprintf("The task %s has been created at %s!", cliui.Keyword("task-wild-goldfish-27"), cliui.Timestamp(taskCreatedAt)),
handler: func(t *testing.T, ctx context.Context) http.HandlerFunc {
return templateAndVersionFoundHandler(t, ctx, organizationID, "my-template", "my-template-version", "", "my custom prompt")
},
},
{
args: []string{"--input", "my custom prompt", "--org", organizationID.String()},
env: []string{"CODER_TASK_TEMPLATE_NAME=my-template", "CODER_TASK_TEMPLATE_VERSION=my-template-version"},
expectOutput: fmt.Sprintf("The task %s has been created at %s!", cliui.Keyword("task-wild-goldfish-27"), cliui.Timestamp(taskCreatedAt)),
handler: func(t *testing.T, ctx context.Context) http.HandlerFunc {
return templateAndVersionFoundHandler(t, ctx, organizationID, "my-template", "my-template-version", "", "my custom prompt")
},
},
{
env: []string{"CODER_TASK_TEMPLATE_NAME=my-template", "CODER_TASK_TEMPLATE_VERSION=my-template-version", "CODER_TASK_INPUT=my custom prompt", "CODER_ORGANIZATION=" + organizationID.String()},
expectOutput: fmt.Sprintf("The task %s has been created at %s!", cliui.Keyword("task-wild-goldfish-27"), cliui.Timestamp(taskCreatedAt)),
handler: func(t *testing.T, ctx context.Context) http.HandlerFunc {
return templateAndVersionFoundHandler(t, ctx, organizationID, "my-template", "my-template-version", "", "my custom prompt")
},
},
{
args: []string{"my-template", "--input", "my custom prompt", "--org", organizationID.String()},
expectOutput: fmt.Sprintf("The task %s has been created at %s!", cliui.Keyword("task-wild-goldfish-27"), cliui.Timestamp(taskCreatedAt)),
handler: func(t *testing.T, ctx context.Context) http.HandlerFunc {
return templateAndVersionFoundHandler(t, ctx, organizationID, "my-template", "", "", "my custom prompt")
},
},
{
args: []string{"my-template", "--input", "my custom prompt", "--preset", "my-preset", "--org", organizationID.String()},
expectOutput: fmt.Sprintf("The task %s has been created at %s!", cliui.Keyword("task-wild-goldfish-27"), cliui.Timestamp(taskCreatedAt)),
handler: func(t *testing.T, ctx context.Context) http.HandlerFunc {
return templateAndVersionFoundHandler(t, ctx, organizationID, "my-template", "", "my-preset", "my custom prompt")
},
},
{
args: []string{"my-template", "--input", "my custom prompt"},
env: []string{"CODER_TASK_PRESET_NAME=my-preset"},
expectOutput: fmt.Sprintf("The task %s has been created at %s!", cliui.Keyword("task-wild-goldfish-27"), cliui.Timestamp(taskCreatedAt)),
handler: func(t *testing.T, ctx context.Context) http.HandlerFunc {
return templateAndVersionFoundHandler(t, ctx, organizationID, "my-template", "", "my-preset", "my custom prompt")
},
},
{
args: []string{"my-template", "--input", "my custom prompt", "--preset", "not-real-preset"},
expectError: `preset "not-real-preset" not found`,
handler: func(t *testing.T, ctx context.Context) http.HandlerFunc {
return templateAndVersionFoundHandler(t, ctx, organizationID, "my-template", "", "my-preset", "my custom prompt")
},
},
{
args: []string{"my-template@not-real-template-version", "--input", "my custom prompt"},
expectError: httpapi.ResourceNotFoundResponse.Message,
handler: func(t *testing.T, ctx context.Context) http.HandlerFunc {
return func(w http.ResponseWriter, r *http.Request) {
switch r.URL.Path {
case "/api/v2/users/me/organizations":
httpapi.Write(ctx, w, http.StatusOK, []codersdk.Organization{
{MinimalOrganization: codersdk.MinimalOrganization{
ID: organizationID,
}},
})
case fmt.Sprintf("/api/v2/organizations/%s/templates/my-template/versions/not-real-template-version", organizationID):
httpapi.ResourceNotFound(w)
default:
t.Errorf("unexpected path: %s", r.URL.Path)
}
}
},
},
{
args: []string{"not-real-template", "--input", "my custom prompt", "--org", organizationID.String()},
expectError: httpapi.ResourceNotFoundResponse.Message,
handler: func(t *testing.T, ctx context.Context) http.HandlerFunc {
return func(w http.ResponseWriter, r *http.Request) {
switch r.URL.Path {
case "/api/v2/users/me/organizations":
httpapi.Write(ctx, w, http.StatusOK, []codersdk.Organization{
{MinimalOrganization: codersdk.MinimalOrganization{
ID: organizationID,
}},
})
case fmt.Sprintf("/api/v2/organizations/%s/templates/not-real-template", organizationID):
httpapi.ResourceNotFound(w)
default:
t.Errorf("unexpected path: %s", r.URL.Path)
}
}
},
},
{
args: []string{"template-in-different-org", "--input", "my-custom-prompt", "--org", anotherOrganizationID.String()},
expectError: httpapi.ResourceNotFoundResponse.Message,
handler: func(t *testing.T, ctx context.Context) http.HandlerFunc {
return func(w http.ResponseWriter, r *http.Request) {
switch r.URL.Path {
case "/api/v2/users/me/organizations":
httpapi.Write(ctx, w, http.StatusOK, []codersdk.Organization{
{MinimalOrganization: codersdk.MinimalOrganization{
ID: anotherOrganizationID,
}},
})
case fmt.Sprintf("/api/v2/organizations/%s/templates/template-in-different-org", anotherOrganizationID):
httpapi.ResourceNotFound(w)
default:
t.Errorf("unexpected path: %s", r.URL.Path)
}
}
},
},
{
args: []string{"no-org", "--input", "my-custom-prompt"},
expectError: "Must select an organization with --org=<org_name>",
handler: func(t *testing.T, ctx context.Context) http.HandlerFunc {
return func(w http.ResponseWriter, r *http.Request) {
switch r.URL.Path {
case "/api/v2/users/me/organizations":
httpapi.Write(ctx, w, http.StatusOK, []codersdk.Organization{})
default:
t.Errorf("unexpected path: %s", r.URL.Path)
}
}
},
},
}
for _, tt := range tests {
t.Run(strings.Join(tt.args, ","), func(t *testing.T) {
t.Parallel()
var (
ctx = testutil.Context(t, testutil.WaitShort)
srv = httptest.NewServer(tt.handler(t, ctx))
client = new(codersdk.Client)
args = []string{"exp", "task", "create"}
sb strings.Builder
err error
)
t.Cleanup(srv.Close)
client.URL, err = url.Parse(srv.URL)
require.NoError(t, err)
inv, root := clitest.New(t, append(args, tt.args...)...)
inv.Environ = serpent.ParseEnviron(tt.env, "")
inv.Stdout = &sb
inv.Stderr = &sb
clitest.SetupConfig(t, client, root)
err = inv.WithContext(ctx).Run()
if tt.expectError == "" {
assert.NoError(t, err)
} else {
assert.ErrorContains(t, err, tt.expectError)
}
assert.Contains(t, sb.String(), tt.expectOutput)
})
}
}
+142
View File
@@ -0,0 +1,142 @@
package cli
import (
"fmt"
"strings"
"time"
"golang.org/x/xerrors"
"github.com/coder/coder/v2/cli/cliui"
"github.com/coder/coder/v2/codersdk"
"github.com/coder/serpent"
)
type taskListRow struct {
Task codersdk.Task `table:"t,recursive_inline"`
StateChangedAgo string `table:"state changed"`
}
func taskListRowFromTask(now time.Time, t codersdk.Task) taskListRow {
var stateAgo string
if t.CurrentState != nil {
stateAgo = now.UTC().Sub(t.CurrentState.Timestamp).Truncate(time.Second).String() + " ago"
}
return taskListRow{
Task: t,
StateChangedAgo: stateAgo,
}
}
func (r *RootCmd) taskList() *serpent.Command {
var (
statusFilter string
all bool
user string
client = new(codersdk.Client)
formatter = cliui.NewOutputFormatter(
cliui.TableFormat(
[]taskListRow{},
[]string{
"id",
"name",
"status",
"state",
"state changed",
"message",
},
),
cliui.ChangeFormatterData(
cliui.JSONFormat(),
func(data any) (any, error) {
rows, ok := data.([]taskListRow)
if !ok {
return nil, xerrors.Errorf("expected []taskListRow, got %T", data)
}
out := make([]codersdk.Task, len(rows))
for i := range rows {
out[i] = rows[i].Task
}
return out, nil
},
),
)
)
cmd := &serpent.Command{
Use: "list",
Short: "List experimental tasks",
Aliases: []string{"ls"},
Middleware: serpent.Chain(
serpent.RequireNArgs(0),
r.InitClient(client),
),
Options: serpent.OptionSet{
{
Name: "status",
Description: "Filter by task status (e.g. running, failed, etc).",
Flag: "status",
Default: "",
Value: serpent.StringOf(&statusFilter),
},
{
Name: "all",
Description: "List tasks for all users you can view.",
Flag: "all",
FlagShorthand: "a",
Default: "false",
Value: serpent.BoolOf(&all),
},
{
Name: "user",
Description: "List tasks for the specified user (username, \"me\").",
Flag: "user",
Default: "",
Value: serpent.StringOf(&user),
},
},
Handler: func(inv *serpent.Invocation) error {
ctx := inv.Context()
exp := codersdk.NewExperimentalClient(client)
targetUser := strings.TrimSpace(user)
if targetUser == "" && !all {
targetUser = codersdk.Me
}
tasks, err := exp.Tasks(ctx, &codersdk.TasksFilter{
Owner: targetUser,
Status: statusFilter,
})
if err != nil {
return xerrors.Errorf("list tasks: %w", err)
}
// If no rows and not JSON, show a friendly message.
if len(tasks) == 0 && formatter.FormatID() != cliui.JSONFormat().ID() {
_, _ = fmt.Fprintln(inv.Stderr, "No tasks found.")
return nil
}
rows := make([]taskListRow, len(tasks))
now := time.Now()
for i := range tasks {
rows[i] = taskListRowFromTask(now, tasks[i])
}
out, err := formatter.Format(ctx, rows)
if err != nil {
return xerrors.Errorf("format tasks: %w", err)
}
_, _ = fmt.Fprintln(inv.Stdout, out)
return nil
},
}
formatter.AttachOptions(&cmd.Options)
return cmd
}
+278
View File
@@ -0,0 +1,278 @@
package cli_test
import (
"bytes"
"context"
"database/sql"
"encoding/json"
"io"
"testing"
"github.com/google/uuid"
"github.com/stretchr/testify/require"
"cdr.dev/slog"
"cdr.dev/slog/sloggers/sloghuman"
"github.com/coder/coder/v2/cli/clitest"
"github.com/coder/coder/v2/coderd/coderdtest"
"github.com/coder/coder/v2/coderd/database"
"github.com/coder/coder/v2/coderd/database/dbauthz"
"github.com/coder/coder/v2/coderd/database/dbfake"
"github.com/coder/coder/v2/coderd/database/dbgen"
"github.com/coder/coder/v2/coderd/util/slice"
"github.com/coder/coder/v2/codersdk"
"github.com/coder/coder/v2/pty/ptytest"
"github.com/coder/coder/v2/testutil"
)
// makeAITask creates an AI-task workspace.
func makeAITask(t *testing.T, db database.Store, orgID, adminID, ownerID uuid.UUID, transition database.WorkspaceTransition, prompt string) (workspace database.WorkspaceTable) {
t.Helper()
tv := dbfake.TemplateVersion(t, db).
Seed(database.TemplateVersion{
OrganizationID: orgID,
CreatedBy: adminID,
HasAITask: sql.NullBool{
Bool: true,
Valid: true,
},
}).Do()
ws := database.WorkspaceTable{
OrganizationID: orgID,
OwnerID: ownerID,
TemplateID: tv.Template.ID,
}
build := dbfake.WorkspaceBuild(t, db, ws).
Seed(database.WorkspaceBuild{
TemplateVersionID: tv.TemplateVersion.ID,
Transition: transition,
}).WithAgent().Do()
dbgen.WorkspaceBuildParameters(t, db, []database.WorkspaceBuildParameter{
{
WorkspaceBuildID: build.Build.ID,
Name: codersdk.AITaskPromptParameterName,
Value: prompt,
},
})
agents, err := db.GetWorkspaceAgentsByWorkspaceAndBuildNumber(
dbauthz.AsSystemRestricted(context.Background()),
database.GetWorkspaceAgentsByWorkspaceAndBuildNumberParams{
WorkspaceID: build.Workspace.ID,
BuildNumber: build.Build.BuildNumber,
},
)
require.NoError(t, err)
require.NotEmpty(t, agents)
agentID := agents[0].ID
// Create a workspace app and set it as the sidebar app.
app := dbgen.WorkspaceApp(t, db, database.WorkspaceApp{
AgentID: agentID,
Slug: "task-sidebar",
DisplayName: "Task Sidebar",
External: false,
})
// Update build flags to reference the sidebar app and HasAITask=true.
err = db.UpdateWorkspaceBuildFlagsByID(
dbauthz.AsSystemRestricted(context.Background()),
database.UpdateWorkspaceBuildFlagsByIDParams{
ID: build.Build.ID,
HasAITask: sql.NullBool{Bool: true, Valid: true},
HasExternalAgent: sql.NullBool{Bool: false, Valid: false},
SidebarAppID: uuid.NullUUID{UUID: app.ID, Valid: true},
UpdatedAt: build.Build.UpdatedAt,
},
)
require.NoError(t, err)
return build.Workspace
}
func TestExpTaskList(t *testing.T) {
t.Parallel()
t.Run("NoTasks_Table", func(t *testing.T) {
t.Parallel()
// Quiet logger to reduce noise.
quiet := slog.Make(sloghuman.Sink(io.Discard))
client, _ := coderdtest.NewWithDatabase(t, &coderdtest.Options{Logger: &quiet})
owner := coderdtest.CreateFirstUser(t, client)
memberClient, _ := coderdtest.CreateAnotherUser(t, client, owner.OrganizationID)
inv, root := clitest.New(t, "exp", "task", "list")
clitest.SetupConfig(t, memberClient, root)
pty := ptytest.New(t).Attach(inv)
ctx := testutil.Context(t, testutil.WaitShort)
err := inv.WithContext(ctx).Run()
require.NoError(t, err)
pty.ExpectMatch("No tasks found.")
})
t.Run("Single_Table", func(t *testing.T) {
t.Parallel()
// Quiet logger to reduce noise.
quiet := slog.Make(sloghuman.Sink(io.Discard))
client, db := coderdtest.NewWithDatabase(t, &coderdtest.Options{Logger: &quiet})
owner := coderdtest.CreateFirstUser(t, client)
memberClient, memberUser := coderdtest.CreateAnotherUser(t, client, owner.OrganizationID)
wantPrompt := "build me a web app"
ws := makeAITask(t, db, owner.OrganizationID, owner.UserID, memberUser.ID, database.WorkspaceTransitionStart, wantPrompt)
inv, root := clitest.New(t, "exp", "task", "list", "--column", "id,name,status,initial prompt")
clitest.SetupConfig(t, memberClient, root)
pty := ptytest.New(t).Attach(inv)
ctx := testutil.Context(t, testutil.WaitShort)
err := inv.WithContext(ctx).Run()
require.NoError(t, err)
// Validate the table includes the task and status.
pty.ExpectMatch(ws.Name)
pty.ExpectMatch("running")
pty.ExpectMatch(wantPrompt)
})
t.Run("StatusFilter_JSON", func(t *testing.T) {
t.Parallel()
// Quiet logger to reduce noise.
quiet := slog.Make(sloghuman.Sink(io.Discard))
client, db := coderdtest.NewWithDatabase(t, &coderdtest.Options{Logger: &quiet})
owner := coderdtest.CreateFirstUser(t, client)
memberClient, memberUser := coderdtest.CreateAnotherUser(t, client, owner.OrganizationID)
// Create two AI tasks: one running, one stopped.
running := makeAITask(t, db, owner.OrganizationID, owner.UserID, memberUser.ID, database.WorkspaceTransitionStart, "keep me running")
stopped := makeAITask(t, db, owner.OrganizationID, owner.UserID, memberUser.ID, database.WorkspaceTransitionStop, "stop me please")
// Use JSON output to reliably validate filtering.
inv, root := clitest.New(t, "exp", "task", "list", "--status=stopped", "--output=json")
clitest.SetupConfig(t, memberClient, root)
ctx := testutil.Context(t, testutil.WaitShort)
var stdout bytes.Buffer
inv.Stdout = &stdout
inv.Stderr = &stdout
err := inv.WithContext(ctx).Run()
require.NoError(t, err)
var tasks []codersdk.Task
require.NoError(t, json.Unmarshal(stdout.Bytes(), &tasks))
// Only the stopped task is returned.
require.Len(t, tasks, 1, "expected one task after filtering")
require.Equal(t, stopped.ID, tasks[0].ID)
require.NotEqual(t, running.ID, tasks[0].ID)
})
t.Run("UserFlag_Me_Table", func(t *testing.T) {
t.Parallel()
quiet := slog.Make(sloghuman.Sink(io.Discard))
client, db := coderdtest.NewWithDatabase(t, &coderdtest.Options{Logger: &quiet})
owner := coderdtest.CreateFirstUser(t, client)
_, memberUser := coderdtest.CreateAnotherUser(t, client, owner.OrganizationID)
_ = makeAITask(t, db, owner.OrganizationID, owner.UserID, memberUser.ID, database.WorkspaceTransitionStart, "other-task")
ws := makeAITask(t, db, owner.OrganizationID, owner.UserID, owner.UserID, database.WorkspaceTransitionStart, "me-task")
inv, root := clitest.New(t, "exp", "task", "list", "--user", "me")
//nolint:gocritic // Owner client is intended here smoke test the member task not showing up.
clitest.SetupConfig(t, client, root)
pty := ptytest.New(t).Attach(inv)
ctx := testutil.Context(t, testutil.WaitShort)
err := inv.WithContext(ctx).Run()
require.NoError(t, err)
pty.ExpectMatch(ws.Name)
})
}
func TestExpTaskList_OwnerCanListOthers(t *testing.T) {
t.Parallel()
// Quiet logger to reduce noise.
quiet := slog.Make(sloghuman.Sink(io.Discard))
ownerClient, db := coderdtest.NewWithDatabase(t, &coderdtest.Options{Logger: &quiet})
owner := coderdtest.CreateFirstUser(t, ownerClient)
// Create two additional members in the owner's organization.
_, memberAUser := coderdtest.CreateAnotherUser(t, ownerClient, owner.OrganizationID)
_, memberBUser := coderdtest.CreateAnotherUser(t, ownerClient, owner.OrganizationID)
// Seed an AI task for member A and B.
_ = makeAITask(t, db, owner.OrganizationID, owner.UserID, memberAUser.ID, database.WorkspaceTransitionStart, "member-A-task")
_ = makeAITask(t, db, owner.OrganizationID, owner.UserID, memberBUser.ID, database.WorkspaceTransitionStart, "member-B-task")
t.Run("OwnerListsSpecificUserWithUserFlag_JSON", func(t *testing.T) {
t.Parallel()
// As the owner, list only member A tasks.
inv, root := clitest.New(t, "exp", "task", "list", "--user", memberAUser.Username, "--output=json")
//nolint:gocritic // Owner client is intended here to allow member tasks to be listed.
clitest.SetupConfig(t, ownerClient, root)
var stdout bytes.Buffer
inv.Stdout = &stdout
ctx := testutil.Context(t, testutil.WaitShort)
err := inv.WithContext(ctx).Run()
require.NoError(t, err)
var tasks []codersdk.Task
require.NoError(t, json.Unmarshal(stdout.Bytes(), &tasks))
// At least one task to belong to member A.
require.NotEmpty(t, tasks, "expected at least one task for member A")
// All tasks should belong to member A.
for _, task := range tasks {
require.Equal(t, memberAUser.ID, task.OwnerID, "expected only member A tasks")
}
})
t.Run("OwnerListsAllWithAllFlag_JSON", func(t *testing.T) {
t.Parallel()
// As the owner, list all tasks to verify both member tasks are present.
// Use JSON output to reliably validate filtering.
inv, root := clitest.New(t, "exp", "task", "list", "--all", "--output=json")
//nolint:gocritic // Owner client is intended here to allow all tasks to be listed.
clitest.SetupConfig(t, ownerClient, root)
var stdout bytes.Buffer
inv.Stdout = &stdout
ctx := testutil.Context(t, testutil.WaitShort)
err := inv.WithContext(ctx).Run()
require.NoError(t, err)
var tasks []codersdk.Task
require.NoError(t, json.Unmarshal(stdout.Bytes(), &tasks))
// Expect at least two tasks and ensure both owners (member A and member B) are represented.
require.GreaterOrEqual(t, len(tasks), 2, "expected two or more tasks in --all listing")
// Use slice.Find for concise existence checks.
_, foundA := slice.Find(tasks, func(t codersdk.Task) bool { return t.OwnerID == memberAUser.ID })
_, foundB := slice.Find(tasks, func(t codersdk.Task) bool { return t.OwnerID == memberBUser.ID })
require.True(t, foundA, "expected at least one task for member A in --all listing")
require.True(t, foundB, "expected at least one task for member B in --all listing")
})
}
+7 -7
View File
@@ -18,7 +18,7 @@ import (
// workspaceListRow is the type provided to the OutputFormatter. This is a bit
// dodgy but it's the only way to do complex display code for one format vs. the
// other.
type workspaceListRow struct {
type WorkspaceListRow struct {
// For JSON format:
codersdk.Workspace `table:"-"`
@@ -40,7 +40,7 @@ type workspaceListRow struct {
DailyCost string `json:"-" table:"daily cost"`
}
func workspaceListRowFromWorkspace(now time.Time, workspace codersdk.Workspace) workspaceListRow {
func WorkspaceListRowFromWorkspace(now time.Time, workspace codersdk.Workspace) WorkspaceListRow {
status := codersdk.WorkspaceDisplayStatus(workspace.LatestBuild.Job.Status, workspace.LatestBuild.Transition)
lastBuilt := now.UTC().Sub(workspace.LatestBuild.Job.CreatedAt).Truncate(time.Second)
@@ -55,7 +55,7 @@ func workspaceListRowFromWorkspace(now time.Time, workspace codersdk.Workspace)
favIco = "★"
}
workspaceName := favIco + " " + workspace.OwnerName + "/" + workspace.Name
return workspaceListRow{
return WorkspaceListRow{
Favorite: workspace.Favorite,
Workspace: workspace,
WorkspaceName: workspaceName,
@@ -80,7 +80,7 @@ func (r *RootCmd) list() *serpent.Command {
filter cliui.WorkspaceFilter
formatter = cliui.NewOutputFormatter(
cliui.TableFormat(
[]workspaceListRow{},
[]WorkspaceListRow{},
[]string{
"workspace",
"template",
@@ -107,7 +107,7 @@ func (r *RootCmd) list() *serpent.Command {
r.InitClient(client),
),
Handler: func(inv *serpent.Invocation) error {
res, err := queryConvertWorkspaces(inv.Context(), client, filter.Filter(), workspaceListRowFromWorkspace)
res, err := QueryConvertWorkspaces(inv.Context(), client, filter.Filter(), WorkspaceListRowFromWorkspace)
if err != nil {
return err
}
@@ -137,9 +137,9 @@ func (r *RootCmd) list() *serpent.Command {
// queryConvertWorkspaces is a helper function for converting
// codersdk.Workspaces to a different type.
// It's used by the list command to convert workspaces to
// workspaceListRow, and by the schedule command to
// WorkspaceListRow, and by the schedule command to
// convert workspaces to scheduleListRow.
func queryConvertWorkspaces[T any](ctx context.Context, client *codersdk.Client, filter codersdk.WorkspaceFilter, convertF func(time.Time, codersdk.Workspace) T) ([]T, error) {
func QueryConvertWorkspaces[T any](ctx context.Context, client *codersdk.Client, filter codersdk.WorkspaceFilter, convertF func(time.Time, codersdk.Workspace) T) ([]T, error) {
var empty []T
workspaces, err := client.Workspaces(ctx, filter)
if err != nil {
+85 -49
View File
@@ -11,7 +11,9 @@ import (
"runtime"
"slices"
"strings"
"time"
"github.com/google/uuid"
"github.com/skratchdot/open-golang/open"
"golang.org/x/xerrors"
@@ -42,7 +44,6 @@ func (r *RootCmd) openVSCode() *serpent.Command {
generateToken bool
testOpenError bool
appearanceConfig codersdk.AppearanceConfig
containerName string
)
client := new(codersdk.Client)
@@ -71,7 +72,7 @@ func (r *RootCmd) openVSCode() *serpent.Command {
// need to wait for the agent to start.
workspaceQuery := inv.Args[0]
autostart := true
workspace, workspaceAgent, err := getWorkspaceAndAgent(ctx, inv, client, autostart, workspaceQuery)
workspace, workspaceAgent, otherWorkspaceAgents, err := GetWorkspaceAndAgent(ctx, inv, client, autostart, workspaceQuery)
if err != nil {
return xerrors.Errorf("get workspace and agent: %w", err)
}
@@ -79,6 +80,70 @@ func (r *RootCmd) openVSCode() *serpent.Command {
workspaceName := workspace.Name + "." + workspaceAgent.Name
insideThisWorkspace := insideAWorkspace && inWorkspaceName == workspaceName
// To properly work with devcontainers, VS Code has to connect to
// parent workspace agent. It will then proceed to enter the
// container given the correct parameters. There is inherently no
// dependency on the devcontainer agent in this scenario, but
// relying on it simplifies the logic and ensures the devcontainer
// is ready. To eliminate the dependency we would need to know that
// a sub-agent that hasn't been created yet may be a devcontainer,
// and thus will be created at a later time as well as expose the
// container folder on the API response.
var parentWorkspaceAgent codersdk.WorkspaceAgent
var devcontainer codersdk.WorkspaceAgentDevcontainer
if workspaceAgent.ParentID.Valid {
// This is likely a devcontainer agent, so we need to find the
// parent workspace agent as well as the devcontainer.
for _, otherAgent := range otherWorkspaceAgents {
if otherAgent.ID == workspaceAgent.ParentID.UUID {
parentWorkspaceAgent = otherAgent
break
}
}
if parentWorkspaceAgent.ID == uuid.Nil {
return xerrors.Errorf("parent workspace agent %s not found", workspaceAgent.ParentID.UUID)
}
printedWaiting := false
for {
resp, err := client.WorkspaceAgentListContainers(ctx, parentWorkspaceAgent.ID, nil)
if err != nil {
return xerrors.Errorf("list parent workspace agent containers: %w", err)
}
for _, dc := range resp.Devcontainers {
if dc.Agent.ID == workspaceAgent.ID {
devcontainer = dc
break
}
}
if devcontainer.ID == uuid.Nil {
cliui.Warnf(inv.Stderr, "Devcontainer %q not found, opening as a regular workspace...", workspaceAgent.Name)
parentWorkspaceAgent = codersdk.WorkspaceAgent{} // Reset to empty, so we don't use it later.
break
}
// Precondition, the devcontainer must be running to enter
// it. Once running, devcontainer.Container will be set.
if devcontainer.Status == codersdk.WorkspaceAgentDevcontainerStatusRunning {
break
}
if devcontainer.Status != codersdk.WorkspaceAgentDevcontainerStatusStarting {
return xerrors.Errorf("devcontainer %q is in unexpected status %q, expected %q or %q",
devcontainer.Name, devcontainer.Status,
codersdk.WorkspaceAgentDevcontainerStatusRunning,
codersdk.WorkspaceAgentDevcontainerStatusStarting,
)
}
if !printedWaiting {
_, _ = fmt.Fprintf(inv.Stderr, "Waiting for devcontainer %q status to change from %q to %q...\n", devcontainer.Name, devcontainer.Status, codersdk.WorkspaceAgentDevcontainerStatusRunning)
printedWaiting = true
}
time.Sleep(5 * time.Second) // Wait a bit before retrying.
}
}
if !insideThisWorkspace {
// Wait for the agent to connect, we don't care about readiness
// otherwise (e.g. wait).
@@ -99,6 +164,9 @@ func (r *RootCmd) openVSCode() *serpent.Command {
// the created state, so we need to wait for that to happen.
// However, if no directory is set, the expanded directory will
// not be set either.
//
// Note that this is irrelevant for devcontainer sub agents, as
// they always have a directory set.
if workspaceAgent.Directory != "" {
workspace, workspaceAgent, err = waitForAgentCond(ctx, client, workspace, workspaceAgent, func(_ codersdk.WorkspaceAgent) bool {
return workspaceAgent.LifecycleState != codersdk.WorkspaceAgentLifecycleCreated
@@ -114,41 +182,6 @@ func (r *RootCmd) openVSCode() *serpent.Command {
directory = inv.Args[1]
}
if containerName != "" {
containers, err := client.WorkspaceAgentListContainers(ctx, workspaceAgent.ID, map[string]string{"devcontainer.local_folder": ""})
if err != nil {
return xerrors.Errorf("list workspace agent containers: %w", err)
}
var foundContainer bool
for _, container := range containers.Containers {
if container.FriendlyName != containerName {
continue
}
foundContainer = true
if directory == "" {
localFolder, ok := container.Labels["devcontainer.local_folder"]
if !ok {
return xerrors.New("container missing `devcontainer.local_folder` label")
}
directory, ok = container.Volumes[localFolder]
if !ok {
return xerrors.New("container missing volume for `devcontainer.local_folder`")
}
}
break
}
if !foundContainer {
return xerrors.New("no container found")
}
}
directory, err = resolveAgentAbsPath(workspaceAgent.ExpandedDirectory, directory, workspaceAgent.OperatingSystem, insideThisWorkspace)
if err != nil {
return xerrors.Errorf("resolve agent path: %w", err)
@@ -174,14 +207,16 @@ func (r *RootCmd) openVSCode() *serpent.Command {
u *url.URL
qp url.Values
)
if containerName != "" {
if devcontainer.ID != uuid.Nil {
u, qp = buildVSCodeWorkspaceDevContainerLink(
token,
client.URL.String(),
workspace,
workspaceAgent,
containerName,
parentWorkspaceAgent,
devcontainer.Container.FriendlyName,
directory,
devcontainer.WorkspaceFolder,
devcontainer.ConfigPath,
)
} else {
u, qp = buildVSCodeWorkspaceLink(
@@ -247,13 +282,6 @@ func (r *RootCmd) openVSCode() *serpent.Command {
),
Value: serpent.BoolOf(&generateToken),
},
{
Flag: "container",
FlagShorthand: "c",
Description: "Container name to connect to in the workspace.",
Value: serpent.StringOf(&containerName),
Hidden: true, // Hidden until this features is at least in beta.
},
{
Flag: "test.open-error",
Description: "Don't run the open command.",
@@ -288,7 +316,7 @@ func (r *RootCmd) openApp() *serpent.Command {
}
workspaceName := inv.Args[0]
ws, agt, err := getWorkspaceAndAgent(ctx, inv, client, false, workspaceName)
ws, agt, _, err := GetWorkspaceAndAgent(ctx, inv, client, false, workspaceName)
if err != nil {
var sdkErr *codersdk.Error
if errors.As(err, &sdkErr) && sdkErr.StatusCode() == http.StatusNotFound {
@@ -430,8 +458,14 @@ func buildVSCodeWorkspaceDevContainerLink(
workspaceAgent codersdk.WorkspaceAgent,
containerName string,
containerFolder string,
localWorkspaceFolder string,
localConfigFile string,
) (*url.URL, url.Values) {
containerFolder = filepath.ToSlash(containerFolder)
localWorkspaceFolder = filepath.ToSlash(localWorkspaceFolder)
if localConfigFile != "" {
localConfigFile = filepath.ToSlash(localConfigFile)
}
qp := url.Values{}
qp.Add("url", clientURL)
@@ -440,6 +474,8 @@ func buildVSCodeWorkspaceDevContainerLink(
qp.Add("agent", workspaceAgent.Name)
qp.Add("devContainerName", containerName)
qp.Add("devContainerFolder", containerFolder)
qp.Add("localWorkspaceFolder", localWorkspaceFolder)
qp.Add("localConfigFile", localConfigFile)
if token != "" {
qp.Add("token", token)
@@ -469,7 +505,7 @@ func waitForAgentCond(ctx context.Context, client *codersdk.Client, workspace co
}
for workspace = range wc {
workspaceAgent, err = getWorkspaceAgent(workspace, workspaceAgent.Name)
workspaceAgent, _, err = getWorkspaceAgent(workspace, workspaceAgent.Name)
if err != nil {
return workspace, workspaceAgent, xerrors.Errorf("get workspace agent: %w", err)
}
+132 -213
View File
@@ -1,8 +1,10 @@
package cli_test
import (
"context"
"net/url"
"os"
"path"
"path/filepath"
"runtime"
"strings"
@@ -11,11 +13,11 @@ import (
"github.com/google/uuid"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
"go.uber.org/mock/gomock"
"golang.org/x/xerrors"
"github.com/coder/coder/v2/agent"
"github.com/coder/coder/v2/agent/agentcontainers"
"github.com/coder/coder/v2/agent/agentcontainers/acmock"
"github.com/coder/coder/v2/agent/agentcontainers/watcher"
"github.com/coder/coder/v2/agent/agenttest"
"github.com/coder/coder/v2/cli/clitest"
"github.com/coder/coder/v2/coderd/coderdtest"
@@ -289,6 +291,60 @@ func TestOpenVSCode_NoAgentDirectory(t *testing.T) {
}
}
type fakeContainerCLI struct {
resp codersdk.WorkspaceAgentListContainersResponse
}
func (f *fakeContainerCLI) List(ctx context.Context) (codersdk.WorkspaceAgentListContainersResponse, error) {
return f.resp, nil
}
func (*fakeContainerCLI) DetectArchitecture(ctx context.Context, containerID string) (string, error) {
return runtime.GOARCH, nil
}
func (*fakeContainerCLI) Copy(ctx context.Context, containerID, src, dst string) error {
return nil
}
func (*fakeContainerCLI) ExecAs(ctx context.Context, containerID, user string, args ...string) ([]byte, error) {
return nil, nil
}
type fakeDevcontainerCLI struct {
config agentcontainers.DevcontainerConfig
execAgent func(ctx context.Context, token string) error
}
func (f *fakeDevcontainerCLI) ReadConfig(ctx context.Context, workspaceFolder, configFile string, env []string, opts ...agentcontainers.DevcontainerCLIReadConfigOptions) (agentcontainers.DevcontainerConfig, error) {
return f.config, nil
}
func (f *fakeDevcontainerCLI) Exec(ctx context.Context, workspaceFolder, configFile string, name string, args []string, opts ...agentcontainers.DevcontainerCLIExecOptions) error {
var opt agentcontainers.DevcontainerCLIExecConfig
for _, o := range opts {
o(&opt)
}
var token string
for _, arg := range opt.Args {
if strings.HasPrefix(arg, "CODER_AGENT_TOKEN=") {
token = strings.TrimPrefix(arg, "CODER_AGENT_TOKEN=")
break
}
}
if token == "" {
return xerrors.New("no agent token provided in args")
}
if f.execAgent == nil {
return nil
}
return f.execAgent(ctx, token)
}
func (*fakeDevcontainerCLI) Up(ctx context.Context, workspaceFolder, configFile string, opts ...agentcontainers.DevcontainerCLIUpOptions) (string, error) {
return "", nil
}
func TestOpenVSCodeDevContainer(t *testing.T) {
t.Parallel()
@@ -296,56 +352,85 @@ func TestOpenVSCodeDevContainer(t *testing.T) {
t.Skip("DevContainers are only supported for agents on Linux")
}
agentName := "agent1"
agentDir, err := filepath.Abs(filepath.FromSlash("/tmp"))
require.NoError(t, err)
parentAgentName := "agent1"
devcontainerID := uuid.New()
devcontainerName := "wilson"
workspaceFolder := "/home/coder/wilson"
configFile := path.Join(workspaceFolder, ".devcontainer", "devcontainer.json")
containerID := uuid.NewString()
containerName := testutil.GetRandomName(t)
containerFolder := "/workspace/coder"
ctrl := gomock.NewController(t)
mccli := acmock.NewMockContainerCLI(ctrl)
mccli.EXPECT().List(gomock.Any()).Return(
codersdk.WorkspaceAgentListContainersResponse{
Containers: []codersdk.WorkspaceAgentContainer{
{
ID: uuid.NewString(),
CreatedAt: dbtime.Now(),
FriendlyName: containerName,
Image: "busybox:latest",
Labels: map[string]string{
"devcontainer.local_folder": "/home/coder/coder",
},
Running: true,
Status: "running",
Volumes: map[string]string{
"/home/coder/coder": containerFolder,
},
},
},
}, nil,
).AnyTimes()
containerFolder := "/workspaces/wilson"
client, workspace, agentToken := setupWorkspaceForAgent(t, func(agents []*proto.Agent) []*proto.Agent {
agents[0].Directory = agentDir
agents[0].Name = agentName
agents[0].Name = parentAgentName
agents[0].OperatingSystem = runtime.GOOS
return agents
})
fCCLI := &fakeContainerCLI{
resp: codersdk.WorkspaceAgentListContainersResponse{
Containers: []codersdk.WorkspaceAgentContainer{
{
ID: containerID,
CreatedAt: dbtime.Now(),
FriendlyName: containerName,
Image: "busybox:latest",
Labels: map[string]string{
agentcontainers.DevcontainerLocalFolderLabel: workspaceFolder,
agentcontainers.DevcontainerConfigFileLabel: configFile,
agentcontainers.DevcontainerIsTestRunLabel: "true",
"coder.test": t.Name(),
},
Running: true,
Status: "running",
},
},
},
}
fDCCLI := &fakeDevcontainerCLI{
config: agentcontainers.DevcontainerConfig{
Workspace: agentcontainers.DevcontainerWorkspace{
WorkspaceFolder: containerFolder,
},
},
execAgent: func(ctx context.Context, token string) error {
t.Logf("Starting devcontainer subagent with token: %s", token)
_ = agenttest.New(t, client.URL, token)
<-ctx.Done()
return ctx.Err()
},
}
_ = agenttest.New(t, client.URL, agentToken, func(o *agent.Options) {
o.Devcontainers = true
o.DevcontainerAPIOptions = append(o.DevcontainerAPIOptions,
agentcontainers.WithContainerCLI(mccli),
agentcontainers.WithContainerLabelIncludeFilter("this.label.does.not.exist.ignore.devcontainers", "true"),
agentcontainers.WithProjectDiscovery(false),
agentcontainers.WithContainerCLI(fCCLI),
agentcontainers.WithDevcontainerCLI(fDCCLI),
agentcontainers.WithWatcher(watcher.NewNoop()),
agentcontainers.WithDevcontainers(
[]codersdk.WorkspaceAgentDevcontainer{{
ID: devcontainerID,
Name: devcontainerName,
WorkspaceFolder: workspaceFolder,
Status: codersdk.WorkspaceAgentDevcontainerStatusStopped,
}},
[]codersdk.WorkspaceAgentScript{{
ID: devcontainerID,
LogSourceID: uuid.New(),
}},
),
agentcontainers.WithContainerLabelIncludeFilter("coder.test", t.Name()),
)
})
_ = coderdtest.NewWorkspaceAgentWaiter(t, client, workspace.ID).Wait()
coderdtest.NewWorkspaceAgentWaiter(t, client, workspace.ID).AgentNames([]string{parentAgentName, devcontainerName}).Wait()
insideWorkspaceEnv := map[string]string{
"CODER": "true",
"CODER_WORKSPACE_NAME": workspace.Name,
"CODER_WORKSPACE_AGENT_NAME": agentName,
"CODER_WORKSPACE_AGENT_NAME": devcontainerName,
}
wd, err := os.Getwd()
@@ -361,215 +446,47 @@ func TestOpenVSCodeDevContainer(t *testing.T) {
}{
{
name: "nonexistent container",
args: []string{"--test.open-error", workspace.Name, "--container", containerName + "bad"},
args: []string{"--test.open-error", workspace.Name + "." + devcontainerName + "bad"},
wantError: true,
},
{
name: "ok",
args: []string{"--test.open-error", workspace.Name, "--container", containerName},
wantDir: containerFolder,
args: []string{"--test.open-error", workspace.Name + "." + devcontainerName},
wantError: false,
},
{
name: "ok with absolute path",
args: []string{"--test.open-error", workspace.Name, "--container", containerName, containerFolder},
wantDir: containerFolder,
args: []string{"--test.open-error", workspace.Name + "." + devcontainerName, containerFolder},
wantError: false,
},
{
name: "ok with relative path",
args: []string{"--test.open-error", workspace.Name, "--container", containerName, "my/relative/path"},
wantDir: filepath.Join(agentDir, filepath.FromSlash("my/relative/path")),
args: []string{"--test.open-error", workspace.Name + "." + devcontainerName, "my/relative/path"},
wantDir: path.Join(containerFolder, "my/relative/path"),
wantError: false,
},
{
name: "ok with token",
args: []string{"--test.open-error", workspace.Name, "--container", containerName, "--generate-token"},
wantDir: containerFolder,
args: []string{"--test.open-error", workspace.Name + "." + devcontainerName, "--generate-token"},
wantError: false,
wantToken: true,
},
// Inside workspace, does not require --test.open-error
{
name: "ok inside workspace",
env: insideWorkspaceEnv,
args: []string{workspace.Name, "--container", containerName},
wantDir: containerFolder,
},
{
name: "ok inside workspace relative path",
env: insideWorkspaceEnv,
args: []string{workspace.Name, "--container", containerName, "foo"},
wantDir: filepath.Join(wd, "foo"),
},
{
name: "ok inside workspace token",
env: insideWorkspaceEnv,
args: []string{workspace.Name, "--container", containerName, "--generate-token"},
wantDir: containerFolder,
wantToken: true,
},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
t.Parallel()
inv, root := clitest.New(t, append([]string{"open", "vscode"}, tt.args...)...)
clitest.SetupConfig(t, client, root)
pty := ptytest.New(t)
inv.Stdin = pty.Input()
inv.Stdout = pty.Output()
ctx := testutil.Context(t, testutil.WaitLong)
inv = inv.WithContext(ctx)
for k, v := range tt.env {
inv.Environ.Set(k, v)
}
w := clitest.StartWithWaiter(t, inv)
if tt.wantError {
w.RequireError()
return
}
me, err := client.User(ctx, codersdk.Me)
require.NoError(t, err)
line := pty.ReadLine(ctx)
u, err := url.ParseRequestURI(line)
require.NoError(t, err, "line: %q", line)
qp := u.Query()
assert.Equal(t, client.URL.String(), qp.Get("url"))
assert.Equal(t, me.Username, qp.Get("owner"))
assert.Equal(t, workspace.Name, qp.Get("workspace"))
assert.Equal(t, agentName, qp.Get("agent"))
assert.Equal(t, containerName, qp.Get("devContainerName"))
if tt.wantDir != "" {
assert.Equal(t, tt.wantDir, qp.Get("devContainerFolder"))
} else {
assert.Equal(t, containerFolder, qp.Get("devContainerFolder"))
}
if tt.wantToken {
assert.NotEmpty(t, qp.Get("token"))
} else {
assert.Empty(t, qp.Get("token"))
}
w.RequireSuccess()
})
}
}
func TestOpenVSCodeDevContainer_NoAgentDirectory(t *testing.T) {
t.Parallel()
if runtime.GOOS != "linux" {
t.Skip("DevContainers are only supported for agents on Linux")
}
agentName := "agent1"
containerName := testutil.GetRandomName(t)
containerFolder := "/workspace/coder"
ctrl := gomock.NewController(t)
mccli := acmock.NewMockContainerCLI(ctrl)
mccli.EXPECT().List(gomock.Any()).Return(
codersdk.WorkspaceAgentListContainersResponse{
Containers: []codersdk.WorkspaceAgentContainer{
{
ID: uuid.NewString(),
CreatedAt: dbtime.Now(),
FriendlyName: containerName,
Image: "busybox:latest",
Labels: map[string]string{
"devcontainer.local_folder": "/home/coder/coder",
},
Running: true,
Status: "running",
Volumes: map[string]string{
"/home/coder/coder": containerFolder,
},
},
},
}, nil,
).AnyTimes()
client, workspace, agentToken := setupWorkspaceForAgent(t, func(agents []*proto.Agent) []*proto.Agent {
agents[0].Name = agentName
agents[0].OperatingSystem = runtime.GOOS
return agents
})
_ = agenttest.New(t, client.URL, agentToken, func(o *agent.Options) {
o.Devcontainers = true
o.DevcontainerAPIOptions = append(o.DevcontainerAPIOptions,
agentcontainers.WithContainerCLI(mccli),
agentcontainers.WithContainerLabelIncludeFilter("this.label.does.not.exist.ignore.devcontainers", "true"),
)
})
_ = coderdtest.NewWorkspaceAgentWaiter(t, client, workspace.ID).Wait()
insideWorkspaceEnv := map[string]string{
"CODER": "true",
"CODER_WORKSPACE_NAME": workspace.Name,
"CODER_WORKSPACE_AGENT_NAME": agentName,
}
wd, err := os.Getwd()
require.NoError(t, err)
tests := []struct {
name string
env map[string]string
args []string
wantDir string
wantError bool
wantToken bool
}{
{
name: "ok",
args: []string{"--test.open-error", workspace.Name, "--container", containerName},
},
{
name: "no agent dir error relative path",
args: []string{"--test.open-error", workspace.Name, "--container", containerName, "my/relative/path"},
wantDir: filepath.FromSlash("my/relative/path"),
wantError: true,
},
{
name: "ok with absolute path",
args: []string{"--test.open-error", workspace.Name, "--container", containerName, "/home/coder"},
wantDir: "/home/coder",
},
{
name: "ok with token",
args: []string{"--test.open-error", workspace.Name, "--container", containerName, "--generate-token"},
wantToken: true,
},
// Inside workspace, does not require --test.open-error
{
name: "ok inside workspace",
env: insideWorkspaceEnv,
args: []string{workspace.Name, "--container", containerName},
args: []string{workspace.Name + "." + devcontainerName},
},
{
name: "ok inside workspace relative path",
env: insideWorkspaceEnv,
args: []string{workspace.Name, "--container", containerName, "foo"},
args: []string{workspace.Name + "." + devcontainerName, "foo"},
wantDir: filepath.Join(wd, "foo"),
},
{
name: "ok inside workspace token",
env: insideWorkspaceEnv,
args: []string{workspace.Name, "--container", containerName, "--generate-token"},
args: []string{workspace.Name + "." + devcontainerName, "--generate-token"},
wantToken: true,
},
}
@@ -610,8 +527,10 @@ func TestOpenVSCodeDevContainer_NoAgentDirectory(t *testing.T) {
assert.Equal(t, client.URL.String(), qp.Get("url"))
assert.Equal(t, me.Username, qp.Get("owner"))
assert.Equal(t, workspace.Name, qp.Get("workspace"))
assert.Equal(t, agentName, qp.Get("agent"))
assert.Equal(t, parentAgentName, qp.Get("agent"))
assert.Equal(t, containerName, qp.Get("devContainerName"))
assert.Equal(t, workspaceFolder, qp.Get("localWorkspaceFolder"))
assert.Equal(t, configFile, qp.Get("localConfigFile"))
if tt.wantDir != "" {
assert.Equal(t, tt.wantDir, qp.Get("devContainerFolder"))
-1
View File
@@ -435,7 +435,6 @@ func applyOrgResourceActions(role *codersdk.Role, resource string, actions []str
// Construct new site perms with only new perms for the resource
keep := make([]codersdk.Permission, 0)
for _, perm := range role.OrganizationPermissions {
perm := perm
if string(perm.ResourceType) != resource {
keep = append(keep, perm)
}
-2
View File
@@ -116,7 +116,6 @@ func (r *RootCmd) setOrganizationSettings(orgContext *OrganizationContext, setti
}
for _, set := range settings {
set := set
patch := set.Patch
cmd.Children = append(cmd.Children, &serpent.Command{
Use: set.Name,
@@ -192,7 +191,6 @@ func (r *RootCmd) printOrganizationSetting(orgContext *OrganizationContext, sett
}
for _, set := range settings {
set := set
fetch := set.Fetch
cmd.Children = append(cmd.Children, &serpent.Command{
Use: set.Name,

Some files were not shown because too many files have changed in this diff Show More