Skip to content

Create Git Pipeline on Rafay in 3 easy steps

Rafay’s Kubernetes Operations Platform includes a GitOps service that enables infrastructure orchestration (Infra GitOps) and application deployment (App GitOps) through multi-stage, git-triggered pipelines. In this blog post, we will discuss setting up a simple pipeline to sync cluster configuration to a Git repo in 3 easy steps.

In this example, we will start with a brownfield cluster that we will import and convert to a ‘Rafay managed’ cluster. We will then initiate a ‘system sync’ operation to write back the cluster configuration to a specified Git repo.


Step 1: Create a GitOps Agent

We will first need to create a GitOps agent in a Docker instance or a Kubernetes cluster. This agent will enable secure connectivity to your repositories.

To create a GitOps agent, login to Rafay Console

  • Navigate to the GitOps section and select GitOps Agents.
  • Click on New Agent.
  • Fill in the form with appropriate values.


Step 2: Add Repository

To add the repository, login to Rafay Console

  • Navigate to the Integrations section.
  • Select Repositories and click on New Repository.
  • Fill in all the necessary details as shown in screenshot below ( don’t forget to select the agent created in step 1).



Step 3: Create Pipeline

  • Navigate to the GitOps section.
  • Select Pipelines and Click on New Pipeline.
  • Click on Add New Stage.
  • In the Action select System sync.
  • Fill in all the necessary details as shown in screenshot below ( don’t forget to select the repository created in step 2, in the Source Repository Section ).
  • Here we have selected cluster as included resource, user can appropriately select any other resource as required.


  • Click on Add Trigger and fill in the details as shown the screenshot below.


  • Add the Webhook url and Webhook Secret on the Github → Settings → Webhook section.


The Process of creating a Git pipeline is now complete. You can now trigger the Pipeline from Rafay, sync the cluster configuration and manage any cluster operations from then on through Git.

Blog Ideas

Sincere thanks to readers of our blog who spend time reading our product blogs. Please Contact the Rafay Product Team if you would like us to write about other topics.