An ember-cli-deploy plugin that first integrates Rollbar to your application and second uploads your source maps to Rollbar.
This plugin will integrate Rollbar into your index.html
file and uploads generated source maps via Rollbar API. During upload of the source maps to Rollbar you must provide source_code
string that will match the error raised in Rollbar with the same value. To do this, Rollbar snippet is injected into index.html
after the revision data is generated with revision key as source_code
. After all, the plugin uploads the source maps with the same revision key as injected into index.html
.
You can take a look here how Rollbar defines its flow with source maps
A plugin is an addon that can be executed as a part of the ember-cli-deploy pipeline. A plugin will implement one or more of the ember-cli-deploy's pipeline hooks.
For more information on what plugins are and how they work, please refer to the Plugin Documentation.
To get up and running quickly, do the following:
-
Ensure ember-cli-deploy-build is installed and configured
-
Ensure ember-cli-deploy-revision-data is installed and configured
-
Install this plugin
$ ember install ember-cli-deploy-rollbar
- Run the pipeline
$ ember deploy
Run the following command in your terminal:
ember install ember-cli-deploy-rollbar
For detailed information on what plugin hooks are and how they work, please refer to the Plugin Documentation.
willUpload
(inject Rollbar snippet)upload
(upload source maps)
For detailed information on how configuration of plugins works, please refer to the Plugin Documentation.
Rollbar client access token to trigger errors.
Rollbar server access token to allow uploading source maps to your account.
Rollbar demands to upload both source map and URL to minified file. This config let's you define the prepend to URL your assets will be available after upload. E.g. if you are using ember-cli-deploy-s3
, add the same string as in fingerprint/prepend
option in your ember-cli-deploy
file.
Defines internal enabled
Rollbar config.
Default: true
Alternatives: false
Defines internal environment
Rollbar config.
Default: production
Alternatives: any other env
Defines internal captureUncaught
Rollbar config.
Default: true
Alternatives: false
The following properties are expected to be present on the deployment context
object:
distDir
(provided by ember-cli-deploy-build)distFiles
(provided by ember-cli-deploy-build)revisionData
(provided by ember-cli-deploy-revision-data)
- You must enable source maps in your
ember-cli-deploy
file, even inproduction
env. However, you don't need to upload them anywhere (they won't be available online) - they are only needed duringupload
phase in deploy pipeline. - If you are using gzipping, make sure that you are not gzipping source maps - Rollbar will not accept gzipped files.
- If you bump in any other issue in your deployment flow, give me a sign and I'll try to make this addon more flexible for you.