A Puppet module to manage the config and jobs of Consul Template from Hashicorp
Перейти к файлу
gdhbashton c5b3ed6b77 Merge pull request #1 from bashtoni/master
Working spec tests + cleanups
2015-01-30 11:18:21 +00:00
files Initial commit 2015-01-23 13:08:00 +00:00
lib/puppet Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
manifests Fix arch tests 2015-01-30 11:01:07 +00:00
spec Fix arch tests 2015-01-30 11:01:07 +00:00
templates Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
tests Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
.fixtures.yml Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
.gitignore Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
.travis.yml Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
CHANGELOG Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
CONTRIBUTING.md Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
CONTRIBUTORS Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
Gemfile Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
Gemfile.lock Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
Guardfile Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
LICENSE Initial commit 2015-01-23 13:08:00 +00:00
Modulefile Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
README.markdown Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
Rakefile Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00
metadata.json Massive cleanup; working spec tests! 2015-01-30 10:40:29 +00:00

README.markdown

#consul_template for Puppet

##Installation

###What This Module Affects

  • Installs the consul-template binary (via url or package)
  • Optionally installs a user to run it under
  • Installs a configuration file (/etc/consul-template/config.json)
  • Manages the consul-template service via upstart, sysv, or systemd

##Usage

include consul_template

Watch files

To declare a file that you wish to populate from Consul key-values, you use the watch define. This requires a source .ctmpl file and the file on-disk that you want to update.

consul_template::watch { 'common':
    template    => 'data/common.json.ctmpl.erb',
    destination => '/tmp/common.json',
    command     => 'true',
}

##Limitations

Depends on the JSON gem, or a modern ruby.

##Development Open an issue or fork and open a Pull Request