summaryrefslogtreecommitdiff
path: root/lib/api/runner.rb
diff options
context:
space:
mode:
authorTomasz Maczukin <tomasz@maczukin.pl>2018-03-21 02:02:38 +0100
committerTomasz Maczukin <tomasz@maczukin.pl>2018-03-28 13:58:34 +0200
commit557c85a79f141e435c56d971d813f492978bad61 (patch)
treecfb6f2813bbdaaf270f8e9b5565c85af62e5a288 /lib/api/runner.rb
parent9ccde9cc1f1ccb70cc455686a5c7aed94adb8876 (diff)
downloadgitlab-ce-557c85a79f141e435c56d971d813f492978bad61.tar.gz
Use raw value of maximum_timeout for Runner registration API
Diffstat (limited to 'lib/api/runner.rb')
-rw-r--r--lib/api/runner.rb5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/api/runner.rb b/lib/api/runner.rb
index 95f57e6402d..57c0a729535 100644
--- a/lib/api/runner.rb
+++ b/lib/api/runner.rb
@@ -14,12 +14,11 @@ module API
optional :locked, type: Boolean, desc: 'Should Runner be locked for current project'
optional :run_untagged, type: Boolean, desc: 'Should Runner handle untagged jobs'
optional :tag_list, type: Array[String], desc: %q(List of Runner's tags)
- optional :maximum_timeout, type: String, desc: 'Maximum timeout set when this Runner will handle the job'
+ optional :maximum_timeout, type: Integer, desc: 'Maximum timeout set when this Runner will handle the job'
end
post '/' do
- attributes = attributes_for_keys([:description, :locked, :run_untagged, :tag_list])
+ attributes = attributes_for_keys([:description, :locked, :run_untagged, :tag_list, :maximum_timeout])
.merge(get_runner_details_from_request)
- .merge(maximum_timeout_human_readable: params[:maximum_timeout])
runner =
if runner_registration_token_valid?