Skip to main content
A command you triggered by mistake, or one that is stuck, is its own kind of incident. You can cancel it.

Cancel it

With no query, formae cancel targets the most recent command. To target specific in-progress commands, pass a query:

What cancel does

By default, cancel is careful about work that is already in flight:
  • Only commands in the InProgress state can be canceled.
  • Resources already executing run through to completion, so formae leaves no half-applied or orphaned resources behind. Operations that have not started yet are dropped.
  • Work already completed is not rolled back. Cancel stops further changes; it does not undo what already happened.
This is the live view the moment you cancel. Some resources are already done (the check marks), a couple are still running to completion (the spinner), and the rest are canceled. The progress bar turns red to show the command is being canceled:
  formae status command                                                                                     ↻ live
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
     ID                          Command   Mode        Progress                         ✓    ✗    ◐    ○    Time
⣾    3GovHX0bguXAqlm8H98bXBebF5q apply     reconcile   ███████████████████████░░░░ 4/15 4    9    2    0    00:14
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────

  ▌ Targets
        Label ▲                                                                                   Operation   Time
       aws-target                                                                                create      00:00

  ▌ Stacks
        Label ▲                                                                                   Operation   Time
       lifeline                                                                                  create      00:00

  ▌ Resources
        Label ▲                                               Type                                Operation   Time
       lifeline-alb-http-ingress                             AWS::EC2::SecurityGroupIngress      create      
       lifeline-alb-sg                                       AWS::EC2::SecurityGroup             create      
       lifeline-igw                                          AWS::EC2::InternetGateway           create      00:05
       lifeline-igw-attachment                               AWS::EC2::VPCGatewayAttachment      create      
       lifeline-public-route                                 AWS::EC2::Route                     create      
   ⣾    lifeline-public-rt                                    AWS::EC2::RouteTable                create      00:14
   ⣾    lifeline-public-subnet-1                              AWS::EC2::Subnet                    create      00:14
       lifeline-public-subnet-1-assoc                        AWS::EC2::SubnetRouteTableAssocia…  create      
       lifeline-public-subnet-2                              AWS::EC2::Subnet                    create      
       lifeline-public-subnet-2-assoc                        AWS::EC2::SubnetRouteTableAssocia…  create      
       lifeline-task-http-ingress                            AWS::EC2::SecurityGroupIngress      create      
       lifeline-task-sg                                      AWS::EC2::SecurityGroup             create      
       lifeline-vpc                                          AWS::EC2::VPC                       create      00:03

────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
Once the in-flight resources finish, the command settles into a terminal canceled state. The resources that completed remain under management: inspect them with formae inventory, or remove them with formae destroy.
  formae status command                                                                                     ↻ live
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
     ID                          Command   Mode        Progress                         ✓    ✗    ◐    ○    Time
⊘    3GovHX0bguXAqlm8H98bXBebF5q apply     reconcile   canceled 6/15                    6    9    0    0    00:22
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────

  ▌ Targets
        Label ▲                                                                                   Operation   Time
       aws-target                                                                                create      00:00

  ▌ Stacks
        Label ▲                                                                                   Operation   Time
       lifeline                                                                                  create      00:00

  ▌ Resources
        Label ▲                                               Type                                Operation   Time
       lifeline-alb-http-ingress                             AWS::EC2::SecurityGroupIngress      create      
       lifeline-alb-sg                                       AWS::EC2::SecurityGroup             create      
       lifeline-igw                                          AWS::EC2::InternetGateway           create      00:05
       lifeline-igw-attachment                               AWS::EC2::VPCGatewayAttachment      create      
       lifeline-public-route                                 AWS::EC2::Route                     create      
       lifeline-public-rt                                    AWS::EC2::RouteTable                create      00:18
       lifeline-public-subnet-1                              AWS::EC2::Subnet                    create      00:20
       lifeline-public-subnet-1-assoc                        AWS::EC2::SubnetRouteTableAssocia…  create      
       lifeline-public-subnet-2                              AWS::EC2::Subnet                    create      
       lifeline-public-subnet-2-assoc                        AWS::EC2::SubnetRouteTableAssocia…  create      
       lifeline-task-http-ingress                            AWS::EC2::SecurityGroupIngress      create      
       lifeline-task-sg                                      AWS::EC2::SecurityGroup             create      
       lifeline-vpc                                          AWS::EC2::VPC                       create      00:03

────────────────────────────────────────────────────────────────────────────────────────────────────────────────────

See also