Balena Integration to CI/CD

I am trying to deploy balena images through CI/CD. Currently, I have 4 fleets, and I have to build images for all 4 fleets which takes certain time to build and deploy. There are requirements where more fleets needs to be added. How can I effectively improve this step? I created 15 test fleets and tried to deploy through CI/CD. Since, it is taking too long time to build and deploy, the CI/CD times out.

Hello @jenish1231

Could you please share more details of the CI/CD? What do you use? Could you please share some logs?

Thanks!

Are you deploying in parallel?
We have 4 fleets and also had long deploys in the past. Now, the deploy takes now 6 to 12 minutes. But it probably depends on the number&size of your container images.

We use the Balena GitHub action and have multiple deploys in parallel from the same repository but with different docker files specific for the different fleets.
Works pretty well.

Thanks @maartenc and @spacetesla for sharing your experiences :slight_smile:

Could you share a few examples of how you’ve set this up before? We currently have this working, but only for a single fleet in production. We’d like to extend it across multiple environments and fleets

A GitHub Actions matrix like this can deploy to multiple fleets in parallel, just read the GitHub workflow syntax documentation if you need more matrices like environments.