2018-07-16 12:31:01 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2017-01-20 08:57:01 -05:00
|
|
|
module Ci
|
|
|
|
class UpdateRunnerService
|
|
|
|
attr_reader :runner
|
|
|
|
|
|
|
|
def initialize(runner)
|
|
|
|
@runner = runner
|
|
|
|
end
|
|
|
|
|
|
|
|
def update(params)
|
2017-02-06 14:05:19 -05:00
|
|
|
runner.update(params).tap do |updated|
|
|
|
|
runner.tick_runner_queue if updated
|
2017-01-20 08:57:01 -05:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|