Trying to migrate to a new server with the current database and the same codebase

[Picture deleted][Picture deleted]

I need the response, this is still what is sent :wink:

I don’t have a call from this url in the network tab

I can send you the .har file with all the network traffic but it is over 15mb (over the 8mb limit here) and does not contain

I deleted the development branch that directed to localhost, even though I was trying to connect to the production branch, and now I am getting a different error when trying to connect:

Hmm, it’s a CORS issue. Could you share you CORS configuration ?

  credentials: true,
  origin: [

The server code has not changed when migrating to the new server and this code works with the GSL_Admin project in the production environment

import express from "@feathersjs/express";
import dotenv from "dotenv";
import jwt from "express-jwt";
import Liana, { ensureAuthenticated, PUBLIC_ROUTES } from "forest-express-mongoose";
import Mongoose from "mongoose";
import path from "path";
import { Application } from "./declarations";
import logger from "./logger";
import projectAssessmentsRoutes from "./routes/projectassessments";
import projectRoutes from "./routes/projects";
import userRoutes from "./routes/users";


export default async function forestAdmin(app: Application) {
  const connection = app.get("mongooseClient");
  const forestConfig = app.get("forestAdmin");

  console.log(`forestConfig.envSecret: ${forestConfig.envSecret}`)
  console.log(`forestConfig.authSecret: ${forestConfig.authSecret}`)

  const liana = await Liana.init({
    configDir: path.join(__dirname, '/forest'),
    envSecret: forestConfig.envSecret,
    authSecret: forestConfig.authSecret,
    schemaDir: process.env.FOREST_SCHEMA_DIR,
    objectMapping: Mongoose,
    connections: {
        default: connection


      secret: forestConfig.authSecret,
      credentialsRequired: false,
      algorithms: ["HS256"],

  app.use(['/forest', '/forest/*'], (request: any, response: any, next: any) => {"forest route");
    if (PUBLIC_ROUTES.includes(request.url)) {"public forest route");
      return next();
    }"checking authentication");
    return ensureAuthenticated(request, response, next);

  app.use(express.errorHandler({ logger } as any));

This is the code we use on the server to communicate with forest. It works when running on the localhost during the initial setup. Is there something here that can cause this issue in the production environment?

Could you try something like:

  credentials: true,
  origin: [
  credentials: true,
  allowedHeaders: ['Authorization', 'X-Requested-With', 'Content-Type', 'forest-context-url'],

let me know if it works

I added your code, besides the null that caused the ts error about string not being able to be null, but I still get the same error

Which cors package or you using ?