diff options
Diffstat (limited to 'app/graphql/types/ci')
-rw-r--r-- | app/graphql/types/ci/ci_cd_setting_type.rb | 3 | ||||
-rw-r--r-- | app/graphql/types/ci/runner_sort_enum.rb | 4 | ||||
-rw-r--r-- | app/graphql/types/ci/runner_type.rb | 2 | ||||
-rw-r--r-- | app/graphql/types/ci/runner_type_enum.rb | 8 |
4 files changed, 12 insertions, 5 deletions
diff --git a/app/graphql/types/ci/ci_cd_setting_type.rb b/app/graphql/types/ci/ci_cd_setting_type.rb index b34a91446a2..f90c75454ba 100644 --- a/app/graphql/types/ci/ci_cd_setting_type.rb +++ b/app/graphql/types/ci/ci_cd_setting_type.rb @@ -16,6 +16,9 @@ module Types field :keep_latest_artifact, GraphQL::BOOLEAN_TYPE, null: true, description: 'Whether to keep the latest builds artifacts.', method: :keep_latest_artifacts_available? + field :job_token_scope_enabled, GraphQL::BOOLEAN_TYPE, null: true, + description: 'Indicates CI job tokens generated in this project have restricted access to resources.', + method: :job_token_scope_enabled? field :project, Types::ProjectType, null: true, description: 'Project the CI/CD settings belong to.' end diff --git a/app/graphql/types/ci/runner_sort_enum.rb b/app/graphql/types/ci/runner_sort_enum.rb index 550e870316a..95ec1867fea 100644 --- a/app/graphql/types/ci/runner_sort_enum.rb +++ b/app/graphql/types/ci/runner_sort_enum.rb @@ -7,7 +7,9 @@ module Types description 'Values for sorting runners' value 'CONTACTED_ASC', 'Ordered by contacted_at in ascending order.', value: :contacted_asc - value 'CREATED_DESC', 'Ordered by created_date in descending order.', value: :created_date + value 'CONTACTED_DESC', 'Ordered by contacted_at in descending order.', value: :contacted_desc + value 'CREATED_ASC', 'Ordered by created_at in ascending order.', value: :created_at_asc + value 'CREATED_DESC', 'Ordered by created_at in descending order.', value: :created_at_desc end end end diff --git a/app/graphql/types/ci/runner_type.rb b/app/graphql/types/ci/runner_type.rb index 3abed7289d5..837d91ef765 100644 --- a/app/graphql/types/ci/runner_type.rb +++ b/app/graphql/types/ci/runner_type.rb @@ -40,3 +40,5 @@ module Types end end end + +Types::Ci::RunnerType.prepend_mod_with('Types::Ci::RunnerType') diff --git a/app/graphql/types/ci/runner_type_enum.rb b/app/graphql/types/ci/runner_type_enum.rb index f771635f4ed..12e87906179 100644 --- a/app/graphql/types/ci/runner_type_enum.rb +++ b/app/graphql/types/ci/runner_type_enum.rb @@ -5,10 +5,10 @@ module Types class RunnerTypeEnum < BaseEnum graphql_name 'CiRunnerType' - ::Ci::Runner.runner_types.keys.each do |type| - value type.upcase, - description: "A runner that is #{type.tr('_', ' ')}.", - value: type + ::Ci::Runner::AVAILABLE_TYPES.each do |runner_type| + value runner_type.upcase, + description: "A runner that is #{runner_type.tr('_', ' ')}.", + value: runner_type end end end |