debian-mirror-gitlab/lib/api/entities/ci/runner.rb

25 lines
754 B
Ruby
Raw Normal View History

2021-09-30 23:02:18 +05:30
# frozen_string_literal: true
module API
module Entities
module Ci
class Runner < Grape::Entity
expose :id
expose :description
expose :ip_address
2022-05-07 20:08:51 +05:30
expose :active # TODO Remove in %16.0 in favor of `paused` for REST calls, see https://gitlab.com/gitlab-org/gitlab/-/issues/351109
2022-04-04 11:22:00 +05:30
expose :paused do |runner|
!runner.active
end
2021-09-30 23:02:18 +05:30
expose :instance_type?, as: :is_shared
expose :runner_type
expose :name
expose :online?, as: :online
2021-12-11 22:18:48 +05:30
# DEPRECATED
2022-05-07 20:08:51 +05:30
# TODO Remove in %16.0 in favor of `status` for REST calls, see https://gitlab.com/gitlab-org/gitlab/-/issues/344648
2022-01-26 12:08:38 +05:30
expose :deprecated_rest_status, as: :status
2021-09-30 23:02:18 +05:30
end
end
end
end