Inputs & outputs
Generated from action.yml
Both tables are generated from packages/github-action/action.yml. The
hand-written version of this page was missing three inputs and both outputs,
which is why it is generated now.
Inputs#
| Input | Required | Default | What it does |
|---|---|---|---|
token | Yes | — | Envpilot API key (envpk_…) with the GitHub Action surface, scoped to a project and environment. Create one under Organization → Settings → API Keys. |
environment | Yes | — | Environment to pull variables from, e.g. production, staging, development. |
api-url | No | https://www.envpilot.dev | Envpilot API base URL. Override only for self-hosted or non-production instances. |
export-env | No | true | When true, exports every pulled variable to $GITHUB_ENV so later steps can read it directly. |
env-file | No | — | Optional path to write the pulled variables as a dotenv file. Skipped when unset. |
files | No | false | When true, also pulls the project's secret files (keystores, SSH keys, certificates) and writes each to its recorded path. The API key must carry the 'files' resource, which is never granted by default. |
project | No | — | Project slug. Required when files is true — the files endpoint is project-scoped, unlike variables which the token scope resolves. |
files-dir | No | — | Directory that secret file paths are resolved against. Defaults to the workspace root. |
Outputs#
| Output | What it holds |
|---|---|
count | Number of variables pulled from Envpilot. |
files-count | Number of secret files written. Zero when files is false. |
Using an output:
❯yaml
- id: envpilot
uses: rafay99-epic/envpilot-action@v1
with:
token: ${{ secrets.ENVPILOT_TOKEN }}
environment: production
- run: echo "Pulled ${{ steps.envpilot.outputs.count }} variables"Limits#
- Inputs are strings — GitHub Actions has no boolean type.
export-env: "true"andfiles: "true"are quoted on purpose. api-urlexists for non-production instances; leave it unset otherwise.projectis ignored unlessfiles: true, where it is required.files-diris created if it does not exist, then resolved to a real path before anything is written.