DEV Community

Gordon Johnston for Lineup Ninja

Posted on

Migrate from ember-cli-deploy-sentry to sentry-cli

ember-cli-deploy-sentry is a plugin for Ember that pushes sourcemaps and releases to Sentry when Ember is deployed.

However it is no longer maintained, and since Sentry released sentry-cli, no longer required.

Get started by installing sentry-cli

By default ember deploy does not retain the assets after the deploy. To retain them and subsequently submit to Sentry you need to specify a path to store them. Do this by adding ENV.build.outputPath = 'build-output-path'; to your deploy.js. Obviously change build-output-path with an appropriate location.

The run the following commands where $SENTRY_ORG_SLUG, $SENTRY_PROJECT_SLUG are what they sound like, and $SENTRY_RELEASE is what you want to call the release in Sentry.

$ ember deploy ....
$ cd build-output-path
$ sentry-cli releases --org $SENTRY_ORG_SLUG --project $SENTRY_PROJECT_SLUG new $SENTRY_RELEASE
$ sentry-cli sourcemaps  --org $SENTRY_ORG_SLUG --project $SENTRY_PROJECT_SLUG --release $SENTRY_RELEASE  upload .
$ sentry-cli releases set-commits $SENTRY_RELEASE --local  --ignore-missing
$ sentry-cli releases --org $SENTRY_ORG_SLUG --project $SENTRY_PROJECT_SLUG finalize $SENTRY_RELEASE
Enter fullscreen mode Exit fullscreen mode

If you have integrated your repo with Sentry then you will need to update the set-commits line.

Also note that if build-output-path is outside the git repo for the project you should cd back into to the repo before running the set-commits command.

Top comments (0)