Chronicles of the Afro Kid
Chronicles of the Afro Kid
It goes without saying that having the ability to schedule posts is somewhat of a must-have functionality in a CMS - at least that's what I've noticed or heard. Before I begin, note that this is a poor man's implementation of a post scheduler. In my opinion, it is not scalable and should not be used if you have 50+
Now that Let's Encrypt is in public beta, you can go ahead and secure all your websites and move one step closer to making the web a more secure place. At the time of writing, automatic configuration for Nginx is still in development, so it's a better idea to generate the certificates manually and place them manually in the configuration
This weird problem came to be when I was trying to enforce HTTPS for a NodeJS application running behind 2 ELBs (Elastic Load Balancers) on AWS. The NodeJS application in question had sockets running for real-time communication with the client. The ELBs were configured to listen over TCP for HTTP and SSL for HTTPS and redirect to the NodeJS app
I use Mongoose - the ORM for MongoDB, everyday, and there's one thing in Mongoose, I find very extremely useful - discriminators. In a nutshell, it's inheritance of database models but the documentation for it has a lot to be desired. I was working on a model that made use of discriminators and like before, I thought it would be
The problem We have an app running on the MEAN stack and are using MongooseJS as our ORM. Now, we have 2 collections event and eventV2. We are looking to drop the event collection and rename the eventV2 collection to just event. The solution This means running a migration script and fortunately for us, mongoose can connect to MongoDB directly