Auth fixes, show correct cost each value on pos
This commit is contained in:
@@ -62,6 +62,11 @@ if (!process.env.JWT_SECRET) {
|
||||
const app = express();
|
||||
const PORT = Number(process.env.DASHBOARD_PORT) || 3015;
|
||||
|
||||
// Trust X-Forwarded-* only when the immediate hop is loopback (Caddy on the same
|
||||
// host). Required for the KIOSK_IPS bypass in shared/auth/middleware.js to see
|
||||
// real client IPs instead of 127.0.0.1.
|
||||
app.set('trust proxy', 'loopback');
|
||||
|
||||
// Single Postgres pool — used by authenticate() to load user permissions.
|
||||
// All four vendors share this pool (auth lookups are the only DB hits at runtime).
|
||||
const pool = createPool('DB');
|
||||
|
||||
Reference in New Issue
Block a user