Closed vito closed 6 years ago
Ahoy there!
I like the idea. I'm trying to reason about what the "expected" behavior would be for dealing with the lock itself.
1) Wait on the lock to release, then do the put
action.
2) Attach to the running task and use that as the indicator for success or failure.
I believe the first option makes more sense, but I want to confirm this jives with what you were thinking.
Yeah I like the first approach the most. Identifying which task to attach to and confirming it's doing the same thing the step's about to do seems like too much work.
The first approach is nice because it just has to wait for any locks to release, and then it'll do its thing, which might end up just being a no-op but re-running it will still provide peace of mind.
Awesome!
Currently
put
can fail if it can't get the deployment lock. I think it'd be pretty nice if it would wait on the lock (maybe and deploy after it's released. This would prevent spurious errors and also make it so Concourse can deploy over itself.This could be done with the new
bosh locks
command, finding the one for the deployment, and usingbosh task
to attach to it (or just wait for the lock to go away).