Skip to content

bratucornel/consulenv

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ConsulENV

Pulls key/value pairs from Consul KV store and returns it to stdout.

Alternative to envconsul.

  • It doesn't keep connection to Consul opened.
  • Env variable change is not triggering service restart, that's handled by rolling update to secure availability.
  • Env variables are loaded in order specified by prefixes, interpolation supported.

Building

go build

Configuring

use config.example.yml or env variables.

  • CONSUL_HTTP_ADDR (localhost:1234)
  • CONSUL_HTTP_TOKEN
  • CONSUL_HTTP_AUTH (user:pass)
  • CONSUL_HTTP_SSL (true|false)

Running

eval "$(./consulenv -p staging/env/ -p staging/MyApp/env/)"

About

Pulling ENV from Consul KV

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Go 91.9%
  • Makefile 8.1%