Skip to content

Instantly share code, notes, and snippets.

@velotiotech
Created June 17, 2020 05:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save velotiotech/00de67f9d100e89a85a3ad7de55474d3 to your computer and use it in GitHub Desktop.
Save velotiotech/00de67f9d100e89a85a3ad7de55474d3 to your computer and use it in GitHub Desktop.
Velotio - HashiCorp Consul Part 2 - Configuration of Django App with Consul KV using Consul's HTTP API
# Flag to run Django app in debug mode
curl -X PUT -d 'True' consul_server:8500/v1/kv/web/debug
# Dynamic entries into Django app configuration
# to denote allowed set of hosts
curl -X PUT -d 'localhost, 33.10.0.100' consul_server:8500/v1/kv/web/allowed_hosts
# Dynamic entries into Django app configuration
# to denote installed apps
curl -X PUT -d 'tweetapp' consul_server:8500/v1/kv/web/installed_apps
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment