diff options
Diffstat (limited to 'app/workers/build_success_worker.rb')
-rw-r--r-- | app/workers/build_success_worker.rb | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/app/workers/build_success_worker.rb b/app/workers/build_success_worker.rb index c17608f7378..f3530317090 100644 --- a/app/workers/build_success_worker.rb +++ b/app/workers/build_success_worker.rb @@ -16,7 +16,14 @@ class BuildSuccessWorker private + ## + # Deprecated: + # As of 11.5, we started creating a deployment record when ci_builds record is created. + # Therefore we no longer need to create a deployment, after a build succeeded. + # We're leaving this code for the transition period, but we can remove this code in 11.6. def create_deployment(build) - CreateDeploymentService.new(build).execute + build.create_deployment.try do |deployment| + deployment.succeed + end end end |