mirror of
https://github.com/AmruthPillai/Reactive-Resume.git
synced 2025-11-13 00:03:27 +10:00
remove sentry integration, fix linting issues
This commit is contained in:
@ -45,9 +45,6 @@ export const configSchema = z.object({
|
||||
.default("false")
|
||||
.transform((s) => s !== "false" && s !== "0"),
|
||||
|
||||
// Sentry
|
||||
SERVER_SENTRY_DSN: z.string().url().startsWith("https://").optional(),
|
||||
|
||||
// Crowdin (Optional)
|
||||
CROWDIN_PROJECT_ID: z.coerce.number().optional(),
|
||||
CROWDIN_PERSONAL_TOKEN: z.string().optional(),
|
||||
|
||||
@ -3,10 +3,8 @@ import { ConfigService } from "@nestjs/config";
|
||||
import { NestFactory } from "@nestjs/core";
|
||||
import { NestExpressApplication } from "@nestjs/platform-express";
|
||||
import { DocumentBuilder, SwaggerModule } from "@nestjs/swagger";
|
||||
import * as Sentry from "@sentry/node";
|
||||
import cookieParser from "cookie-parser";
|
||||
import helmet from "helmet";
|
||||
import { PrismaService } from "nestjs-prisma";
|
||||
import { patchNestJsSwagger } from "nestjs-zod";
|
||||
|
||||
import { AppModule } from "./app.module";
|
||||
@ -19,27 +17,6 @@ async function bootstrap() {
|
||||
logger: process.env.NODE_ENV === "development" ? ["debug"] : ["error", "warn", "log"],
|
||||
});
|
||||
const configService = app.get(ConfigService<Config>);
|
||||
const prisma = app.get(PrismaService);
|
||||
|
||||
// Sentry
|
||||
// Error Reporting and Performance Monitoring
|
||||
const sentryDsn = configService.get("SERVER_SENTRY_DSN");
|
||||
|
||||
if (sentryDsn) {
|
||||
const express = app.getHttpAdapter().getInstance();
|
||||
|
||||
Sentry.init({
|
||||
dsn: sentryDsn,
|
||||
tracesSampleRate: 1,
|
||||
profilesSampleRate: 1,
|
||||
integrations: [
|
||||
new Sentry.Integrations.Http({ tracing: true }),
|
||||
new Sentry.Integrations.Express({ app: express }),
|
||||
new Sentry.Integrations.Prisma({ client: prisma }),
|
||||
...Sentry.autoDiscoverNodePerformanceMonitoringIntegrations(),
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
// Cookie Parser
|
||||
app.use(cookieParser());
|
||||
|
||||
Reference in New Issue
Block a user