[ansible-project] run command on ansible host with sudo privilege.

2016-10-14 Thread Kevin Parent
Hi guys, I am using: - hosts: 127.0.0.1 connection: local to execute command on the ansible host, I disabled privilege escalation because I would get an error message: "module_stderr": "sudo: effective uid is not 0, is /usr/bin/sudo on a file system with the 'nosuid' option set or an NFS fil

[ansible-project] NetScreen | ScreenOS Devices - Devices without Python and Shell

2016-10-14 Thread Daniel Neto
Hi Friends, I'm interested in develop or start something to help me in Configuration Management of devices without Python and Shell. There are simple devices, running the old OS of Juniper. Basically they only support raw commands, but even raw commands I'm not getting results in my lab tests

Re: [ansible-project] Keeping ansible code and app code in sync?

2016-10-14 Thread 'Felix Fontein' via Ansible Project
Hi, > The best mariage I see is to make them live in the same repository. > Any reason why they are kind of separated for you ? a very good reason to have them in separate repositories is that your deployment repository contain secret things like database passwords, private TLS keys etc. which ar

Re: [ansible-project] Keeping ansible code and app code in sync?

2016-10-14 Thread Rénald Casagraude
Hi! The best mariage I see is to make them live in the same repository. Any reason why they are kind of separated for you ? R. Le vendredi 14 octobre 2016, Guy Matz a écrit : > Hi! I have some ansible code that deploys an app . . . some structure of > the app has changed which is reflected i

[ansible-project] Re: Having trouble using with_items, delegate_to and run_once to fake having serial: 1 on an include in a role

2016-10-14 Thread Stig Døssing
Tested this some more, and it seems to actually do what I expected. The include is run on both hosts once, sequentially. It seems a little weird that Ansible is showing the host as host1 -> None instead of host1 -> host1 or host1 -> host2 for the debug tasks, but that's only a minor problem. I'm

[ansible-project] Keeping ansible code and app code in sync?

2016-10-14 Thread Guy Matz
Hi! I have some ansible code that deploys an app . . . some structure of the app has changed which is reflected in the ansible code . . . I'm wondering if anyone has some good techniques for keeping versions of app code and deployment code "married" Thanks!! Guy -- You received this message b

[ansible-project] Having trouble using with_items, delegate_to and run_once to fake having serial: 1 on an include in a role

2016-10-14 Thread Stig Døssing
I'm trying to use the approach described here https://github.com/ansible/ansible/issues/12170 to get part of a role to run serially. I am on 2.1.2.0, but have also tried 2.1.1.0 and 2.0.2.0. - include: do_deploy.yml with_items: "{{ play_hosts }}" delegate_to: "{{ item }}" run_once: true

[ansible-project] Re: Error: "ImportError: No module named grp" when running playbook against windows

2016-10-14 Thread Sam Brelsfoard
Excellent. Thanks for the thorough, helpful answer, Matt! -Sam On Friday, October 14, 2016 at 1:33:41 PM UTC-4, Matt Davis wrote: > > Not sure why you're using ssh/Python to talk to Windows- you *might* be > able to get it to work, but the native Windows management transport that > Ansible suppo

[ansible-project] A question regarding openstack module authentication

2016-10-14 Thread Mihkel Pärna
Hello, I'm trying to configure keystone domains/projects/users through Ansible using os_keystone_domain/os_keystone_project & os_user modules but I'm having difficultys understanding the authentication method. I have preset j2 template that's placed on the host(admin-openrc) and all of the inf

[ansible-project] Re: Error: "ImportError: No module named grp" when running playbook against windows

2016-10-14 Thread Matt Davis
Not sure why you're using ssh/Python to talk to Windows- you *might* be able to get it to work, but the native Windows management transport that Ansible supports is Powershell over WinRM. "shell" is still a module, so it requires that Ansible's basic.py module API and the shell module code its

Re: [ansible-project] How can I get only json data as response from ANSIBLE REST APIS

2016-10-14 Thread Brian Coca
Ansible does not have a REST API, Tower does, for Tower support please go to http://support.ansible.com -- Brian Coca -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it,

[ansible-project] Re: Error: "ImportError: No module named grp" when running playbook against windows

2016-10-14 Thread Sam Brelsfoard
All I'm trying to do is run a shell command though. Am I approaching this wrong? Here's my playbook: --- - hosts: samtestwin gather_facts: false tasks: - name: get server.db from devopscoms shell: mv devopscoms/server.db ~/server.db On Thursday, October 13, 2016 at 2:24:33 PM UTC

[ansible-project] How can I get only json data as response from ANSIBLE REST APIS

2016-10-14 Thread Sumit Dangi
When I hit my Ansible REST API from REST Client, I get whole HTML document back. All I am interested in is the json data which should come back as response. Could you please help and let me know if there is any configuration or header which will get me only json data in REST CLIENT? -- You rec