remind101 / slashdeploy

GitHub Deployments for Slack
https://slashdeploy.io
BSD 2-Clause "Simplified" License
153 stars 20 forks source link

Add feature to automatically lock an environment when deploying a topic branch #89

Closed ejholmes closed 7 years ago

ejholmes commented 7 years ago

I think some behavior like this would be pretty slick. Let's say you configure the default branch for "staging" as master.

If I deploy a topic branch to staging (anything that's not master), then it should automatically lock (or send me a DM with some message buttons asking me if I want to lock it).

When I'm done, I can just deploy the master branch again, and SlashDeploy sends me a DM asking me if I want to unlock it.

I think something along the lines of this can help ensure that people lock when they need to, and don't forget to unlock.

bmarini commented 7 years ago

I think that's exactly the right behavior. It even makes sense with production too.

phobologic commented 7 years ago

What happens when someone forgets to re-deploy master or unlock the environment? Any ideas on safe guards there? Seems especially important in prod, though maybe this is very rare in prod, so won't matter.

bmarini commented 7 years ago

If we got notified when auto deploys failed because the environment was locked, I think that'd be enough. That already happens to us now sometimes, when we lock prod on an app.

bmarini commented 7 years ago

In staging, I can think of several (bad) ideas; they all sound like too much work and too specific to our workflows.

ejholmes commented 7 years ago

Ok awesome, I'll try to tackle this sometime soon. Should be pretty straight forward.

ejholmes commented 7 years ago

Done in https://github.com/remind101/slashdeploy/pull/90