chore: remove Sentry integration
All checks were successful
Gitea CI / test-build (push) Successful in 11m8s

Remove @sentry/nextjs and all related files since it was never actively used.
- Delete sentry.server.config.ts, sentry.edge.config.ts
- Delete sentry-example-page and sentry-example-api routes
- Clean up instrumentation.ts, global-error.tsx, middleware.ts
- Remove Sentry env vars from env.example and docs
- Update CLAUDE.md, copilot-instructions.md, PRODUCTION_READINESS.md

Middleware bundle reduced from 86KB to 34.8KB (-51KB).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
2026-03-04 13:00:34 +01:00
parent de3ef37b48
commit 60ea4e99be
15 changed files with 97 additions and 2893 deletions

View File

@@ -13,7 +13,7 @@ This document provides an assessment of the portfolio website's production readi
- [x] Input sanitization on forms
- [x] SQL injection protection (Prisma ORM)
- [x] XSS protection via React and sanitize-html
- [x] Error monitoring with Sentry.io
- [x] Error logging in development mode
### Performance
- [x] Next.js App Router with Server Components
@@ -42,10 +42,8 @@ This document provides an assessment of the portfolio website's production readi
- [x] Analytics opt-in (Umami - privacy-friendly)
- [x] Data processing documentation
- [x] Contact form with consent
- [x] Sentry.io mentioned in privacy policy
### Monitoring & Observability
- [x] Sentry.io error tracking (configured)
- [x] Umami analytics (self-hosted, privacy-friendly)
- [x] Health check endpoint (`/api/health`)
- [x] Logging infrastructure
@@ -79,15 +77,6 @@ This document provides an assessment of the portfolio website's production readi
- Locations: Hero.tsx, CurrentlyReading.tsx, Projects pages
- Benefit: Better performance, automatic optimization
2. **Configure Sentry.io DSN**
- Set `NEXT_PUBLIC_SENTRY_DSN` in production environment
- Set `SENTRY_AUTH_TOKEN` for source map uploads
- Get DSN from: https://sentry.io/settings/dk0/projects/portfolio/keys/
3. **Review CSP for Sentry**
- May need to adjust Content-Security-Policy headers to allow Sentry
- Add `connect-src` directive for `*.sentry.io`
### Medium Priority
1. **Accessibility audit**
- Run Lighthouse audit
@@ -105,7 +94,6 @@ This document provides an assessment of the portfolio website's production readi
### Low Priority
1. **Enhanced monitoring**
- Custom Sentry contexts for better debugging
- Performance metrics dashboard
2. **Advanced features**
@@ -123,10 +111,6 @@ Before deploying to production:
DATABASE_URL=postgresql://...
REDIS_URL=redis://...
# Sentry (Recommended)
NEXT_PUBLIC_SENTRY_DSN=https://...@sentry.io/...
SENTRY_AUTH_TOKEN=...
# Email (Optional)
MY_EMAIL=...
MY_PASSWORD=...
@@ -156,7 +140,6 @@ Before deploying to production:
- Test HTTPS redirect
6. **Monitoring**
- Verify Sentry is receiving events
- Check Umami analytics tracking
- Test health endpoint
@@ -200,13 +183,12 @@ The application is production-ready with the following notes:
3. **Performance**: Optimized for production
4. **SEO**: Properly configured for search engines
5. **Privacy**: GDPR-compliant with privacy policy
6. **Monitoring**: Sentry.io configured (needs DSN in production)
6. **Monitoring**: Umami analytics (self-hosted)
**Next Steps**:
1. Configure Sentry.io DSN in production environment
2. Replace `<img>` tags with Next.js `<Image />` for optimal performance
3. Run final accessibility audit
4. Monitor performance metrics after deployment
1. Replace `<img>` tags with Next.js `<Image />` for optimal performance
2. Run final accessibility audit
3. Monitor performance metrics after deployment
---