CI/CD

API Keys

In CI, you authenticate with an API key instead of GitHub OAuth. Generate an API key from the ev web dashboard under Settings → API Keys.

Store the key as a secret in your CI provider — never in your code or ev.yaml.

Environment Variables

VariableDescription
EV_API_KEYAPI key for authentication (required in CI)
EV_API_URLURL of your ev API server (required if self-hosted)

GitHub Actions

Full example that installs ev and pulls secrets before running tests:

name: CI
 
on:
  push:
    branches: [main]
  pull_request:
 
jobs:
  test:
    runs-on: ubuntu-latest
 
    steps:
      - uses: actions/checkout@v4
 
      - uses: actions/setup-node@v4
        with:
          node-version: 20
 
      - name: Install ev
        run: npm i -g @rowlabs/ev
 
      - name: Pull secrets
        run: ev pull
        env:
          EV_API_KEY: ${{ secrets.EV_API_KEY }}
          EV_API_URL: https://your-ev-api.com
 
      - name: Install dependencies
        run: npm ci
 
      - name: Run tests
        run: npm test

Targeting a Specific Environment

Pull from a specific environment in CI:

- name: Pull production secrets
  run: ev pull prod
  env:
    EV_API_KEY: ${{ secrets.EV_API_KEY }}
    EV_API_URL: https://your-ev-api.com

Monorepo Pull Examples

For monorepos, pull secrets for each app before its build step:

- name: Pull backend secrets
  run: ev pull backend:prod
  env:
    EV_API_KEY: ${{ secrets.EV_API_KEY }}
    EV_API_URL: https://your-ev-api.com
 
- name: Pull frontend secrets
  run: ev pull frontend:prod
  env:
    EV_API_KEY: ${{ secrets.EV_API_KEY }}
    EV_API_URL: https://your-ev-api.com

Other CI Providers

ev works with any CI system that can run shell commands and set environment variables. Set EV_API_KEY and EV_API_URL as secret environment variables in your provider's settings:

CircleCI:

steps:
  - run: npm i -g @rowlabs/ev
  - run: ev pull

Set EV_API_KEY and EV_API_URL in CircleCI's environment variable settings for the project.

GitLab CI:

pull-secrets:
  script:
    - npm i -g @rowlabs/ev
    - ev pull

Set EV_API_KEY and EV_API_URL as masked CI/CD variables in GitLab project settings.

On this page