...
This user guide will walk you through how to create and configure Salesforce CI/CD pipeline in Opsera
Table of Contents |
---|
Prerequisites for setting up the pipeline:
Below information are needed before setting up a pipeline,
...
3. Credentials of Source code Repository such as Gitlab/Github/Bitbucket
Steps to configure SFDC pipeline in Opsera
Login into the Opsera Portal (https://portal.opsera.io/) and sign in with your registered email.
Add SFDC Org to the Opsera portal
click on Tool Registry (found at the left panel of options as shown below)
...
7. Click Save. This will save the tool Configuration will be updated successfully and Salesforce org has been successfully added to Opsera portal.
...
Next - Create Source Code repository for your pipeline (Gitlab/github/bitbucket)
8. Click on Tool Registry on left navigation panel and click on ‘New Tool’.
...
25. Login to Jenkins to verify the integration of repository tool. Navigate to Jenkins and login, Click on Admin” from the right top corner and click on “Credentials” at the left list of options - to verify the Integration of repository tool with Jenkins.
...
Next, Creation of SFDC Jenkins jobs in Opsera Portal
(each one represents the SFDC Process such as Validate Package XML, Backup of an Org, Unit Test, Deploy to an Org)
...
Jobs have been created and configured and all ready for use. This is a one time configuration activity & can be used repeatedly for “n” number of pipelines.
Next, Creation of pipeline and its configuration.
31. On the Opsera portal, Click on Pipelines from the left navigation panel to open the catalog to create pipeline. Click on ‘Catalog’ Tab (found at the right top panel as shown below)
...
To give a meaningful name for the pipeline, On Summary tab, click on the little pencil icon (next to salesforce template name - to edit the name)
...
Create Package XML job & Configuration
34. Click on Workflow tab → A default step ‘Create Package Job’ will be available
...
SFDC process includes, ‘Create Package XML’, ‘Validate XML’, ‘Backup’, ‘Unit Test’ and ‘Deploy’ steps in pipeline, where each one can be used based upon the organization need and each can be plugged in/out based upon necessity.
Next add another Pipeline step configuration for Validate XML Step
38. Click on ‘Edit workflow’ option on the pipeline as shown below.
...
Next Pipeline Step Configuration - Backup → The entire SFDC Org components will be taken a backup and will be pushed to Git/Bitbucket Repository based upon the step configuration.
Next, Backup of an Org - Step to be Configured
47. Repeat the above for creating a New step for Backup to be added
...
52. As a token of verification, a ‘SFDC_Backup’ build job will be created in Jenkins which will have ‘Pipeline and Step ID’ suffix for unique identification.
...
Next Pipeline Step Configuration for Unit Test
(All the test classes will be executed for this step)
...
59. As a token of verification, a ‘SFDC_Unit Testing’ job will be created in Jenkins which will have ‘Pipeline and Step ID’ suffix for unique identification.
...
Next Pipeline Step Configuration for “ Deploy”
(Destination SFDC Org to be configured where the modified files created as part of ‘Create Package XML’ step will be deployed )
...
The necessary steps of SFDC Process has been configured successfully. Now the pipeline can be started / initiated to run.
Sample Pipeline Run / Execution
Sample pipeline run has been shown below to explain the process and its successful deployment on Git to SFDC Org.
...