Commit Graph

3112 Commits

Author SHA1 Message Date
dependabot[bot] 3980f15340
chore: bump crate-ci/typos from 1.13.3 to 1.13.9 (#5906)
Bumps [crate-ci/typos](https://github.com/crate-ci/typos) from 1.13.3 to 1.13.9.
- [Release notes](https://github.com/crate-ci/typos/releases)
- [Changelog](https://github.com/crate-ci/typos/blob/master/CHANGELOG.md)
- [Commits](https://github.com/crate-ci/typos/compare/v1.13.3...v1.13.9)

---
updated-dependencies:
- dependency-name: crate-ci/typos
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-01-30 01:56:34 +00:00
Ammar Bandukwala 4eaa2d63b0
chore(.github): relax stale bot (#5902)
At 60 days it was more spammy than helpful.
2023-01-29 19:52:44 -06:00
Kyle Carberry 12314d7dc5
update readme (#5911) 2023-01-29 19:45:00 -06:00
Kyle Carberry b423218615 chore: remove markdown-lint-check
It's broken for some unfortunate reason!
2023-01-29 23:34:52 +00:00
Kyle Carberry b4a1c32ed3 chore: run markdown-link-check before linting types 2023-01-29 23:29:57 +00:00
Kyle Carberry 0d08065488
fix: use a waitgroup to ensure all connections are cleaned up in agent (#5910)
* fix: use a waitgroup to ensure all connections are cleaned up in agent

There was a race where connections would be created at the same time as close.
The `net.Conn` produced by Tailscale doesn't close then the listener does.

* Remove accidental test
2023-01-29 17:20:30 -06:00
Kyle Carberry ce36a84dd5 fix: specify folder path for markdown-lint-check
This was checking node_modules I believe causing it to hang.
2023-01-29 22:36:47 +00:00
Kyle Carberry a911ddaa7b
fix: access GetUserByID in database fake without lock to resolve race (#5909)
See: https://github.com/coder/coder/actions/runs/4038615993/jobs/6942750837
2023-01-29 16:03:29 -06:00
Kyle Carberry 7ad87505c8
chore: move agent functions from `codersdk` into `agentsdk` (#5903)
* chore: rename `AgentConn` to `WorkspaceAgentConn`

The codersdk was becoming bloated with consts for the workspace
agent that made no sense to a reader. `Tailnet*` is an example
of these consts.

* chore: remove `Get` prefix from *Client functions

* chore: remove `BypassRatelimits` option in `codersdk.Client`

It feels wrong to have this as a direct option because it's so infrequently
needed by API callers. It's better to directly modify headers in the two
places that we actually use it.

* Merge `appearance.go` and `buildinfo.go` into `deployment.go`

* Merge `experiments.go` and `features.go` into `deployment.go`

* Fix `make gen` referencing old type names

* Merge `error.go` into `client.go`

`codersdk.Response` lived in `error.go`, which is wrong.

* chore: refactor workspace agent functions into agentsdk

It was odd conflating the codersdk that clients should use
with functions that only the agent should use. This separates
them into two SDKs that are closely coupled, but separate.

* Merge `insights.go` into `deployment.go`

* Merge `organizationmember.go` into `organizations.go`

* Merge `quota.go` into `workspaces.go`

* Rename `sse.go` to `serversentevents.go`

* Rename `codersdk.WorkspaceAppHostResponse` to `codersdk.AppHostResponse`

* Format `.vscode/settings.json`

* Fix outdated naming in `api.ts`

* Fix app host response

* Fix unsupported type

* Fix imported type
2023-01-29 15:47:24 -06:00
Kyle Carberry e49f41652f
chore: merge codeql checks to run in parallel (#5907)
* chore: merge codeql checks to run in parallel

This reduces a check and should maintain ~the same CI time.

* fix: close reconnecting pty conn when exiting agent

Fixes https://github.com/coder/coder/actions/runs/4038282899/jobs/6942170850

* Fix closing when agent fails

* Fix conpty

* Fix contrib

* Skip runner tests for being flakes

* Fix gpg key test

* Fix golden files

* Fix comments

* Fix closed

* Fix capitalized title

* Add a timeout when checking for dead links
2023-01-29 15:28:22 -06:00
Kyle Carberry 8487127f5c
chore: skip reconnecting pty scale tests (#5908)
* fix: close reconnecting pty conn when exiting agent

Fixes https://github.com/coder/coder/actions/runs/4038282899/jobs/6942170850

* Fix conpty

* Fix contrib

* Skip runner tests for being flakes

* Fix gpg key test

* Fix golden files

* Fix comments
2023-01-29 14:53:49 -06:00
Kyle Carberry 33c6260efb
chore: merge CI linting jobs (#5904)
* chore: merge CI linting jobs

* Merge the `markdown-lint-check` step into `lint`

* Rename `coder.yaml` to `ci.yaml`

* Improve casing of security workflow

* Remove unused workflows and merge into contrib

* Format ci.yaml

* Fix CodeQL language

* Fix github action name
2023-01-29 13:16:48 -06:00
Kyle Carberry eaf1b95e70
chore: disable auto generated tag for CLI docs (#5905)
This was causing `make gen` to fail as the days went on!
2023-01-29 12:58:12 -06:00
sharkymark 2312bc4a6e
docs: added alpha jetbrains gateway coder plugin | remove code-server version parameter (#5900) 2023-01-28 19:09:41 -06:00
Kyle Carberry 7880b941b8
docs: remove quote from README 2023-01-27 21:24:54 -06:00
Mathias Fredriksson a1212014df
chore(examples): Add `login_before_ready` and `startup_script_timeout` (#5880) 2023-01-27 21:01:48 +00:00
Mathias Fredriksson 90c4d5d28a
docs: Document agent readiness issues (startup script) (#5877)
Refs: #5749, #5851
2023-01-27 22:23:47 +02:00
Mathias Fredriksson 981cac5e28
chore: Invert `delay_login_until_ready`, now `login_before_ready` (#5893) 2023-01-27 20:07:47 +00:00
Kira Pilot 8a5760a2fe
chore: replace AuditableGroup label in docs (#5894) 2023-01-27 13:36:00 -05:00
Bruno Quaresma e0d48e7d79
docs: Add CLI docs (#5879) 2023-01-27 18:10:40 +00:00
Mathias Fredriksson a753703e47
feat(cli): Add support for `delay_login_until_ready` (#5851) 2023-01-27 19:05:40 +02:00
Kira Pilot cf93fbd39a
chore: update Audit docs to include Audit Actions (#5887)
* chore: update Audit docs to include Audit Actions

* regenerated audit docs

* adjusted check_enterprise_imports.sh

* PR feedback

* changing script back for now as CI faiiling
2023-01-27 11:50:21 -05:00
Kyle Carberry b20cb993bd
fix: loop variable captured by func literal in parameters test (#5878)
I noticed this when adding a new parameter type. There's a test
case for an empty string that returned false for validation,
but appears like it could be true.

If there is no value for a string, then the default is used.
In this case there is no default, but that's technically fine
I believe.
2023-01-27 09:37:55 -06:00
Kira Pilot e663eaad96
chore: remove flaking e2e test (#5884) 2023-01-26 23:10:01 -03:00
Kira Pilot 3d58e6912a
chore: removing unaudited resources (#5885)
* chore: removing unaudited resources

* cleaned up tests

* CI errors
2023-01-26 18:14:09 -05:00
Kira Pilot e2bea2d20f
chore: autogenerate audit log documentation (#5862)
* added script for table creation

* added tags to audit-logs.md

* removed log

* removed empty block line

* PR feedback

* modify check_unstaged

* third times the charm maybe

* spelling

* relative path

* excluding from the right script this time

* sorted resources to ensure table order

* running make cmd

* running make again

* ensuring order on subtable
2023-01-26 18:12:12 -05:00
Colin Adler cc694a55bc
feat: add debug info to HA coordinator (#5883) 2023-01-26 16:32:38 -06:00
Colin Adler 52ecd35c8f
fix(wsconncache): only allow one peer per connection (#5886)
If an agent went away and reconnected, the wsconncache connection would
be polluted for about 10m because there would be two peers with the
same IP. The old peer always had priority, which caused the dashboard to
try and always dial the old peer until it was removed.

Fixes: https://github.com/coder/coder/issues/5292
2023-01-26 22:23:35 +00:00
Steven Masley b0a16150a3
chore: Implement standard rbac.Subject to be reused everywhere (#5881)
* chore: Implement standard rbac.Subject to be reused everywhere

An rbac subject is created in multiple spots because of the way we
expand roles, scopes, etc. This difference in use creates a list
of arguments which is unwieldy.

Use of the expander interface lets us conform to a single subject
in every case
2023-01-26 14:42:54 -06:00
ElliotG 5c54d8b8cd
docs: create a SECURITY.md file (#5875) 2023-01-26 14:13:36 -06:00
Mathias Fredriksson 496beae807
Revert "feat(dogfood): install nix package manager (#5308)" (#5871) 2023-01-26 15:41:59 +00:00
Geoffrey Huntley bfc8a1094b
feat(dogfood): install nix package manager (#5308)
Co-authored-by: Dean Sheather <dean@deansheather.com>
Co-authored-by: Mathias Fredriksson <mafredri@gmail.com>
Co-authored-by: Kyle Carberry <kyle@carberry.com>
2023-01-26 16:39:30 +02:00
Bruno Quaresma 721957dee3
chore(site): Ignore progress build bar on Chromatic (#5869) 2023-01-26 10:45:59 -03:00
Josh Goldberg 43a441fe63
chore(site): align ESLint config to typescript-eslint's recommended-requiring-type-checking (#5797) 2023-01-26 10:32:50 -03:00
Colin Adler dd8eab5675
fix: cache disconnected agent names in tailnet coordinator debug (#5870) 2023-01-25 21:23:14 -06:00
Presley Pizzo 16d8cc4176
feat(site): Add deployment-wide DAU chart (#5810) 2023-01-25 22:03:47 -03:00
Bruno Quaresma e7b8318b87
refactor(site): Normalize avatar components (#5860) 2023-01-26 00:54:53 +00:00
Colin Adler 233492b75d
fix: ensure coordinator debug output is always sorted (#5867) 2023-01-26 00:29:51 +00:00
Ammar Bandukwala 5da4b5358a
docs: use and in enterprise feature matrix (#5866)
The grey X was ambiguous.
2023-01-25 22:58:53 +00:00
Eric Paulsen 98011570be
fix: agent log location (#5742) 2023-01-25 17:45:50 -05:00
Cian Johnston 8735f51047
feat(coder): add authz_querier experiment (#5858)
* feat(coderd): add authz_querier experiment

* coderdtest: wire up authz_querier

* wire up AuthzQuerier in coderd

* remove things that do not yet exist in this timeline

* add newline

* comment unreachable code
2023-01-25 21:35:53 +00:00
Colin Adler 1cd5f38cb0
feat: add debug server for tailnet coordinators (#5861)
Implements a Tailscale-like debug server for our in-memory coordinator. This should provide some visibility into why connections could be failing.
Resolves: https://github.com/coder/coder/issues/5845

![image](https://user-images.githubusercontent.com/6332295/214680832-2724d633-2d54-44d6-a7ce-5841e5824ee5.png)
2023-01-25 21:27:36 +00:00
Kyle Carberry 8830ddfd56
docs: update the readme to reduce unnecessary text (#5837)
The README was starting to get quite large, and I felt it was a bit bloaty.

- Removes Twitter badge (the API was removed, so it wasn't working anyways)
- Adds tagline to the title (an experiment, but worth a shot)
- Reduces highlights
- Removes recommended reading (people want to get started asap on a repo)
- Updates doc links `/docs/coder-oss` -> `/docs/v2`
- Moves comparison to the bottom
- Removes adopters.md (we never promoted this, so it hasn't been used)
2023-01-25 14:49:15 -06:00
Steven Masley 08412fd1af
chore: Remove unused SQL functions (#5857)
* chore: Remove unused sql functions
- GetProvisionerDaemonByID
- UpdateProvisionerDaemonByID
- GetUserGroups
- GetWorkspaceCountByUserID
- GetLatestAgentStat
2023-01-25 11:30:12 -06:00
Steven Masley b678309fc9
chore: Authz should support non-named roles (#5855)
* chore: Authz should support non-named roles

Named roles are a construct for users to assign/interact with roles.
For authzlayer implementation, we need to create "system" users.
To enforce strict security, we are making specific roles with
the exact required permissions for the system action.
These new roles should not be available to the user. There is a
clear code divide with this implementation that allows a RoleNames
implemenation for users to user, and system users can create their
own implementation
2023-01-25 10:54:16 -06:00
Bruno Quaresma de66f0d540
docs: Add frontend guide (#5852) 2023-01-25 16:15:06 +00:00
Mathias Fredriksson 5c5ddc6b23
fix(site): Hide agent lifecycle unless opted in via `delay_login_until_ready` (#5850)
Refs: #5835, #5749
2023-01-25 15:23:31 +02:00
Mathias Fredriksson 78ede50be8
ci: Add authors to release notes (#5834) 2023-01-25 11:13:42 +02:00
Kira Pilot 322a4d93e1
feat: add audit log filter for autostarted and autostopped workspace builds (#5830)
* added query

* fixed query

* added example to dropdown

* added documentation

* added test

* fixed formatting

* fixed format
2023-01-24 15:34:29 -05:00
Bruno Quaresma 36384aa3c1
chore(site): Use react-query and refactor the workspaces page to use it (#5838) 2023-01-24 16:22:42 -03:00