

Amazon CodeCatalyst is no longer open to new customers. Existing customers can continue to use the service as normal. For more information, see [How to migrate from CodeCatalyst](migration.md).

# Publishing files to Amazon S3 with a workflow
<a name="s3-pub-action"></a>

This section describes how to publish files to Amazon S3 using a CodeCatalyst workflow. To accomplish this, you must add the **Amazon S3 publish** action to your workflow. The **Amazon S3 publish** action copies files from a source directory to an Amazon S3 bucket. The source directory can reside in:
+ A [source repository](source.md), or 
+ An [output artifact](workflows-working-artifacts.md) generated by another workflow action

**Topics**
+ [When to use the 'Amazon S3 publish' action](#s3-pub-action-when-to-use)
+ [Runtime image used by the 'Amazon S3 publish' action](#s3-pub-action-runtime)
+ [Example: Publish files to Amazon S3](s3-pub-action-example-workflow.md)
+ [Adding the 'Amazon S3 publish' action](s3-pub-action-add.md)
+ ['Amazon S3 publish' action YAML](s3-pub-action-ref.md)

## When to use the 'Amazon S3 publish' action
<a name="s3-pub-action-when-to-use"></a>

Use this action if:
+ You have a workflow that generates files that you want to store in Amazon S3.

  For example, you might have a workflow that builds a static website that you want to host in Amazon S3. In this case, your workflow would include a [build action](build-add-action.md) to build the site's HTML and supporting files, and an **Amazon S3 publish** action to copy the files to Amazon S3.
+ You have a source repository that contains files that you want to store in Amazon S3.

  For example, you might have a source repository with application source files that you want to archive on a nightly basis to Amazon S3.

## Runtime image used by the 'Amazon S3 publish' action
<a name="s3-pub-action-runtime"></a>

The **Amazon S3 publish** action runs on a [November 2022 image](build-images.md#build.previous-image). For more information, see [Active images](build-images.md#build-curated-images).