juwai.consul-template

Ansible 角色: Consul-Template

在 CentOS 服务器上安装 Consul-Template。

要求

适用于 Ansible 2.0 及以上版本。

角色变量

可用的变量列在下面,以及默认值(请查看 defaults/main.yml):

consul_template_enabled

是否启用 consul-template。

默认值为 true

consul_template_supervisor_enabled

是否在 supervisor 中安装 consul-template。

默认值为 true

consul_template_user

consul-template 的用户。

默认用户为 consul

consul_template_group

consul-template 的组。

默认组为 consul

consul_template_version

consul-template 的版本。

默认版本为 0.10.0

consul_template_release

consul-template 的发布名称。

默认值为 consul-template_0.10.0_linux_386

consul_template_archive_file

consul-template 的发布压缩文件名。

默认值为 consul-template_0.10.0_linux_386.tar.gz

consul_template_download_url

下载链接。

默认值为 https://github.com/hashicorp/consul-template/releases/download/v0.10.0/consul-template_0.10.0_linux_386.tar.gz

consul_template_home

consul-template 的主目录。

默认值为 /home/consul/consul-template

consul_template_config_file_template

consul-template 主配置片段的模板名称。

默认值为 consul-template.cfg.j2

注意:此模板将生成 {{ consul_template_home }}/config/fragments/1_main.cfg

consul_template_config_file

consul-template 的配置文件名。

默认值为 consul-template.cfg

注意:此文件将生成在 {{ consul_template_home }}/config 下。

consul_template_consul_server

consul-template 要连接的 Consul 服务器。

默认值为 127.0.0.1

依赖关系

  • juwai.supervisor,当 consul_template_supervisor_enabled 为真时

示例剧本

- hosts: servers
  roles:
    - juwai.consul-template

许可证

MIT

作者信息

该角色由 Juwai Limited 于 2016 年创建。

关于项目

Ansible role for Consul Template

安装
ansible-galaxy install juwai.consul-template
许可证
mit
下载
2.5k
拥有者
Where Chinese find international property