N
Novu13mo ago
starsend

Self hosted set up with custom Db

Hi folks, I checked the documentation and the wee chat feature, but I can't figure out how to actually get it up and running with a custom DB. What do I need to do? Couldn't find any guides - just spin up a mongo DB in aws?
4 Replies
todd
todd13mo ago
@starsend I have just spend way too much time (and now it turns out money as well) on MongoDb Atlas (AWS hosted). Others have done DocumentDB. You could also cluster it or run if off an instance (but those non-managed services have to have persistence managed too). So,iIt depends on your budget. I found the dev version on docker seamless, but productionising is harder and expensive (in AWS). It seems you need to think about ownership of data (self hosting because I don't see export functionality), cost (in small scale I would run with Novu—or a low availability self-hosted version). From what I am seeing between setup instructions and data migrations, you are going to have to work harder than expected. For example, you need to setup redis and s3 in some form too—plus logging. Also, when containerising there are at least 4 workloads to setup—as well as the front door, etc. I plan to share my terraform scripts to help people understand the scope of this exercise and that Novu's pricing is reasonable particularly when you take into account the maintenance costs. I hope this is a reasonable assessment and helpful. @starsend Oh, and I forgot to say. There is a last decision on how you deal with all this in a build pipeline for EACH environment. I go for isolation and thus stand up everything separately (ie seperate mongo cluster per environment rather than seperate collections). That also adds to the expense and make it is further expensive. 😦 Alternatively, you can deal with environments at db connection level or in the cloud solution through the API via environments. Again depends on what you want—marketing vs automation led approach.
starsend
starsend13mo ago
Right, my biggest problem is that it seems like on the ec2 box The DB gets periodically wiped and drops all users which is a bit of a pain, since it basically needs to be set up again and again
todd
todd13mo ago
Your volume should be persistent on a virtual machine—sounds like you are doing all-in-one deployment via docker compose not your original "spin up MongoDB in aws" which is to separate out the database. Again, the development solution is easy. Novu has made it easy to deploy on a single machine—and by inference same network. I suspect drawing out your design will help. I also find that terraforming all aws services is helpful (and painful).
starsend
starsend13mo ago
Yeah, think I am going to either go hosted or just go with mailgun or sth sismpler for the time being, thank you so much todd!
Want results from more Discord servers?
Add your server