mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
135 lines
6.2 KiB
ReStructuredText
135 lines
6.2 KiB
ReStructuredText
.. image:: http://ansible.github.com/mpd_rings.jpg
|
|
:height: 225
|
|
:width: 300
|
|
:alt: ""
|
|
:target: http://photos.michaeldehaan.net/infrared/h3d850bdf#h3d850bdf
|
|
.. image:: http://ansible.github.com/mpd_tunnel.jpg
|
|
:height: 225
|
|
:width: 337
|
|
:alt: ""
|
|
:target: http://photos.michaeldehaan.net/favorites/h2428aca7#h2428aca7
|
|
.. image:: http://ansible.github.com/mpd_tubes.jpg
|
|
:height: 225
|
|
:width: 225
|
|
:alt: ""
|
|
:target: http://photos.michaeldehaan.net/ncsu/h3b63b68e#h3b63b68e
|
|
|
|
Introducing Ansible
|
|
===================
|
|
|
|
Ansible is a radically simple deployment, model-driven configuration management,
|
|
and command execution framework. Other tools in this space have been too
|
|
complicated for too long, require too much bootstrapping, and have too
|
|
much learning curve. Ansible is dead simple and painless to extend.
|
|
For comparison, Puppet and Chef have about 60k lines of code.
|
|
Ansible's core is a little over 1000 lines.
|
|
|
|
Ansible isn't just for idempotent configuration -- it's also great for ad-hoc
|
|
tasks, quickly firing off commands against nodes. See :doc:`examples`.
|
|
|
|
Where Ansible excels though, is expressing complex multi-node
|
|
deployment processes, executing ordered sequences on
|
|
different sets of nodes through :doc:`playbooks`. Playbooks contain one or
|
|
more plays, each executed against a different batch of nodes. Think about
|
|
webservers, database servers, and backend servers in a multi-node web environment. A play could address each set of machines in a cycle, ensuring the configurations of the machines were correct and also updating them to the specified
|
|
version of software if required.
|
|
|
|
Multi-machine software deployment is poorly solved by most systems management tools -- often due to architectural nature of being pull oriented and having complex ordering systems, they cover configuration but fail at deployment when updating tiers of machines in well defined steps. This results in using two (or more) logically distinct tools and having complex overlap between them.
|
|
|
|
Other deployment oriented frameworks similarly cover deployment well but lack a strongly defined resource model and devolve into glorified remote scripts. Ansible playbooks -- having been designed with this problem in mind -- are good at both deployment & idempotent configuration, meaning you don't have to spread your infrastructure management out between different tools (Puppet+Capistrano, Chef+Fabric, etc), and performing ordered steps between different classes of machines is no problem, yet our modules affect system state only when required -- while avoiding the problem of fragile scripting that assumes certain starting
|
|
or ending states.
|
|
|
|
Ansible is also unique in other ways. Extending ansible does not require programming in any particular language -- you can write :doc:`modules` as idempotent scripts or programs that return simple JSON. Ansible is also pragmatic, so when you need to, it's also trivially easy to just execute useful shell commands.
|
|
|
|
Why use Ansible versus something else? (Puppet, Chef, Capistrano, etc?) Ansible will have far
|
|
less code, it will be (by extension) more correct, and it will be the
|
|
easiest thing to hack on and use you'll ever see -- regardless of your
|
|
favorite language of choice.
|
|
|
|
Systems management doesn't have to be complicated. Ansible's docs
|
|
will remain short & simple, and the source will be blindingly obvious.
|
|
|
|
We've learned well from "Infrastructure is Code". Infrastructure should be easy and powerful to command, but it should not look like code, lest it acquire the disadvantages of a software project -- bugs, complexity, and overhead. Infrastructure configurations should be simple, easy to develop, and easy to audit.
|
|
|
|
|
|
Architecture
|
|
````````````
|
|
|
|
.. image:: http://ansible.github.com/ansible_arch.jpg
|
|
:alt: "Architecture Diagram"
|
|
:width: 648
|
|
:height: 464
|
|
|
|
|
|
Features
|
|
````````
|
|
|
|
* Dead simple setup
|
|
* Super fast & parallel by default
|
|
* No server or client daemons; use existing SSHd out of the box
|
|
* No additional software required on client boxes
|
|
* Can be easily run from a checkout, no installation required
|
|
* Modules are idempotent, but you can also easily use shell commands
|
|
* Modules can be written in ANY language
|
|
* Awesome API for creating very powerful distributed scripts
|
|
* Does not have to run remote steps as root
|
|
* Pluggable transports (SSH is just the default)
|
|
* Source host info & variables from files or external software
|
|
* The easiest config management system to use, ever.
|
|
|
|
|
|
Resources
|
|
`````````
|
|
|
|
Your ideas and contributions are welcome. We're also happy to help
|
|
you with questions about Ansible.
|
|
|
|
* Visit the `project page <https://github.com/ansible/ansible>`_ on Github
|
|
* View the `issue tracker <https://github.com/ansible/ansible/issues>`_
|
|
* Visit the `Google Group <http://groups.google.com/group/ansible-project>`_
|
|
* Chat on `FreeNode <http://webchat.freenode.net/?channels=ansible>`_
|
|
|
|
.. raw:: html
|
|
|
|
<img src="http://groups.google.com/intl/en/images/logos/groups_logo_sm.gif" height=30 width=140 alt="Google Groups">
|
|
<br/>
|
|
<b>Subscribe to Ansible Project</b>
|
|
<br/>
|
|
<form action="http://groups.google.com/group/ansible-project/boxsubscribe">
|
|
<br/>
|
|
Email: <input type=text name=email> <input type=submit name="sub" value="Subscribe">
|
|
<br/></br>
|
|
</form>
|
|
<br/>
|
|
|
|
|
|
Contents
|
|
========
|
|
|
|
.. toctree::
|
|
:maxdepth: 3
|
|
|
|
gettingstarted
|
|
patterns
|
|
examples
|
|
modules
|
|
YAMLSyntax
|
|
playbooks
|
|
api
|
|
moduledev
|
|
faq
|
|
man
|
|
|
|
About the Author
|
|
````````````````
|
|
|
|
Ansible was originally developed by `Michael DeHaan <http://michaeldehaan.net>`_ (`@laserllama <http://twitter.com/#!/laserllama>`_), a Raleigh, NC
|
|
based software developer and architect. He created the popular
|
|
DevOps program `Cobbler <http://cobbler.github.com/>`_.
|
|
Cobbler is used to deploy mission critical systems all over the
|
|
planet, in industries ranging from massively multiplayer gaming, core
|
|
internet infrastructure, finance, chip design, and more. Michael also
|
|
helped co-author `Func <http://fedorahosted.org/func/>`_, a precursor to Ansible, which is used to
|
|
orchestrate systems in lots of diverse places. He's worked on systems
|
|
software for IBM, Motorola, Red Hat's Emerging Technologies Group,
|
|
Puppet Labs, and rPath. Reach Michael by email `here <mailto:michael.dehaan@gmail.com>`_.
|