2
0
salt-formula/salt/files/minion.d/f_defaults.conf

373 lines
10 KiB
Plaintext
Raw Normal View History

2013-08-14 16:43:46 +02:00
# This file managed by Salt, do not edit by hand!!
# Based on salt version 0.17.4 default config
2014-10-03 10:43:59 +02:00
{% set reserved_keys = ['master', 'minion', 'cloud', 'salt_cloud_certs'] -%}
{% set cfg_salt = pillar.get('salt', {}) -%}
{% set cfg_minion = cfg_salt.get('minion', {}) -%}
2013-08-14 16:43:46 +02:00
{%- macro get_config(configname, default_value) -%}
{%- if configname in cfg_minion -%}
{{ configname }}: {{ cfg_minion[configname] }}
{%- elif configname in cfg_salt and configname not in reserved_keys -%}
{{ configname }}: {{ cfg_salt[configname] }}
2013-08-14 16:43:46 +02:00
{%- else -%}
#{{ configname }}: {{ default_value }}
{%- endif -%}
{%- endmacro -%}
{%- from 'salt/formulas.jinja' import file_roots, formulas with context -%}
2013-07-15 13:25:42 +02:00
##### Primary configuration settings #####
##########################################
# minion includes
{{ get_config('default_include', 'minion.d/*.conf') }}
2013-07-15 13:25:42 +02:00
# master configs
{%- if 'master' in cfg_minion -%}
{%- if cfg_minion['master'] is not string %}
master:
{% for name in cfg_minion['master'] -%}
- {{ name }}
{% endfor -%}
{%- else %}
2013-08-14 16:43:46 +02:00
{{ get_config('master', 'salt') }}
{%- endif %}
{% elif 'master' in cfg_salt -%}
{%- if cfg_salt['master'] is not string %}
master:
{% for name in cfg_salt['master'] -%}
- {{ name }}
{% endfor -%}
{%- else %}
{{ get_config('master', 'salt') }}
{%- endif -%}
{%- endif %}
# choose a random master
{{ get_config('random_master', 'False') }}
# use IPv6
2013-08-14 16:43:46 +02:00
{{ get_config('ipv6', 'False') }}
2013-07-15 13:25:42 +02:00
# name resolution retries
2013-08-14 16:43:46 +02:00
{{ get_config('retry_dns', '30') }}
2013-07-15 13:25:42 +02:00
# master port
2013-08-14 16:43:46 +02:00
{{ get_config('master_port', '4506') }}
2013-07-15 13:25:42 +02:00
# user to run salt.
2013-08-14 16:43:46 +02:00
{{ get_config('user', 'root') }}
2013-07-15 13:25:42 +02:00
# PID file
2013-08-14 16:43:46 +02:00
{{ get_config('pidfile', '/var/run/salt-minion.pid') }}
2013-07-15 13:25:42 +02:00
# root dir
2013-08-14 16:43:46 +02:00
{{ get_config('root_dir', '/') }}
2013-07-15 13:25:42 +02:00
# pki dir
2013-08-14 16:43:46 +02:00
{{ get_config('pki_dir', '/etc/salt/pki/minion') }}
2013-07-15 13:25:42 +02:00
# minion id
{% if 'id' in cfg_minion -%}
id: {{ cfg_minion['id'] }}
2013-08-14 16:43:46 +02:00
{% else -%}
2013-07-15 13:25:42 +02:00
#id:
2013-08-14 16:43:46 +02:00
{%- endif %}
2013-07-15 13:25:42 +02:00
# domain name for hostnames
2013-08-14 16:43:46 +02:00
{{ get_config('append_domain', '') }}
2013-07-15 13:25:42 +02:00
# custom grains
2013-08-14 16:43:46 +02:00
{{ get_config('grains', '{}') }}
2013-07-15 13:25:42 +02:00
# cache location
2013-08-14 16:43:46 +02:00
{{ get_config('cachedir', '/var/cache/salt/minion') }}
2013-07-15 13:25:42 +02:00
# environment verification
2013-08-14 16:43:46 +02:00
{{ get_config('verify_env', 'True') }}
2013-07-15 13:25:42 +02:00
# cache executed jobs
2013-08-14 16:43:46 +02:00
{{ get_config('cache_jobs', 'False') }}
2013-07-15 13:25:42 +02:00
# unix socket location
2013-08-14 16:43:46 +02:00
{{ get_config('sock_dir', '/var/run/salt/minion') }}
2013-07-15 13:25:42 +02:00
# output formatter
2013-08-14 16:43:46 +02:00
{{ get_config('output', 'nested') }}
# output color
2013-08-14 16:43:46 +02:00
{{ get_config('color', 'True') }}
# remove nested color
{{ get_config('strip_colors', 'False') }}
# backup modified files
2013-08-14 16:43:46 +02:00
{{ get_config('backup_mode', 'minion') }}
2013-07-15 13:25:42 +02:00
# key acceptance time
2013-08-14 16:43:46 +02:00
{{ get_config('acceptance_wait_time', '10') }}
# maximum acceptance wait
2013-08-14 16:43:46 +02:00
{{ get_config('acceptance_wait_time_max', '0') }}
# retry key
{{ get_config('rejected_retry', 'False') }}
# time to wait for trying reauth
2013-08-14 16:43:46 +02:00
{{ get_config('random_reauth_delay', '60') }}
# auth wait timeout
{{ get_config('auth_timeout', '60') }}
# auth retries
{{ get_config('auth_tries', '7') }}
# retry auth if ping failed
{{ get_config('auth_safemode', 'False') }}
2013-08-14 16:43:46 +02:00
# master ping interval
{{ get_config('ping_interval', '0') }}
# salt mine functions execution interval
2015-02-20 20:43:14 +01:00
{{ get_config('mine_interval', '60') }}
# mine functions
{%- if 'mine_functions' in cfg_minion %}
mine_functions:
{%- for func, args in cfg_minion['mine_functions'].items() %}
{{ func }}: {{ args }}
{%- endfor %}
{%- endif %}
# reconnection parameters
2013-08-14 16:43:46 +02:00
{{ get_config('recon_default', '100') }}
{{ get_config('recon_max', '5000') }}
{{ get_config('recon_randomize', 'False') }}
2013-07-15 13:25:42 +02:00
# minion scheduler interval
2013-08-14 16:43:46 +02:00
{{ get_config('loop_interval', '60') }}
2013-07-15 13:25:42 +02:00
# grain refresh interval
{{ get_config('grains_refresh_every', '1') }}
# cache grains in minion
{{ get_config('grains_cache', 'False') }}
# grains cache expiration interval
{{ get_config('grains_cache_expiration', '300') }}
# ipc method
2013-08-14 16:43:46 +02:00
{{ get_config('ipc_mode', 'ipc') }}
# ipc tcp ports
2013-08-14 16:43:46 +02:00
{{ get_config('tcp_pub_port', '4510') }}
{{ get_config('tcp_pull_port', '4511') }}
2013-07-15 13:25:42 +02:00
# max event size in minion bus
{{ get_config('max_event_size', '1048576') }}
# master check alive interval
{{ get_config('master_alive_interval', '30') }}
2015-07-24 16:58:41 +02:00
# verify_master_pubkey_sign
{{ get_config('verify_master_pubkey_sign', 'False') }}
# include extra config
{% if 'include' in cfg_minion -%}
{% if isinstance(cfg_minion['include'], list) -%}
2013-07-22 16:56:36 +02:00
include:
{% for include in cfg_minion['include'] -%}
2013-07-22 16:56:36 +02:00
- {{ include }}
{% endfor -%}
{% else -%}
include: cfg_minion['include']
2013-07-22 16:56:36 +02:00
{% endif -%}
{% elif 'include' in cfg_salt -%}
{% if isinstance(cfg_salt['include'], list) -%}
2013-08-14 16:43:46 +02:00
include:
{% for include in cfg_salt['include'] -%}
2013-08-14 16:43:46 +02:00
- {{ include }}
{% endfor -%}
{% else -%}
include: cfg_salt['include']
2013-08-14 16:43:46 +02:00
{% endif -%}
2013-07-22 16:56:36 +02:00
{% endif -%}
2013-07-15 13:25:42 +02:00
2013-07-15 13:25:42 +02:00
##### Minion module management #####
##########################################
# disable modules
2013-08-14 16:43:46 +02:00
{{ get_config('disable_modules', '[cmd,test]') }}
{{ get_config('disable_returners', '[]') }}
2013-07-15 13:25:42 +02:00
#
# minion modules search paths
2013-08-14 16:43:46 +02:00
{{ get_config('module_dirs', '[]') }}
{{ get_config('returner_dirs', '[]') }}
{{ get_config('states_dirs', '[]') }}
{{ get_config('render_dirs', '[]') }}
{{ get_config('utils_dirs', '[]') }}
# module overrides
2013-08-14 16:43:46 +02:00
{{ get_config('providers', '{}') }}
# enable cython modules
2013-08-14 16:43:46 +02:00
{{ get_config('cython_enable', 'False') }}
# max module size
{{ get_config('modules_max_memory', '-1') }}
2013-07-15 13:25:42 +02:00
##### State Management Settings #####
###########################################
# renderer selection
2013-08-14 16:43:46 +02:00
{{ get_config('renderer', 'yaml_jinja') }}
# fail on first failure
{{ get_config('failhard', 'False') }}
# auto reload dynamic modules
2013-08-14 16:43:46 +02:00
{{ get_config('autoload_dynamic_modules', 'True') }}
# sync dynamic modules with deletion
2013-08-14 16:43:46 +02:00
{{ get_config('clean_dynamic_modules', 'True') }}
# minion accepted environment
2013-08-14 16:43:46 +02:00
{{ get_config('environment', 'None') }}
# top state file
2013-08-14 16:43:46 +02:00
{{ get_config('state_top', 'top.sls') }}
# states to run in minion daemon
2013-08-14 16:43:46 +02:00
{{ get_config('startup_states', "''") }}
# sls states to run
2013-08-14 16:43:46 +02:00
{{ get_config('sls_list', '[]') }}
# top file to run
{{ get_config('top_file', "''") }}
2013-07-15 13:25:42 +02:00
##### File Directory Settings #####
##########################################
# file client location
2014-12-21 15:35:45 +01:00
{%- if standalone %}
file_client: local
{%- else %}
2013-08-14 16:43:46 +02:00
{{ get_config('file_client', 'remote') }}
2014-12-21 15:35:45 +01:00
{%- endif %}
2013-07-15 13:25:42 +02:00
# environment file roots
{% if 'file_roots' in cfg_minion -%}
{{ file_roots(cfg_minion['file_roots']) }}
{%- elif 'file_roots' in cfg_salt -%}
{{ file_roots(cfg_salt['file_roots']) }}
{%- elif formulas|length -%}
{{ file_roots({'base': ['/srv/salt']}) }}
2013-08-14 16:43:46 +02:00
{%- endif %}
2013-07-15 13:25:42 +02:00
# limit fileserver traversal
{{ get_config('fileserver_limit_traversal', 'False') }}
# gitfs provider
{{ get_config('gitfs_provider', 'pygit2') }}
# gitfs remotes
{% if 'gitfs_remotes' in cfg_minion -%}
gitfs_remotes:
{%- for remote in cfg_minion['gitfs_remotes'] %}
{%- if remote is iterable and remote is not string %}
{%- for repo, children in remote.items() %}
- {{ repo }}:
{%- for child in children %}
{%- for key, value in child.items() %}
- {{ key }}: {{ value }}
{%- endfor -%}
{%- endfor -%}
{%- endfor -%}
{%- else %}
- {{ remote }}
{%- endif -%}
{%- endfor -%}
{%- endif %}
# verify git ssl errors
{{ get_config('gitfs_ssl_verify', 'True') }}
# gitfs root dir
{{ get_config('gitfs_root', 'somefolder/otherfolder') }}
# file hash method
2013-08-14 16:43:46 +02:00
{{ get_config('hash_type', 'md5') }}
2013-07-15 13:25:42 +02:00
# pillar roots
{% if 'pillar_roots' in cfg_minion -%}
2013-08-14 16:43:46 +02:00
pillar_roots:
{%- for name, roots in cfg_minion['pillar_roots']|dictsort %}
2013-08-14 16:43:46 +02:00
{{ name }}:
{%- for dir in roots %}
- {{ dir }}
{%- endfor -%}
{%- endfor -%}
{% elif 'pillar_roots' in cfg_salt -%}
2013-08-14 16:43:46 +02:00
pillar_roots:
{%- for name, roots in cfg_salt['pillar_roots']|dictsort %}
2013-08-14 16:43:46 +02:00
{{ name }}:
{%- for dir in roots %}
- {{ dir }}
{%- endfor -%}
{%- endfor -%}
2013-08-14 16:43:46 +02:00
{%- endif %}
2013-07-15 13:25:42 +02:00
2013-07-15 13:25:42 +02:00
###### Security settings #####
###########################################
# disable authentication
2013-08-14 16:43:46 +02:00
{{ get_config('open_mode', 'False') }}
# allow access to pki dir
2013-08-14 16:43:46 +02:00
{{ get_config('permissive_pki_access', 'False') }}
2013-07-15 13:25:42 +02:00
# print verbose changes
2013-08-14 16:43:46 +02:00
{{ get_config('state_verbose', 'True') }}
# multi line output
2013-08-14 16:43:46 +02:00
{{ get_config('state_output', 'full') }}
# output diff
{{ get_config('state_output_diff', 'False') }}
# master fingerprint
2013-08-14 16:43:46 +02:00
{{ get_config('master_finger', "''") }}
2013-07-15 13:25:42 +02:00
###### Thread settings #####
###########################################
# enable multiprocessing
2013-08-14 16:43:46 +02:00
{{ get_config('multiprocessing', 'True') }}
2013-07-15 13:25:42 +02:00
2013-07-15 13:25:42 +02:00
##### Logging settings #####
##########################################
# log file and log lock file location
2013-08-14 16:43:46 +02:00
{{ get_config('log_file', '/var/log/salt/minion') }}
{{ get_config('key_logfile', ' /var/log/salt/key') }}
# console log level
2013-08-14 16:43:46 +02:00
{{ get_config('log_level', 'warning') }}
# logfile log level
{{ get_config('log_level_logfile', '') }}
2013-07-15 13:25:42 +02:00
# datetime format for console and logfile
2013-08-14 16:43:46 +02:00
{{ get_config('log_datefmt', "'%H:%M:%S'") }}
{{ get_config('log_datefmt_logfile', "'%Y-%m-%d %H:%M:%S'") }}
# log format for console and logfiles
2013-08-14 16:43:46 +02:00
{{ get_config('log_fmt_console', "'[%(levelname)-8s] %(message)s'") }}
{{ get_config('log_fmt_logfile', "'%(asctime)s,%(msecs)03.0f [%(name)-17s][%(levelname)-8s] %(message)s'") }}
# log particular modules
2013-08-14 16:43:46 +02:00
{{ get_config('log_granular_levels', '{}') }}
2013-07-15 13:25:42 +02:00
2013-07-15 13:25:42 +02:00
###### Module configuration #####
###########################################
# module parameters
{%- if 'module_config' in cfg_minion %}
{%- for modkey, modval in cfg_minion.module_config.items() %}
{{ modkey }}: {{ modval }}
{%- endfor %}
{%- endif %}
2013-07-15 13:25:42 +02:00
2013-07-15 13:25:42 +02:00
###### Update settings ######
###########################################
# update url
2013-08-14 16:43:46 +02:00
{{ get_config('update_url', 'False') }}
# services to restart after update
2013-08-14 16:43:46 +02:00
{{ get_config('update_restart_services', '[]') }}
2013-07-15 13:25:42 +02:00
###### Keepalive settings ######
############################################
# use tcp keepalive
2013-08-14 16:43:46 +02:00
{{ get_config('tcp_keepalive', 'True') }}
# first keepalive from idle
2013-08-14 16:43:46 +02:00
{{ get_config('tcp_keepalive_idle', '300') }}
# keepalive number for connection lost
2013-08-14 16:43:46 +02:00
{{ get_config('tcp_keepalive_cnt', '-1') }}
# keepalive interval
2013-08-14 16:43:46 +02:00
{{ get_config('tcp_keepalive_intvl', '-1') }}
2013-07-15 13:25:42 +02:00
###### Windows Software settings ######
############################################
# windows repo cache
2013-08-14 16:43:46 +02:00
{{ get_config('win_repo_cachefile', 'salt://win/repo/winrepo.p') }}