Commit Graph

249 Commits

Author SHA1 Message Date
1033e02d79 feat: add coder server postgres-builtin-serve to run the built-in DB (#2997) 2022-07-14 21:51:44 +00:00
b5f5e909bd Return template parameters in consistent order (#2975)
* return parameters from Terraform provisioner in sorted order

* persist parameter indices in database and return them in correct order from API

* don't re-sort parameters by name when creating templates
2022-07-13 15:29:34 -05:00
8b76e40629 fix: Fetch GitHub teams by name for performance (#2955)
In large organizations with thousands of teams, looping took >5s.
This fetches organizations by team name, which should be very fast!
2022-07-13 00:45:43 +00:00
5ee112bc00 fix: Fetch all GitHub teams on login (#2951)
This wasn't looping prior, so organizations with >100 teams
couldn't login. Contributes to #2848.
2022-07-12 23:06:27 +00:00
59facdd8dc fix: Show schedule commands in help, improve template (#2923)
* fix: Show schedule commands in help, improve template

* chore: Remove schedule long help, fixed by listing missing commands

* chore: Clean up annotation usage with template function

* fix: Drive-by fix for trailing whitespace for flags

Introduced in c7681370b5.
2022-07-12 23:24:53 +03:00
5e6320163d change default aws linux instance type to t3.micro, reduce default template TTL (#2776)
- make default template max TTL 24 hours (still less than 168)
- make default workspace autostop 2 hours unless specified otherwise
- add instance type selector to aws templates
2022-07-12 19:37:59 +01:00
61c52b3090 feat: default confirm to no for cli delete (#2919) 2022-07-12 10:36:07 -07:00
536c77af5d fix: confirm when deleting template (#2866)
* prompt for confirmation before deleting templates (#2830)

* populate templateNames from the interactive picker too

* allow skipping delete confirmation prompt with --yes flag

* eliminate unnecessary newline

* test both confirmation of delete and `--yes` with no confirmation

* fix failing test that needed --yes

* remove unnecessary empty line the linter disliked

* make the tests correct
2022-07-11 13:13:56 -05:00
5eecbaa534 fix: trim leading and trailing spaces from template parameters (#2829) (#2879) 2022-07-11 11:46:03 -05:00
749694b7de fix: Standardize and wrap example descriptions at 80 chars (#2894) 2022-07-11 19:08:09 +03:00
c7681370b5 fix: Wrap help flags at 100 chars (#2893)
Because the actual flags take quite a bit of space, wrapping at 80
characters creates a very cramped output for e.g. `coder server`, for
this reasons, flags are wrapped at 100 chars (vs. standard 80).

The `Consumes $ENV_FLAG` message was put on a newline for consistency,
this should allow users to learn where to look for the informations.

Side note: we should perhaps stop adding period (`.`) at the end of flag
descriptions to be consistent, for instance, command helps usually don't
have one.

This change fixes the biggest issue in #2363, but not all `--help`
output is guaranteed (yet) to wrap at 80-100 chars.

Fixes #2363
2022-07-11 17:07:25 +03:00
dff6e97f83 feat: Add allowlist of GitHub teams for OAuth (#2849)
Fixes #2848.
2022-07-08 21:37:18 -05:00
2609be767d feat: add timestamps to output at end of some workspace and template subcommands (#2831) 2022-07-08 14:27:56 -05:00
584448e089 fix: worksapces -> workspaces in template create CLI (#2857)
Fixes #2846.
2022-07-08 14:22:30 -05:00
dc58d1b734 fix: Update text in logout tests (#2851)
This fixes CI!
2022-07-07 21:46:31 -05:00
4f1e9dae27 Ketan/cli help tweak (#2803)
* fix CLI help text for logout

"log out" is verb, "logout" is a noun

* add CLI help for port-forward command (#2802)

* found another noun where a verb should be
2022-07-04 15:48:08 -05:00
e5d5fa7706 fix: reprompt for matching passwords on mismatch (#2758)
- Previously we only re-prompted for the password confirmation.
2022-07-01 11:49:39 -05:00
554d9917c0 feat: make 'templates update [name]' optional (#2761)
- If the name is not specified the current working directory
  name is used or the name specified by "--directory". This
  reflects 'templates create" behavior.
2022-07-01 11:49:29 -05:00
de1fc40000 fix: consistent workspace status b/w CLI and UI (#2743) 2022-07-01 14:40:03 +00:00
6ad0f31687 fix: don't check version on gitssh cmds (#2757) 2022-06-30 12:03:41 -05:00
7df5827767 feat: add version checking to CLI (#2725) 2022-06-29 17:49:40 -05:00
6a55889362 fix: disable wireguard in portforward and gitssh tests (#2728) 2022-06-29 17:37:26 +00:00
ea7f9e2d47 chore: Parameter listing cmd default adding scope column (#2718) 2022-06-29 11:29:21 -05:00
2b6dcb842d Revert "feat: add version checking to CLI" (#2712) 2022-06-29 02:42:23 +00:00
7ee7be3391 feat: add version checking to CLI (#2643)
* feat: add version checking to CLI
2022-06-28 20:55:34 -05:00
4b6189c9e9 fix: fix panic in template pull (#2710) 2022-06-28 19:54:28 -05:00
69f27efead fix: Close parameter file before test exit (#2694)
Flake seen here:
https://github.com/coder/coder/runs/7079404499?check_suite_focus=true
2022-06-27 14:42:26 -05:00
2353687610 feat: unexpose coderdtest.NewWithAPI (#2613)
* feat: unexpose coderdtest.NewWithAPI
2022-06-27 13:50:52 -05:00
3a3aa493f1 fix: use absolute path for config-ssh coder binary (#2647) 2022-06-27 12:15:55 -05:00
6429dfee1f test: Use a template to prevent migrations from running for every test (#2462)
* test: Use a template to prevent migrations from running for every test

* Create a single makefile target

* Fix built-in race

* Extend timeout of built-in PostgreSQL fetch
2022-06-27 17:07:39 +00:00
f41b50a253 feat: Updating workspace prompts new parameters (#2598) 2022-06-27 16:19:10 +00:00
16ac54cbd9 fix: Wait for workspace build to complete before running SSH tests (#2671)
This was causing a race shown here:
https://github.com/coder/coder/runs/7063713786?check_suite_focus=true
2022-06-26 23:10:52 +00:00
dac6838fc3 fix: Await workspace build job before waiting for CLI output (#2670)
This was causing occasional flakes seen here:
https://github.com/coder/coder/runs/7063142245?check_suite_focus=true
2022-06-26 22:05:37 +00:00
d1c69866e8 fix: provide environment variable for CLI session token (#2648) 2022-06-24 18:50:35 -05:00
6aed58f486 feat: add ssh support over wireguard (#2642) 2022-06-24 16:21:46 -05:00
bd07284a68 feat: Add success messages for CLI commands (#2634) 2022-06-24 16:30:22 +00:00
05b67ab1cf feat: peer wireguard (#2445) 2022-06-24 10:25:01 -05:00
c6b1daabc5 feat: Download default terraform version when minor version mismatches (#1775) 2022-06-22 23:11:52 +00:00
437066ce20 fix: Stop sending additional signals in Shutdown test (#2582)
Coder was exiting before the additional signals were handled,
which caused occasional CI failures.
2022-06-22 11:32:34 -05:00
11c47e0d3b feat: Rename config-ssh --diff to --dry-run (#2575)
* feat: Rename config-ssh `--diff` to `--dry-run`

Since the intent between diff and dry-run are different, this change
allows for interactive prompts to be shown during `--dry-run`,
previously prompts were disabled. Dry-run can also be chanied with
`--yes` and `--use-previous-options` for non-interactive modes.

Dry-run is like a normal run with changes replaced by diff.

Fixes #2530

Co-authored-by: Cian Johnston <cian@coder.com>
2022-06-22 18:33:08 +03:00
92bcacebde cli/templateinit: add links to template READMEs (#2576)
- template init: add links to template docs
- examples: add URL field to examples, ensure that example fields are always non-empty
- cliui: bump wrap width to 80 from 58
2022-06-22 14:15:04 +00:00
ee5918217b fix: cleanup reaper implementation (#2563)
- Clean up the agent/reaper API to be a more isolated and reusable package.
2022-06-21 18:01:34 -05:00
e2785ada5e feat: Compress and extract slim binaries with zstd (#2533)
Fixes #2202

Co-authored-by: Dean Sheather <dean@deansheather.com>
2022-06-21 19:53:36 +03:00
fe81b0b859 fix: Wait for TestServer/Telemetry to close before exit (#2554)
This was causing occasional test failures due to leakage!
2022-06-21 19:50:29 +03:00
7a4fd12911 Alias users CLI subcommand as user (#2522) 2022-06-20 10:40:08 -04:00
1455603505 fix: cli: create: use new autostart format, opt-in by default (#2472) 2022-06-17 20:38:10 +00:00
4616499030 chore: Reuse ComputedParmeter, remove duplicated codersdk type (#2477)
* chore: Reuse ComputedParmeter instead of custom type
2022-06-17 15:20:13 -05:00
17ba4c8e88 fix: Allow template names to be re-used after deletion (#2454)
Fixes #2152
2022-06-17 19:18:07 +00:00
64b92eea67 feat: Allow inheriting parameters from previous template_versions when updating a template (#2397)
* WIP: feat: Update templates also updates parameters
* Insert params for template version update
* Working implementation of inherited params
* Add "--always-prompt" flag and logging info
2022-06-17 12:22:28 -05:00
18973a65c1 fix: Add reaper to coder agent (#2441)
* fix: Add reaper to coder agent

- The coder agent runs as PID 1 in some of our Docker workspaces.
  In such cases it is the responsibility of the init process to
  reap dead processes. Failing to do so can result in an inability
  to create new processes by running out of PIDs.

  This PR adds a reaper to our agent that is only spawned if it
  detects that it is PID1.
2022-06-17 11:51:46 -05:00