GitLab CI/CD OverView
Last updated
Last updated
Adding a CI/CD capability into a project repository requires connecting a workflow yml
script created and managed in GitLab with the iCR server offering the analysis. It is assumed that there is a DevOps engineer, or someone with equivalent skill, who is already familiar with GitLab CI/CD and who will prepare iCR for integration into GitLab. The diagram below will be used as the reference for the steps.
Step 1. GitLab CI/CD employs a framework where customizable functionality can be easily added and controlled. A yml
script is added to any repository where CI/CD automation is requested. iCR is invoked by executing an OpenRefactory supplied Docker container that is named in the yml
script. The image
tag defines the name of the iCR container. You may want to view the sample yml
script in the Configuring the GitLab Script variables section. The script determines the manner in which iCR will be triggered. The script provides the iCR server with necessary details about the project. GitLab CI/CD environment variables and user supplied variables provide iCR with the necessary values to select the correct branch and authenticate with GitLab.
Step 2. When the trigger specified in the yml
occurs, the script is executed. The Navigator will be requested to start an analysis using information provided from the script variables.
Step 3. The Navigator uses the information in the variables to determine the specific branch to be analyzed from this repository. The Navigator will automatically fetch the source code of the configured repository in GitLab and initiate an analysis.
Step 4. Once the analysis completes, the user is notified via an email message. The email is sent to the address defined by the OR_MAIL_ADDRESS. This email address MUST be provided so that iCR has a way of not only signaling completion, but also a way of communicating any errors that may have occurred.
Step 5. Once notified that analysis is complete and that results are available, the user may login directly to the iCR server which ran the analysis. From that login, the user can enter the Reviewer to process results in exactly the same manner as described in the Reviewing Your Results.