How to not deploy after time of day or certain day?

Is it possible to limit "when" a deployment gets executed?

E.g. we have plans that get triggered by Pull Requests. They get deployed to either staging or production, depending on the branch that was merged (develop/master). 

The plan to staging (develop branch) can deploy whenever merges happen, as it is the staging, and meh. 

To production I want to limit deployments by time and day. No deployments to production (master branch) should be done on Friday/Saturday/Sunday and other days no deployments should be done after 15:00 or before 08:30.

The effect I want to achieve is that if a merge is done to master that it should be queued for the first allowed day after the allowed time. 

E.g. A merge done to the master branch should be queued for Monday 08:30 or when an agent is available.

1 answer

0 vote

Unfortunately scheduled deployments are not available yet, though in increasingly high demand - please watch and vote for the following related issues to guide Atlassian's roadmap in this regard:

Hi, that is very unfortunate indeed.

However, issue BAM-13517, would that not already be possible if you use a Release branch and/or tags combined with scheduling via the cronjob option? You'd then allow the deployment only on a new Tag (instead of a merge of a Pull Request for example). It would check & deploy this at the cronjob's' scheduled time.

BAM-13819 Would indeed also be nice. 

Next to that would be my issue. I would like deployments to happen as work is approved via merge of Pull Request, but only within the 08:30 to 15:00 window, Monday to Thursday. If Merges happen outside that window, then they would need to be queued for the next available window. 

There are certainly a couple of alternatives and/or workarounds, though most seem to come with their own constraints in turn, see for example:

The latter specifically mentions a trigger that's based on a tag, and then refers to another issue, though I do not fully understand how this would cover a tag based trigger:

Either way, right now we seem to be stuck with working around the status quo one way or another ...

 

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published May 18, 2017 in Bamboo

FAQ: How to Upgrade Bamboo Server

Bamboo 5.9 will no longer be supported after June 12, 2017. What does this mean? As part of our End of Life policy, Atlassian supports major versions for two years after the first major iteratio...

1,783 views 0 6
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you