Skip to content

armgit / E2B

Public Imported from GitHub
0

Open-source, secure environment with real-world tools for enterprise-grade agents.

Add redirects

Tomas Valenta3dff8980f823
diff --git a/apps/reverse-proxy/middleware.ts b/apps/reverse-proxy/middleware.ts
index 94a381edc..c81c2f8c2 100644
--- a/apps/reverse-proxy/middleware.ts
+++ b/apps/reverse-proxy/middleware.ts
@@ -13,6 +13,14 @@ export async function middleware(req: NextRequest): Promise<NextResponse> {
url.hostname = 'e2b-landing-page.framer.website'
}
+ if (url.pathname.startsWith('/terms') || url.pathname.startsWith('/terms/')) {
+ url.hostname = 'e2b-landing-page.framer.website'
+ }
+
+ if (url.pathname.startsWith('/privacy') || url.pathname.startsWith('/privacy/')) {
+ url.hostname = 'e2b-landing-page.framer.website'
+ }
+
if (url.pathname.startsWith('/ai-agents')) {
url.hostname = 'e2b-landing-page.framer.website'
}
@@ -51,5 +59,5 @@ export async function middleware(req: NextRequest): Promise<NextResponse> {
// We should probably filter all /, /blog and /changelog paths here and decide what to do with them in the middleware body.
export const config = {
- matcher: ['/', '/blog/:path*', '/changelog/:path*', '/ai-agents/:path*'],
+ matcher: ['/', '/blog/:path*', '/changelog/:path*', '/ai-agents/:path*', '/privacy/:path*', '/terms/:path*'],
}