9df9ad4503
feat: embed common client requests into the template html ( #8076 )
...
This should reduce the number of API requests a client makes
when loading the dashboard dramatically!
2023-06-18 13:57:27 -05:00
0c5077464b
fix: avoid missed logs when streaming startup logs ( #8029 )
...
* feat(coderd,agent): send startup log eof at the end
* fix(coderd): fix edge case in startup log pubsub
* fix(coderd): ensure startup logs are closed on lifecycle state change (fallback)
* fix(codersdk): fix startup log channel shared memory bug
* fix(site): remove the EOF log line
2023-06-16 17:14:22 +03:00
6c4c3d6ce5
feat: add login type 'none' to prevent password login ( #8009 )
...
* feat: add login type 'none' to prevent login
Users with this login type must use tokens to authenticate.
Tokens must come from some other source, not a /login with password
authentication
2023-06-14 12:48:43 -05:00
e4b6f5695b
chore: separate pubsub into a new package ( #8017 )
...
* chore: rename store to dbmock for consistency
* chore: remove redundant dbtype package
This wasn't necessary and forked how we do DB types.
* chore: separate pubsub into a new package
This didn't need to be in database and was bloating it.
2023-06-14 15:34:54 +00:00
8c4b7c01e2
chore: remove redundant dbtype package ( #8014 )
...
* chore: rename store to dbmock for consistency
* chore: remove redundant dbtype package
This wasn't necessary and forked how we do DB types.
2023-06-13 19:14:55 +00:00
4f512fb230
chore: use gcr.io for postgres image in OpenContainerized
( #8015 )
...
Refs #7935
2023-06-13 22:03:33 +03:00
7d54fd5e0d
chore: rename store to dbmock for consistency ( #8013 )
2023-06-13 13:57:43 -05:00
a658c94a67
chore: automatically generate dbauthz when new queries are added ( #8007 )
...
* chore: automatically generate dbauthz when new queries are added
* Merge system functions
2023-06-13 13:40:46 -05:00
794a551176
chore: generate dbmetrics automatically when adding new queries ( #7999 )
...
* chore: rename dbgen package files and remove small file
* chore: automatically generate dbmetrics when new queries are added
2023-06-13 12:35:12 -05:00
9cf3c582cb
test: add unit test that deletes abandoned workspace ( #7990 )
...
* test: add unit test that deletes abandoned workspace
This is to ensure we do not break this functionality in future.
This is important incase this edge case happens, an admin can
clean up the abandoned resources.
2023-06-13 10:42:18 -05:00
9440b3da66
chore: rename dbgen package files and remove small file ( #7997 )
2023-06-13 09:21:12 -05:00
518300a26c
fix(coderd/database): improve pubsub closure and context cancellation ( #7993 )
2023-06-13 15:19:56 +03:00
28f35393e7
chore: generate and order dbfake funcs automatically ( #7986 )
...
* chore: rename `databasefake` to `dbfake`
* Remove unused method
* chore: add generation to dbfake
* Auto gen on make gen
* Fix preserving imports
* gen dbfake
* Add goimports
* Fix the makefile
* Make it panic instead of a comment
2023-06-12 17:40:58 -05:00
685abfc6d7
chore: rename databasefake
to dbfake
( #7979 )
...
* chore: rename `databasefake` to `dbfake`
* Remove unused method
2023-06-12 16:05:37 -05:00
c60ea38691
chore: use gcr.io for postgres image in CI ( #7935 )
2023-06-09 13:39:55 +00:00
fa8153a0fd
chore: make default workspace proxy editable ( #7903 )
...
* chore: add editing the default workspace proxy
2023-06-08 10:30:15 -05:00
94aa9be33a
feat(cli/ssh): implement wait options and deprecate no-wait ( #7894 )
...
Fixes #7768
Refs #7893
2023-06-08 16:52:44 +03:00
f6db95e71c
test(coderd/database/migrations): increase fixture test timeout
2023-06-07 23:17:29 +00:00
74ffd2756a
fix: respect uppercase letters in username filter for audit ( #7880 )
...
* fix: respect uppercase letters in username filter for audit
* updated documentation
2023-06-07 05:48:08 -07:00
ee45b3df77
fix: ignore case while sorting usernames ( #7870 )
2023-06-06 12:37:41 +02:00
660bbb8d38
refactor: deprecate login_before_ready
in favor of startup_script_behavior
( #7837 )
...
Fixes #7758
2023-06-06 11:58:07 +03:00
93378daeb3
feat: sort users by username ( #7838 )
2023-06-06 08:47:59 +02:00
fa8f50a169
fix: fix workspace status filter returning more statuses that requested ( #7732 )
2023-06-05 18:12:10 -05:00
e016c307ae
Fix postgres ephemeral ports; don't use for TestPubsub_Disconnect ( #7798 )
...
Signed-off-by: Spike Curtis <spike@coder.com >
2023-06-05 09:24:44 +04:00
a7366a8b76
feat!: drop support for legacy parameters ( #7663 )
2023-06-02 11:16:46 +02:00
cf8d2bc096
feat: use tz_offset when doing deployment dau query ( #7736 )
...
* Have FE query correct tz_offset data
2023-06-01 09:23:50 -04:00
784696dfa5
feat: add prometheus metrics to database.Store ( #7713 )
...
* Adds dbmetrics package and wraps database.Store with a Prometheus HistogramVec of timings.
* Adds Wrappers method to database.Store to avoid double-wrapping interfaces
* Fixes test flake in TestLicensesListFake
2023-05-31 14:55:57 +01:00
c795a0e500
feat: Fix Deployment DAUs to work with local timezones ( #7647 )
...
* chore: Add timezone param to DAU SQL query
* Merge DAUs response
* Pass time offsets to metricscache
2023-05-30 13:18:27 -04:00
702c9081e0
fix: do not skip parameter validation if min or max = 0 ( #7707 )
2023-05-30 14:57:06 +02:00
d9299caa12
feat: order workspaces by running first ( #7656 )
...
* wip
* use updated sql
* wip
* Implement sorting in databasefake.go
* More fixes
* sql fmt
---------
Co-authored-by: Marcin Tojek <marcin@coder.com >
2023-05-25 13:35:47 -03:00
05da1e94a2
Fix pubsub goroutines in tests ( #7677 )
...
Signed-off-by: Spike Curtis <spike@coder.com >
2023-05-25 14:46:32 +04:00
67cc196c92
feat: pubsub reports dropped messages ( #7660 )
...
* Implementation; need linux tests
Signed-off-by: Spike Curtis <spike@coder.com >
* Pubsub with errors tests and fixes
Signed-off-by: Spike Curtis <spike@coder.com >
* Deal with test goroutines
Signed-off-by: Spike Curtis <spike@coder.com >
---------
Signed-off-by: Spike Curtis <spike@coder.com >
2023-05-25 06:22:30 +00:00
cd416c86dd
refactor: workspace builds ( #7541 )
...
* refactor workspace builds
Signed-off-by: Spike Curtis <spike@coder.com >
* make gen
Signed-off-by: Spike Curtis <spike@coder.com >
* Remove ParameterResolver from typescript
Signed-off-by: Spike Curtis <spike@coder.com >
* rename conversion -> database/db2sdk
Signed-off-by: Spike Curtis <spike@coder.com >
* tests for db2sdk
Signed-off-by: Spike Curtis <spike@coder.com >
* Tests for ParameterResolver
Signed-off-by: Spike Curtis <spike@coder.com >
* wsbuilder tests
Signed-off-by: Spike Curtis <spike@coder.com >
* Move parameter validation tests to richparameters_test.go
Signed-off-by: Spike Curtis <spike@coder.com >
* Fix CI generation; rename mock->dbmock
Signed-off-by: Spike Curtis <spike@coder.com >
* Fix test imports
Signed-off-by: Spike Curtis <spike@coder.com >
---------
Signed-off-by: Spike Curtis <spike@coder.com >
2023-05-23 12:06:33 +04:00
ec5ef51b49
feat: add session token injection to provisioner ( #7461 )
2023-05-17 23:29:22 -05:00
00a2413c03
feat: add telemetry support for workspace agent subsystem ( #7579 )
2023-05-17 22:49:25 -05:00
70d2203b9e
chore: reduce the log output of skipped tests ( #7520 )
...
With the introduction of the workspace proxy tests there was a lot
of output if a test was eventually skipped.
2023-05-14 19:37:00 -05:00
26490aecca
chore: improve postgres test time by removing cleanup ( #7522 )
...
We don't need to delete databases on cleanup... and we don't need to
always run without a cache either!
2023-05-14 15:32:44 -05:00
b5ad628460
chore: Allow editing proxy fields via api. ( #7435 )
...
* chore: Add ability to update workspace proxy fields
2023-05-09 13:46:50 -05:00
8899dd89ca
chore: add global caching to rbac ( #7439 )
...
Co-authored-by: Steven Masley <stevenmasley@coder.com >
2023-05-08 08:59:01 -05:00
5ffa6dae50
feat: add inactivity cleanup and failure cleanup configuration fields to Template Schedule Form ( #7402 )
...
* added workspace actions entitlement
* added workspace actions experiment
* added new route for template enterprise meta
* removing new route; repurposing old
* add new fields to get endpoints
* removed workspace actions experiment
* added logic to enterprise template store
* added new form fields
* feature flagged new fields
* fix validation
* fixed submit btn
* fix tests
* changed ttl defaults
* added FE tests
* added BE tests
* fixed lint
* adjusted comment language
* fixing unstaged changes check
* fix test
* Update coderd/database/migrations/000122_add_template_cleanup_ttls.down.sql
Co-authored-by: Dean Sheather <dean@deansheather.com >
* Update coderd/database/migrations/000122_add_template_cleanup_ttls.up.sql
Co-authored-by: Dean Sheather <dean@deansheather.com >
---------
Co-authored-by: Dean Sheather <dean@deansheather.com >
2023-05-05 08:19:26 -07:00
a6a44896bf
fix: pubsub ordering ( #7404 )
...
* fix: pubsub sends messages in order
Signed-off-by: Spike Curtis <spike@coder.com >
* Drop messages rather than block
Signed-off-by: Spike Curtis <spike@coder.com >
---------
Signed-off-by: Spike Curtis <spike@coder.com >
2023-05-05 09:39:07 +04:00
8bd9f9c351
feat: unified tracing between coderd<->provisionerd ( #7370 )
2023-05-03 23:02:35 +00:00
3368b8b65f
chore: Minor rbac memory optimization ( #7391 )
...
* test: Add benchmark for static rbac roles
* static roles should only be allocated once
* A unit test that modifies the ast value should not mess with the globals
* Cache subject AST values to avoid reallocating slices
2023-05-03 14:42:24 -05:00
8fc8559076
fix(coderd): ensure that user API keys are deleted when a user is ( #7270 )
...
Fixes an issue where API tokens belonging to a deleted user were
not invalidated:
- Adds a trigger to delete rows from the api_key stable when the
column deleted is set to true in the users table.
- Adds a trigger to the api_keys table to ensure that new rows
may not be added where user_id corresponds to a deleted user.
- Adds a migration to delete all API keys from deleted users.
- Adds tests + dbfake implementation for the above.
2023-04-24 21:48:26 +01:00
4353ad7940
chore: Remove url and wildcard url from moon create ( #7224 )
...
* chore: Remove url and wildcard url from moon create
2023-04-20 21:09:14 -05:00
68667323f3
chore: support signed token query param for web terminal ( #7197 )
...
* chore: add endpoint to get token for web terminal
* chore: support signed token query param for web terminal
2023-04-20 23:59:45 +00:00
7fa1112958
chore: Enforce workspace proxy unique name case insensitive ( #7202 )
...
* chore: Enforce workspace proxy unique name case insensitive
2023-04-20 11:30:52 -05:00
a5a5c4d400
chore: Add workspace proxy enterprise cli commands ( #7176 )
...
* feat: Add workspace proxy enterprise cli commands
* chore: Handle custom workspace proxy options. Remove excess
* chore: Add endpoint to register workspace proxies
2023-04-20 09:48:47 -05:00
528a0686c0
chore: fix deadlock in dbfake and incorrect lock types ( #7218 )
...
I manually went through every single dbfake function and ensured it has
the correct lock type depending on whether it writes or only reads.
There were a surprising amount of methods that had the wrong lock type
(Lock when only reading, or RLock when writing (!!!)).
This also manually fixes every method that acquires a RLock and then
calls a method that also acquires it's own RLock to use noLock methods
instead. You cannot rely on acquiring a RLock twice in the same
goroutine as RWMutex prioritizes any waiting Lock calls.
I tried writing a ruleguard rule for this but because of limitations in
ruleguard it doesn't seem possible.
2023-04-20 21:53:34 +10:00
658246d5f2
chore: add workspace proxies to the backend ( #7032 )
...
Co-authored-by: Dean Sheather <dean@deansheather.com >
2023-04-17 19:57:21 +00:00