[talk] classifying BSD init

Patrik Lundin patrik at sigterm.se
Sun Sep 6 05:38:26 EDT 2015


On Sun, Sep 06, 2015 at 07:44:32AM +0530, Sujit K M wrote:
> On Sat, Sep 5, 2015 at 6:47 PM, Patrik Lundin <patrik at sigterm.se> wrote:
> 
> These are just documentation of the yum/apt or openbsd modules. Below
> what I mean.
> 
> https://raymii.org/s/tutorials/Ansible_-_Only_if_on_specific_distribution_or_distribution_version.html
> 

What I am aiming for is writing playbooks where ansible already takes
care of the "when: ansible_distribution ==" magic (which it does, and
populates the "ansible_pkg_mgr" fact for you).

> >>
> >> In Ansible It get the OS dependent information every time it upgrades
> >> or installs
> >> a package.
> >>
> >
> > I dont understand what you mean by this.
> 
> Well what I mean is given below.
> 
> http://docs.ansible.com/ansible/playbooks_variables.html#information-discovered-from-systems-facts
> 

Note that the "ansible_pkg_mgr" fact exists in that listing, already taking
care of the decision of what module to use so you dont need that extra
scaffolding in the playbook. 

There is however no "service" equivalent fact since the same module is
used on all platforms, which is kind of a discrepancy.

Standardizing on one way of doing this is all I am saying is a good
thing. Hope this explains what I mean :).

-- 
Patrik Lundin




More information about the talk mailing list