Yandex Cloud
Search
Contact UsGet started
  • Blog
  • Pricing
  • Documentation
  • All Services
  • System Status
    • Featured
    • Infrastructure & Network
    • Data Platform
    • Containers
    • Developer tools
    • Serverless
    • Security
    • Monitoring & Resources
    • ML & AI
    • Business tools
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Customer Stories
    • Cloud credits to scale your IT product
    • Gateway to Russia
    • Cloud for Startups
    • Education and Science
    • Yandex Cloud Partner program
  • Blog
  • Pricing
  • Documentation
© 2025 Direct Cursus Technology L.L.C.
Yandex Managed Service for Kubernetes
  • Comparison with other Yandex Cloud services
  • Getting started
    • All guides
    • Connecting to a node over SSH
    • Connecting to a node via OS Login
    • Updating Kubernetes
    • Configuring autoscaling
      • Getting started with Cloud Marketplace
      • Installing Argo CD
      • Installing Chaos Mesh
      • Installing cert-manager with the Cloud DNS ACME webhook plugin
      • Installing Container Storage Interface for S3
      • Installing Crossplane
      • Installing External Secrets Operator
      • Installing ExternalDNS with a plugin for Cloud DNS
      • Installing Falco
      • Installing Filebeat OSS
      • Installing Fluent Bit
      • Installing Gatekeeper
      • Installing Gateway API
      • Installing the GitLab Agent
      • Installing GitLab Runner
      • Installing HashiCorp Vault
      • Installing Ingress NGINX
      • Installing the Application Load Balancer Ingress controller
      • Upgrading the Application Load Balancer Ingress controller
      • Installing Istio
      • Installing Jaeger
      • Installing Kruise
      • Installing Kyverno & Kyverno Policies
      • Installing Loki
      • Installing Metrics Provider
      • Installing NodeLocal DNS
      • Installing Policy Reporter
      • Installing Prometheus Operator
      • Installing Thumbor
      • Installing Velero
    • Connecting external nodes to the cluster
  • Access management
  • Pricing policy
  • Terraform reference
  • Monitoring metrics
  • Audit Trails events
  • Release notes

In this article:

  • Getting started
  • Installation using Yandex Cloud Marketplace
  • Installation using a Helm chart
  • Use cases
  • See also
  1. Step-by-step guides
  2. Installing apps from Cloud Marketplace
  3. Installing the GitLab Agent

Installing the GitLab Agent

Written by
Yandex Cloud
Improved by
Dmitry A.
Updated at May 5, 2025
  • Getting started
  • Installation using Yandex Cloud Marketplace
  • Installation using a Helm chart
  • Use cases
  • See also

The GitLab Agent is used to connect a Managed Service for Kubernetes cluster to GitLab. You can deploy the application in a Yandex Managed Service for GitLab instance or in a standalone GitLab instance.

The GitLab Agent enables you to:

  • Work with Managed Service for Kubernetes clusters behind NAT.
  • Get real-time access to the Managed Service for Kubernetes cluster API.
  • Receive information about events in a Managed Service for Kubernetes cluster.
  • Activate the cache of Kubernetes objects, which are updated with very low latency.

Note

The GitLab Agent does not execute CI/CD pipelines. To do this, install GitLab Runner.

Getting startedGetting started

  1. If you do not have the Yandex Cloud CLI yet, install and initialize it.

    The folder specified when creating the CLI profile is used by default. To change the default folder, use the yc config set folder-id <folder_ID> command. You can specify a different folder using the --folder-name or --folder-id parameter.

  2. Make sure that the security groups for the Managed Service for Kubernetes cluster and its node groups are configured correctly. If any rule is missing, add it.

    Warning

    The configuration of security groups determines the performance and availability of the cluster and the services and applications running in it.

  3. Prepare for GitLab Agent installation:

    1. Create a Managed Service for GitLab instance or a standalone instance.
    2. Create an agent configuration file in the repository:
      1. Open your GitLab instance and go to your project.
      2. In the main branch, create a new folder named .gitlab/agents/<GitLab_agent_name>.
      3. In the <GitLab_agent_name> folder, create an empty file named config.yaml.
    3. Register the agent in GitLab and get an access token:
      1. Open your GitLab instance and go to your project.
      2. Select Operate on the left-hand panel, and then select Kubernetes clusters from the drop-down menu.
      3. Click Connect a cluster and select the agent name: <GitLab_agent_name>.
      4. Click Register.
      5. GitLab will create a token required to install the application. Store the token in a secure place.

    Note

    For more information about setting up and registering an agent, see the GitLab documentation.

Installation using Yandex Cloud MarketplaceInstallation using Yandex Cloud Marketplace

  1. Navigate to the folder dashboard and select Managed Service for Kubernetes.
  2. Click the name of the Managed Service for Kubernetes cluster you need and select the Marketplace tab.
  3. Under Application available for installation, select GitLab Agent and click Go to install.
  4. Configure the application:
    • Namespace: Create a new namespace, e.g., gitlab-agent-space. If you leave the default namespace, GitLab Agent may work incorrectly.
    • Application name: Specify the app name, e.g., gitlab-agent.
    • GitLab domain name: Enter the name of your GitLab domain, e.g., gitlab-test.gitlab.yandexcloud.net.
    • Agent access token: Paste the GitLab access token you received earlier into this field.
  5. Click Install.
  6. Wait for the application status to change to Deployed.
  7. Open your GitLab instance and go to Infrastucture → Kubernetes clusters. Make sure the agent status changed to Connected.

Installation using a Helm chartInstallation using a Helm chart

  1. Install Helm v3.8.0 or higher.

  2. Install kubect and configure it to work with the new cluster.

  3. To install a Helm chart with the GitLab Agent, run the following command:

    helm pull oci://cr.yandex/yc-marketplace/yandex-cloud/gitlab-org/gitlab-agent/chart/gitlab-agent \
      --version 1.16.0-1 \
      --untar && \
    helm upgrade --install \
      --namespace <namespace> \
      --create-namespace \
      --set config.kasAddress='wss://<your_GitLab_domain_name>/-/kubernetes-agent/' \
      --set config.token='<GitLab_access_token>' \
      gitlab-agent ./gitlab-agent/
    

    This command also creates a new namespace required for the application.

    If you set namespace to the default namespace, GitLab Agent may work incorrectly. We recommend you to specify a value different from all existing namespaces (e.g., gitlab-agent-space).

    Note

    If you are using a Helm version below 3.8.0, append the export HELM_EXPERIMENTAL_OCI=1 && \ string to the command to enable Open Container Initiative (OCI) support in the Helm client.

  4. Make sure the GitLab Agent pod status changed to Running:

    kubectl get pods --namespace gitlab-agent
    
  5. Open your GitLab instance and go to Infrastucture → Kubernetes clusters. Make sure the agent status changed to Connected.

Use casesUse cases

  • Continuous deployment of containerized applications using GitLab.

See alsoSee also

  • GitLab Agent documentation.
  • Managed Service for GitLab documentation.

Was the article helpful?

Previous
Installing Gateway API
Next
Installing GitLab Runner
© 2025 Direct Cursus Technology L.L.C.