Commit Graph

850 Commits

Author SHA1 Message Date
a8a8f9dbf3 chore: skip some flaky tests (#1643)
* chore: skip some flaky tests

* Update peer/conn_test.go

* add makefile targets, reduce parallelism in go test
2022-05-21 00:39:51 +01:00
4f75291446 feat: form for editing ws schedule (#1634)
* feat: ui for editing ws schedule

Summary:

This presents a form component and storybook. The UI will be a routed
page and added into the dashboard in a separate PR. It is likely a
XService will be used at the page level to supply errors and actions to
this form.

Impact of Change:

Further progress on #1455

Squashed Commits:

* refactor: add className prop to Stack

combine classes with internal classes and an optional external className
to better control the Stack.

* fix: getFormHelpers helperText

the helperText logic was incorrect, the helperText would only show if not touched.
2022-05-20 20:26:43 +00:00
b29a2dfdde refactor: Minor design adjustments (#1637) 2022-05-20 19:37:03 +00:00
3653fcf256 fix: remove outdated doc paths in goreleaser (#1633)
It appears we were manually moving the `README.md`. This should have been updated in https://github.com/coder/coder/pull/1630 but slipped through CI
2022-05-20 19:02:38 +00:00
e40c68399d feat: resources card (#1627)
* Set up table

* Format

* Hook up api and test - bug assigning resources

* Remove debugging code

* Format

* Remove unnecessary cards

* Fix test

* Fix assignment

* Fix tests

* Lint
2022-05-20 18:29:42 +00:00
c189fc52c1 fix: using a trailing slash on login url (#1622) 2022-05-20 12:42:01 -05:00
ce7bf0b847 feat: Redesign the workspace page (#1620) 2022-05-20 17:05:00 +00:00
0622603220 docs: move README to root (#1630)
We noticed that when you download the repo as a ZIP from GitHub, it
places the `README.md` in the root, which causes the relative links to
break.

By moving it to the root, this will fix that issue.
2022-05-20 09:56:50 -07:00
ad946c3902 feat: Add confirm prompts to some cli actions (#1591)
* feat: Add confirm prompts to some cli actions
- Add optional -y skip. Standardize -y flag across commands
2022-05-20 15:59:04 +00:00
4f70f84635 feat: WorkspaceSection action, styles (#1623)
This PR is a squash of refactors and improvements in our Workspace and
WorkspaceSection components. An action prop is added to WorkspaceSection
and along the way, I refactored things that were not meeting conventions
or were hard to read. With this addition, I am further unblocked in
making auto-start/off editable in the UI, as I intend to use the Action
prop to trigger a modal (or routed page view) with the form.

Squashed commits:

* refactor: spaces for readability
It's hard to read HTMl markup without spaces on adjacent nodes

* refactor: props
Our components had unused props and arbitrary ordering.
2022-05-20 11:55:39 -04:00
0effb71f43 feat: add tracing for sql (#1610) 2022-05-20 10:51:06 -05:00
7c3e1a5d97 feat: Read params from file for template/workspace creation (#1541)
* Read params from file for template/workspace creation

* Use os.ReadFile

* Refactor reading params into a separate module

* Add comments and unit tests

* Rename variable

* Uncomment and fix unit test

* Fix comment

* Refactor tests

* Fix unit tests for windows

* Fix unit tests for Windows

* Add comments for the hotfix
2022-05-20 11:29:10 -04:00
d0fd0d7040 feat: added error boundary (#1602)
* added error boundary and error ui components

* add body txt and standardize btn size

* added story

* feat: added error boundary

closes #1013

* committing lockfile

* added email body to help link
2022-05-20 10:48:39 -04:00
52230fab56 feat: make default autobuild poll intervals configurable (#1618)
* feat: make default poll intervals for autobuild and ssh ttl polling configurable
2022-05-20 10:57:02 +00:00
992b58389b fix: Use the cobra CommandPath for usage to avoid duplication (#1617) 2022-05-20 12:42:56 +03:00
adb7d20c16 feat: skip terraform destroy if there is no state when deleting (#1594) 2022-05-20 14:07:23 +10:00
a03615a01f feature: disable provisionerd listen endpoint (#1614)
* feature: disable provisionerd listen endpoint

Signed-off-by: Spike Curtis <spike@coder.com>

* Regenerate ts types

Signed-off-by: Spike Curtis <spike@coder.com>
2022-05-19 23:52:17 +00:00
d1817310a1 fix build and lint (#1613)
Signed-off-by: Spike Curtis <spike@coder.com>
2022-05-19 23:28:29 +00:00
1871b09697 feat: in-process provisionerd connection (#1568)
* in-process provisionerd connection

Signed-off-by: Spike Curtis <spike@coder.com>

* disable lint for server.go/newProvisionerDaemon

Signed-off-by: Spike Curtis <spike@coder.com>
2022-05-19 17:47:45 -05:00
376c6819e0 feat: Move from datadog to generic otel (#1567) 2022-05-19 17:43:07 -05:00
2a85d3d083 chore: unconditionally run all make cmds in CI (#1608) 2022-05-19 17:42:49 -05:00
077f16ce2c feat: add coder logout command (#1609) 2022-05-19 22:42:32 +00:00
0c4a65b113 fix: manually fix coderd/database/dump.sql and make style/gen check run more reliably (#1607) 2022-05-19 22:37:22 +00:00
6dae48a1a8 fix: show --help message for CLI errors, add tests for delete (#1403)
* feat(cli): add test for delete

This adds a new test for the `delete` command to ensure it works as
expected when provided the correct args.

* fix(cli): use ExecuteC() to match Cobra

This modifies the `cli.Root().Execute()` to `cli.Root).ExecuteC()` to
match the default behavior of Cobra. We do this so errors will always
print the "run --help" line.

* feat(cli): add WithoutParameters test for delete

This adds a new test to the `delete_test.go` suite to ensure the correct
behavior occurs when `delete` is called without an argument.

* fixup! feat(cli): add WithoutParameters test for delete

* refactor(cli): show --help error message on main

This adds an error message which shows when there is an error with any
commands called to improve the UX.

* fixup! refactor(cli): show --help error message on main

* refactor(cli): handle err with FormatCobraError

This adds a new helper function called `FormatCobraError` to `root.go`
so that we can colorize and add "--help" message to cobra command errors
like calling `delete`.

* refactor(cli): add root_test.go, move delete test
2022-05-19 22:35:59 +00:00
a64ab6538e chore: update CODEOWNERS (#1600)
Resolves: #1559
2022-05-19 16:26:39 -05:00
0ffcc47f32 fix: Fix log order in the workspace build page (#1604) 2022-05-19 21:19:28 +00:00
3be356095f feat: Add create workspace page (#1589) 2022-05-19 20:51:10 +00:00
4afc66faf5 chore: remove docker host from docker-compose (#1596) 2022-05-19 20:38:07 +00:00
0b1a35f7b8 feat: Add workspace build logs page (#1598) 2022-05-19 15:34:42 -05:00
d72c45e483 refactor: workspace autostop_schedule -> ttl (#1578)
Co-authored-by: G r e y <grey@coder.com>
2022-05-19 15:09:27 -04:00
6c1117094d chore: Force codersdk to not import anything from database (#1576)
* chore: Force codersdk to not import anything from database (linter rule)
* chore: Move all database types in codersdk out
2022-05-19 13:04:44 -05:00
a0834404f7 chore: rm dead code; add check:all (#1595) 2022-05-19 12:40:40 -05:00
c47b6f0381 chore: use docker host in docker-compose (#1592) 2022-05-19 11:49:22 -05:00
67333b6186 feat: getWorkspaces filter site api (#1564) 2022-05-19 12:08:55 -04:00
LG
0438430c7c fix: missing spacing added; typo fix (#1586)
Co-authored-by: Ben <ben@coder.com>
2022-05-19 15:51:49 +00:00
e0165c5d89 fix: static data in mocks (#1574) 2022-05-19 11:36:14 -04:00
3f770e1111 fix: User permissions on UI (#1570) 2022-05-19 15:10:18 +00:00
4eb0bb6afd feat: don't return 200 for deleted workspaces (#1556) 2022-05-20 00:29:10 +10:00
eb8f371f34 chore: add container image to footer of releases (#1579)
* chore: add docker pull to footer
2022-05-19 13:38:05 +00:00
38ee519f42 feat: Expose the values contained in an HCL validation string to the API (#1587)
* feat: Expose the values contained in an HCL validation string to the API

This allows the frontend to render inputs displaying these values!

* Update codersdk/parameters.go

Co-authored-by: Cian Johnston <cian@coder.com>

* Call a spade a space

* Fix linting errors with type conversion

Co-authored-by: Cian Johnston <cian@coder.com>
2022-05-19 13:29:36 +00:00
ad9bdb7bd1 fix: More robust provisionersdk agent init scripts (#1551)
Related #1544

Co-authored-by: Dean Sheather <dean@deansheather.com>
2022-05-19 13:02:42 +00:00
6f969214d3 chore: validate docs (#1485) 2022-05-19 08:01:19 -05:00
cabc164f74 feat: use and display default template values when creating wkspc. (#1584) 2022-05-19 22:49:40 +10:00
8814cb0722 Revert "fix: Use Terraform address to index resource + agent association (#1577)" (#1585)
This reverts commit f3fe2a08ce.
2022-05-19 12:18:40 +01:00
c034e8389e feat: Add RBAC to /workspace endpoints (#1566)
* feat: Add RBAC to /workspace endpoints
2022-05-18 18:15:19 -05:00
f3fe2a08ce fix: Use Terraform address to index resource + agent association (#1577)
This fixes resources created from Terraform modules not
properly being associated with an agent.

By not using the address, and resource identifiers prefixed
with `module.<name>` would be missed!
2022-05-18 16:26:08 -05:00
0706c60445 chore: Add watch workspace endpoint (#1493) 2022-05-18 16:16:26 -05:00
b8ee939e52 chore: change Slack to Discord link (#1573) 2022-05-18 21:14:31 +00:00
37cf3bb491 example: add docker-image-builds + docker docs (#1526)
Co-authored-by: Katie Horne <katie@23spoons.com>
2022-05-18 16:03:20 -05:00
97699e9704 fix: Rename NewMemoryCoderd to NewWithServer (#1571)
This name felt invalid, because `New` was also in memory.
2022-05-18 15:49:46 -05:00