Required Editions: Copado Essentials Plus
Your Salesforce production instance contains not only data but also metadata holding your organization’s code and configurations. Over time, metadata becomes a significant investment and represents years of your team’s development and customization effort. As important as it sounds, Salesforce does not provide an out of the box mechanism for backing up your metadata. This means that you risk loosing those years of development effort in the event that your org’s metadata is accidentally overwritten.
In this article, we’ll show you how to backup your org’s metadata in a few clicks using Copado Essentials Plus. The Copado Essentials Plus backup process does more than just dumping a zip archive in a storage. We commit your org’s metadata changes to a Git repository on a regular basis. As a result, what you get is not only a backup but also history tracking with incremental change monitoring.
How it works
We assume you already have a Git repository setup. If not, GitHub, GitLab, Bitbucket, Azure, and Copado Version Control are all supported.
First, in Copado Essentials Plus, add a new organization of type GitHub, GitLab, Bitbucket, Azure, or Copado Version Control, and proceed with authorization, like below:
Next, create a CI job in Copado Essentials Plus and specify the Source Org as your Salesforce production org and Target Org as your Git repository. You can then select a backup schedule that indicates how frequently the job will run, like below.
After defining your new job, navigate to the Deploy Options, and under "Advanced Options", click "Change", and select to "commit directly to the target branch".
Finally, go to the “Add Component” tab, select “Wildcard” component type and include all sub types in your backup, like below.
That is it. Now you can assure that your selected production metadata is backed up. You can also see history tracking as well as understand how your org metadata changes over time by viewing Git commit history in your chosen repository.
For more information about using Copado Essentials Plus CI Jobs, check out this article: Copado Essentials CI Jobs Overview.