Closed sunank200 closed 11 months ago
@pankajastro when setting up or editing the Cloudflare Pages project, we can specify the branch to deploy. However, I could not find a way for Cloudflare Pages to support deployments based only on tags directly from its UI.
So this is what we require: we can have release
branch for prod deployment and dev branch can be on main and non-prod branches. WDYT?
We have created a Slack app in a private account and tested this implementation and this app works fine.
Also, we have created a release branch for prod.
Steps to Implement:
Create distinct Cloud Build configuration files for production and development, named cloudbuild-prod.yaml and cloudbuild-dev.yaml respectively.
Configure GitHub triggers for tagged releases in both configurations, ensuring they correspond to their respective environments.
Implement conditional logic within each configuration file to determine whether a build and deployment should proceed based on branch and tag information.
Outcome:
Additional Context:
This change enhances deployment control and separates production and development workflows, improving overall project management.