Follow and recover deployments

Prev Next

Deploy an approved application artifact, inspect the exact operation and recover from a failure without hiding partial work. The administrator deployment guide and operator overview define ownership and acceptance.

Prerequisites

Confirm the canonical Controller, installed target environment, registered application and accepted image. Use a user login with application deployment permission; environment infrastructure operations require their own permission. Check registry access, configuration, secrets and the recovery decision. This procedure describes Builder 2.71.0 and Miso 2.1.65 source contracts.

For Test/Production promotion, obtain the accepted immutable image identity and approved target-specific configuration. A source environment's successful test does not authorize production deployment or provide its credentials. Verify application placement: installation-wide applications belong to the platform environment; environment applications belong to the selected business environment.

Where it lives

Builder submits the application deployment to the Controller and follows its operation. Use the actual deployment ID and environment from that response. Local application definitions and registration must resolve to the intended app. The Controller application view, deployment/job history and provider's installed-image reference together establish what is running.

How to set

  1. Inspect the user and current application:

    aifabrix auth status
    aifabrix app show <appKey>
    aifabrix app deployment <appKey>
    aifabrix deployment list --environment dev
    

    Replace the placeholders and target with your approved values. Check for an active deployment before another mutation. If registration is missing, resolve the exact application/environment relationship through the supported registration workflow.

  2. After reviewing the application definition and configuration, deploy the accepted image to its permitted environment:

    aifabrix deploy <appKey> --env pro --image <approved-image-reference>
    

    This is an authorized application promotion, separate from DEV-only platform upgrade apply. Do not use it to bypass placement, compatibility, registry or recovery checks. A digest reference identifies the accepted image more precisely than a mutable tag. The command polls; application deploy has no polling-disable flag.

  3. Retain and inspect the operation:

    aifabrix deployment get <deploymentId>
    aifabrix deployment get <deploymentId> --logs
    aifabrix app deployment <appKey>
    

    Keep your selected Controller/environment unchanged while following it. After a disconnected session or timeout, read that deployment before retrying. Acceptance is not completion. Inspect the returned failure stage and diagnostic IDs.

  4. If stopping an operation is authorized, inspect it first and cancel the exact ID:

    aifabrix deployment cancel <deploymentId> --environment dev
    

    On a terminal the command confirms. Automation or JSON output requires explicit --yes after approval. Cancellation uses a human user login; application tokens, service identities and development test keys are refused. Use the correct environment, not the example, for the original deployment.

  5. Verify the response and current state. Only an explicit status: released together with lockReleased: true proves the environment lock was released. A cancelled application job, unclear response or older Controller can leave that question open. Resolve it through the deployment owner before another infrastructure deployment.

Defaults and examples

Deployment list and get use the configured target unless overridden where supported. Application deployment follows a different option vocabulary from deployment cancellation; use each command's help rather than carrying flags between them. Environment provisioning uses env deploy, not an application image deployment.

For cancellation, exit 0 means a confirmed release or cancellation, not automatically both. Exit 1 includes a kept lock, unclear result or failed/refused operation. Exit 2 indicates missing input or a required noninteractive confirmation. Inspect the reported fields rather than interpreting the exit code alone.

Validate

Check terminal outcome, effective installed image, application health, sign-in and an authorized representative operation. Preserve previous images and failed-stage evidence. Image-pull failure belongs to artifact/registry access; startup failure needs dependency, configuration and migration review; healthy origin with failing public access needs routing diagnosis. Restoring an image does not reverse data migrations. Use upgrade verification and recovery for the stateful recovery decision.

Common mistakes

Observation Action
Deployment get exits 0 for a failed deployment The read succeeded; inspect the deployment status itself.
Cancel reports cancelled without lock release Inspect explicit release fields before another infrastructure deployment.
A deployment result is unknown Read the existing operation before starting another one.

Limits

This procedure does not establish a runtime deployment or lock-release proof. Installed-image reporting depends on the provider path. Generic cancellation does not promise resource cleanup, data rollback or permission to force a lock release. Production promotion needs the installation's accepted artifact/configuration runbook.