Changes between Version 6 and Version 7 of GENIExperimenter/Tutorials/GENIExperimentEngine/DesignSetup
- Timestamp:
- 03/16/15 12:32:29 (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
GENIExperimenter/Tutorials/GENIExperimentEngine/DesignSetup
v6 v7 46 46 Two basic concepts in Ansible are ''inventories'' and ''modules''. An inventory is a list of hosts to be managed by Ansible, organized into groups. When you run Ansible commands, either from the command-line or in a playbook, you specify the host group that the command should operate on. In this way Ansible commands can operate on many hosts in parallel. Take a look at the Ansible inventory in your '''ansible-hosts''' file. This is basically the equivalent of the '''ssh-config''' except its specialized for Ansible. 47 47 48 A commandconsists of a module and some arguments for the module. A module provides a declarative abstraction on top of standard shell commands. So for example, in the shell on an Ubuntu machine you might install package “foo” like this:48 A ''task'' in Ansible consists of a module and some arguments for the module. A module provides a declarative abstraction on top of standard shell commands. So for example, in the shell on an Ubuntu machine you might install package “foo” like this: 49 49 50 50 {{{ … … 53 53 }}} 54 54 55 An equivalent Ansible commandin a playbook would look like:55 An equivalent Ansible task in a playbook would look like: 56 56 57 57 {{{ 58 apt: name=foo state=latest update_cache=yes58 - apt: name=foo state=latest update_cache=yes 59 59 }}} 60 60 61 Or the same Ansible commandcould be invoked directly on the command line like this:61 Or the same Ansible task could be invoked directly on the command line like this: 62 62 63 63 {{{ … … 65 65 }}} 66 66 67 The commanduses the '''apt''' module, and tells Ansible: “Make sure the latest version of package foo is installed”. There are many other modules which are well-documented at http://docs.ansible.com.67 The task uses the '''apt''' module, and tells Ansible: “Make sure the latest version of package foo is installed”. There are many other modules which are well-documented at http://docs.ansible.com. 68 68 69 69 == 4. Configure the Ansible controller for your slicelet ==