A GitHub Action that installs and runs the Lunar CI Agent. The agent instruments your workflow, triggering collectors and policies at the appropriate points during execution.
Add the action as an early step in your workflow:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Run Lunar CI Agent
uses: earthly/lunar-ci-action@v2.1.2
env:
LUNAR_HUB_TOKEN: ${{ secrets.LUNAR_HUB_TOKEN }}
LUNAR_HUB_HOST: your_hub_host
- uses: actions/checkout@v4
# ... rest of your workflowThe action downloads and runs the Lunar CI Agent, then attaches it to the workflow process. It also downloads the Lunar CLI (by default, the latest version available at the time the agent release was created). All subsequent steps are automatically instrumented.
All configuration is passed via environment variables
| Variable | Description |
|---|---|
LUNAR_HUB_TOKEN |
Auth token for your Hub installation. |
LUNAR_HUB_HOST |
Hostname of your Hub installation. Must be reachable from the runner. |
| Variable | Default | Description |
|---|---|---|
LUNAR_HUB_GRPC_PORT |
443 |
Hub's gRPC port. |
LUNAR_HUB_HTTP_PORT |
443 |
Hub's HTTP port. |
LUNAR_HUB_INSECURE |
false |
Set to true when connecting to a Hub without TLS. |
LUNAR_UPDATE_PERIOD |
15s |
How often the agent polls Hub for configuration updates. |
LUNAR_LOG_LEVEL |
error |
Log verbosity. Set to debug for troubleshooting. |
LUNAR_GIT_BASE_URL |
GitHub API base URL. Required for GitHub Enterprise Server. |
The action runs as a job step. It attaches to the current shell process via ptrace and traces all commands executed by subsequent steps in the same job.
The agent exits automatically when the job completes.
- Linux x86_64 runners (GitHub-hosted or self-hosted).
Copyright Earthly Technologies, Inc. All rights reserved.