dcloud deploy errors connectConnect Error Tracking: DSN, environment and release at build and run time
At every build and rollout the app gets SENTRY_DSN and NEXT_PUBLIC_SENTRY_DSN (the project’s managed key, filed in Secrets as a managed entry), SENTRY_ENVIRONMENT and SENTRY_RELEASE (the commit). A build also gets SENTRY_ORG, SENTRY_PROJECT, SENTRY_URL and, as a BuildKit secret, a SENTRY_AUTH_TOKEN minted for that build alone (source-map upload to this project only), revoked when the build ends. A variable the app defines itself wins. With redeploy: true the live commit is rebuilt, so the DSN reaches the browser bundle and source maps are uploaded.
Synopsis
dcloud deploy errors connect id --project-id projectId [flags]Arguments
<id>Requiredstring
Also accepted as
--id. Constraints: uuid
Flags
--project-idRequiredstring
Error Tracking project id
Constraints: uuid
--dsn-envOptionalstring
Server DSN variable (default SENTRY_DSN)
Constraints: /^([A-Za-z_][A-Za-z0-9_]{0,127})?$/
--public-dsn-envOptionalstring
Browser DSN variable (default NEXT_PUBLIC_SENTRY_DSN; VITE_SENTRY_DSN or PUBLIC_SENTRY_DSN for Vite and SvelteKit)
Constraints: /^([A-Za-z_][A-Za-z0-9_]{0,127})?$/
--environment-envOptionalstring
Environment variable (default SENTRY_ENVIRONMENT)
Constraints: /^([A-Za-z_][A-Za-z0-9_]{0,127})?$/
--release-envOptionalstring
Release variable (default SENTRY_RELEASE)
Constraints: /^([A-Za-z_][A-Za-z0-9_]{0,127})?$/
--environmentOptionalstring
SENTRY_ENVIRONMENT; omitted: the app’s secrets environment, else production
Constraints: 1-64 chars, /^[^\s/]+$/
May be null.
--redeployOptionalboolean (--redeploy / --no-redeploy)
Rebuild and redeploy now, so the build bakes the DSN into the browser bundle and uploads source maps
Example
dcloud deploy errors connect id --project-id 00000000-0000-0000-0000-000000000000Generated from the API description, the same one the API checks requests against and the CLI is built from.