DevOps Pipeline for the React Native iOS App

Atul Yadav

2 min read

June 21, 2024

This article covers Understanding how to build a CI & CD pipeline for React Native apps like iOS.

There are many tools that support the CI & CD operations for the apps. Fastlane, Jenkins, Drone Circle CI, Travis and many more. In order to build and deploy the app, Solution Architect needs to gather the information based on the customer discussions and later put on the papers to start working on the interim pipeline.

In this case, I will talk about the tools which can be used for iOS apps.

  1. Fastlane: Fastlane is a tool for iOS and Android developers to automate tedious tasks like generating screenshots, dealing with provisioning profiles, and releasing your application. Fastlane works on the lane concept, each stage is known as lane and the user can define its tasks under lane. Fastlane has a list of the toolchain to work like magic,

Diagram for the pipeline flow

Different steps for iOS react native apps in Devops Pipeline

Here Gym, Scan, Snapshot are the toolchains or alias of Fastlane. Xcode is a tool that is used to build the ios application. The Gym starts the build using the Xcode tool. Please note that iOS apps can only be built through Xcode which is proprietary of Apple.

In the above diagram, the Developer pushes the code to Git Hub which triggers the DevOps pipeline. Fastlane has “fastfile” which like Jenkinsfile or any other instruction file with the set of instructions that trigger different lanes. The first step is to build, Archive and generate the IPA. IPA is nothing but the final application which will be uploaded to Test Flight / Apperian or Hockey App for the beta testing. Once the IPA is created unit tests are done using scan followed by sonarqube, snapshot and security testing. Tools can vary depending upon the business requirement and compliance. Once all the steps are completed then its time to upload the app for QA testing. There are many stores available where the app can be uploaded like a hockey App, Apperian, Test flight, etc.

Fastlane is used to perform all these steps in the order defined by the DevOps Engineer.

Thanks for reading, please clap n number of times and share it.