Expert Insights Technology

Mobile DevOps with Gitlab and VS AppCenter

Significance and Background

Because of the specific obstacles that mobile development poses for DevOps, not all organizations that employ DevOps use it for mobile apps. 

Before DevOps, developers had to create a lot of code, build and install the app, and then submit it to a tester to test it. This cycle took a lot of time and effort. By following the DevOps method, tasks are evenly allocated across the many teams, with a common aim and clear visibility of app performance. Adopting DevOps can provide a slew of advantages, including: 

Delivery of content software 

• Bug fixes and problems are resolved more quickly. 

• Improvised support and flexibility 

• Fewer chances of product failure 

• Increase inefficiency 

• Stable environment for easy deployments 

• Extra time for a new feature 

Idea – Challenge – Action

Several roadblocks arise during the creation of a mobile application. Let’s look at the key elements to consider while implementing DevOps in mobile app development. 

Continuous Integration and Delivery — Developers should write code that can easily be combined with the code of other teams. In order to guarantee continuous integration and delivery, the development team must also ensure that all tools, including scripts, configuration, and documents, are maintained transparent. 

Testing and monitoring – When developing a mobile application, it is critical to test it in a real-world environment that includes a variety of factors such as screen size, features, capabilities, and different devices. Continuous testing and monitoring should be used to work on frequent builds, detect bugs, and eliminate all issues at an early stage. 

For the initiative, we used a specific set of tools. Gitlab is the tool used for code management and CI/CD. Gitlab Runner will perform unit testing, trigger the build on VS Appcenter, and VS App Center will handle the build, sign the build, and send the app to testers for testing, as well as monitor app activities 

GitLab CI/CD:

Step 1: Define your triggers. 

The code below ensures that the pipeline is only triggered on pushes to the master branch and tagged. The benefit of having several triggers is that you may send builds prompted by a push to the beta testers group while sending builds triggered by a tag to the public group. 

only-push: &only-push 
   - pushes 
   - /^dha_+.*$/ 
   - /^release_+.*$/ 
   - merge_requests 
    - main 

Step 2: Define variables 

We will use a variables segment to make it smooth for different builders to replace the pipeline withinside the future. 

Step 3: Configure the environment You must first install Appcenter CLI and configure some environment variables before you can build and deploy the application. It is recommended to use the node-alpine image for the pipeline to reduce container loading time on gitlab runner. 

Step 4: Build & distribute 

You must login to Appcenter by using `appcenter login` before you can build and distribute the app on it. 

stage: build 
   - appcenter login --token $APPCENTER_API_TOKEN 
    - appcenter build queue --app "dhademo/flutter-android" --branch $CI_MERGE_REQUEST_SOURCE_BRANCH_NAME --token $APPCENTER_API_TOKEN 

The build will need some build scripts for each os type. You can find it from GitHub: microsoft/appcenter 

After that connect Appcenter with your repository and configure the build based on your requirement. 

Setup Environment during build if required, for Android you need Keystore to sign the app 

For iOS, you need a mobile provision file and p12 key. 

And configure the distribution to send the app to your team and tester. 


By using GitlabCI and App Center you can easily set up a continuous delivery pipeline for your mobile project. 

You can additionally monitor the health of a mobile app with App Center by integrating appcenter SDK to your application. 


VS AppCenter combines the lifecycle, monitoring, and backend options of Microsoft’s existing stack into one platform. Nowadays, once quality is a lot of necessary than ever, VS AppCenter provides a sturdy crash-reporting answer analytics platform, sanctioning you to watch the behavior and happiness of the customers. Moreover, VS AppCenter is modular, which supplies you the flexibleness to use solely the tools you wish and zip more.