Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app/graphql/types/environment_type.rb')
-rw-r--r--app/graphql/types/environment_type.rb8
1 files changed, 7 insertions, 1 deletions
diff --git a/app/graphql/types/environment_type.rb b/app/graphql/types/environment_type.rb
index 239b26f9c38..e4631a4a903 100644
--- a/app/graphql/types/environment_type.rb
+++ b/app/graphql/types/environment_type.rb
@@ -5,6 +5,8 @@ module Types
graphql_name 'Environment'
description 'Describes where code is deployed for a project'
+ present_using ::EnvironmentPresenter
+
authorize :read_environment
field :name, GraphQL::STRING_TYPE, null: false,
@@ -16,6 +18,10 @@ module Types
field :state, GraphQL::STRING_TYPE, null: false,
description: 'State of the environment, for example: available/stopped'
+ field :path, GraphQL::STRING_TYPE, null: true,
+ description: 'The path to the environment. Will always return null ' \
+ 'if `expose_environment_path_in_alert_details` feature flag is disabled'
+
field :metrics_dashboard, Types::Metrics::DashboardType, null: true,
description: 'Metrics dashboard schema for the environment',
resolver: Resolvers::Metrics::DashboardResolver
@@ -23,6 +29,6 @@ module Types
field :latest_opened_most_severe_alert,
Types::AlertManagement::AlertType,
null: true,
- description: 'The most severe open alert for the environment. If multiple alerts have equal severity, the most recent is returned.'
+ description: 'The most severe open alert for the environment. If multiple alerts have equal severity, the most recent is returned'
end
end