Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 Bug Report: Self Hosted signup process fails #6410

Open
2 tasks done
AdzeB opened this issue Aug 29, 2024 · 3 comments
Open
2 tasks done

🐛 Bug Report: Self Hosted signup process fails #6410

AdzeB opened this issue Aug 29, 2024 · 3 comments

Comments

@AdzeB
Copy link

AdzeB commented Aug 29, 2024

📜 Description

The signup process fails with a 431 Request Header Fields Too Large error using mongoDB altas and coolify (docker-compose )

👟 Reproduction steps

  1. Set up Novu using Docker with MongoDB Atlas as the database.
  2. Configure the environment variables in the .env file, including MONGO_URL for MongoDB Atlas.
  3. Start the Novu services using docker-compose.
  4. Navigate to http://MY_IP_ADDRESS:4200/auth/signup
  5. Enter signup details and click on the sign-up button.
  6. Observe the 431 error

My Env

API_CONTEXT_PATH=
API_PORT=3000
API_ROOT_URL=$HOST_NAME:3000
AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=
BROADCAST_QUEUE_CHUNK_SIZE=
DISABLE_USER_REGISTRATION=
DOCKER_REDIS_SERVICE_PORT=6379
FRONT_BASE_URL=$HOST_NAME:4200
HOST_NAME=http://<REDACTED>
IS_MULTI_TENANCY_ENABLED=
JWT_SECRET=<REDACTED>
MONGO_INITDB_ROOT_PASSWORD=<REDACTED>
MONGO_INITDB_ROOT_USERNAME=<REDACTED>
MONGO_MAX_POOL_SIZE=
MONGO_MIN_POOL_SIZE=
MONGO_URL=mongodb+srv://<REDACTED>:<REDACTED>@<REDACTED>/novu-db?authSource=admin
MULTICAST_QUEUE_CHUNK_SIZE=
NEW_RELIC_APP_NAME=
NEW_RELIC_LICENSE_KEY=
NODE_ENV=local
REACT_APP_API_URL=$HOST_NAME:3000
REACT_APP_WS_URL=$HOST_NAME:3002
REDIS_CACHE_SERVICE_HOST=
REDIS_CACHE_SERVICE_PORT=6379
REDIS_HOST=redis
REDIS_PASSWORD=
REDIS_PORT=
S3_BUCKET_NAME=
S3_LOCAL_STACK=
S3_REGION=
SENTRY_DSN=
STORE_ENCRYPTION_KEY=<REDACTED>
WIDGET_CONTEXT_PATH=
WIDGET_EMBED_PATH=$HOST_NAME:4701/embed.umd.min.js
WIDGET_URL=$HOST_NAME:4500
WS_CONTEXT_PATH=
WS_PORT=3002

👍 Expected behavior

The signup process should complete successfully, creating a new user in the MongoDB Atlas database.be completed

👎 Actual Behavior with Screenshots

Receiving a 431 Request Header Fields Too Large error. The request URL shown is:
http://MY_IP_ADDRESS:4200/auth/:3000/v1/auth/register
Request Method: POST
Status Code: 431 Request Header Fields Too Large
image

Novu version

0.24.0 (based on the Docker image versions in the compose file)

npm version

NA (using Docker setup)

node version

NA (using Docker setup)

📃 Provide any additional context for the Bug.

  • Using MongoDB Atlas instead of a local MongoDB instance.
  • Environment variables for API_ROOT_URL and FRONT_BASE_URL are set using $HOST_NAME:
  • API_ROOT_URL=$HOST_NAME:3000
  • FRONT_BASE_URL=$HOST_NAME:4200
  • The full .env configuration is based on the .env.example file provided by Novu.
  • The error URL (http://MY_IP_ADDRESS:4200/auth/:3000/v1/auth/register) suggests there might be an issue with how the API URL is being constructed.

👀 Have you spent some time to check if this bug has been raised before?

  • I checked and didn't find a similar issue

🏢 Have you read the Contributing Guidelines?

Are you willing to submit PR?

None

Copy link

linear bot commented Aug 29, 2024

@jainpawan21
Copy link
Member

@AdzeB

I see request url is not correct. it is using both 4200 and 3001 port

Can you check if all environment variables are correct as per our example?

@AdzeB
Copy link
Author

AdzeB commented Oct 8, 2024

Hi @jainpawan21 , I have deleted the server but I kept the env record on my notes, please find it attached here

API_CONTEXT_PATH=

API_PORT=3000

API_ROOT_URL=$HOST_NAME:3000

AWS_ACCESS_KEY_ID=

AWS_SECRET_ACCESS_KEY=

BROADCAST_QUEUE_CHUNK_SIZE=

DISABLE_USER_REGISTRATION=

DOCKER_REDIS_SERVICE_PORT=6379

FRONT_BASE_URL=$HOST_NAME:4200

HOST_NAME=http://IP_ADDRESS_HERE

IS_MULTI_TENANCY_ENABLED=

JWT_SECRET=2rAULjLcL6@o\*

MONGO_INITDB_ROOT_PASSWORD=PASSWORD

MONGO_INITDB_ROOT_USERNAME=USERNAME

MONGO_MAX_POOL_SIZE=

MONGO_MIN_POOL_SIZE=

MONGO_URL=MONGO_DB_HERE

MULTICAST_QUEUE_CHUNK_SIZE=

NEW_RELIC_APP_NAME=

NEW_RELIC_LICENSE_KEY=

NODE_ENV=local

REACT_APP_API_URL=$HOST_NAME:3000

REACT_APP_WS_URL=$HOST_NAME:3002

REDIS_CACHE_SERVICE_HOST=

REDIS_CACHE_SERVICE_PORT=6379

REDIS_HOST=redis

REDIS_PASSWORD=

REDIS_PORT=

S3_BUCKET_NAME=

S3_LOCAL_STACK=

S3_REGION=

SENTRY_DSN=

STORE_ENCRYPTION_KEY=RANDOM_HERE

WIDGET_CONTEXT_PATH=

WIDGET_EMBED_PATH=$HOST_NAME:4701/embed.umd.min.js

WIDGET_URL=$HOST_NAME:4500

WS_CONTEXT_PATH=

WS_PORT=3002  

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants