I’m working on a personal blog that will be used for reviewing various goods/services and as a dev journal. I’m writing this in Angularjs and Nodejs as a learning experience, but I plan on using it for a long time as well.
I have a section like a newspaper column where authenticated users can write their own mini blog and can also upload their own images. I plan on limiting all images on the blogs to 4 files (max) at 1MB (max) each.
I’ve seen a lot of angular file upload plugins, which is nice, but my primary concern is whether I should serve the images through a cdn now or to just store everything (the site, database, images, etc) on a single VPS instance. Digital Ocean gives 2 TB transfer (incoming + outgoing combined), and disk storage is pretty cheap.
I guess I’m not sure when to optimize bandwidth costs and server loads? If I do it now, there’s an extra upfront cost in dev time and monetary costs, but in the long run things may be easier to manage. If instead I deploy everything on one instance and then migrate the site to a CDN when there’s a consistent traffic increase, this may be cheaper upfront, but migrating the database may be a huge pain/testing nightmare? I don’t expect much traffic. Maybe 100k-200k daily views at best after a few years(optimistically speaking).
1
I’d follow the YAGNI approach for this (You Aint Gonna Need It). If you don’t need a CDN right now, keep it all on your server. There’s no need to carry extra expense and complication for something you don’t even know you’ll need for sure. Just be sure to code the site and set up the database with the notion that you may do a migration someday in the future