feat(cli): colorize help page (#9589)

This commit is contained in:
Ammar Bandukwala
2023-09-08 18:21:33 +00:00
committed by GitHub
parent 11404af9ca
commit e361f1107b
86 changed files with 1224 additions and 920 deletions
+25 -21
View File
@@ -1,58 +1,62 @@
Usage: coder [global-flags] <subcommand>
coder v0.0.0-devel
Coder v0.0.0-devel — A tool for provisioning self-hosted development environments with Terraform.
- Start a Coder server:
USAGE:
coder [global-flags] <subcommand>
$ coder server
Coder v0.0.0-devel — A tool for provisioning self-hosted development
environments with Terraform.
- Start a Coder server:
$ coder server
- Get started by creating a template from an example:
$ coder templates init
- Get started by creating a template from an example:
$ coder templates init
Subcommands
SUBCOMMANDS:
features List Enterprise features
groups Manage groups
licenses Add, delete, and list licenses
provisionerd Manage provisioner daemons
server Start a Coder server
Global Options
GLOBAL OPTIONS:
Global options are applied to all commands. They can be set using environment
variables or flags.
--debug-options bool
--debug-options bool
Print all options, how they're set, then exit.
--disable-direct-connections bool, $CODER_DISABLE_DIRECT_CONNECTIONS
--disable-direct-connections bool, $CODER_DISABLE_DIRECT_CONNECTIONS
Disable direct (P2P) connections to workspaces.
--global-config string, $CODER_CONFIG_DIR (default: ~/.config/coderv2)
--global-config string, $CODER_CONFIG_DIR (default: ~/.config/coderv2)
Path to the global `coder` config directory.
--header string-array, $CODER_HEADER
--header string-array, $CODER_HEADER
Additional HTTP headers added to all requests. Provide as key=value.
Can be specified multiple times.
--header-command string, $CODER_HEADER_COMMAND
--header-command string, $CODER_HEADER_COMMAND
An external command that outputs additional HTTP headers added to all
requests. The command must output each header as `key=value` on its
own line.
--no-feature-warning bool, $CODER_NO_FEATURE_WARNING
--no-feature-warning bool, $CODER_NO_FEATURE_WARNING
Suppress warnings about unlicensed features.
--no-version-warning bool, $CODER_NO_VERSION_WARNING
--no-version-warning bool, $CODER_NO_VERSION_WARNING
Suppress warning when client and server versions do not match.
--token string, $CODER_SESSION_TOKEN
--token string, $CODER_SESSION_TOKEN
Specify an authentication token. For security reasons setting
CODER_SESSION_TOKEN is preferred.
--url url, $CODER_URL
--url url, $CODER_URL
URL to a deployment.
-v, --verbose bool, $CODER_VERBOSE
-v, --verbose bool, $CODER_VERBOSE
Enable verbose output.
---
———
Report bugs and request features at https://github.com/coder/coder/issues/new
+8 -5
View File
@@ -1,11 +1,14 @@
Usage: coder features
coder v0.0.0-devel
List Enterprise features
USAGE:
coder features
Aliases: feature
List Enterprise features
Subcommands
Aliases: feature
SUBCOMMANDS:
list
---
———
Run `coder --help` for a list of global options.
+9 -6
View File
@@ -1,14 +1,17 @@
Usage: coder features list [flags]
coder v0.0.0-devel
Aliases: ls
USAGE:
coder features list [flags]
Options
-c, --column string-array (default: Name,Entitlement,Enabled,Limit,Actual)
Aliases: ls
OPTIONS:
-c, --column string-array (default: Name,Entitlement,Enabled,Limit,Actual)
Specify a column to filter in the table. Available columns are: Name,
Entitlement, Enabled, Limit, Actual.
-o, --output string (default: table)
-o, --output string (default: table)
Output format. Available formats are: table, json.
---
———
Run `coder --help` for a list of global options.
+8 -5
View File
@@ -1,14 +1,17 @@
Usage: coder groups
coder v0.0.0-devel
Manage groups
USAGE:
coder groups
Aliases: group
Manage groups
Subcommands
Aliases: group
SUBCOMMANDS:
create Create a user group
delete Delete a user group
edit Edit a user group
list List user groups
---
———
Run `coder --help` for a list of global options.
+9 -6
View File
@@ -1,13 +1,16 @@
Usage: coder groups create [flags] <name>
coder v0.0.0-devel
Create a user group
USAGE:
coder groups create [flags] <name>
Options
-u, --avatar-url string, $CODER_AVATAR_URL
Create a user group
OPTIONS:
-u, --avatar-url string, $CODER_AVATAR_URL
Set an avatar for a group.
--display-name string, $CODER_DISPLAY_NAME
--display-name string, $CODER_DISPLAY_NAME
Optional human friendly name for the group.
---
———
Run `coder --help` for a list of global options.
+7 -4
View File
@@ -1,8 +1,11 @@
Usage: coder groups delete <name>
coder v0.0.0-devel
Delete a user group
USAGE:
coder groups delete <name>
Aliases: rm
Delete a user group
---
Aliases: rm
———
Run `coder --help` for a list of global options.
+12 -9
View File
@@ -1,22 +1,25 @@
Usage: coder groups edit [flags] <name>
coder v0.0.0-devel
Edit a user group
USAGE:
coder groups edit [flags] <name>
Options
-a, --add-users string-array
Edit a user group
OPTIONS:
-a, --add-users string-array
Add users to the group. Accepts emails or IDs.
-u, --avatar-url string
-u, --avatar-url string
Update the group avatar.
--display-name string, $CODER_DISPLAY_NAME
--display-name string, $CODER_DISPLAY_NAME
Optional human friendly name for the group.
-n, --name string
-n, --name string
Update the group name.
-r, --rm-users string-array
-r, --rm-users string-array
Remove users to the group. Accepts emails or IDs.
---
———
Run `coder --help` for a list of global options.
+9 -6
View File
@@ -1,14 +1,17 @@
Usage: coder groups list [flags]
coder v0.0.0-devel
List user groups
USAGE:
coder groups list [flags]
Options
-c, --column string-array (default: name,display name,organization id,members,avatar url)
List user groups
OPTIONS:
-c, --column string-array (default: name,display name,organization id,members,avatar url)
Columns to display in table output. Available columns: name, display
name, organization id, members, avatar url.
-o, --output string (default: table)
-o, --output string (default: table)
Output format. Available formats: table, json.
---
———
Run `coder --help` for a list of global options.
+8 -5
View File
@@ -1,13 +1,16 @@
Usage: coder licenses
coder v0.0.0-devel
Add, delete, and list licenses
USAGE:
coder licenses
Aliases: license
Add, delete, and list licenses
Subcommands
Aliases: license
SUBCOMMANDS:
add Add license to Coder deployment
delete Delete license by ID
list List licenses (including expired)
---
———
Run `coder --help` for a list of global options.
+10 -7
View File
@@ -1,16 +1,19 @@
Usage: coder licenses add [flags] [-f file | -l license]
coder v0.0.0-devel
Add license to Coder deployment
USAGE:
coder licenses add [flags] [-f file | -l license]
Options
--debug bool
Add license to Coder deployment
OPTIONS:
--debug bool
Output license claims for debugging.
-f, --file string
-f, --file string
Load license from file.
-l, --license string
-l, --license string
License string.
---
———
Run `coder --help` for a list of global options.
@@ -1,8 +1,11 @@
Usage: coder licenses delete <id>
coder v0.0.0-devel
Delete license by ID
USAGE:
coder licenses delete <id>
Aliases: del, rm
Delete license by ID
---
Aliases: del, rm
———
Run `coder --help` for a list of global options.
+10 -7
View File
@@ -1,16 +1,19 @@
Usage: coder licenses list [flags]
coder v0.0.0-devel
List licenses (including expired)
USAGE:
coder licenses list [flags]
Aliases: ls
List licenses (including expired)
Options
-c, --column string-array (default: UUID,Expires At,Uploaded At,Features)
Aliases: ls
OPTIONS:
-c, --column string-array (default: UUID,Expires At,Uploaded At,Features)
Columns to display in table output. Available columns: id, uuid,
uploaded at, features, expires at, trial.
-o, --output string (default: table)
-o, --output string (default: table)
Output format. Available formats: table, json.
---
———
Run `coder --help` for a list of global options.
+7 -4
View File
@@ -1,9 +1,12 @@
Usage: coder provisionerd
coder v0.0.0-devel
Manage provisioner daemons
USAGE:
coder provisionerd
Subcommands
Manage provisioner daemons
SUBCOMMANDS:
start Run a provisioner daemon
---
———
Run `coder --help` for a list of global options.
@@ -1,22 +1,25 @@
Usage: coder provisionerd start [flags]
coder v0.0.0-devel
Run a provisioner daemon
USAGE:
coder provisionerd start [flags]
Options
-c, --cache-dir string, $CODER_CACHE_DIRECTORY (default: [cache dir])
Run a provisioner daemon
OPTIONS:
-c, --cache-dir string, $CODER_CACHE_DIRECTORY (default: [cache dir])
Directory to store cached data.
--poll-interval duration, $CODER_PROVISIONERD_POLL_INTERVAL (default: 1s)
--poll-interval duration, $CODER_PROVISIONERD_POLL_INTERVAL (default: 1s)
How often to poll for provisioner jobs.
--poll-jitter duration, $CODER_PROVISIONERD_POLL_JITTER (default: 100ms)
--poll-jitter duration, $CODER_PROVISIONERD_POLL_JITTER (default: 100ms)
How much to jitter the poll interval by.
--psk string, $CODER_PROVISIONER_DAEMON_PSK
--psk string, $CODER_PROVISIONER_DAEMON_PSK
Pre-shared key to authenticate with Coder server.
-t, --tag string-array, $CODER_PROVISIONERD_TAGS
-t, --tag string-array, $CODER_PROVISIONERD_TAGS
Tags to filter provisioner jobs by.
---
———
Run `coder --help` for a list of global options.
+125 -122
View File
@@ -1,8 +1,11 @@
Usage: coder server [flags]
coder v0.0.0-devel
Start a Coder server
USAGE:
coder server [flags]
Subcommands
Start a Coder server
SUBCOMMANDS:
create-admin-user Create a new admin user with the given username,
email and password and adds it to every
organization.
@@ -11,153 +14,153 @@ Start a Coder server
postgres-builtin-url Output the connection URL for the built-in
PostgreSQL deployment.
Options
--cache-dir string, $CODER_CACHE_DIRECTORY (default: [cache dir])
OPTIONS:
--cache-dir string, $CODER_CACHE_DIRECTORY (default: [cache dir])
The directory to cache temporary files. If unspecified and
$CACHE_DIRECTORY is set, it will be used for compatibility with
systemd.
--disable-owner-workspace-access bool, $CODER_DISABLE_OWNER_WORKSPACE_ACCESS
--disable-owner-workspace-access bool, $CODER_DISABLE_OWNER_WORKSPACE_ACCESS
Remove the permission for the 'owner' role to have workspace execution
on all workspaces. This prevents the 'owner' from ssh, apps, and
terminal access based on the 'owner' role. They still have their user
permissions to access their own workspaces.
--disable-path-apps bool, $CODER_DISABLE_PATH_APPS
--disable-path-apps bool, $CODER_DISABLE_PATH_APPS
Disable workspace apps that are not served from subdomains. Path-based
apps can make requests to the Coder API and pose a security risk when
the workspace serves malicious JavaScript. This is recommended for
security purposes if a --wildcard-access-url is configured.
--swagger-enable bool, $CODER_SWAGGER_ENABLE
--swagger-enable bool, $CODER_SWAGGER_ENABLE
Expose the swagger endpoint via /swagger.
--experiments string-array, $CODER_EXPERIMENTS
--experiments string-array, $CODER_EXPERIMENTS
Enable one or more experiments. These are not ready for production.
Separate multiple experiments with commas, or enter '*' to opt-in to
all available experiments.
--postgres-url string, $CODER_PG_CONNECTION_URL
--postgres-url string, $CODER_PG_CONNECTION_URL
URL of a PostgreSQL database. If empty, PostgreSQL binaries will be
downloaded from Maven (https://repo1.maven.org/maven2) and store all
data in the config root. Access the built-in database with "coder
server postgres-builtin-url".
--ssh-keygen-algorithm string, $CODER_SSH_KEYGEN_ALGORITHM (default: ed25519)
--ssh-keygen-algorithm string, $CODER_SSH_KEYGEN_ALGORITHM (default: ed25519)
The algorithm to use for generating ssh keys. Accepted values are
"ed25519", "ecdsa", or "rsa4096".
--update-check bool, $CODER_UPDATE_CHECK (default: false)
--update-check bool, $CODER_UPDATE_CHECK (default: false)
Periodically check for new releases of Coder and inform the owner. The
check is performed once per day.
Client Options
CLIENT OPTIONS:
These options change the behavior of how clients interact with the Coder.
Clients include the coder cli, vs code extension, and the web UI.
--ssh-config-options string-array, $CODER_SSH_CONFIG_OPTIONS
--ssh-config-options string-array, $CODER_SSH_CONFIG_OPTIONS
These SSH config options will override the default SSH config options.
Provide options in "key=value" or "key value" format separated by
commas.Using this incorrectly can break SSH to your deployment, use
cautiously.
--ssh-hostname-prefix string, $CODER_SSH_HOSTNAME_PREFIX (default: coder.)
--ssh-hostname-prefix string, $CODER_SSH_HOSTNAME_PREFIX (default: coder.)
The SSH deployment prefix is used in the Host of the ssh config.
Config Options
CONFIG OPTIONS:
Use a YAML configuration file when your server launch become unwieldy.
-c, --config yaml-config-path, $CODER_CONFIG_PATH
-c, --config yaml-config-path, $CODER_CONFIG_PATH
Specify a YAML file to load configuration from.
--write-config bool
--write-config bool
Write out the current server config as YAML to stdout.
Introspection / Logging Options
--enable-terraform-debug-mode bool, $CODER_ENABLE_TERRAFORM_DEBUG_MODE (default: false)
INTROSPECTION / LOGGING OPTIONS:
--enable-terraform-debug-mode bool, $CODER_ENABLE_TERRAFORM_DEBUG_MODE (default: false)
Allow administrators to enable Terraform debug output.
--log-human string, $CODER_LOGGING_HUMAN (default: /dev/stderr)
--log-human string, $CODER_LOGGING_HUMAN (default: /dev/stderr)
Output human-readable logs to a given file.
--log-json string, $CODER_LOGGING_JSON
--log-json string, $CODER_LOGGING_JSON
Output JSON logs to a given file.
-l, --log-filter string-array, $CODER_LOG_FILTER
-l, --log-filter string-array, $CODER_LOG_FILTER
Filter debug logs by matching against a given regex. Use .* to match
all debug logs.
--log-stackdriver string, $CODER_LOGGING_STACKDRIVER
--log-stackdriver string, $CODER_LOGGING_STACKDRIVER
Output Stackdriver compatible logs to a given file.
Introspection / Prometheus Options
--prometheus-address host:port, $CODER_PROMETHEUS_ADDRESS (default: 127.0.0.1:2112)
INTROSPECTION / PROMETHEUS OPTIONS:
--prometheus-address host:port, $CODER_PROMETHEUS_ADDRESS (default: 127.0.0.1:2112)
The bind address to serve prometheus metrics.
--prometheus-collect-agent-stats bool, $CODER_PROMETHEUS_COLLECT_AGENT_STATS
--prometheus-collect-agent-stats bool, $CODER_PROMETHEUS_COLLECT_AGENT_STATS
Collect agent stats (may increase charges for metrics storage).
--prometheus-collect-db-metrics bool, $CODER_PROMETHEUS_COLLECT_DB_METRICS (default: false)
--prometheus-collect-db-metrics bool, $CODER_PROMETHEUS_COLLECT_DB_METRICS (default: false)
Collect database metrics (may increase charges for metrics storage).
--prometheus-enable bool, $CODER_PROMETHEUS_ENABLE
--prometheus-enable bool, $CODER_PROMETHEUS_ENABLE
Serve prometheus metrics on the address defined by prometheus address.
Introspection / Tracing Options
--trace-logs bool, $CODER_TRACE_LOGS
INTROSPECTION / TRACING OPTIONS:
--trace-logs bool, $CODER_TRACE_LOGS
Enables capturing of logs as events in traces. This is useful for
debugging, but may result in a very large amount of events being sent
to the tracing backend which may incur significant costs.
--trace bool, $CODER_TRACE_ENABLE
--trace bool, $CODER_TRACE_ENABLE
Whether application tracing data is collected. It exports to a backend
configured by environment variables. See:
https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/protocol/exporter.md.
--trace-honeycomb-api-key string, $CODER_TRACE_HONEYCOMB_API_KEY
--trace-honeycomb-api-key string, $CODER_TRACE_HONEYCOMB_API_KEY
Enables trace exporting to Honeycomb.io using the provided API Key.
Introspection / pprof Options
--pprof-address host:port, $CODER_PPROF_ADDRESS (default: 127.0.0.1:6060)
INTROSPECTION / PPROF OPTIONS:
--pprof-address host:port, $CODER_PPROF_ADDRESS (default: 127.0.0.1:6060)
The bind address to serve pprof.
--pprof-enable bool, $CODER_PPROF_ENABLE
--pprof-enable bool, $CODER_PPROF_ENABLE
Serve pprof metrics on the address defined by pprof address.
Networking Options
--access-url url, $CODER_ACCESS_URL
NETWORKING OPTIONS:
--access-url url, $CODER_ACCESS_URL
The URL that users will use to access the Coder deployment.
--docs-url url, $CODER_DOCS_URL
--docs-url url, $CODER_DOCS_URL
Specifies the custom docs URL.
--proxy-trusted-headers string-array, $CODER_PROXY_TRUSTED_HEADERS
--proxy-trusted-headers string-array, $CODER_PROXY_TRUSTED_HEADERS
Headers to trust for forwarding IP addresses. e.g. Cf-Connecting-Ip,
True-Client-Ip, X-Forwarded-For.
--proxy-trusted-origins string-array, $CODER_PROXY_TRUSTED_ORIGINS
--proxy-trusted-origins string-array, $CODER_PROXY_TRUSTED_ORIGINS
Origin addresses to respect "proxy-trusted-headers". e.g.
192.168.1.0/24.
--redirect-to-access-url bool, $CODER_REDIRECT_TO_ACCESS_URL
--redirect-to-access-url bool, $CODER_REDIRECT_TO_ACCESS_URL
Specifies whether to redirect requests that do not match the access
URL host.
--secure-auth-cookie bool, $CODER_SECURE_AUTH_COOKIE
--secure-auth-cookie bool, $CODER_SECURE_AUTH_COOKIE
Controls if the 'Secure' property is set on browser session cookies.
--wildcard-access-url url, $CODER_WILDCARD_ACCESS_URL
--wildcard-access-url url, $CODER_WILDCARD_ACCESS_URL
Specifies the wildcard hostname to use for workspace applications in
the form "*.example.com".
Networking / DERP Options
NETWORKING / DERP OPTIONS:
Most Coder deployments never have to think about DERP because all connections
between workspaces and users are peer-to-peer. However, when Coder cannot
establish a peer to peer connection, Coder uses a distributed relay network
backed by Tailscale and WireGuard.
--block-direct-connections bool, $CODER_BLOCK_DIRECT
--block-direct-connections bool, $CODER_BLOCK_DIRECT
Block peer-to-peer (aka. direct) workspace connections. All workspace
connections from the CLI will be proxied through Coder (or custom
configured DERP servers) and will never be peer-to-peer when enabled.
@@ -165,36 +168,36 @@ backed by Tailscale and WireGuard.
until they are restarted after this change has been made, but new
connections will still be proxied regardless.
--derp-config-path string, $CODER_DERP_CONFIG_PATH
--derp-config-path string, $CODER_DERP_CONFIG_PATH
Path to read a DERP mapping from. See:
https://tailscale.com/kb/1118/custom-derp-servers/.
--derp-config-url string, $CODER_DERP_CONFIG_URL
--derp-config-url string, $CODER_DERP_CONFIG_URL
URL to fetch a DERP mapping on startup. See:
https://tailscale.com/kb/1118/custom-derp-servers/.
--derp-force-websockets bool, $CODER_DERP_FORCE_WEBSOCKETS
--derp-force-websockets bool, $CODER_DERP_FORCE_WEBSOCKETS
Force clients and agents to always use WebSocket to connect to DERP
relay servers. By default, DERP uses `Upgrade: derp`, which may cause
issues with some reverse proxies. Clients may automatically fallback
to WebSocket if they detect an issue with `Upgrade: derp`, but this
does not work in all situations.
--derp-server-enable bool, $CODER_DERP_SERVER_ENABLE (default: true)
--derp-server-enable bool, $CODER_DERP_SERVER_ENABLE (default: true)
Whether to enable or disable the embedded DERP relay server.
--derp-server-region-name string, $CODER_DERP_SERVER_REGION_NAME (default: Coder Embedded Relay)
--derp-server-region-name string, $CODER_DERP_SERVER_REGION_NAME (default: Coder Embedded Relay)
Region name that for the embedded DERP server.
--derp-server-stun-addresses string-array, $CODER_DERP_SERVER_STUN_ADDRESSES (default: stun.l.google.com:19302,stun1.l.google.com:19302,stun2.l.google.com:19302,stun3.l.google.com:19302,stun4.l.google.com:19302)
--derp-server-stun-addresses string-array, $CODER_DERP_SERVER_STUN_ADDRESSES (default: stun.l.google.com:19302,stun1.l.google.com:19302,stun2.l.google.com:19302,stun3.l.google.com:19302,stun4.l.google.com:19302)
Addresses for STUN servers to establish P2P connections. It's
recommended to have at least two STUN servers to give users the best
chance of connecting P2P to workspaces. Each STUN server will get it's
own DERP region, with region IDs starting at `--derp-server-region-id
+ 1`. Use special value 'disable' to turn off STUN completely.
Networking / HTTP Options
--disable-password-auth bool, $CODER_DISABLE_PASSWORD_AUTH
NETWORKING / HTTP OPTIONS:
--disable-password-auth bool, $CODER_DISABLE_PASSWORD_AUTH
Disable password authentication. This is recommended for security
purposes in production deployments that rely on an identity provider.
Any user with the owner role will be able to sign in with their
@@ -203,226 +206,226 @@ backed by Tailscale and WireGuard.
create-admin` command to create a new admin user directly in the
database.
--disable-session-expiry-refresh bool, $CODER_DISABLE_SESSION_EXPIRY_REFRESH
--disable-session-expiry-refresh bool, $CODER_DISABLE_SESSION_EXPIRY_REFRESH
Disable automatic session expiry bumping due to activity. This forces
all sessions to become invalid after the session expiry duration has
been reached.
--http-address string, $CODER_HTTP_ADDRESS (default: 127.0.0.1:3000)
--http-address string, $CODER_HTTP_ADDRESS (default: 127.0.0.1:3000)
HTTP bind address of the server. Unset to disable the HTTP endpoint.
--max-token-lifetime duration, $CODER_MAX_TOKEN_LIFETIME (default: 876600h0m0s)
--max-token-lifetime duration, $CODER_MAX_TOKEN_LIFETIME (default: 876600h0m0s)
The maximum lifetime duration users can specify when creating an API
token.
--proxy-health-interval duration, $CODER_PROXY_HEALTH_INTERVAL (default: 1m0s)
--proxy-health-interval duration, $CODER_PROXY_HEALTH_INTERVAL (default: 1m0s)
The interval in which coderd should be checking the status of
workspace proxies.
--session-duration duration, $CODER_SESSION_DURATION (default: 24h0m0s)
--session-duration duration, $CODER_SESSION_DURATION (default: 24h0m0s)
The token expiry duration for browser sessions. Sessions may last
longer if they are actively making requests, but this functionality
can be disabled via --disable-session-expiry-refresh.
Networking / TLS Options
NETWORKING / TLS OPTIONS:
Configure TLS / HTTPS for your Coder deployment. If you're running Coder behind
a TLS-terminating reverse proxy or are accessing Coder over a secure link, you
can safely ignore these settings.
--strict-transport-security int, $CODER_STRICT_TRANSPORT_SECURITY (default: 0)
--strict-transport-security int, $CODER_STRICT_TRANSPORT_SECURITY (default: 0)
Controls if the 'Strict-Transport-Security' header is set on all
static file responses. This header should only be set if the server is
accessed via HTTPS. This value is the MaxAge in seconds of the header.
--strict-transport-security-options string-array, $CODER_STRICT_TRANSPORT_SECURITY_OPTIONS
--strict-transport-security-options string-array, $CODER_STRICT_TRANSPORT_SECURITY_OPTIONS
Two optional fields can be set in the Strict-Transport-Security
header; 'includeSubDomains' and 'preload'. The
'strict-transport-security' flag must be set to a non-zero value for
these options to be used.
--tls-address host:port, $CODER_TLS_ADDRESS (default: 127.0.0.1:3443)
--tls-address host:port, $CODER_TLS_ADDRESS (default: 127.0.0.1:3443)
HTTPS bind address of the server.
--tls-cert-file string-array, $CODER_TLS_CERT_FILE
--tls-cert-file string-array, $CODER_TLS_CERT_FILE
Path to each certificate for TLS. It requires a PEM-encoded file. To
configure the listener to use a CA certificate, concatenate the
primary certificate and the CA certificate together. The primary
certificate should appear first in the combined file.
--tls-client-auth string, $CODER_TLS_CLIENT_AUTH (default: none)
--tls-client-auth string, $CODER_TLS_CLIENT_AUTH (default: none)
Policy the server will follow for TLS Client Authentication. Accepted
values are "none", "request", "require-any", "verify-if-given", or
"require-and-verify".
--tls-client-ca-file string, $CODER_TLS_CLIENT_CA_FILE
--tls-client-ca-file string, $CODER_TLS_CLIENT_CA_FILE
PEM-encoded Certificate Authority file used for checking the
authenticity of client.
--tls-client-cert-file string, $CODER_TLS_CLIENT_CERT_FILE
--tls-client-cert-file string, $CODER_TLS_CLIENT_CERT_FILE
Path to certificate for client TLS authentication. It requires a
PEM-encoded file.
--tls-client-key-file string, $CODER_TLS_CLIENT_KEY_FILE
--tls-client-key-file string, $CODER_TLS_CLIENT_KEY_FILE
Path to key for client TLS authentication. It requires a PEM-encoded
file.
--tls-enable bool, $CODER_TLS_ENABLE
--tls-enable bool, $CODER_TLS_ENABLE
Whether TLS will be enabled.
--tls-key-file string-array, $CODER_TLS_KEY_FILE
--tls-key-file string-array, $CODER_TLS_KEY_FILE
Paths to the private keys for each of the certificates. It requires a
PEM-encoded file.
--tls-min-version string, $CODER_TLS_MIN_VERSION (default: tls12)
--tls-min-version string, $CODER_TLS_MIN_VERSION (default: tls12)
Minimum supported version of TLS. Accepted values are "tls10",
"tls11", "tls12" or "tls13".
OAuth2 / GitHub Options
--oauth2-github-allow-everyone bool, $CODER_OAUTH2_GITHUB_ALLOW_EVERYONE
OAUTH2 / GITHUB OPTIONS:
--oauth2-github-allow-everyone bool, $CODER_OAUTH2_GITHUB_ALLOW_EVERYONE
Allow all logins, setting this option means allowed orgs and teams
must be empty.
--oauth2-github-allow-signups bool, $CODER_OAUTH2_GITHUB_ALLOW_SIGNUPS
--oauth2-github-allow-signups bool, $CODER_OAUTH2_GITHUB_ALLOW_SIGNUPS
Whether new users can sign up with GitHub.
--oauth2-github-allowed-orgs string-array, $CODER_OAUTH2_GITHUB_ALLOWED_ORGS
--oauth2-github-allowed-orgs string-array, $CODER_OAUTH2_GITHUB_ALLOWED_ORGS
Organizations the user must be a member of to Login with GitHub.
--oauth2-github-allowed-teams string-array, $CODER_OAUTH2_GITHUB_ALLOWED_TEAMS
--oauth2-github-allowed-teams string-array, $CODER_OAUTH2_GITHUB_ALLOWED_TEAMS
Teams inside organizations the user must be a member of to Login with
GitHub. Structured as: <organization-name>/<team-slug>.
--oauth2-github-client-id string, $CODER_OAUTH2_GITHUB_CLIENT_ID
--oauth2-github-client-id string, $CODER_OAUTH2_GITHUB_CLIENT_ID
Client ID for Login with GitHub.
--oauth2-github-client-secret string, $CODER_OAUTH2_GITHUB_CLIENT_SECRET
--oauth2-github-client-secret string, $CODER_OAUTH2_GITHUB_CLIENT_SECRET
Client secret for Login with GitHub.
--oauth2-github-enterprise-base-url string, $CODER_OAUTH2_GITHUB_ENTERPRISE_BASE_URL
--oauth2-github-enterprise-base-url string, $CODER_OAUTH2_GITHUB_ENTERPRISE_BASE_URL
Base URL of a GitHub Enterprise deployment to use for Login with
GitHub.
OIDC Options
--oidc-group-auto-create bool, $CODER_OIDC_GROUP_AUTO_CREATE (default: false)
OIDC OPTIONS:
--oidc-group-auto-create bool, $CODER_OIDC_GROUP_AUTO_CREATE (default: false)
Automatically creates missing groups from a user's groups claim.
--oidc-allow-signups bool, $CODER_OIDC_ALLOW_SIGNUPS (default: true)
--oidc-allow-signups bool, $CODER_OIDC_ALLOW_SIGNUPS (default: true)
Whether new users can sign up with OIDC.
--oidc-auth-url-params struct[map[string]string], $CODER_OIDC_AUTH_URL_PARAMS (default: {"access_type": "offline"})
--oidc-auth-url-params struct[map[string]string], $CODER_OIDC_AUTH_URL_PARAMS (default: {"access_type": "offline"})
OIDC auth URL parameters to pass to the upstream provider.
--oidc-client-cert-file string, $CODER_OIDC_CLIENT_CERT_FILE
--oidc-client-cert-file string, $CODER_OIDC_CLIENT_CERT_FILE
Pem encoded certificate file to use for oauth2 PKI/JWT authorization.
The public certificate that accompanies oidc-client-key-file. A
standard x509 certificate is expected.
--oidc-client-id string, $CODER_OIDC_CLIENT_ID
--oidc-client-id string, $CODER_OIDC_CLIENT_ID
Client ID to use for Login with OIDC.
--oidc-client-key-file string, $CODER_OIDC_CLIENT_KEY_FILE
--oidc-client-key-file string, $CODER_OIDC_CLIENT_KEY_FILE
Pem encoded RSA private key to use for oauth2 PKI/JWT authorization.
This can be used instead of oidc-client-secret if your IDP supports
it.
--oidc-client-secret string, $CODER_OIDC_CLIENT_SECRET
--oidc-client-secret string, $CODER_OIDC_CLIENT_SECRET
Client secret to use for Login with OIDC.
--oidc-email-domain string-array, $CODER_OIDC_EMAIL_DOMAIN
--oidc-email-domain string-array, $CODER_OIDC_EMAIL_DOMAIN
Email domains that clients logging in with OIDC must match.
--oidc-email-field string, $CODER_OIDC_EMAIL_FIELD (default: email)
--oidc-email-field string, $CODER_OIDC_EMAIL_FIELD (default: email)
OIDC claim field to use as the email.
--oidc-group-field string, $CODER_OIDC_GROUP_FIELD
--oidc-group-field string, $CODER_OIDC_GROUP_FIELD
This field must be set if using the group sync feature and the scope
name is not 'groups'. Set to the claim to be used for groups.
--oidc-group-mapping struct[map[string]string], $CODER_OIDC_GROUP_MAPPING (default: {})
--oidc-group-mapping struct[map[string]string], $CODER_OIDC_GROUP_MAPPING (default: {})
A map of OIDC group IDs and the group in Coder it should map to. This
is useful for when OIDC providers only return group IDs.
--oidc-ignore-email-verified bool, $CODER_OIDC_IGNORE_EMAIL_VERIFIED
--oidc-ignore-email-verified bool, $CODER_OIDC_IGNORE_EMAIL_VERIFIED
Ignore the email_verified claim from the upstream provider.
--oidc-ignore-userinfo bool, $CODER_OIDC_IGNORE_USERINFO (default: false)
--oidc-ignore-userinfo bool, $CODER_OIDC_IGNORE_USERINFO (default: false)
Ignore the userinfo endpoint and only use the ID token for user
information.
--oidc-issuer-url string, $CODER_OIDC_ISSUER_URL
--oidc-issuer-url string, $CODER_OIDC_ISSUER_URL
Issuer URL to use for Login with OIDC.
--oidc-group-regex-filter regexp, $CODER_OIDC_GROUP_REGEX_FILTER (default: .*)
--oidc-group-regex-filter regexp, $CODER_OIDC_GROUP_REGEX_FILTER (default: .*)
If provided any group name not matching the regex is ignored. This
allows for filtering out groups that are not needed. This filter is
applied after the group mapping.
--oidc-scopes string-array, $CODER_OIDC_SCOPES (default: openid,profile,email)
--oidc-scopes string-array, $CODER_OIDC_SCOPES (default: openid,profile,email)
Scopes to grant when authenticating with OIDC.
--oidc-user-role-default string-array, $CODER_OIDC_USER_ROLE_DEFAULT
--oidc-user-role-default string-array, $CODER_OIDC_USER_ROLE_DEFAULT
If user role sync is enabled, these roles are always included for all
authenticated users. The 'member' role is always assigned.
--oidc-user-role-field string, $CODER_OIDC_USER_ROLE_FIELD
--oidc-user-role-field string, $CODER_OIDC_USER_ROLE_FIELD
This field must be set if using the user roles sync feature. Set this
to the name of the claim used to store the user's role. The roles
should be sent as an array of strings.
--oidc-user-role-mapping struct[map[string][]string], $CODER_OIDC_USER_ROLE_MAPPING (default: {})
--oidc-user-role-mapping struct[map[string][]string], $CODER_OIDC_USER_ROLE_MAPPING (default: {})
A map of the OIDC passed in user roles and the groups in Coder it
should map to. This is useful if the group names do not match. If
mapped to the empty string, the role will ignored.
--oidc-username-field string, $CODER_OIDC_USERNAME_FIELD (default: preferred_username)
--oidc-username-field string, $CODER_OIDC_USERNAME_FIELD (default: preferred_username)
OIDC claim field to use as the username.
--oidc-sign-in-text string, $CODER_OIDC_SIGN_IN_TEXT (default: OpenID Connect)
--oidc-sign-in-text string, $CODER_OIDC_SIGN_IN_TEXT (default: OpenID Connect)
The text to show on the OpenID Connect sign in button.
--oidc-icon-url url, $CODER_OIDC_ICON_URL
--oidc-icon-url url, $CODER_OIDC_ICON_URL
URL pointing to the icon to use on the OpenID Connect login button.
Provisioning Options
PROVISIONING OPTIONS:
Tune the behavior of the provisioner, which is responsible for creating,
updating, and deleting workspace resources.
--provisioner-force-cancel-interval duration, $CODER_PROVISIONER_FORCE_CANCEL_INTERVAL (default: 10m0s)
--provisioner-force-cancel-interval duration, $CODER_PROVISIONER_FORCE_CANCEL_INTERVAL (default: 10m0s)
Time to force cancel provisioning tasks that are stuck.
--provisioner-daemon-poll-interval duration, $CODER_PROVISIONER_DAEMON_POLL_INTERVAL (default: 1s)
--provisioner-daemon-poll-interval duration, $CODER_PROVISIONER_DAEMON_POLL_INTERVAL (default: 1s)
Time to wait before polling for a new job.
--provisioner-daemon-poll-jitter duration, $CODER_PROVISIONER_DAEMON_POLL_JITTER (default: 100ms)
--provisioner-daemon-poll-jitter duration, $CODER_PROVISIONER_DAEMON_POLL_JITTER (default: 100ms)
Random jitter added to the poll interval.
--provisioner-daemon-psk string, $CODER_PROVISIONER_DAEMON_PSK
--provisioner-daemon-psk string, $CODER_PROVISIONER_DAEMON_PSK
Pre-shared key to authenticate external provisioner daemons to Coder
server.
--provisioner-daemons int, $CODER_PROVISIONER_DAEMONS (default: 3)
--provisioner-daemons int, $CODER_PROVISIONER_DAEMONS (default: 3)
Number of provisioner daemons to create on start. If builds are stuck
in queued state for a long time, consider increasing this.
Telemetry Options
TELEMETRY OPTIONS:
Telemetry is critical to our ability to improve Coder. We strip all
personalinformation before sending data to our servers. Please only disable
telemetrywhen required by your organization's security policy.
--telemetry bool, $CODER_TELEMETRY_ENABLE (default: false)
--telemetry bool, $CODER_TELEMETRY_ENABLE (default: false)
Whether telemetry is enabled or not. Coder collects anonymized usage
data to help improve our product.
--telemetry-trace bool, $CODER_TELEMETRY_TRACE (default: false)
--telemetry-trace bool, $CODER_TELEMETRY_TRACE (default: false)
Whether Opentelemetry traces are sent to Coder. Coder collects
anonymized application tracing to help improve our product. Disabling
telemetry also disables this option.
User Quiet Hours Schedule Options
USER QUIET HOURS SCHEDULE OPTIONS:
Allow users to set quiet hours schedules each day for workspaces to avoid
workspaces stopping during the day due to template max TTL.
--default-quiet-hours-schedule string, $CODER_QUIET_HOURS_DEFAULT_SCHEDULE
--default-quiet-hours-schedule string, $CODER_QUIET_HOURS_DEFAULT_SCHEDULE
The default daily cron schedule applied to users that haven't set a
custom quiet hours schedule themselves. The quiet hours schedule
determines when workspaces will be force stopped due to the template's
@@ -432,8 +435,8 @@ workspaces stopping during the day due to template max TTL.
one hour and minute can be specified (ranges or comma separated values
are not supported).
⚠️ Dangerous Options
--dangerous-allow-path-app-sharing bool, $CODER_DANGEROUS_ALLOW_PATH_APP_SHARING
⚠️ DANGEROUS OPTIONS:
--dangerous-allow-path-app-sharing bool, $CODER_DANGEROUS_ALLOW_PATH_APP_SHARING
Allow workspace apps that are not served from subdomains to be shared.
Path-based app sharing is DISABLED by default for security purposes.
Path-based apps can make requests to the Coder API and pose a security
@@ -441,7 +444,7 @@ workspaces stopping during the day due to template max TTL.
can be disabled entirely with --disable-path-apps for further
security.
--dangerous-allow-path-app-site-owner-access bool, $CODER_DANGEROUS_ALLOW_PATH_APP_SITE_OWNER_ACCESS
--dangerous-allow-path-app-site-owner-access bool, $CODER_DANGEROUS_ALLOW_PATH_APP_SITE_OWNER_ACCESS
Allow site-owners to access workspace apps from workspaces they do not
own. Owners cannot access path-based apps they do not own by default.
Path-based apps can make requests to the Coder API and pose a security
@@ -449,17 +452,17 @@ workspaces stopping during the day due to template max TTL.
can be disabled entirely with --disable-path-apps for further
security.
Enterprise Options
ENTERPRISE OPTIONS:
These options are only available in the Enterprise Edition.
--browser-only bool, $CODER_BROWSER_ONLY
--browser-only bool, $CODER_BROWSER_ONLY
Whether Coder only allows connections to workspaces via the browser.
--derp-server-relay-url url, $CODER_DERP_SERVER_RELAY_URL
--derp-server-relay-url url, $CODER_DERP_SERVER_RELAY_URL
An HTTP URL that is accessible by other replicas to relay DERP
traffic. Required for high availability.
--external-token-encryption-keys string-array, $CODER_EXTERNAL_TOKEN_ENCRYPTION_KEYS
--external-token-encryption-keys string-array, $CODER_EXTERNAL_TOKEN_ENCRYPTION_KEYS
Encrypt OIDC and Git authentication tokens with AES-256-GCM in the
database. The value must be a comma-separated list of base64-encoded
keys. Each key, when base64-decoded, must be exactly 32 bytes in
@@ -469,9 +472,9 @@ These options are only available in the Enterprise Edition.
process of rotating keys with the `coder server dbcrypt rotate`
command.
--scim-auth-header string, $CODER_SCIM_AUTH_HEADER
--scim-auth-header string, $CODER_SCIM_AUTH_HEADER
Enables SCIM and sets the authentication header for the built-in SCIM
server. New users are automatically created with OIDC authentication.
---
———
Run `coder --help` for a list of global options.
@@ -1,32 +1,35 @@
Usage: coder server create-admin-user [flags]
coder v0.0.0-devel
Create a new admin user with the given username, email and password and adds it
to every organization.
USAGE:
coder server create-admin-user [flags]
Options
--email string, $CODER_EMAIL
Create a new admin user with the given username, email and password and adds
it to every organization.
OPTIONS:
--email string, $CODER_EMAIL
The email of the new user. If not specified, you will be prompted via
stdin.
--password string, $CODER_PASSWORD
--password string, $CODER_PASSWORD
The password of the new user. If not specified, you will be prompted
via stdin.
--postgres-url string, $CODER_PG_CONNECTION_URL
--postgres-url string, $CODER_PG_CONNECTION_URL
URL of a PostgreSQL database. If empty, the built-in PostgreSQL
deployment will be used (Coder must not be already running in this
case).
--raw-url bool
--raw-url bool
Output the raw connection URL instead of a psql command.
--ssh-keygen-algorithm string, $CODER_SSH_KEYGEN_ALGORITHM (default: ed25519)
--ssh-keygen-algorithm string, $CODER_SSH_KEYGEN_ALGORITHM (default: ed25519)
The algorithm to use for generating ssh keys. Accepted values are
"ed25519", "ecdsa", or "rsa4096".
--username string, $CODER_USERNAME
--username string, $CODER_USERNAME
The username of the new user. If not specified, you will be prompted
via stdin.
---
———
Run `coder --help` for a list of global options.
+7 -4
View File
@@ -1,12 +1,15 @@
Usage: coder server dbcrypt
coder v0.0.0-devel
Manage database encryption.
USAGE:
coder server dbcrypt
Subcommands
Manage database encryption.
SUBCOMMANDS:
decrypt Decrypt a previously encrypted database.
delete Delete all encrypted data from the database. THIS IS A
DESTRUCTIVE OPERATION.
rotate Rotate database encryption keys.
---
———
Run `coder --help` for a list of global options.
@@ -1,17 +1,20 @@
Usage: coder server dbcrypt decrypt [flags]
coder v0.0.0-devel
Decrypt a previously encrypted database.
USAGE:
coder server dbcrypt decrypt [flags]
Options
--keys string-array, $CODER_EXTERNAL_TOKEN_ENCRYPTION_DECRYPT_KEYS
Decrypt a previously encrypted database.
OPTIONS:
--keys string-array, $CODER_EXTERNAL_TOKEN_ENCRYPTION_DECRYPT_KEYS
Keys required to decrypt existing data. Must be a comma-separated list
of base64-encoded keys.
--postgres-url string, $CODER_PG_CONNECTION_URL
--postgres-url string, $CODER_PG_CONNECTION_URL
The connection URL for the Postgres database.
-y, --yes bool
-y, --yes bool
Bypass prompts.
---
———
Run `coder --help` for a list of global options.
@@ -1,15 +1,18 @@
Usage: coder server dbcrypt delete [flags]
coder v0.0.0-devel
Delete all encrypted data from the database. THIS IS A DESTRUCTIVE OPERATION.
USAGE:
coder server dbcrypt delete [flags]
Aliases: rm
Delete all encrypted data from the database. THIS IS A DESTRUCTIVE OPERATION.
Options
--postgres-url string, $CODER_EXTERNAL_TOKEN_ENCRYPTION_POSTGRES_URL
Aliases: rm
OPTIONS:
--postgres-url string, $CODER_EXTERNAL_TOKEN_ENCRYPTION_POSTGRES_URL
The connection URL for the Postgres database.
-y, --yes bool
-y, --yes bool
Bypass prompts.
---
———
Run `coder --help` for a list of global options.
@@ -1,20 +1,23 @@
Usage: coder server dbcrypt rotate [flags]
coder v0.0.0-devel
Rotate database encryption keys.
USAGE:
coder server dbcrypt rotate [flags]
Options
--new-key string, $CODER_EXTERNAL_TOKEN_ENCRYPTION_ENCRYPT_NEW_KEY
Rotate database encryption keys.
OPTIONS:
--new-key string, $CODER_EXTERNAL_TOKEN_ENCRYPTION_ENCRYPT_NEW_KEY
The new external token encryption key. Must be base64-encoded.
--old-keys string-array, $CODER_EXTERNAL_TOKEN_ENCRYPTION_ENCRYPT_OLD_KEYS
--old-keys string-array, $CODER_EXTERNAL_TOKEN_ENCRYPTION_ENCRYPT_OLD_KEYS
The old external token encryption keys. Must be a comma-separated list
of base64-encoded keys.
--postgres-url string, $CODER_PG_CONNECTION_URL
--postgres-url string, $CODER_PG_CONNECTION_URL
The connection URL for the Postgres database.
-y, --yes bool
-y, --yes bool
Bypass prompts.
---
———
Run `coder --help` for a list of global options.
@@ -1,10 +1,13 @@
Usage: coder server postgres-builtin-serve [flags]
coder v0.0.0-devel
Run the built-in PostgreSQL deployment.
USAGE:
coder server postgres-builtin-serve [flags]
Options
--raw-url bool
Run the built-in PostgreSQL deployment.
OPTIONS:
--raw-url bool
Output the raw connection URL instead of a psql command.
---
———
Run `coder --help` for a list of global options.
@@ -1,10 +1,13 @@
Usage: coder server postgres-builtin-url [flags]
coder v0.0.0-devel
Output the connection URL for the built-in PostgreSQL deployment.
USAGE:
coder server postgres-builtin-url [flags]
Options
--raw-url bool
Output the connection URL for the built-in PostgreSQL deployment.
OPTIONS:
--raw-url bool
Output the raw connection URL instead of a psql command.
---
———
Run `coder --help` for a list of global options.