Re: [ansible-devel] How to define hosts when you integrate Ansible into external system

2021-07-02 Thread Bob Harold
I use: *ansible-playbook myplaybook.yml -i hosts -e host=myhost.mydomain.com <http://myhost.mydomain.com>* and in the playbook: *hosts: "{{ host }}"* That works well for me. I think "all" is much too dangerous, and hardcoding a host or group is too limiting. -- B

Re: [ansible-devel] searching multi lines using regex

2020-09-21 Thread Bob Harold
I don't think you can use caret " ^ " in the middle of a regex. It is probably trying to match a literal ^ symbol and not finding it. Try removing the caret. -- Bob Harold -- You received this message because you are subscribed to the Google Groups "Ansible Development

Re: [ansible-devel] error in import playbook

2019-08-21 Thread Bob Harold
oes not line up 2. tabs vs spaces (they look the same, but count as different indents) 3. invisible characters (look like blanks or none, but are not understood by the program) I don't see anything, but the mail client could have changed characters. yaml still confuses me. Should "- always&qu

Re: [ansible-devel] error when running a windows command using 'raw'

2019-08-15 Thread Bob Harold
On Thu, Aug 15, 2019 at 4:07 PM Bob Harold wrote: > > On Thu, Aug 15, 2019 at 12:08 PM Chris Jackson wrote: > >> >> Hi all, >> >> Tearing my hair out trying to resolve this. I am getting the following:- >> >> "reason": "failed

Re: [ansible-devel] error when running a windows command using 'raw'

2019-08-15 Thread Bob Harold
LIB\BIN\db2licm -a >{{ temp_area }}\{{ db2_lic_file }} > > Can anyone help? > > Many Thanks > > Chris. > My first guess is that the backslash "\" characters are 'escaping' the following character. Try doubling each of them "\\" --

Re: [ansible-devel] how should I connect to windows clients with dhcp addresses?

2019-03-21 Thread Bob Harold
> inventory file, and then write another playbook to add them to the domain? > Any better approaches? > If Active Directory and the clients are configured properly, the Active Directory DNS should be updated automatically. I do not know the details. -- Bob Harold -- You received thi

Re: [ansible-devel] host unreachable

2018-11-15 Thread Bob Harold
On Wed, Nov 14, 2018 at 3:12 PM flowerysong wrote: > On Wednesday, November 14, 2018 at 11:19:55 AM UTC-5, Bob Harold wrote: >> >> >> On Tue, Nov 13, 2018 at 5:37 PM Brian Coca wrote: >> >>> 1 play before your normal play: >>> >>> &g

Re: [ansible-devel] host unreachable

2018-11-14 Thread Bob Harold
_facts: False tasks: - ping: register: pingtest - hosts: hostb when: pingtest.failed But so far I cannot get it to work. I am looking to use the same logic to connect to the internal or external IP of an AWS server depending on where I happen to be running Ansible at that moment. --