N
Novu14mo ago
rp1303

self

How to setup novu web with docker for contribution? Self Hosting
No description
14 Replies
rp1303
rp1303OP14mo ago
Which jwt_secert we have to pass?
No description
Sathish
Sathish14mo ago
Same error i am getting.please help
Sudhanshu
Sudhanshu14mo ago
GitHub
Project Setup: Clearing Most Common asked doubts ( For Window User...
How to Setup Novu for the First Time? Refer to this Run Novu in Local Machine. 1. Unable to Login ? Mostly it happens if you did not set up the MongoDB and Redis. Solution 1: Just run npm run start...
rp1303
rp1303OP14mo ago
This option for local machine I have self hosted Digitalocean thorw above error @Sudhanshu
Novu_Bot
Novu_Bot14mo ago
@rp1303, you just advanced to level 1!
rp1303
rp1303OP14mo ago
Here is my env file data JWT_SECRET=SECRET_KEY STORE_ENCRYPTION_KEY=C8lrtIKEDWetdO9VcC7yb5TdDuk8WoRY General NODE_ENV=production MONGO_URL=mongodb+srv://jupiter:[email protected]/jupiter_novu?retryWrites=true&w=majority MONGO_MAX_POOL_SIZE=500 REDIS_HOST=redis REDIS_PASSWORD= REDIS_CACHE_SERVICE_HOST= Ports API_PORT=3000 REDIS_PORT=6379 REDIS_CACHE_SERVICE_PORT=6379 WS_PORT=3002 Root URL REACT_APP_WS_URL=http://146.190.240.211:3002 Uncomment this one when deploying Novu in the local environment as Web app local Dockerfile will have to load this to be used. Deployment version doesn't need as we inject it with API_ROOT_URL value. REACT_APP_API_URL=http://localhost:3000 API_ROOT_URL=http://146.190.240.211:3000 DISABLE_USER_REGISTRATION=false FRONT_BASE_URL=http://146.190.240.211:4200 WIDGET_EMBED_PATH=http://146.190.240.211:4701/embed.umd.min.js WIDGET_URL=http://146.190.240.211:4500 Context Paths Only needed for setups with reverse-proxies GLOBAL_CONTEXT_PATH= WEB_CONTEXT_PATH= API_CONTEXT_PATH= WS_CONTEXT_PATH= WIDGET_CONTEXT_PATH= Analytics SENTRY_DSN= NEW_RELIC_APP_NAME= NEW_RELIC_LICENSE_KEY= @Pawan Jain above env file right? And I am passing digitalocen server Ipaddress in api_root_url I have self-hosted in Digitalocean throwing in network error how do I solve these can you guide me?
todd
todd13mo ago
@rp1303 self hosting is a "tricky" definition for Novu. I have a self hosted version and spend more time that I care to admin getting it working for a production environment. Summary: development environment is seamless—production-like is hard. I started with a development environment, "self hosted". That was a single machine docker using the docker compose that also gave me s3, mongodb and redis as well as the network. This is straightforward. I actually use minio for s3 because it gives better retention than localstack. Next, might be to get it onto a machine with a proxy and DNS and start separating out the services. I found generally that the logging was too noisey and turned the level down to see the errors. Finally, I have all my services terraformed with high availability (cluster and managed mongo and redis services, as well as S3). I run mine on AWS and the networks/perms need quite a bit of work. Throughout each of these steps, you'll need to get good finding the errors—the initial secrets are an easy gotcha but it is logged. In short, it is a long road to production-quality self hosting. I have written elsewhere you need to know what you want/why (design/availability/data sovereignty) and what you willing to pay. The overall design for Novu is for large scale deployment IMHO—well exceeding my needs. I hope there is something useful in this because without specific errors messages it is hard to see how far you have got! Good luck 🙂
Novu_Bot
Novu_Bot13mo ago
@todd, you just advanced to level 4!
rp1303
rp1303OP13mo ago
@todd Please provide a valid app identifier show error
todd
todd13mo ago
@rp1303 I'm sorry but I don't understand. Looking at the image above, the problem is that the client/browser is making requests to localhost. You instead need it to request your server http://146.190.240.211. Your docker compose 'web' needs its environment variables set—so you need to check WHY it isn't. That is why you .env file you have the settings isn't being picked up.
Dauntless
Dauntless8mo ago
@todd Would you be willing to write a guide for production environment hosting?
todd
todd8mo ago
I am going to be a little bold here. Writing a guide is probably the wrong direction because it should really be a deployment scripts via tooling into environments. I know that there needs to be some documentation. My problem was the subtleties of making it work that IMHO most documentation can't cover. I have and am still happy to share my deployment scripts (but there are not generalised because they are part of my production environment). I deploy via terraform to AWS. However, much is also about the plugging in credentials into my services to talk back to the services. Finally, I am snowed under and still running 0.18 of the project. I am behind on upgrades and am probably still a month out. Have you seen my other pieces and are there specifics you are looking for?
Dauntless
Dauntless8mo ago
I understand. I'm a full-stack dev who is new to a lot of things devops. I started self-hosting less than a year ago, and I'm still figuring a lot of things out. Making things work locally, fine. Making things work with docker compose, on a vps with reverse proxies is a little harder, and I often find it difficult to debug. Sometimes I like to follow guides, just to see how some things are deployed from start to finish, but there are always some details that need to be adhered to for each case, and that's where my lack of experience creates challenges. It's not so much about having scripts handy, as it is about following good practices and understanding concepts. Right now I have Novu deployed, logs show no errors, the reverse proxy seems to route correctly. But somehow I'm getting a blank page that says in the source that you need to enable javascript to view this page. So clearly something is misconfigured, and a static page is loader rather than the React frontend I'm looking for. If there was a guide I'd probably be able to go through the steps, cross ref with my own, and point out the mistake I made. But I have full understanding for something like this not being available. I'm using coolify, which I'd honestly rather move away from and just set up nginx instead of relying on the automation it provides, and do everything in the command line. Hosted on a Hetzner VPS. What do you think @todd ?
todd
todd8mo ago
I am wanting solutions/hosting that are/is transparent (understandable and explainable), automate-able (into a continuous build pipeline but be usable from a local dev machine) and economic at scale (from free in local dev to reasonable price through environment and in the large in production if needed). I'm sure, say, DevOps has this well defined somewhere and more elegantly said. If you go back to old school computer science like Fred Brooks (and DeRemer & Kron), it is based around models of programming in the large. It feels to me is that "trend" (aka trendy) is to provide hosting and development approaches which tend towards programming in the small—in other word, glue code as the primary mode to create systems. In terms of command line, yes in some environments and in some environment never as standard but possible as fallback. Your Hetzner VPS looks to be regionally based so may not solve multi-zone implementations—if that was the case given I supply services to the Pacific, it probably isn't so good! So the answer is it depends on which constraints you want to subordinate too—and if you subordinate them all means you have missed the one that makes the others a group of constraints themselves.
Want results from more Discord servers?
Add your server