Hi all,
When specifying an host in the playbook itself but not in the inventory
file, I get the message 'skipping: no hosts matched.'
When I pass the host via:
ansible-playbook playbook.yml -i hostname,
All is just working fine.
But why is Ansible unable to just pick up this host defined in
Cool, did not know that! Thnx for your help.
On Friday, July 14, 2017 at 8:05:21 PM UTC+2, Kai Stian Olstad wrote:
>
> On 14. juli 2017 19:46, Listing wrote:
> > This indeed seems to be the case when I compared paths. How is this
> > possible? The 'remote' machine is the
?
On Tuesday, May 30, 2017 at 9:02:44 AM UTC+2, Kai Stian Olstad wrote:
>
> On 29.05.2017 16:26, Listing wrote:
> > Hi Kai,
> >
> > Thank you for your reply. But what is the difference then between
> > regexp
> > and insertafter etc? Is regexp always bei
Hi guys,
I want to install a role automatically via a playbook. But what would be
the best way to do this? Is that by using the shell/command module and then
'ansible-galaxy install', or is there something better available?
--
You received this message because you are subscribed to the Google
. It's in your path on localhost, and
> not on the account you're using remotely.
>
> On 13 July 2017 at 22:05, Listing <mens...@gmail.com >
> wrote:
> > Hi,
> >
> > I am trying to run the following playbook:
> >
> > ---
> > - hosts: m
Can you show me the playbook you are using?
On Friday, July 14, 2017 at 9:01:35 AM UTC+2, Suresh Prajapati wrote:
>
> Hi Guys,
>
>
> I am using a list of users to define the exact set of user accounts I need
> on all of my managed compute instances.
>
> For example:
>
> ---
> users:
> - {
Have you considered lineinfile?
On Friday, July 14, 2017 at 9:14:14 AM UTC+2, Selvakumar Ponnusamy wrote:
>
> I know we can use blockinfile in Ansible 2. Is there any way to achieve
> same in Ansible 1.9
>
--
You received this message because you are subscribed to the Google Groups
"Ansible
Hi,
I am trying to run the following playbook:
---
- hosts: mymachine.lan
become: true
tasks:
- name: shell
shell: "ambari-server status"
The problem is that this results in the following output:
[ansi...@mymachine.lan ~]$ ansible-playbook shell.yml
PLAY [mymachine.lan]
On Thursday, July 6, 2017 at 10:58:18 PM UTC+2, Kai Stian Olstad wrote:
>
> On 06. juli 2017 22:47, Listing wrote:
> > with_items: groups['all:!excluded_group'] does not seem to work. Have
> you
> > got any idea how to exclude here? :)
>
> with_items: "{{ g
HI al,
I am running a playbook on a set of hosts of which I expect them to be
offline. I want to check every 10 seconds whether they are online or not
and then output a message when all is running, or another message when all
is not running after 10 retries for instance.
I am getting 'host
Hi guys,
I am looking for the best way to automatically install a role from a
source. I am currently using these two ways:
1. via requirements.yml file
---
- src: geerlingguy.ruby
Then by running the following playbook (install.yml):
---
- hosts: all
tasks:
- name: run ansible galaxy
Hi all,
I am running my playbooks as user ansible (which has sudo rights) for
instance but often need to escalate privileges. This can be done in
multiple ways:
1. specify per task: become=true
2. specify for the entire playbook at the beginning: become=true
3. specify for the entire host via
Hi,
When initiating a role I noticed that there is a test folder being created
with test.yml in it. When I run my roles in production environments, I
always run roles by creating a playbook with the following contents:
---
- hosts: webservers
roles:
- common
- webservers
When
Ok cool, thanks!
On Tuesday, June 13, 2017 at 7:39:57 PM UTC+2, Brian Coca wrote:
>
> It is a runtime import, it has nothing to do with installation.
>
>
> --
> Brian Coca
>
--
You received this message because you are subscribed to the Google Groups
"Ansible Project" group.
To
On Tuesday, June 13, 2017 at 7:35:55 PM UTC+2, Brian Coca wrote:
>
> They are not installed automatically.
>
>
> --
> Brian Coca
>
Ah, so they are just there for the users that use this role so they can
install the roles manually and then it will be included?
--
You received this
the following error:
ERROR! the role 'geerlingguy.php' was not found in
/etc/ansible/roles/roles:/etc/ansible/roles:/etc/ansible/roles:/etc/ansible/roles
The error appears to have been in
'/etc/ansible/roles/listing/meta/main.yml': line 56, column 5, but may
be elsewhere in the file depending
Very clear, thank you!
On Tuesday, May 30, 2017 at 9:02:44 AM UTC+2, Kai Stian Olstad wrote:
>
> On 29.05.2017 16:26, Listing wrote:
> > Hi Kai,
> >
> > Thank you for your reply. But what is the difference then between
> > regexp
> > and insertafter
Hi Kai,
Thank you for your reply. But what is the difference then between regexp
and insertafter etc? Is regexp always being replaced? Or what is exactly
the logic?
On Sunday, May 28, 2017 at 7:38:16 PM UTC+2, Kai Stian Olstad wrote:
>
> On 28. mai 2017 11:53, Listing wrote:
>
Hi guys,
I have some problems with the lineinfile module. I try to add
'inserted_text' after '#insertbelow' when 'this' has been found in
/etc/ansible/lineinfile/lol. This is my task:
---
- hosts: localhost
tasks:
- name: lol
lineinfile:
path: /etc/ansible/lineinfile/lol
:
>
> For tower questions and support please utilize
> https://access.redhat.com/products/ansible-tower-red-hat
>
> This mailing list is for the open source ansible project.
>
>
>
> On Sun, May 7, 2017 at 11:38 AM Listing <mens...@gmail.com >
> wrote:
>
>> Hi,
FWIW: you can also use grep or sed in command and then register the result.
If you then output result.stdout you will get the result of the grep/sed.
On Tuesday, May 16, 2017 at 7:17:29 AM UTC+2, AnsiNoob wrote:
>
> Hi
>
> Two things that I miss in Ansible when compared to shell scripting is
Hi,
You have set_fact and the ability to set vars, but when should one use
set_fact? In the ansible-doc I see the following example, but when setting
'one_fact', what is the benefit instead of defining a var? Wouldn't it be
possible to define vars per host as well? I hope someone can explain
What happens if you add 'register: blah'? So like this:
- name: Evaluate oo_all_hosts
add_host:
name: "{{ item }}"
groups: oo_all_hosts
ansible_ssh_user: "{{ g_ssh_user | default(omit) }}"
ansible_become: "{{ g_sudo | default(omit) }}"
with_items: "{{ g_all_hosts
Hi Bob,
What happens if you do 'ssh '? Do you still need to provide a
password?
Ping in this module is not the ping we are used to use, it just establishes
a connection and returns 'pong' if all is working. It is not doing an ICMP
ping (which I think you are expecting).
On Saturday, May 13,
Hi,
When running a job template in Ansible-Tower I notice that I can only
select one credential per job run. I have many machines in my inventory
with different credentials and occasionally I would like to connect with
passwords instead of private keys.
I can get this to work just perfectly
Hi,
Sometimes I need (offline) information about how to use specific arguments
on modules like 'with_items', 'with_files', 'tags', 'when' etc. I would
then like to use ansible-doc to get my playbook done, but I seem to be
unable to find information in ansible-doc about this.
Is this present?
26 matches
Mail list logo