gitlab-org--gitlab-foss/app/services/ci/create_trace_artifact_service.rb
2018-02-06 15:50:08 +09:00

16 lines
352 B
Ruby

module Ci
class CreateTraceArtifactService < BaseService
def execute(job)
return if job.job_artifacts_trace
job.trace.read do |stream|
if stream.file?
job.create_job_artifacts_trace!(
project: job.project,
file_type: :trace,
file: stream)
end
end
end
end
end