Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

patch: Deploy to Heroku on PR merge #2299

Closed
wants to merge 1 commit into from

Conversation

vipulgupta2048
Copy link
Member

@vipulgupta2048 vipulgupta2048 commented May 25, 2022

This way we won't be deploying twice since like we are doing as mentioned belowL

  1. Once when the PR is merged and change is pushed to master
  2. When balena-ci pushes the new semver and changelog to master

Using: https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#running-your-workflow-when-a-pull-request-merges
FD: https://www.flowdock.com/app/rulemotion/resin-devops/threads/lRgvlRyPy6MLl4c5dsgI-vVbnEw

Signed-off-by: Vipul Gupta (@vipulgupta2048) vipul@balena.io


Please make sure to read the CONTRIBUTING document before opening the PR for relevant information on contributing to the documentation. Thanks!

Signed-off-by: Vipul Gupta (@vipulgupta2048) <vipul@balena.io>
# Deploys to Heroku once each day
schedule:
- cron: "0 0 * * *"

jobs:
build:
if_merged:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vipulgupta2048 , you may as well remove the cron schedule above if we're going to have this condition. This makes sure that only changes from merges are acted on.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree @cmfcruz Will close this out. Thanks for the review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants