Skip to main content

Configuring git follower mode

Omni’s git follower mode helps you centralize model development while keeping multiple environments in sync. By designating one model as the leader and others as followers, you can make changes in one model and easily apply them to other models.

This guide demonstrates how to set up follower mode for a development-to-production workflow, but you can also use these instructions for multi-region or multi-organization deployments.

Requirements

To follow the steps in this guide, you'll need:

  • In Omni:
    • Connection Admin permissions for the models you want to connect to git
    • Models with identical schemas, meaning that the schemas and tables powering the models have the same structure
  • In your git provider:
    • An existing git repository in GitHub, GitLab, or Azure DevOps
    • Permissions in your git provider that allow you to complete the following. Refer to the documentation for your git provider for information about their user permissions:
      • Add webhooks to repositories
      • Add deploy/SSH keys to repositories

1. Set up the leader

The first step is to set up the leader model. This is where you'll make direct changes to the model, such as adding topics, curating fields, and so on.

  1. In Omni, navigate to and open the model you want to use as the leader.
  2. Follow the steps in the git integration guide to connect the model to the git repository.
  3. After you finish setting up the repository, configure the following Omni git settings:
    • Base branch - Enter the name of the git branch Omni should use for pull requests. Omni recommends you use the default branch, which is typically main.
    • Source model name - Enter the path to the model files in the repository. For example, if you entered blobs_r_us, Omni will look for model files in a /blobs_r_us folder in the repository.

2. Set up the follower

The next step is to set up the follower model. This is a read-only model that will absorb changes from the leader.

  1. In Omni, navigate to and open the model you want to use as the follower.
  2. Follow the steps in the git integration guide to connect the model to the same git repository you used to set up the leader. This includes adding a second deploy key and webhook.
  3. In the git repository, create a new branch to use as the Omni base branch. In our dev to prod example, we'll name the branch prod.
  4. After you finish setting up the repository, configure the following Omni git settings:
    • Base branch - Enter the name of the branch you created in step 3. For example, prod.
    • Always create branches - Enable this setting, which will ensure that Omni detects and applies changes merged to the Base branch.
    • Git follower mode - Enable this setting, which will designate the model as a follower.
    • Source model name - Enter the path to the model files in the repository. The value of this setting must match the value for the leader.

3. Verify settings configuration

Before you test out the setup, take a moment to verify the setting configuration for both the leader and follower.

In our dev to prod example, the settings for the leader and follower look like this:

Loading data...

4. Test the setup

Use the following steps to perform an end-to-end test of your setup. If successful, this is also the workflow Omni recommends using for model development and deployment.

Part 1: Leader

  1. In Omni:
    1. Open a branch against the leader model. In our dev to prod example, this model would be named dev.
    2. Make a change to the model.
    3. When finished, click Create pull request in the branch header. This will prompt you to create a pull request against the main branch in the git repository.
  2. In the git repository: Merge the pull request, which will merge the branch into the repository's main branch.
  3. In Omni: Verify that the changes you merged are available in the leader (dev) model.

Part 2: Follower

  1. In Omni: Perform a schema refresh on the follower model. This step is required to ensure that the follower's schema model matches the schema model of the leader.
  2. In the git repository:
    1. Create a new branch off of the main branch. Omni recommends using a name like release-to-prod-YYYYMMDD, where YYYYMMDD is a date. For example, release-to-prod-20250901

    2. Create a pull request that will merge the release-to-prod-YYYYMMDD branch into the follower's base branch. In our dev to prod example, the follower's base branch would be prod.

      If you enabled the Always create branches setting in Omni, this should create a branch in Omni with the same name.

  3. In Omni:
    1. Navigate to the follower model and open the model IDE.
    2. Open the release-to-prod-YYYYMMDD branch.
    3. Test the changes, including checking the Content Validator for issues.
  4. In the git repository: Merge the pull request, which will merge the branch into the repository's prod branch.
  5. In Omni: After the pull request is merged, confirm that the changes are present in the follower model.

What's next?

Now that you've set up follower mode, check out the git follower mode best practices to learn how to best develop your models.