# Adding Deployment Keys to CI/CD Services

This article describes how to activate your KendoReact [license](https://www.telerik.com/kendo-react-ui-develop/components/my-license) in popular CI/CD services. Use [Deployment Keys](https://www.telerik.com/account/downloads/deployment-keys) for build pipelines and provide the key through an environment variable or a secure file.

Deployment keys are dedicated license keys for build pipelines. Each deployment key is tied to one application and its selected products. You cannot use deployment keys for application development.

> Developer license keys remain valid for CI/CD deployments, so existing pipelines do not need to be updated. For new pipelines, we recommend using deployment keys. For more information, see [the differences between developer license keys and deployment keys](https://www.telerik.com/kendo-react-ui-develop/components/my-license/faq#what-is-the-difference-between-developer-license-keys-and-deployment-keys).

To activate your license in a CI/CD environment:

1. Go to the [Deployment Keys](https://www.telerik.com/account/downloads/deployment-keys) page.
2. Click **Add Application**. In the form that opens:
   * Add the application name.
   * Select the type of application—public or private.
   * Select the set of products used in the application.
3. Copy the deployment key and store it securely.
4. [Create an environment variable](https://www.telerik.com/kendo-react-ui-develop/components/my-license/ci-services#creating-an-environment-variable) named `TELERIK_LICENSE`, and set it to the deployment key value. Alternatively, store the key in a `telerik-license.txt` file, for example, through the [Azure Secure Files approach](https://www.telerik.com/kendo-react-ui-develop/components/my-license/ci-services#using-secure-files-on-azure-devops).

The following general requirements apply to all CI/CD environments:

* Regardless of the CI/CD tool you use, the step that installs the project dependencies must be executed before the step that activates the license.
* The license activation step requires the `@progress/kendo-licensing` package to be downloaded and set up in your local environment or CI/CD pipeline.
* Store the deployment key securely in an environment variable, a secret, or a secure file. Never hardcode a key in the build script.
* The CI pipeline configurations are not executable. They merely outline the specific sequence of steps.

> For a runnable demo with setup pipelines for all CI services, refer to the [DevOps - Pipeline and Workflow](https://github.com/LanceMcCarthy/DevOpsExamples/tree/main) GitHub repository.

## Creating an Environment Variable

Set `TELERIK_LICENSE` to your deployment key. Each platform has a different process for setting environment variables. The following examples cover popular CI/CD services.

> Starting with the 2025 Q1 release, the name of the environment variable changes from `KENDO_UI_LICENSE` to `TELERIK_LICENSE` and the downloaded file changes from `kendo-ui-license.txt` to `telerik-license.txt`. This change is required as all Telerik UI and Kendo UI products now use the same licensing mechanism with a common license key. Existing pipelines can continue to use the legacy names. See the [Handling License Key File Name and Environment Variable Name Changes in the 2025 Q1 Release](https://www.telerik.com/kendo-react-ui-develop/components/knowledge-base/docs/knowledge-base/handling-license-key-file-and-env-variable-changes-2025) knowledge base article for more details.

### GitHub Actions

1. Create a new [Repository Secret](https://docs.github.com/en/actions/how-tos/write-workflows/choose-what-workflows-do/use-secrets#creating-secrets-for-a-repository) or an [Organization Secret](https://docs.github.com/en/actions/how-tos/write-workflows/choose-what-workflows-do/use-secrets#creating-secrets-for-an-organization). Set the secret name to `TELERIK_LICENSE` and paste the deployment key as its value.
2. After running `npm install` or `yarn`, add a build step to activate the license.

```yaml
steps:
    # ... install modules before activating the license
    - name: Install NPM modules
      run: npm install

    - name: Activate Kendo UI License
      # Set working directory if the application is not in the repository root folder:
      # working-directory: 'ClientApp'
      run: npx kendo-ui-license activate
      env:
          TELERIK_LICENSE: ${{ secrets.TELERIK_LICENSE }}

    # ... run application build after license activation
    - name: Build Application
      run: npm run build
```

### GitLab CI/CD Pipelines

1. Go to **Settings > CI/CD > Variables** in your GitLab project.
2. Add a new `TELERIK_LICENSE` [CI/CD variable](https://docs.gitlab.com/ci/variables/). Paste the deployment key as its value, and mask the variable.
3. After running `npm install` or `yarn`, add a build step to activate the license.

```yaml
build:
    stage: build
    script:
        # ... Install modules before activating the license.
        - npm install
        - npx kendo-ui-license activate
        # ... Run the application build after license activation.
        - npm run build
```

### Vercel

1. In your Vercel project, go to **Settings > Environment Variables**.

2. Add `TELERIK_LICENSE` and use the deployment key as its value. For details, see [Vercel environment variables](https://vercel.com/docs/environment-variables).

   The following screenshot shows the supported legacy `KENDO_UI_LICENSE` name. Use the recommended `TELERIK_LICENSE` name for new configurations.

   ![Vercel - add deployment key environment variable](https://www.telerik.com/kendo-react-ui-develop/components/assets/b86e02ab6fdb673bb4e97f74314981b1/vercel-env-variable.png)

3. Under **Settings > Build and Deployment**, override the **Install Command** with `npm install && npx kendo-ui-license activate`.

   ![Vercel license activation in project settings](https://www.telerik.com/kendo-react-ui-develop/components/assets/07759c4b11dd55ed289e67eb9a895fce/vercel-install-command.png)

The next deployment activates the license for the KendoReact components in your project. The components no longer show a watermark or a license warning in the console.

### Azure Pipelines (YAML)

1. Create a new [Secret Variable](https://learn.microsoft.com/en-us/azure/devops/pipelines/process/set-secret-variables?view=azure-devops\&tabs=yaml%2Cbash#use-a-secret-variable-in-the-ui) named `TELERIK_LICENSE`.
2. Paste the deployment key as its value.
3. Add a build step that runs `npx kendo-ui-license activate` or `yarn run kendo-ui-license activate` after installing the project dependencies.

The following examples show the syntax for Windows and Linux build agents.

```yaml Windows build agents
pool:
    vmImage: 'windows-latest'

steps:
    # ... install modules before activating the license
    - script: call npm install
      displayName: 'Install NPM modules'

    - script: call npx kendo-ui-license activate
      displayName: 'Activate Kendo UI License'
      # Set working directory if the application is not in the repository root folder:
      # workingDirectory: 'ClientApp'
      env:
          TELERIK_LICENSE: $(TELERIK_LICENSE)

    # ... run application build after license activation
    - script: call npm run build
      displayName: 'Build Application'
```

```yaml Linux build agents
pool:
    vmImage: 'ubuntu-latest'

steps:
    # ... install modules before activating the license
    - script: npm install
      displayName: 'Install NPM modules'

    - script: npx kendo-ui-license activate
      displayName: 'Activate Kendo UI License'
      # Set working directory if the application is not in the repository root folder:
      # workingDirectory: 'ClientApp'
      env:
          TELERIK_LICENSE: $(TELERIK_LICENSE)

    # ... run application build after license activation
    - script: npm run build
      displayName: 'Build Application'
```

### Azure Pipelines (Classic)

1. Create a new [Secret Variable](https://learn.microsoft.com/en-us/azure/devops/pipelines/process/set-secret-variables?view=azure-devops\&tabs=yaml%2Cbash#use-a-secret-variable-in-the-ui) named `TELERIK_LICENSE`.

2. Paste the deployment key as its value.

3. Add a new Bash task to the Agent job before the NPM build task and configure it with the `TELERIK_LICENSE` environment variable set to `$(TELERIK_LICENSE)`. This is required because Azure DevOps does not automatically pass secret variables to Bash tasks.

   ![Azure Pipelines Classic - add Bash task](https://www.telerik.com/kendo-react-ui-develop/components/assets/baa68798869535ef4448826035a039cb/azure-devops-classic-step-2.jpg)

4. Change the step to inline and use the following command:

```bash
# Activate the license
npx kendo-ui-license activate
```

![Azure Pipelines Classic - Step type Inline](https://www.telerik.com/kendo-react-ui-develop/components/assets/e4dc4e46dfa214f93d94f6be92afcc32/azure-devops-classic-step-3.jpg)

### Using Secure Files on Azure DevOps

[Secure files](https://learn.microsoft.com/en-us/azure/devops/pipelines/library/secure-files?view=azure-devops) are an alternative approach for sharing the license key file in Azure Pipelines that does not have the size limitations of environment variables.

You have two options for a file-based approach:

* Set the `TELERIK_LICENSE_PATH` variable.
* Add a file named `telerik-license.txt` to the project directory or a parent directory.

> Make sure you reference `@progress/kendo-licensing` v1.5.0 or later.

#### YAML Pipeline

With a YAML pipeline, you can use the [DownloadSecureFile@1](https://learn.microsoft.com/en-us/azure/devops/pipelines/tasks/reference/download-secure-file-v1?view=azure-pipelines) task, then use `$(name.secureFilePath)` to reference it.

```yaml
# ... Install modules before activating the license.
- script: npm install
  displayName: 'Install NPM modules'

- task: DownloadSecureFile@1
  name: DownloadTelerikLicenseFile # defining the 'name' is important
  displayName: 'Download Telerik License Key File'
  inputs:
      secureFile: 'telerik-license.txt'

- script: npx kendo-ui-license activate
  displayName: 'Activate Kendo UI License'
  # Set a working directory if the application is not in the repository root folder:
  # workingDirectory: 'ClientApp'
  env:
      # use the name.secureFilePath value to set TELERIK_LICENSE_PATH
      TELERIK_LICENSE_PATH: $(DownloadTelerikLicenseFile.secureFilePath)
```

#### Classic Pipeline

With a classic pipeline, use the “Download secure file” task and a PowerShell script to set `TELERIK_LICENSE_PATH` to the secure file path.

1. Add a “Download secure file” task and set the output variable's name to `telerikLicense`.
   ![Azure Pipelines Classic - Download secure file](https://www.telerik.com/kendo-react-ui-develop/components/assets/6feae2e3c9d8bd5dad5ddd5b9a56bba0/secure-files-step-1.png)

2. Add a PowerShell task and set the `TELERIK_LICENSE_PATH` variable and activate the license. Use the following script:

```powershell
# Set TELERIK_LICENSE_PATH
Write-Host "Setting TELERIK_LICENSE_PATH to $(telerikLicense.secureFilePath)"
$Env:TELERIK_LICENSE_PATH = "$(telerikLicense.secureFilePath)"

# Activate Kendo UI license
npx kendo-ui-license activate
```

![Azure Pipelines Classic - Set TELERIK_LICENSE_PATH](https://www.telerik.com/kendo-react-ui-develop/components/assets/eb98a709216e2d62f0b40907e7456118/secure-files-step-2.png)

Alternatively, copy the file into the repository directory:

```powershell
# Copy telerik-license.txt from secure file
echo "Copying $(telerikLicense.secureFilePath) to $(Build.Repository.LocalPath)/telerik-license.txt"
Copy-Item -Path "$(telerikLicense.secureFilePath)" -Destination "$(Build.Repository.LocalPath)/telerik-license.txt" -Force

# Activate Kendo UI license
npx kendo-ui-license activate
```

> If using [Task Groups](https://learn.microsoft.com/en-us/azure/devops/pipelines/release/task-groups?view=azure-devops), change the file name from `$(telerikLicense.secureFilePath)` to `$(Agent.TempDirectory)\telerik-license.txt` as output variables are not supported.

## Suggested Links

* [Setting Up Your License Key](https://www.telerik.com/kendo-react-ui-develop/components/my-license)
* [License Activation Errors and Warnings](https://www.telerik.com/kendo-react-ui-develop/components/my-license/license-errors-and-warnings)
* [Frequently Asked Questions about Your KendoReact License Key](https://www.telerik.com/kendo-react-ui-develop/components/my-license/faq)
* [Get Started with KendoReact Free](https://www.telerik.com/kendo-react-ui-develop/components/getting-started/free-vs-premium)
