Creating Deployments
This guide walks you through creating and executing deployments in Mantis.
Deployment Sources
Section titled “Deployment Sources”You can deploy from three sources:
| Source | Description | Use Case |
|---|---|---|
| Solution | Complete deployment package | Full application deployment |
| Sequence | Specific workflow | Targeted operation |
| Action | Single operation | Quick fix or test |
Creating a Solution Deployment
Section titled “Creating a Solution Deployment”Step 1: Navigate to Deployments
Section titled “Step 1: Navigate to Deployments”- Open Lens in your browser
- Open the Deployment group in the top navigation, then the Deployments pill
- Click New Deployment
Step 2: Context
Section titled “Step 2: Context”Choose the tenant and an environment. The environment is a scope, not a destination — it
is listed as {name} (Order: {n}) by promotion order, and targets are chosen in the next
step. Lens labels it “Optional”, but it is required whenever a tenant is set: the API
refuses a tenant deployment without one (environment_id is required for tenant-aware deployments). It is genuinely optional only for a platform-wide deployment with no
tenant.
Step 3: Source
Section titled “Step 3: Source”- Choose Solution as the source type
- Select the solution from the dropdown
- Choose the version to deploy
┌─────────────────────────────────────────────────────────┐│ Create Deployment │├─────────────────────────────────────────────────────────┤│ ││ Source Type: ● Solution ○ Sequence ○ Action ││ ││ Solution: [customer-portal ▼] ││ Version: [1.3.0 ▼] ││ │└─────────────────────────────────────────────────────────┘Step 4: Targets
Section titled “Step 4: Targets”An environment scopes a deployment; it does not receive one. This step is required — the wizard blocks until a destination is chosen, by one of three modes:
┌─────────────────────────────────────────────────────────┐│ Select Targets │├─────────────────────────────────────────────────────────┤│ ││ [ By Target ] [ By Tags ] [ By Pool ] ││ ││ ☑ web-01 ☑ web-02 ☐ db-01 ││ │└─────────────────────────────────────────────────────────┘- By Target — pick targets explicitly
- By Tags — every target carrying the tags, matched ANY or ALL
- By Pool — an execution pool, which runs off-target (see Target Selection)
Step 5: Config
Section titled “Step 5: Config”Set execution options:
| Option | Description | Default |
|---|---|---|
| Execution Mode | Parallel, Sequential, or Rolling | Parallel |
| Failure Strategy | Stop, Continue, or Ignore failures | Stop |
| Timeout | Maximum step duration | 300 seconds |
| Priority | Queue priority | 0 (normal) |
Step 6: Review and Deploy
Section titled “Step 6: Review and Deploy”- Review the deployment summary
- Verify targets and versions
- Click Deploy
┌─────────────────────────────────────────────────────────┐│ Review Deployment │├─────────────────────────────────────────────────────────┤│ ││ Solution: customer-portal v1.3.0 ││ Environment: Production ││ Targets: 12 machines ││ ││ Sequences: ││ 1. run-migrations (^1.0.0 → 1.2.0) ││ 2. deploy-backend (^2.0.0 → 2.3.1) ││ 3. deploy-frontend (^1.0.0 → 1.1.0) ││ ││ Execution: Rolling (batch size: 3) ││ Failure: Stop on first failure ││ ││ [Cancel] [Deploy] │└─────────────────────────────────────────────────────────┘Creating a Sequence Deployment
Section titled “Creating a Sequence Deployment”For targeted operations without a full solution:
- Select Sequence as source type
- Choose the sequence and version
- Select targets directly (not via environment)
- Configure and deploy
Creating an Action Deployment
Section titled “Creating an Action Deployment”For quick single operations:
- Select Action as source type
- Choose the action and version
- Provide argument values
- Select target(s)
- Execute
From the solution detail page
Section titled “From the solution detail page”The solution’s Environment Deployment Status cards do not start a deployment directly. They offer:
- Promote to {environment} — deploy the version this environment holds into the
next one in the chain. Shown when a next environment exists, this one has a version
deployed, and you hold
promotions:create - Rollback — open that environment’s state page. Shown once the environment has a deployed version and a recorded deployment
- Configure Targets — shown while the environment has no targets
To deploy a specific version, use the deployment wizard above.
Variable Override
Section titled “Variable Override”The Configuration step carries a Variables section: enter a name and a value and press Add, once per variable. Inherited environment values are not displayed there — you set the name you want to override and the value to use.
Overrides apply only to the current deployment.
Scheduled Deployments
Section titled “Scheduled Deployments”Scheduled deployments are managed through the Schedules feature, which is separate from creating an ad-hoc deployment. To deploy at a future time or on a recurring basis, create a schedule rather than a deployment directly.
See Schedules for details on creating and managing scheduled deployments.
Deployment from CLI
Section titled “Deployment from CLI”Using the mantisctl deployment create command. The --solution-id, --sequence-id,
--action-id and --environment-id flags are typed as UUIDs, so a slug or a name is
rejected by the CLI before a request is made. Only --target takes free-form strings.
# Deploy a solution to an environment (parallel mode by default). Targets are# required: the environment scopes the deployment, it does not supply them.mantisctl deployment create \ --solution-id 019b8c41-7a52-8e39-9d10-4f2b6c83a501 \ --source-version 1.3.0 \ --environment-id 019b8c41-9f0d-8a74-b2c6-71e3d8f4a922 \ --target 019b8c41-c3a1-8b55-9e07-5d1f2a6b4c88
# Deploy a sequence to specific targetsmantisctl deployment create \ --sequence-id 019b8c42-1e88-8b05-9a3f-5c7d21e60b48 \ --source-version 2.0.0 \ --target 019b8c42-4b31-8d6c-8e70-93a15f2c7d10 \ --target 019b8c42-6c9a-8f21-b458-2d70e9a31c85
# Deploy an action with a variablemantisctl deployment create \ --action-id 019b8c43-0d17-8c94-a6b2-8f31c50d7e26 \ --source-version 1.0.0 \ --target 019b8c42-4b31-8d6c-8e70-93a15f2c7d10 \ --var check_url=http://localhost/healthA --var value is visible to every local user in the process list, so pass secrets in a
file of key=value lines instead: --var-file ./deploy.vars (blank lines and #
comments are skipped, and --var flags override the file). --var-file - reads the
lines from standard input, so a secret never has to be written to disk:
vault kv get -field=vars secret/deploy | mantisctl deployment create ... --var-file -.
To deploy a solution by the slug the Nickel files and the UI show, use the top-level
mantisctl deploy instead — it resolves the solution and environment slugs and then
takes the same path (a UUID is accepted here unchanged too):
mantisctl deploy customer-portal --env production --source-version 1.3.0 \ --target 019b8c41-c3a1-8b55-9e07-5d1f2a6b4c88Sequences and actions have no slug form; they stay on deployment create.
Pre-Deployment Checklist
Section titled “Pre-Deployment Checklist”Before deploying to production:
- Tested in lower environments
- Variable values configured for target environment
- All targets are online
- No deployment freeze is active
- Team is available to monitor
- Rollback plan is ready
Troubleshooting
Section titled “Troubleshooting”Deployment Rejected For Missing Scope
Section titled “Deployment Rejected For Missing Scope”Cause: A tenant was set but no environment was chosen — a tenant deployment requires both
Solution: Pick an environment in the Context step before creating the deployment
Version Not Available
Section titled “Version Not Available”Cause: Requested version doesn’t exist or is archived
Solution: Check available versions in the solution/sequence
Deployment Blocked by Freeze
Section titled “Deployment Blocked by Freeze”Cause: A deployment freeze is active
Solution: Wait for freeze to end or request override
Next Steps
Section titled “Next Steps”- Target Selection - Choose deployment targets
- Execution Modes - Parallel, sequential, rolling
- Monitoring - Track deployment progress
- Overview - Return to deployments overview
