# How to create a Heat stack

Source: https://docs.quake.ai/docs/automation/how-to/create-heat-stack
Markdown: https://docs.quake.ai/docs/automation/how-to/create-heat-stack.md

---

# How to create a Heat stack


Heat is a legacy orchestration path on Quake AI. For new projects, use [OpenTofu](/docs/automation/how-to/getting-started-iac) instead.


A Heat stack provisions a group of resources from a HOT (Heat Orchestration Template) YAML file. You define the resources, parameters, and outputs in the template, and Heat creates them as a single unit that you can update or delete together.

<PrerequisiteBlock methods={["console", "cli"]}>

- A HOT template file (`.yaml`) defining the resources to create
- Familiarity with [Heat and IaC on Quake AI](/docs/automation/concepts/iac-comparison)

</PrerequisiteBlock>



Quake AI flavors report a root disk size of zero (`disk=0`), so an `OS::Nova::Server` in your template must boot from a Cinder volume rather than a flavor root disk. Give the server a `block_device_mapping_v2` entry that sources an image and sets a `volume_size`. A server with a bare flavor and no `block_device_mapping_v2` fails to create with `Forbidden: Only volume-backed servers are allowed for flavors with zero disk. (HTTP 403)`, and Heat rolls the stack back to `ROLLBACK_COMPLETE`. The `Stack Events` tab (Console) or `openstack stack event list` (CLI) reports this error.



The [Heat simple stack](/resources/iac-templates/heat-simple-stack) template shows the full pattern. Its compute resource sets `block_device_mapping_v2` so the server boots from a volume:

```yaml
resources:
  instance:
    type: OS::Nova::Server
    properties:
      flavor: { get_param: flavor }
      key_name: { get_param: key_name }
      networks:
        - port: { get_resource: port }
      block_device_mapping_v2:
        - boot_index: 0
          image: { get_param: image }
          volume_size: 20
          delete_on_termination: true
```

## Create the stack

<MethodTabs>
<Method label="Console">

The Create Stack flow is a two-page wizard. The step indicator at the top names both pages: **Prepare Template** (page 1, template and environment) and **Orchestration information** (page 2, stack name, timeout, and rollback policy).

1. Select **Automation** > **Heat Stacks** > **Create Stack**.
2. On **Prepare Template**, paste the template content, or select **Load from local files** to upload a `.yaml` file.
3. Optionally paste content into the **Environment Variable** field, or use the **Load from local files** control beneath it to upload an environment `.yaml`.
4. Select **Next: Orchestration information**.
5. Every page-2 form field carries a leading `*` to mark it as required. Page 2 also always renders a `Fill In The Parameters` section heading; that section is empty when the template declares no `parameters:` block, otherwise it lists one input per declared parameter.
6. In the `* Stack Name` field, enter a name that identifies this deployment.
7. In the `* Creation Timeout (Minutes)` field, set how long Heat should wait before rolling back. The default is `60`.
8. For `* Fail Rollback`, pick one of two required radio options:
   - **Enable** (the default): Heat deletes the partial resources when stack creation fails (clean-up on failure).
   - **Disable**: Heat keeps the partial resources for inspection (preserve on failure for debugging).

   

   **Enable** (default): Heat deletes partial resources when stack creation fails. **Disable**: Heat keeps partial resources so you can inspect what was created before the failure.

   

   The underlying OpenStack Heat API uses `disable_rollback` as the inverse parameter (`Enable` maps to `disable_rollback=false`, `Disable` to `disable_rollback=true`); this inverse naming is a common source of confusion for Heat operators.
9. The page-2 action bar at the bottom exposes three buttons in this order: `Cancel` (abandon the wizard), `Previous: Prepare Template` (return to page 1; the Console keeps the form state intact), and `Confirm` (create the stack). Select `Confirm`.

</Method>
<Method label="CLI">



Heat creates a Keystone trust on your behalf to drive stack convergence. A restricted application credential, which is the Console default, cannot create that trust, and `openstack stack create` returns an opaque `HTTP 500 RemoteError`. Authenticate with an unrestricted application credential: set **Unrestricted** when you create the credential in the Console, or pass `--unrestricted` to [`openstack application credential create`](/docs/tools/app-credentials). The Console method above is unaffected, because it uses your password-scoped Console session.



```bash
openstack stack create --template YOUR_TEMPLATE.yaml \
  --parameter "key_name=YOUR_KEY" \
  --parameter "image=Ubuntu-22.04" \
  YOUR_STACK_NAME
```

To pass an environment file:

```bash
openstack stack create --template YOUR_TEMPLATE.yaml \
  --environment YOUR_ENVIRONMENT.yaml \
  YOUR_STACK_NAME
```

Monitor creation progress:

```bash
openstack stack show YOUR_STACK_NAME -c stack_status -c stack_status_reason
```

</Method>
</MethodTabs>

## Verify the stack

After creation, verify the stack reached `CREATE_COMPLETE` (the Console renders this state as `Create Complete` with a green status dot):

<MethodTabs>
<Method label="Console">

Navigate to **Automation** > **Heat Stacks** and confirm **Stack Status** shows **Create Complete**. Open the stack to review resources on **Stack Resources** and events on **Stack Events** when creation fails.



For a stack that did not reach `CREATE_COMPLETE` (for example, one in `ROLLBACK_COMPLETE`), the `YAML File` tab can render only the `heat_template_version` header line instead of the full template. To retrieve the complete template for a failed or rolled-back stack, run `openstack stack template show YOUR_STACK_NAME`.



<NoMoreButton />

</Method>
<Method label="CLI">

```bash
openstack stack list
openstack stack event list YOUR_STACK_NAME
```

If the stack shows `CREATE_FAILED`, review the events to identify which resource failed and why. On the Console, the `Stack Events` tab on the stack detail page shows the same event log.

</Method>
</MethodTabs>

## Next steps

- [Heat and IaC comparison](/docs/automation/concepts/iac-comparison): when to use Heat vs. Terraform
- [Automation console](/reference/automation/console)
- [IaC templates](/resources/iac-templates): ready-to-deploy Heat and Terraform templates
