Skip to content

Instantly share code, notes, and snippets.

@pranavcode
Created March 30, 2019 17:53
Show Gist options
  • Save pranavcode/83366fe1a859f818e3b59a57a06af73b to your computer and use it in GitHub Desktop.
Save pranavcode/83366fe1a859f818e3b59a57a06af73b to your computer and use it in GitHub Desktop.
Velotio - HashiCorp Consul Part 2 - Django configuration settings for connecting MongoDB instance on different host using Djongo
...
DATABASES = {
'default': {
'ENGINE': 'djongo',
'NAME': 'db',
'HOST': 'mongodb://mongo-primary.service.consul',
'PORT': 27017,
}
}
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment