Commit Graph

819 Commits

Author SHA1 Message Date
69ec8d774b fix(cli/server): apply log filter to log message as well as name (#9232) 2023-08-21 17:53:26 -05:00
6d939b726c fix: correctly assess quota for stopped resources (#9201) 2023-08-21 09:01:16 -05:00
6b8102cf4c feat(cli): add daily_cost to coder ls (#9200) 2023-08-19 12:56:08 -05:00
22e781eced chore: add /v2 to import module path (#9072)
* chore: add /v2 to import module path

go mod requires semantic versioning with versions greater than 1.x

This was a mechanical update by running:
```
go install github.com/marwan-at-work/mod/cmd/mod@latest
mod upgrade
```

Migrate generated files to import /v2

* Fix gen
2023-08-18 18:55:43 +00:00
95458ac8a5 chore(scripts/develop.sh): restore original access url setting (#9174) 2023-08-18 13:24:17 +00:00
669ae9d4d3 fix(cli): remove prompt for immutable parameters on start and restart (#9173) 2023-08-18 14:06:46 +02:00
be40dc85ab chore: cleanup extraneous logging (#9156)
* The batchstats warning went out on every Ctrl+C in my development

Rule of silence:

The provisioner and connect messages messages were sent out on every startup
without a corresponding user event, making them annoying and more-so
debug messages.
2023-08-17 21:01:55 +00:00
25ce30df36 feat: add azure oidc PKI auth instead of client secret (#9054)
* feat: add azure oidc PKI auth instead of client secret
* add client cert and key as deployment options
* Custom token refresher to handle pki auth
2023-08-14 17:33:13 -05:00
37f9d4b783 feat: add --header-command flag (#9059)
This allows specifying a command to run that can output headers for
cases where users require dynamic headers (like to authenticate to their
VPN).

The primary use case is to add this flag in SSH configs created by the
VS Code plugin, although maybe config-ssh should do the same.
2023-08-14 12:12:17 -08:00
0d01d022f7 fix: remove unnecessary newlines from the end of cli output (#9068)
`Infof` already adds a newline, so we don't need to as well!
2023-08-13 11:48:11 -05:00
40f3fc3a1c feat: allow creating manual oidc/github based users (#9000)
* feat: allow creating manual oidc/github based users
* Add unit test for oidc and no login type create
2023-08-10 20:04:35 -05:00
d2f22b063a fix: move STUN servers into their own regions (#9030) 2023-08-11 05:04:17 +10:00
9d9814c6b0 refactor(cli): adjust parameter resolver (#9019) 2023-08-10 12:08:00 +02:00
370bdd6a03 fix(cli): only init clistat.Client when calling coder stat (#9013) 2023-08-09 19:17:57 -05:00
bc862fa493 chore: upgrade tailscale to v1.46.1 (#8913) 2023-08-09 19:50:26 +00:00
612f1c6a55 chore: use echo provisioners in logging tests (#9008) 2023-08-09 19:03:02 +00:00
0d382d1e05 feat(cli): provide parameter values via command line (#8898) 2023-08-09 13:00:25 +02:00
07fd73c4a0 chore: allow multiple agent subsystems, add exectrace (#8933) 2023-08-08 22:10:28 -07:00
f4122fa9f5 feat: add auto group create from OIDC (#8884)
* add flag for auto create groups
* fixup! add flag for auto create groups
* sync missing groups
Also added a regex filter to filter out groups that are not
important
2023-08-08 11:37:49 -05:00
b2a84462ab chore: fix ruleguard xerrors rules (#8967) 2023-08-08 12:32:41 +00:00
694729b4f7 chore: disable goleak in windows cli tests (#8955) 2023-08-07 22:23:00 -05:00
82e0e2e43c fix(cli): clistat: accept positional arg for stat disk cmd (#8911) 2023-08-07 16:26:16 +01:00
81752d1b84 fix(cli/delete): prompt for confirmation after workspace is found (#8579) 2023-08-05 11:25:37 -05:00
9fb18f3ae5 feat(coderd): batch agent stats inserts (#8875)
This PR adds support for batching inserts to the workspace_agents_stats table.
Up to 1024 stats are batched, and flushed every second in a batch.
2023-08-04 17:00:42 +01:00
ae88b79fd7 fix(cli): stat: set --host arg in TestStatCPUCmd to avoid test flakes in containers (#8806) 2023-08-04 15:15:33 +00:00
607cd11724 fix(cli): address race condition in scaletest_test output (#8902) 2023-08-04 15:06:28 +00:00
cb4989cd8d feat: add PSK for external provisionerd auth (#8877)
Signed-off-by: Spike Curtis <spike@coder.com>
2023-08-04 12:32:28 +04:00
6ea32e4e80 fix: show current DERP name correctly in vscode (#8856) 2023-08-03 01:30:43 +10:00
d6e9870209 feat: add "dormant" user state (#8644) 2023-08-02 16:31:25 +02:00
bd944e0d21 chore: rename startup logs to agent logs (#8649)
* chore: rename startup logs to agent logs

This also adds a `source` property to every agent log. It
should allow us to group logs and display them nicer in
the UI as they stream in.

* Fix migration order

* Fix naming

* Rename the frontend

* Fix tests

* Fix down migration

* Match enums for workspace agent logs

* Fix inserting log source

* Fix migration order

* Fix logs tests

* Fix psql insert
2023-07-28 15:57:23 +00:00
edd9628aa6 fix(cli): correctly print deprecated warnings (#8771)
In the previous implementation, it was possible for default-set values
to trigger the deprecation warning.
2023-07-27 16:42:18 +00:00
32829080ac feat(cli): add dashboard load test command (#8723) 2023-07-27 09:40:13 +01:00
c3aface285 fix: fix coder stat mem (#8762)
- For cgroups v1 the wrong cgroup file was being read
  to determine max memory. This commit updates the file
  from '/sys/fs/cgroup/memory/memory.max_usage_in_bytes' to
  '/sys/fs/cgroup/memory/memory.limit_in_bytes'
2023-07-27 09:33:43 +01:00
5cfa7082d1 chore: attempt to fix windows goleak failures (#8753) 2023-07-26 18:50:13 -05:00
02550a9062 fix(cli): apply log-filter to debug logs only (#8751) 2023-07-26 22:31:41 +00:00
25e30c6f41 feat(cli): support fine-grained server log filtering (#8748) 2023-07-26 16:46:22 -05:00
2f0a9996e7 chore: add derpserver to wsproxy, add proxies to derpmap (#7311) 2023-07-27 02:21:04 +10:00
2a01747804 feat(cli): add --var shorthand for --variable (#8710)
`--variable` is used frequently enough to deserve a shorthand. Unfortunately,
`-v` is taken by verbose, and `-V` is too easily confused with version or
verbose, so we're left with "--var".
2023-07-25 14:36:02 +00:00
30e16052d6 fix(coderd): update icon url to the right one (#8718) 2023-07-25 14:06:58 +00:00
f6f61dfa26 docs: fix duplicate sentence (#8712)
Resolves #8664
2023-07-25 02:22:41 +00:00
f827829afe feat: synchronize oidc user roles (#8595)
* feat: oidc user role sync
User roles come from oidc claims. Prevent manual user role changes
if set.
* allow mapping 1:many
2023-07-24 08:34:24 -04:00
65583eca47 feat(cli): check if dotfiles install script is executable (#8588)
* feat(cli): check if dotfiles install script is executable

* feat(docs): add section for dotfiles setup and document executable fix

---------

Co-authored-by: Mathias Fredriksson <mafredri@gmail.com>
Co-authored-by: Muhammad Atif Ali <matifali@live.com>
2023-07-21 18:39:50 +00:00
fd372f6735 fix(cli/clistat): improve detection of container environment (#8643)
Use the presence of /var/run/secrets/kubernetes.io/serviceaccount/token to determine if we are in a container in addition to sniffing /proc/1/cgroup
2023-07-21 10:18:56 +00:00
2901147ae3 test: fix race in templateedit_test.go (#8641) 2023-07-21 03:26:55 +00:00
dc8b73168e feat: add user quiet hours schedule and restart requirement feature flag (#8115) 2023-07-20 23:35:41 +10:00
9689bca5d2 feat(cli): implement ssh remote forward (#8515) 2023-07-20 12:05:39 +02:00
0965a2de70 fix(cli/clistat): read from alternate cgroup path (#8591)
* Attempts reading cgroupv1 quota, period, usage from /sys/fs/cgroup/cpu,cpuacct by default
* Fall back to /sys/fs/cgroup/cpu for v1 quota and period
* Fall back to /sys/fs/cgroup/cpuacct for v1 usage

Fixes https://github.com/coder/coder/issues/8468
2023-07-19 16:25:26 +01:00
4232a2eb96 feat: add custom docs URL to deployment config (#8590) 2023-07-19 08:31:17 -03:00
98164f687e fix!: remove startup logs eof for streaming (#8528)
* fix: remove startup logs eof for streaming

We have external utilities like logstream-kube that may send
logs after an agent shuts down unexpectedly to report additional
information. In a recent change we stopped accepting these logs,
which broke these utilities.

In the future we'll rename startup logs to agent logs or something
more generalized so this is less confusing in the future.

* fix(cli/cliui): handle never ending startup log stream in Agent

---------

Co-authored-by: Mathias Fredriksson <mafredri@gmail.com>
2023-07-18 09:57:29 -06:00
278527cff4 feat(scaletest): add option to send traffic over SSH (#8521)
- Refactors the metrics logic to avoid needing to pass in a whole prometheus registry
- Adds an --ssh option to the workspace-traffic command to send SSH traffic

Fixes #8242
2023-07-18 12:17:11 +01:00