Replies: 4 comments 1 reply
-
This solves your problem, but allows running two deployments in parallel. So the alternative is to just remove I don't have a proper solution, because I don't know gitlab, but I'll try it anyway :-) Technically the lock is a file created on the remote server, therefore if you kill the job the lock is not deleted. Solution 1: Don't kill the pipeline but have a job which kills the pipeline (and therefore runs |
Beta Was this translation helpful? Give feedback.
-
Maybe this? https://docs.gitlab.com/ee/ci/yaml/index.html#after_script |
Beta Was this translation helpful? Give feedback.
-
Since it doesn't happen often then I didn't modify my script (It shouldn't happen often) |
Beta Was this translation helpful? Give feedback.
-
I understand your Problem. I would love to have this myself. Did you try to: https://www.php.net/manual/en/function.register-shutdown-function.php register_shutdown_function(function() {
invoke("deploy:failed");
}); Or something alike - untested :-) |
Beta Was this translation helpful? Give feedback.
-
I am getting error :
Executing task deploy:lock
In lock.php line 19:
Deploy locked.
Execute "dep deploy:unlock sitename.com" to unlock.
This started happening after I canceled the deployment. (gitlab job)
I have multiple sites that are using this deployment script.
only the one (site) that got canceled started throwing this error.
I guess my only option is to make deployment with unlock as a first task ?
Beta Was this translation helpful? Give feedback.
All reactions