Production code

feat : 2 factor authentication , OTP service , Session timeout
This commit is contained in:
2025-10-15 11:50:25 +05:30
parent 569e31bf12
commit ad19f0cb4c
7 changed files with 62 additions and 40 deletions

View File

@@ -1,4 +1,8 @@
/** @type {import('next').NextConfig} */
import os from "os";
const isWindows = os.platform() === "win32";
const nextConfig = {
experimental: {
serverComponentsExternalPackages: ["typeorm", "knex"],
@@ -6,15 +10,12 @@ const nextConfig = {
reactStrictMode: true,
// For port transfer
async rewrites() {
return[
return [
{
source:'/api/:path*',
destination: 'http://localhost:8080/api/:path*',
// prod
// destination : 'http://lb-kccb-mobile-banking-app-848675342.ap-south-1.elb.amazonaws.com:8080/api/:path*',
// Testing
// destination: 'http://lb-test-mobile-banking-app-192209417.ap-south-1.elb.amazonaws.com:8080/api/:path*',
source: '/api/:path*',
destination: isWindows
? "http://localhost:8080/api/:path*" // For Windows
: "https://kccbmbnk.net/api/:path*", // For Linux/Mac/Server
},
];
},