git-deliver icon indicating copy to clipboard operation
git-deliver copied to clipboard

Lock the remote during deliveries

Open arnoo opened this issue 12 years ago • 3 comments

A lock should be added to prevent simultaneous deliveries to the same server.

arnoo avatar Jul 31 '13 07:07 arnoo

I'm creating a file called "DEPLOYING" on a post-checkout script inside the DELIVERY_PATH and removing it on a post-symlink script.

Now how can I stop the deploy on a pre-delivery script if the remote file DEPLOYING exists?

thelinuxlich avatar Apr 28 '14 20:04 thelinuxlich

Something like this would do the trick inside a .remote.sh script :

[[ -f DEPLOYING ]] && exit 1

A script exiting with a non zero code stops the delivery.

On Mon, Apr 28, 2014 at 10:08 PM, Alisson Cavalcante Agiani < [email protected]> wrote:

I'm creating a file called "DEPLOYING" on a post-checkout script inside the DELIVERY_PATH and removing it on a post-symlink script.

Now how can I stop the deploy on a pre-delivery script if the remote file DEPLOYING exists?

— Reply to this email directly or view it on GitHubhttps://github.com/arnoo/git-deliver/issues/38#issuecomment-41606707 .

arnoo avatar Apr 28 '14 20:04 arnoo

solved it, thanks!

thelinuxlich avatar Apr 28 '14 20:04 thelinuxlich