Redis is a very popular in-memory database when it comes to caching. This post covers the basic configurations for setting up a Redis instance in docker.
Create a directory named
redisdb and ensure the following file structure.
data directory will contain the snapshots taken over time (as
redis.conf file will contain the instance configurations.
The below configurations are what seems important in general. Rest can be left to defaults.
bind 0.0.0.0 # bind to all available interfaces
protectedmode no # since we're not serving over localhost
port 6379 # default…
If you’re coming here for the first time, please take a look at the prequel Self-Hosted MongoDB.
Alright then, picking from where we left off, let’s get started with the data migration.
Now, the basic steps to migrate data from one MongoDB to another would be:
This is very straight forward when the source database is not online. Because we know for sure that there won’t be any new documents created/updated during the migration process.
Let’s look at simple migration first before diving into the…
Let’s Encrypt is a nonprofit Certificate Authority(CA) providing TLS certificates to 260 million websites.
I’m using an Ubuntu 20.4 instance on DigitalOcean for the demo and running my webserver on Nginx.
sudo apt install certbot python3-certbot-nginx
The above command downloads the certbot CLI tool along with it’s nginx plugin.
Say you have multiple subdomains available for your site e.g.
mysite.com, api.msysite.com, console.mysite.com
You might want to consider this option and generate a wildcard certificate valid for the names
I’m going to use
insurewill.com as the domain name here
certbot certonly --manual -d 'insurewill.com,*.insurewill.com'
The above command…
You’re probably hosting your MongoDB on a reliable cloud service provider say Atlas for instance because you really want to focus on your idea and delegate all the subtle key management areas such as networking, storage, access, etc.
It all looks good initially until your small idea starts turning into a business and the cost starts skyrocketing. Even if that is not the case, this post will still give you a general overview of the technical complexities involved (and bucks saved!) if you were to migrate to a self-hosted solution.
A service worker is a script that runs on a background thread and acts as a network proxy for the web application. It has capabilities such as intercepting all network requests within specified scope, caching files, background sync, push notification, etc which makes it very useful for adding offline support in a site or building a PWA(Progressive Web App).
Engineering @ Upraised | Working on something cool