# atmos aws cloudformation watch

Stream events from an existing stack operation until it finishes. The operation
can have been started by Atmos, the AWS Console, or another tool.

> ⚠️ Experimental

**CloudFormation Configuration**

Configure templates, parameters, and delivery targets for your component.
Configuration Reference[Read more](/stacks/components/aws-cloudformation)

## Usage

```shell
atmos aws cloudformation watch <component> --stack <stack> [options]
```

## Examples

```shell
atmos aws cloudformation watch vpc -s plat-ue2-dev
```

Watch all or affected components in dependency order:

```shell
atmos aws cloudformation watch --all -s plat-ue2-dev
atmos aws cloudformation watch --affected --base origin/main
```

## Arguments

- **`component` (required unless selecting multiple components)**
  CloudFormation component name in the Atmos stack.

## Flags

- **`--stack`, `-s` (required for a single component)**
  Atmos stack. With bulk selection flags, limits the selected components to this stack.

## Behavior

With bulk selection, `--stack` is an optional filter. Omit it to select components across stacks.

If the stack ends in a failed status, `watch` exits non-zero, the same
failure signal `apply`/`delete` give when the operation they started fails.

This command does not fire [lifecycle hooks](/stacks/components/aws-cloudformation#lifecycle-hooks).

## Try it out

Requires Docker or Podman, Python 3, and network access for the emulator image. Run against the local AWS emulator; the final commands clean up. No AWS account is needed.

```shell
atmos config set aliases.cft "aws cloudformation"
atmos emulator up aws -s local
atmos cft deploy demo -s local
atmos cft watch demo -s local
atmos cft delete demo -s local --auto-approve
atmos emulator down aws -s local
```
