Ammar Bandukwala
adbb025e74
feat: add user-level parameter autofill ( #11731 )
...
This PR solves #10478 by auto-filling previously used template values in create and update workspace flows.
I decided against explicit user values in settings for these reasons:
* Autofill is far easier to implement
* Users benefit from autofill _by default_ — we don't need to teach them new concepts
* If we decide that autofill creates more harm than good, we can remove it without breaking compatibility
2024-01-30 16:02:21 -06:00
Jon Ayers
4f5a2f0a9b
feat: add backend for jfrog xray support ( #11829 )
2024-01-29 19:30:02 -06:00
Steven Masley
d66e6e78ee
fix: always attempt external auth refresh when fetching ( #11762 ) ( #11830 )
...
* fix: always attempt external auth refresh when fetching
* refactor validate to check expiry when considering "valid"
2024-01-29 08:55:15 -06:00
Dean Sheather
29707099d7
chore: add agentapi tests ( #11269 )
2024-01-26 07:04:19 +00:00
Ammar Bandukwala
79568bf628
Revert "fix: always attempt external auth refresh when fetching ( #11762 )"
...
This reverts commit 0befc0826a .
2024-01-25 14:22:47 -06:00
Steven Masley
0befc0826a
fix: always attempt external auth refresh when fetching ( #11762 )
...
* fix: always attempt external auth refresh when fetching
* refactor validate to check expiry when considering "valid"
2024-01-25 10:54:56 -06:00
Cian Johnston
f92336c4d5
feat(coderd): allow workspace owners to mark workspaces as favorite ( #11791 )
...
- Adds column `favorite` to workspaces table
- Adds API endpoints to favorite/unfavorite workspaces
- Modifies sorting order to return owners' favorite workspaces first
2024-01-24 13:39:19 +00:00
Steven Masley
d6ba0dfecb
feat: add "updated" search param to workspaces ( #11714 )
...
* feat: add "updated" search param to workspaces
* rego -> sql needs to specify which <table>.organization_id
2024-01-23 11:52:06 -06:00
Asher
3014777d2a
feat: add endpoints to oauth2 provider applications ( #11718 )
...
These will show up when configuring the application along with the
client ID and everything else. Should make it easier to configure the
application, otherwise you will have to go look up the URLs in the
docs (which are not yet written).
Co-authored-by: Steven Masley <stevenmasley@gmail.com >
2024-01-22 13:25:25 -09:00
Spike Curtis
387723a596
fix: close pg PubSub listener to avoid race ( #11640 )
...
Fixes flake as seen here: https://github.com/coder/coder/runs/20528529187
2024-01-18 09:18:59 +04:00
Steven Masley
b246f08d84
chore: move app URL parsing to its own package ( #11651 )
...
* chore: move app url parsing to it's own package
2024-01-17 10:41:42 -06:00
Marcin Tojek
5eb3e1cdaa
feat: expose owner_name in coder_workspace resource ( #11639 )
2024-01-17 13:20:45 +01:00
Cian Johnston
d583acad00
fix(coderd): workspaceapps: update last_used_at when workspace app reports stats ( #11603 )
...
- Adds a new query BatchUpdateLastUsedAt
- Adds calls to BatchUpdateLastUsedAt in app stats handler upon flush
- Passes a stats flush channel to apptest setup scaffolding and updates unit tests to assert modifications to LastUsedAt.
2024-01-16 14:06:39 +00:00
Jon Ayers
aecdafdcf2
fix: fix template edit overriding with flag defaults ( #11564 )
2024-01-11 16:18:46 -06:00
Asher
d837d66e29
chore: update sqlc to 1.25.0 ( #11538 )
...
Co-authored-by: Muhammad Atif Ali <atif@coder.com >
2024-01-10 09:19:41 +03:00
Cian Johnston
04fd96a014
feat(coderd): add provisioner_daemons to /debug/health endpoint ( #11393 )
...
Adds a healthcheck for provisioner daemons to /debug/health endpoint.
2024-01-08 09:29:04 +00:00
Garrett Delfosse
b21da38bea
chore: deprecate template create command in favor of template push ( #11390 )
2024-01-05 21:04:14 +00:00
Steven Masley
dd05a6b13a
chore: mockgen archived, moved to new location ( #11415 )
...
* chore: mockgen archived, moved to new location
2024-01-04 18:35:56 -06:00
Steven Masley
85ff030ab4
chore: update LastConnectedReplicaID in dbmem ( #11412 )
2024-01-04 19:18:54 +00:00
Cian Johnston
4355894b2b
fix(coderd/database): revert addition of v prefix to provisioner_daemons.api_version ( #11403 )
...
"Reverts" #11385 by adding an inverse migration.
2024-01-04 11:47:31 +00:00
Spike Curtis
f9ebe8c719
fix: send end of logs when dbfake completes job ( #11402 )
2024-01-04 15:18:00 +04:00
Cian Johnston
f80a1cf3c8
fix(coderd/database): add missing v prefix to provisioner_daemons.api_version ( #11385 )
2024-01-03 14:11:02 +00:00
Cian Johnston
068e730046
chore(coderd/database/dbfake): fix pq test flake in TestStart_Starting ( #11384 )
2024-01-03 12:27:50 +00:00
Spike Curtis
5d76210b0d
fix: change coder start to be a no-op if workspace is started
...
Fixes #11380
2024-01-03 13:24:37 +04:00
Cian Johnston
1ef96022b0
feat(coderd): add provisioner build version and api_version on serve ( #11369 )
...
* assert provisioner daemon version and api_version in unit tests
* add build info in HTTP header, extract codersdk.BuildVersionHeader
* add api_version to codersdk.ProvisionerDaemon
* testutil.MustString -> testutil.MustRandString
2024-01-03 09:01:57 +00:00
Steven Masley
8f49f10134
chore: put overrides and renames in pkg context in sqlc.yaml ( #11347 )
...
* chore: Put overrides and renames in pkg context in sqlc.yaml
---------
Co-authored-by: Andrew Benton <andrewmbenton@gmail.com >
2024-01-02 08:56:38 +00:00
Asher
5cfa34b31e
feat: add OAuth2 applications ( #11197 )
...
* Add database tables for OAuth2 applications
These are applications that will be able to use OAuth2 to get an API key
from Coder.
* Add endpoints for managing OAuth2 applications
These let you add, update, and remove OAuth2 applications.
* Add frontend for managing OAuth2 applications
2023-12-21 21:38:42 +00:00
Steven Masley
fe867d02e0
fix: correct perms for forbidden error in TemplateScheduleStore.Load ( #11286 )
...
* chore: TemplateScheduleStore.Load() throwing forbidden error
* fix: workspace agent scope to include template
2023-12-20 11:38:49 -06:00
Steven Masley
e8be092af0
chore: add sqlc push action on releases ( #11171 )
...
* add sqlc push action on releases
* Make sqlc push optional
2023-12-19 20:31:55 +00:00
Cian Johnston
213b768785
feat(coderd): insert provisioner daemons ( #11207 )
...
* Adds UpdateProvisionerDaemonLastSeenAt
* Adds heartbeat to provisioner daemons
* Inserts provisioner daemons to database upon start
* Ensures TagOwner is an empty string and not nil
* Adds COALESCE() in idx_provisioner_daemons_name_owner_key
2023-12-18 16:44:52 +00:00
Dean Sheather
e46431078c
feat: add AgentAPI using DRPC ( #10811 )
...
Co-authored-by: Spike Curtis <spike@coder.com >
2023-12-18 22:53:28 +10:00
Steven Masley
3f6096b0d7
chore: unit test to enforce authorized queries match args ( #11211 )
...
* chore: unit test to enforce authorized queries match args
* Also check querycontext arguments
2023-12-15 20:31:07 +00:00
Steven Masley
e63de9a259
chore: enforcement of dbauthz tests was broken ( #11218 )
...
* chore: enforcement of dbauthz tests was broken
Implemented missing tests to catch back up
---------
Co-authored-by: Cian Johnston <cian@coder.com >
2023-12-15 18:30:21 +00:00
Dean Sheather
b36071c6bb
feat: allow templates to specify max_ttl or autostop_requirement ( #10920 )
2023-12-15 18:27:56 +10:00
Spike Curtis
fad457420b
fix: copy StringMap on insert and query in dbmem ( #11206 )
...
Addresses the issue in #11185 for the StringMap datatype.
There are other slice data types in our database package that also need to be fixed, but that'll be a different PR
2023-12-14 22:23:29 +04:00
Kayla Washburn
133dc66143
feat: add a theme picker ( #11140 )
2023-12-14 10:38:44 -07:00
Cian Johnston
5b0e6bfa2a
feat(coderd/database): add api_version to provisioner_daemons table ( #11204 )
...
Adds column api_version to the provisioner_daemons table.
This is distinct from the coderd version, and is used to handle breaking changes in the provisioner daemon API.
2023-12-14 12:52:41 +00:00
Steven Masley
b7bdb17460
feat: add metrics to workspace agent scripts ( #11132 )
...
* push startup script metrics to agent
2023-12-13 11:45:43 -06:00
Cian Johnston
4f7ae6461b
feat(coderd/database): add UpsertProvisionerDaemons query ( #11178 )
...
Co-authored-by: Marcin Tojek <marcin@coder.com >
2023-12-13 12:31:40 +00:00
Steven Masley
6800fc8477
chore: bump go (->v1.21.5) and sqlc (->v1.24.0) to new versions ( #11170 )
2023-12-12 18:50:23 -06:00
Steven Masley
e52d848d05
chore: validate queries using sqlc-vet in github actions ( #11163 )
2023-12-12 15:53:26 -06:00
Steven Masley
dba0dfa859
chore: correct 500 -> 404 on workspace agent mw ( #11129 )
...
* chore: correct 500 -> 404
2023-12-12 15:14:32 -06:00
Steven Masley
0181e036f6
chore: remove unused query failing to prepare ( #11167 )
2023-12-12 15:02:15 -06:00
Cian Johnston
b02796655e
fix(coderd/database): remove column updated_at from provisioner_daemons table ( #11108 )
2023-12-12 11:19:28 +00:00
Cian Johnston
197cd935cf
chore(Makefile): use linter version from dogfood Dockerfile ( #11147 )
...
* chore(Makefile): use golangci-lint version from dogfood Dockerfile
* chore(dogfood/Dockerfile): update golangci-lint to latest version
* chore(coderd): address linter complaints
2023-12-12 10:02:32 +00:00
Kayla Washburn
6775a86785
chore: make "users"."avatar_url" NOT NULL ( #11112 )
2023-12-11 10:09:51 -07:00
Kayla Washburn
d8e95001e8
chore: add theme_preference column to users table ( #11069 )
2023-12-08 21:59:53 +00:00
Jon Ayers
e73a202aed
feat: show dormant workspaces by default ( #11053 )
2023-12-07 18:09:35 -06:00
Jon Ayers
ce49a55f56
chore: update build_reason 'autolock' -> 'dormancy' ( #11074 )
2023-12-07 17:11:57 -06:00
Garrett Delfosse
228cbec99b
fix: stop updating agent stats from deleted workspaces ( #11026 )
...
Co-authored-by: Steven Masley <stevenmasley@gmail.com >
2023-12-07 13:55:29 -05:00