Grouping actions into action groups - Amazon CodeCatalyst

Grouping actions into action groups

An action group contains one or more actions. Grouping actions into action groups helps you keep your workflow organized, and also allows you to configure dependencies between different groups.

Note

You cannot nest action groups within other action groups or actions.

Use the following instructions to define an action group.

Visual

Not available. Choose YAML to view the YAML instructions.

YAML
To define a group
  1. Open the CodeCatalyst console at https://codecatalyst.aws/.

  2. Choose your project.

  3. In the navigation pane, choose CI/CD, and then choose Workflows.

  4. Choose the name of your workflow. You can filter by the source repository or branch name where the workflow is defined, or filter by workflow name.

  5. Choose Edit.

  6. Choose YAML.

  7. In Actions, add code similar to the following:

    Actions: action-group-name: Actions: action-1: Identifier: aws/build@v1 Configuration: ... action-2: Identifier: aws/ecs-deploy@v1 DependsOn: - action-1 Configuration: ...

    For another example, see Example: Defining two action groups. For more information, see the description of the action-group-name property in the Actions of the Workflow definition reference.

  8. (Optional) Choose Validate to validate the workflow's YAML code before committing.

  9. Choose Commit, enter a commit message, and choose Commit again.

Example: Defining two action groups

The following example shows how to define two action groups: BuildAndTest and Deploy. The BuildAndTest group includes two actions (Build and Test), and the Deploy group also includes two actions (DeployCloudFormationStack and DeployToECS).

Actions: BuildAndTest: # Action group 1 Actions: Build: Identifier: aws/build@v1 Configuration: ... Test: Identifier: aws/managed-test@v1 Configuration: Deploy: #Action group 2 Actions: DeployCloudFormationStack: Identifier: aws/cfn-deploy@v1 Configuration: ... DeployToECS: Identifier: aws/ecs-deploy@v1 Configuration: ...