Skip to content

Commit

Permalink
allow “projects_url” only in serverless, set default in the config
Browse files Browse the repository at this point in the history
  • Loading branch information
Dosant committed Aug 7, 2023
1 parent bd6e7e1 commit eebd9fb
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
1 change: 0 additions & 1 deletion config/serverless.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ xpack.fleet.internal.activeAgentsSoftLimit: 25000

# Cloud links
xpack.cloud.base_url: "https://cloud.elastic.co"
xpack.cloud.projects_url: "/projects/"

# Enable ZDT migration algorithm
migrations.algorithm: zdt
Expand Down
7 changes: 6 additions & 1 deletion x-pack/plugins/cloud/server/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,12 @@ const configSchema = schema.object({
users_and_roles_url: schema.maybe(schema.string()),
organization_url: schema.maybe(schema.string()),
profile_url: schema.maybe(schema.string()),
projects_url: schema.maybe(schema.string()),
projects_url: schema.conditional(
schema.contextRef('serverless'),
true,
schema.string({ defaultValue: '/projects' }),
schema.never()
),
trial_end_date: schema.maybe(schema.string()),
is_elastic_staff_owned: schema.maybe(schema.boolean()),
serverless: schema.maybe(
Expand Down

0 comments on commit eebd9fb

Please sign in to comment.