News for hackers. Stuff that matters.
Re:An Intuition for Lisp Syntax by drybjed on Monday May 31, 2021 @09:20AM (#27343790)
> I'm almost surprised that you can't add a shebang line pointing to Ansible at the top of your YAML.

You actually can do that, with something like:

    #!/usr/bin/env ansible-playbook
    ---
    - hosts: localhost
      tasks:
        - debug: var=ansible_distribution_release
It works pretty nicely, just remember to make your playbook file executable. It's a bit cumbersome though since you cannot use `ansible-playbook` arguments like `--limit`, `--diff`, `--check` and so on to have better control over the playbook execution.

There are no comments on this comment yet.