mirror of
https://github.com/coder/coder.git
synced 2025-07-13 21:36:50 +00:00
increase default max-token-duration (#6467)
This commit is contained in:
@ -499,10 +499,11 @@ func newConfig() *codersdk.DeploymentConfig {
|
||||
Default: flag.Lookup("test.v") == nil && !buildinfo.IsDev(),
|
||||
},
|
||||
MaxTokenLifetime: &codersdk.DeploymentConfigField[time.Duration]{
|
||||
Name: "Max Token Lifetime",
|
||||
Usage: "The maximum lifetime duration users can specify when creating an API token.",
|
||||
Flag: "max-token-lifetime",
|
||||
Default: 24 * 30 * time.Hour,
|
||||
Name: "Max Token Lifetime",
|
||||
Usage: "The maximum lifetime duration users can specify when creating an API token.",
|
||||
Flag: "max-token-lifetime",
|
||||
// max time.Duration is 290 years
|
||||
Default: 290 * 365 * 24 * time.Hour,
|
||||
},
|
||||
Swagger: &codersdk.SwaggerConfig{
|
||||
Enable: &codersdk.DeploymentConfigField[bool]{
|
||||
|
2
cli/testdata/coder_server_--help.golden
vendored
2
cli/testdata/coder_server_--help.golden
vendored
@ -147,7 +147,7 @@ Flags:
|
||||
can specify when creating an API
|
||||
token.
|
||||
Consumes $CODER_MAX_TOKEN_LIFETIME
|
||||
(default 720h0m0s)
|
||||
(default 2540400h0m0s)
|
||||
--oauth2-github-allow-everyone Allow all logins, setting this
|
||||
option means allowed orgs and teams
|
||||
must be empty.
|
||||
|
Reference in New Issue
Block a user