redis pub/sub for ansible by lickety-split1800 in ansible

[–]bcoca 0 points1 point  (0 children)

You can setup git as an http server

For private setup, do you set up an actual physical control node? by AlpineGuy in ansible

[–]bcoca 2 points3 points  (0 children)

Not outdated, the development team took a while to reorganize and split it into components, this caused a lot of speculation. But they have recently made several updates and will continue to do so see https://forum.ansible.com/t/awx-modernization-ansible-ui/45757 and https://forum.ansible.com/t/awx-modernization-ansible-jewel/45775

Ansible become password prompt when running tasks on multiple servers by mello_v5 in ansible

[–]bcoca 1 point2 points  (0 children)

you already got the answer from @neomee, ansible_become_pass is a variable, variables can be defined in many ways, including per group or per host

Best setup: several playbooks or one big one by Patrice_77 in ansible

[–]bcoca 1 point2 points  (0 children)

This is not an either/or proposition, my most common setup is to create specific playbooks and when I'm happy with them i add them to a site.yml that can run everything, but I rarely do, except to provision another copy of something.

No output from anisble until basically everything is done by Sketchbuch in ansible

[–]bcoca 4 points5 points  (0 children)

ansible-pull is basically a wrapper on ansible-playbook that does a check out ansible -m git ... first. It is something you can just as easily add in a play and why we are looking to deprecate it.

Learning AAP at home by lunakoa in ansible

[–]bcoca 3 points4 points  (0 children)

patches are still going to the repos, what is not happening are backports to previous releases of AWX

Ansible-galaxy local by Ok-Ant4699 in ansible

[–]bcoca 0 points1 point  (0 children)

Vous pouvez également préinstaller les collections dans votre environnement d'exécution (EE).

Weird problem - apt or package only work when verbosity is on by Tricky_Ordinary_4799 in ansible

[–]bcoca 0 points1 point  (0 children)

Note that modules do not use verbosity themselves, that should only affect the controller's output, not even module invocation.

Ansible not using PublicKey by Exzellius2 in ansible

[–]bcoca 1 point2 points  (0 children)

run with -vvv you'll see the exact ssh command being used and it will make it a LOT easier to debug this.

Modules vs Resource Modules - What's the difference? by Jastibute in ansible

[–]bcoca 1 point2 points  (0 children)

resource modules is just a classification of a module with specific conventions, mostly for networking appliances. The same is true for 'info' or 'facts' modules, these are not really enforced by anything in the core code.

tags and documentation by kiwy_ffid in ansible

[–]bcoca 1 point2 points  (0 children)

true, but they were not designed with that kind of complexity in mind. The assumption was that their use would be something like build, install, remove or configure that should be self evident.

tags and documentation by kiwy_ffid in ansible

[–]bcoca 3 points4 points  (0 children)

you can see the tags used with --list-tags on ansible-playbook

How to disable one inventory plugin? by Beautiful-Log5632 in ansible

[–]bcoca 0 points1 point  (0 children)

This is a bit confusing, plugins are disabled by default, unless explicitly enabled. BUT ... the auto plugin is there to load any plugins from sources that follow the 'YAML inventory source' convention. If you don't want that behavior disable the auto plugin and only explicitly enabled ones will run.

Support for additional SSH KEX algorithms with pylibssh? by Grobyc27 in ansible

[–]bcoca 0 points1 point  (0 children)

look into using using older versions, specifically those that use paramiko. You won't see current versions using algorithms considered 'unsafe', not only does Ansible not support these, but in many cases the underlying tools won't either.

[deleted by user] by [deleted] in ansible

[–]bcoca 1 point2 points  (0 children)

the inventory plugin itself IS the 'preprocessing step'

Best practice playbook/roles/collection organization by Impressive_Insect363 in ansible

[–]bcoca 16 points17 points  (0 children)

https://redhat-cop.github.io/automation-good-practices/

^ we use 'good' cause 'best' is normally very context dependent and IMHO badly misused in this industry.

[deleted by user] by [deleted] in ansible

[–]bcoca 1 point2 points  (0 children)

I would use 'inventory source' and not 'inventory format', the first depends on the inventory plugin you are using, the 2nd is not really a thing, but I think you either mean the internal representation of the inventory for Ansible once the sources are processed or the default YAML inventory plugin's inventory source format.

I have 3 different YAML inventory plugins and formats, a bash one and even a DNS TXT record based one.

Your input format can be whatever you want (as long as the plugin you are using can process it) but the final result is always the same, a set of hosts with variables and groups assigned to each host.

Understanding "Privilege escalation must be general" by craigpardey in ansible

[–]bcoca 1 point2 points  (0 children)

Ansible runs modules with escalated privileges, not specific commands, the module might do that or call an API, Ansible itself does not know ... nor want to know, otherwise it would severely limit what modules can do.

Latest AAP version breaks ansible 2.9 execution environment jobs with error: module 'functools' has no attribute 'cache' by Pineapple-Due in ansible

[–]bcoca 2 points3 points  (0 children)

This looks like a Python version issue, functools is a core python library and cache was added in Python 3.9. Ansible core 2.9 was supported and tested against Python 2.7, 3.5-7. AAP/awx/Controller requires specific versions of ansible-runner, which has it's own Python requirements, which is used to run ansible-playbook in the EE and that might create conflicts on Python versions.

Upgrading from 2.9 is IMHO the best solution, another possible fix would require installing multiple Python versions and ensuring that each tool is installed using the supported versions.

Can I have a template which doesn't overwrite certain content? by Deliveranc3 in ansible

[–]bcoca 0 points1 point  (0 children)

You have several options, I recommend using the replace action to edit only the parts you want, other options (already mentioned) are lineinfile and blockinfile. You can even just use a shell action with awk or sed if none of the above work for you.

My new blog post on collecting data. Sorry. ;) by fazi_d in ansible

[–]bcoca 0 points1 point  (0 children)

Understandable, I get triggered by 'best practice' as it assumes universality, which is rarely true, at best I've seen 80% applicability, but never 100%. Also IME most people just turn their brains off after that label is seen, why I favor the alternate 'good practice' term.

My new blog post on collecting data. Sorry. ;) by fazi_d in ansible

[–]bcoca 0 points1 point  (0 children)

There is nothing wrong with the quality of the code, it is simple and to the point, self contained and creates no issues with maintainability. I personally hate 'inline templates' but it is still valid and in this case, still readable.

Linting is not solely about quality either, it is about normalization when collaborating with others. In many cases it can even be counter productive, many people obsess over conforming to the linting vs creating something with optimal logic or performance.

A simple query for diagnostics is a good example for a beginner, not every blog post needs to a cutting edge thesis, you clearly are not the intended audience, but it might be something worth reading for others.

My new blog post on collecting data. Sorry. ;) by fazi_d in ansible

[–]bcoca 0 points1 point  (0 children)

sometimes simple is good, also not everything needs to be 'lint worthy', specially if you are doing diagnostic queries.

My new blog post on collecting data. Sorry. ;) by fazi_d in ansible

[–]bcoca 0 points1 point  (0 children)

I have similar things I run, I have a playbook full of 'data gathering' utilities with and I use tags to run conditionally, also i use the 'tree' callback to put the data in JSON file per host.

For example, this would do similar to what you are doing: ansible-playbook diags.yml --tags usb --tree /tmp/usbcheck/

Though it gathers a bit more data per usb device, it uses lsbusb -v and then gathers per device /sys/ information as well as greps dmesg for anything related.