Ember CLI Deploy S3 Plugin

5.0.1 · active · verified Wed Apr 22

ember-cli-deploy-s3 is an `ember-cli-deploy` plugin designed to upload static assets, such as JavaScript, CSS, images, and the `index.html` file, to an Amazon S3 bucket as part of an Ember CLI application's deployment pipeline. The current stable version is 5.0.1, with releases typically occurring as needed to address bugs, incorporate new features, or handle breaking changes in its underlying dependencies like the AWS SDK. Its primary differentiator is its seamless integration into the `ember-cli-deploy` ecosystem, providing a standardized way to handle asset deployment to S3 without manual scripting. It leverages the AWS SDK for credential resolution and S3 operations, with version 5.x adopting AWS SDK v3, which introduced significant changes compared to previous versions. Configuration is handled through the `config/deploy.js` file, allowing developers to specify S3 bucket details, access credentials, regions, and file patterns for upload.

Common errors

Warnings

Install

Imports

Quickstart

This quickstart demonstrates how to install the plugin, configure it in `config/deploy.js` with essential AWS credentials and S3 bucket details, and the basic command to trigger a deployment.

ember install ember-cli-deploy-s3

// config/deploy.js
module.exports = function(deployTarget) {
  const ENV = {
    build: {},
    s3: {
      accessKeyId: process.env.AWS_ACCESS_KEY_ID ?? 'YOUR_AWS_ACCESS_KEY',
      secretAccessKey: process.env.AWS_SECRET_ACCESS_KEY ?? 'YOUR_AWS_SECRET_KEY',
      bucket: 'your-s3-bucket',
      region: 'your-s3-bucket-region'
    }
  };

  if (deployTarget === 'production') {
    // Additional production-specific configuration
  }

  return ENV;
};


// Run the deployment
// ember deploy

view raw JSON →