Skip to main content

Configure your GitLab CI environment variable

Setting an environment variable in GitLab CI occurs on a per-repository basis. This example demonstrates how to create a variable for your API token.

To complete this task:

  1. In your GitLab environment, select the project you want to scan.

  2. Go to Settings > CI/CD.

  3. Click Expand in the Variables section.

  4. In the Key field, enter SRCCLR_API_TOKEN.

  5. In the Value field, enter your Veracode SCA API token.

  6. Select the State and Masked values you want for your variable.

    Veracode recommends masking the variable and, if you use protected variables, protecting it.

  7. Click Save variables.

Next steps:

You can create an environment variable for your project URL to allow the enabling of automatic pull requests.