ansible.cfg 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137
  1. # config file for ansible -- http://ansible.github.com
  2. # nearly all parameters can be overridden in ansible-playbook or with command line flags
  3. # ansible will read ~/.ansible.cfg or /etc/ansible/ansible.cfg, whichever it finds first
  4. [defaults]
  5. # location of inventory file, eliminates need to specify -i
  6. hostfile = /etc/ansible/hosts
  7. # location of ansible library, eliminates need to specify --module-path
  8. library = /usr/share/ansible
  9. # default module name used in /usr/bin/ansible when -m is not specified
  10. module_name = command
  11. # home directory where temp files are stored on remote systems. Should
  12. # almost always contain $HOME or be a directory writeable by all users
  13. remote_tmp = $HOME/.ansible/tmp
  14. # the default pattern for ansible-playbooks ("hosts:")
  15. pattern = *
  16. # the default number of forks (parallelism) to be used. Usually you
  17. # can crank this up.
  18. forks=5
  19. # the timeout used by various connection types. Usually this corresponds
  20. # to an SSH timeout
  21. timeout=10
  22. # when using --poll or "poll:" in an ansible playbook, and not specifying
  23. # an explicit poll interval, use this interval
  24. poll_interval=15
  25. # when specifying --sudo to /usr/bin/ansible or "sudo:" in a playbook,
  26. # and not specifying "--sudo-user" or "sudo_user" respectively, sudo
  27. # to this user account
  28. sudo_user=root
  29. # the following forces ansible to always ask for the sudo password (instead of having
  30. # to add -K to the commandline). Or you can use the environment variable (ANSIBLE_ASK_SUDO_PASS)
  31. #ask_sudo_pass=True
  32. # the following forces ansible to always ask for the ssh-password (-k)
  33. # can also be set by the environment variable ANSIBLE_ASK_PASS
  34. #ask_pass=True
  35. # connection to use when -c <connection_type> is not specified
  36. transport=paramiko
  37. # remote SSH port to be used when --port or "port:" or an equivalent inventory
  38. # variable is not specified.
  39. remote_port=22
  40. # if set, always run /usr/bin/ansible commands as this user, and assume this value
  41. # if "user:" is not set in a playbook. If not set, use the current Unix user
  42. # as the default
  43. #remote_user=root
  44. # the default sudo executable. If a sudo alternative with a sudo-compatible interface
  45. # is used, specify its executable name as the default
  46. sudo_exe=sudo
  47. # the default flags passed to sudo
  48. # sudo_flags=-H
  49. # how to handle hash defined in several places
  50. # hash can be merged, or replaced
  51. # if you use replace, and have multiple hashes named 'x', the last defined
  52. # will override the previously defined one
  53. # if you use merge here, hash will cumulate their keys, but keys will still
  54. # override each other
  55. # replace is the default value, and is how ansible always handled hash variables
  56. #
  57. # hash_behaviour=replace
  58. # if you need to use jinja2 extensions, you can list them here
  59. # use a coma to separate extensions, e.g. :
  60. # jinja2_extensions=jinja2.ext.do,jinja2.ext.i18n
  61. # no extensions are loaded by default
  62. #jinja2_extensions=
  63. # if set, always use this private key file for authentication, same as if passing
  64. # --private-key to ansible or ansible-playbook
  65. #private_key_file=/path/to/file
  66. # format of string $ansible_managed available within Jinja2 templates, replacing
  67. # {file}, {host} and {uid} with template filename, host and owner respectively.
  68. # The resulting string is passed through strftime(3) so it may contain any
  69. # time-formatting specifiers.
  70. #
  71. # Example: ansible_managed = DONT TOUCH {file}: call {uid} at {host} for changes
  72. ansible_managed = Ansible managed: {file} modified on %Y-%m-%d %H:%M:%S by {uid} on {host}
  73. # additional plugin paths for non-core plugins
  74. action_plugins = /usr/share/ansible_plugins/action_plugins
  75. callback_plugins = /usr/share/ansible_plugins/callback_plugins
  76. connection_plugins = /usr/share/ansible_plugins/connection_plugins
  77. lookup_plugins = /usr/share/ansible_plugins/lookup_plugins
  78. vars_plugins = /usr/share/ansible_plugins/vars_plugins
  79. filter_plugins = /usr/share/ansible_plugins/filter_plugins
  80. [paramiko_connection]
  81. # nothing to configure yet
  82. [ssh_connection]
  83. # if uncommented, sets the ansible ssh arguments to the following. Leaving off ControlPersist
  84. # will result in poor performance, so use transport=paramiko on older platforms rather than
  85. # removing it
  86. ssh_args=-o PasswordAuthentication=no -o ControlMaster=auto -o ControlPersist=60s -o ControlPath=/tmp/ansible-ssh-%h-%p-%r
  87. # the following makes ansible use scp if the connection type is ssh (default is sftp)
  88. #scp_if_ssh=True