Skip to content

Commit

Permalink
fix: remove sourcemap files after upload for safety
Browse files Browse the repository at this point in the history
  • Loading branch information
aube-dev committed Sep 19, 2024
1 parent fd72176 commit a749756
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export default defineConfig(({ mode }) => {
'SENTRY_',
]);

envSchema.parse(viteEnv);
const env = envSchema.parse(viteEnv);

const configEnv = z
.object({
Expand All @@ -31,7 +31,7 @@ export default defineConfig(({ mode }) => {
remixCloudflareDevProxyVitePlugin<ContextEnv, CfProperties>({
getLoadContext: (args) =>
getLoadContext(args, {
authCookieSessionSecret: viteEnv.SERVER_AUTH_COOKIE_SESSION_SECRET,
authCookieSessionSecret: env.SERVER_AUTH_COOKIE_SESSION_SECRET,
}),
}),
remix({
Expand All @@ -48,6 +48,9 @@ export default defineConfig(({ mode }) => {
project: 'ort-frontend',
url: 'https://sentry.io/',
authToken: configEnv.SENTRY_AUTH_TOKEN,
sourcemaps: {
filesToDeleteAfterUpload: './build/**/*.map',
},
}),
],
build: {
Expand Down

0 comments on commit a749756

Please sign in to comment.