Environment Variables Reference

Environment variables are automatically configured when using the curl installation method. This reference is for advanced users who need custom configurations.

Standard Usage

For most users, simply use the curl command with CLI options:

bash
# Device Node
curl -fsSL https://app.devicelab.dev/device-node/YOUR_ORG_KEY | sh -s -- \
  --name "Austin-QA-Lab-MacMini-1" \
  --simulators "iPhone 16"

# Test Node
curl -fsSL https://app.devicelab.dev/test-node/YOUR_ORG_KEY | sh -s -- \
  --name "GitHub - Alpha Release Pipeline" \
  --framework maestro \
  --app app.apk \
  --tests flows/

The curl script automatically configures all required environment variables based on your organization ID.

Advanced: Environment Variable Reference

Device Node Variables

Variable Description Default
DEVICELAB_NODE_NAME Custom name for this node System hostname
DEVICELAB_TURN_ENABLED Enable TURN relay false
APPLE_TEAM_ID Apple Team ID for iOS physical devices -

Test Node Variables

Variable Description Default
DEVICELAB_NODE_NAME Custom name for this node System hostname
LOCAL_HTTP_PORT Local HTTP server port 4723
TESTNODE_TURN_ENABLED Enable TURN relay false

CI/CD Integration

GitHub Actions

yaml
name: Mobile Tests

on: [push, pull_request]

jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4

      - name: Run Maestro Tests
        run: |
          curl -fsSL https://app.devicelab.dev/test-node/${{ secrets.DEVICELAB_ORG_KEY }} | sh -s -- \
            --name "GitHub - PR #${{ github.event.pull_request.number }} Validation" \
            --framework maestro \
            --app ./app.apk \
            --tests ./maestro-tests/

GitLab CI

yaml
test:
  script:
    - curl -fsSL https://app.devicelab.dev/test-node/$DEVICELAB_ORG_KEY | sh -s --
        --name "GitLab - Pipeline $CI_PIPELINE_ID"
        --framework maestro
        --app app.apk
        --tests maestro-tests/

Jenkins

groovy
pipeline {
    agent any
    stages {
        stage('Test') {
            steps {
                sh '''
                    curl -fsSL https://app.devicelab.dev/test-node/${DEVICELAB_ORG_KEY} | sh -s -- \
                      --name "Jenkins - Build #${BUILD_NUMBER}" \
                      --framework maestro \
                      --app app.apk \
                      --tests maestro-tests/
                '''
            }
        }
    }
}

CLI Flag Precedence

When the same setting is available as both an environment variable and CLI flag, CLI flags take precedence.

Setting Environment Variable CLI Flag
Node name DEVICELAB_NODE_NAME --name
TURN enabled DEVICELAB_TURN_ENABLED --enable-turn
Apple Team ID APPLE_TEAM_ID --apple-team-id

We recommend using CLI flags for clarity:

bash
curl -fsSL https://app.devicelab.dev/device-node/YOUR_ORG_KEY | sh -s -- \
  --name "London-Office-MacMini-2" \
  --apple-team-id "ABCD1234EF" \
  --enable-turn

See Also