Test & ship
Environments & deployment
Set up environments or let flunkey detect them in the repository, ship stage by stage, and see what really runs in the cluster.
- Detect
- Set up
- Test connection
- Staging
- Test
- Go to production
Set up an environment
Set up environment opens a wizard with five steps.
- TypeDevelopment, test, staging or production. The type proposes name, order and sensible defaults – production for example with approval and deployment by people.
- TargetCloud through infrastructure as code or GitOps, Kubernetes direct, own server via SSH, or manual.
- AccessOnly the inputs of the chosen target. Secrets carry a lock, are stored encrypted and never shown again.
- DeploymentAddress for end-to-end tests, an address per feature, Who deploys? (people, agent, pipeline), approval needed, and what happens afterwards.
- CheckThe connection test starts on its own – with the same rights as later deploys – and shows each check with a tick, a warning or an error.

Detected in the repository
flunkey reads the repository on every new commit and lists environments it describes that are not set up yet – from GitOps applications, infrastructure folders, overlays, value files per environment, compose files or workflow jobs. Set up opens the wizard prefilled, Set up all creates all of them, Ignore hides a hit.

Single- or multi-stage
Single-stage (default): a feature in Deploy is shipped to production and recorded. Multi-stage: after the test gate the feature runs through the stages before production, such as staging – deploy, then test each (end-to-end against the stage's address, or an exploratory test record). When a stage passes, the next opens; at the end comes Deploy to production.

Who deploys
| Method | How it runs |
|---|---|
| People record the deployment | Someone records each deployment with environment, scope and outcome |
| The deploy step's agent | The agent gets the cluster access in its container for that run, applies the code, waits for ready workloads, checks the host names and records the deployment |
| GitOps | flunkey sets the image tag in the config repository – by pull request or direct commit – and follows the sync until healthy |
| The pipeline's deploy job | A job in .agentic/pipeline.yml with environment:; for production it waits for a project lead's approval |

What really runs in the cluster
For environments with a connected cluster, flunkey reads every 15 minutes, after every deployment and on demand – read-only, never secrets. The overview shows the running version from the image tags, the health, the URLs and the comparison with the repository. If another version runs than recorded, it says so ("Recorded 0.54.0, running 0.55.0"). When two readings see the same version running steadily, it is taken over as a deployment – rollbacks too.