It should be possible to write something like that as an action plugin. The
only problem I see would be: what to do with group_vars?
Michael Peters napisał:
>You could try abstracting out the logic into a separate script that
>both your inventory and your provisioning playbook could call to
>det
Yves,
The current devel branch should become 1.8 this month.
--
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, send an email
to ansible-project+unsubscr...@goo
What will the next version of ansible be? 1.8?
Asking to be able to add go documentation (add in version x).
Thanks.
--
Yves.
http://yves.zioup.com
gpg: 4096R/32B0F416
--
You received this message because you are subscribed to the Google Groups
"Ansible Project" group.
To unsubscribe from th
You could try abstracting out the logic into a separate script that
both your inventory and your provisioning playbook could call to
determine which groups to put it in. I agree that it's a bit of a
pain. I'd really like to have this be possible as well since it would
really simplify some workflows
JBS> This email is intended for the person(s) to whom it is addressed and
JBS> may contain information that is PRIVILEGED or CONFIDENTIAL.
KEJ> (sigh). Really??? Really?? Surely nobody uses that legalese rubbish
KEJ> noise anymore?
Surely not. I can't explain where that text came from. Probably n
MP> No, but you can add the machine to the necessary groups when you use
MP> add_host after its created.
Yeah, I can mostly do this; the tricky thing is that there are some
derived groups that the host gets added to based on logic in the dynamic
inventory script. I could in theory duplicate that l
I'm playing with Ansible+Arista and I'm able to receive JSON back about the
arista device. As an example, I am looking at interface status. While I am
able to receive and display information about a single value/pair from the
array, how can I loop to receive information on every item in the arra
On Mon, Nov 17, 2014 at 10:29:07AM -0800, Simón Muñoz wrote:
> Hi all,
>
> I'm trying to run a task only if a variable is defined (for example, I have
> some groups where it's defined and some others where it's not). I got to
> this (adding when: nginx_sites), that seems to work, but just asking
Hi
On Mon, Nov 17, 2014 at 04:57:21PM -0500, Josh Smift wrote:
> I feel like I've seen questions like this on the list before, but I'm
> having a hard time finding one now; apologies if this is old ground.
>
> I've got a playbook that provisions a new Rackspace Cloud host, and then
> includes a r
Thanks!
As for tests, definitely not - integration tests submitted with modules are
great to have.
On Mon, Nov 17, 2014 at 4:38 PM, Ramon de la Fuente
wrote:
> All clear. It was a bit presumptuous to make a guide but I felt the amount
> of explanation needed for the module’s concepts where ou
No, but you can add the machine to the necessary groups when you use
add_host after its created.
On Mon, Nov 17, 2014 at 4:57 PM, Josh Smift wrote:
> I feel like I've seen questions like this on the list before, but I'm
> having a hard time finding one now; apologies if this is old ground.
>
> I'
I feel like I've seen questions like this on the list before, but I'm
having a hard time finding one now; apologies if this is old ground.
I've got a playbook that provisions a new Rackspace Cloud host, and then
includes a role specific to that type of host. In that role, there are
some templates
Hi thanks for the reply, yes indeed if this is true then it seems pretty
pointless, you shouldnt be expected to run ansible instantly after a reboot
right?
I'll have to use copy and copy a rc.modules file instead.
Den måndagen den 17:e november 2014 kl. 21:44:20 UTC+1 skrev Michael DeHaan:
>
> T
All clear. It was a bit presumptuous to make a guide but I felt the amount of
explanation needed for the module’s concepts where out of place in the module
itself (not being actual parameters or examples). I’ll reformat and remove the
guide.
Would the tests also fall under the strange precedent
Long answer: Yes, probably between 1/4 and 2/3 of this list are doing
these sort of things.
These may be good starting points:
http://docs.ansible.com/test_strategies.html
It looks like my Continuous Deployment (different - it's a next level thing
from CI) meetup talk isn't online - but in gene
Sounds like there's a bug that should be filed - Can you please share the
full ansible-playbook output from the above so we can see it in context
though?
That message *may* be coming from Docker.
On Tue, Nov 11, 2014 at 4:58 PM, simonq wrote:
> I get* template error while templating string:
Yes, -c local will force every host in your playbook to run locally. It's
good for a simple playbook targetting localhost, but you shouldn't do it in
general with playbooks targetting your whole infra.
Glad you figured it out!
On Wed, Nov 12, 2014 at 1:55 PM, Joshua Burke
wrote:
> Hello All,
This is a common misconception.
All groups that a host are in apply to the host during a run.
This is because groups may imply physical location, purpose, hardware type,
and more, while you may only be selecting them by say, purpose.
On Wed, Nov 12, 2014 at 11:20 AM, Tristan van Bokkem <
trist
I agree this would be useful.
We have a list of features to add to Galaxy in the future - though
currently we're prioritizing development on the main project instead.
Look for some upgrades in the coming months.
On Thu, Nov 13, 2014 at 1:03 AM, Will Thames wrote:
> Would it be possible to ad
I naturally tried using backslash to escape the quotes since that is
pretty much the standard in scripting, but that just resulted in the
backslash getting embedded into the result:
lineinfile: dest=/etc/mail/sendmail.mc state=present
regexp='SMART_HOST' line="define(\`SMART_HOST\', \`
Is there any way to get more debugging than `ansible-playbook -`
provides? I'd like to know if it's a network issue, ssh, or something else
and the instance is terminated before I can test it.
On Monday, November 17, 2014 3:29:34 PM UTC-5, Michael DeHaan wrote:
>
> Not that I'm aware of.
>
>
Thanks for sharing!
Related articles for those interested:
http://www.ansible.com/blog/official-ansible-content-on-docker-hub
http://ansible.com/docker
On Thu, Nov 13, 2014 at 2:25 AM, Victor Lin wrote:
> Hey guys,
>
> I am using Ansible and Docker in a very interesting way, I think it would
Generally ansible frowns upon usages that are too "code-like" and tries to
find some other ways to solve them that are easier to read.
Can we talk about your underlying use case that you are trying to model, to
suggest an alternative, easier approach?
On Thu, Nov 13, 2014 at 5:28 AM, Александр
Can you please share what version of Ansible, the output of your ansible
playbook, and how it fails?
Thanks!
On Thu, Nov 13, 2014 at 5:59 AM, Dan Vaida wrote:
> Hello all,
>
> I am creating a VPC with two subnets, a security group and trying to use
> those for launching an EC2 with a private
If you are attempting to talk to only certain instances, usage of the host
group specifier "hosts:" is the way to do it.
To talk to all instances ending in that pattern
- hosts: *_k
The docs also show how to combine patterns and negate them.
(The group_by module can also be used to create group
Multiple checks looks like:
failed_when: color == 'blue' or number == 5
Note that if you are telling when not to fail, you will need to negate your
condition.
Ansible denotes lists of conditions as "ORs" so:
failed_when:
- color == 'blue'
- number == 5
Is equivalent syntax.
On Thu, No
Hi all,
As discussed previously on this list, the idea of blocks will be coming to
a future release of Ansible.
The 'v2/' subtree refactoring is intended to enable such capabilities as
try/except type blocks.
Until then, the "when" feature, along with ignore_errors, etc, is available.
On Fri,
I like using group_vars and host_vars for these things, though it should be
noted it's a good idea to keep your production and dev inventory in
different files, to avoid the chance of doing "-i inventory.ini" against
the all group and managing them simultaneously.
On Fri, Nov 14, 2014 at 4:18 AM
"(once a month or so this summer)"
Not the case.
Major releases typically come about every 2-3 months, on average.
Occasionally we have had to include dot releases to roll up some major
fixes, but are not currently under that sort of scenario.
Our current plan is to release sometime this month.
Please do not cross-post.
On Thu, Nov 13, 2014 at 12:44 PM, wrote:
> Hi, this is going to be a cross post to both ansible and salt user groups.
> I've spent the last few months going through the docs for both projects and
> I know both fairly well. In both cases, the major issue I've stumbled
>
Ansible doesn't know what variables you are going to use in a template up
front, so any group or host variable in the configuration will be loaded.
You may wish to move your secured files to something like (toplevel)
production.yml and do a
ansible-playbook site.yml -e @production.yml
and reduce
Pull requests to enhance docs would be welcome - we're staging a hackfest
to provide some better tutorials soon, but to some extent what keys are
valid is a function of which Boto libraries you have.
So mostly it's showing examples
On Fri, Nov 14, 2014 at 6:09 PM, Yves Dorfsman wrote:
>
> New i
Much rejoicing!
On Fri, Nov 14, 2014 at 7:19 PM, Strahinja Kustudić
wrote:
> Red Hat has finally fixed the bug with ControlPersist on RHEL 6.6 which
> causes Ansible to fail to connect on first try and some other strange
> behavior. So if you are using RHEL/CentOS 6.6 as your management host,
Can you please explain more about your question?
Thanks!
On Sat, Nov 15, 2014 at 4:06 PM, 'Diogene Laerce' via Ansible Project <
ansible-project@googlegroups.com> wrote:
> Hi,
>
> It seems that syncdb --all is an open ticket for now. Is there a way
> to do this with the present code ?
>
> Than
I'm not sure I'm following, can you clarify exactly what your issue is?
The start of this thread was about how to pass variables.
On Sat, Nov 15, 2014 at 5:23 PM, Toshio Kuratomi
wrote:
> What does your execute shell look like with Damir's workaround? Were
> you also able to see the values o
The user module has a flag to create the homedir.
In any case, manually executing SSH with ansible is weird, and not
something I'd want to see in most playbooks, Toshio here I think was
proposing this for a debugging case, but don't do this :)
You could of course simply execute the whoami with th
INI files are presently supported for local facts and are parsed with
Python's ConfigParser.
On Sun, Nov 16, 2014 at 12:09 PM, Toshio Kuratomi
wrote:
> Michael can correct me if I'm wrong but I believe we're moving more
> and more to json for communicating between modules and ansible core.
>
Thanks for this!
My first thought is try to clean up the examples section so there's no
"..." ... make something real world in there, and seperate it out by use
case.
I would not like to see a seperate guide for this module as it sets a bit
of a strange precedent, so it would be better to just sh
A good trick with the lineinfile module is almost always to use the
template module if you can :)
The problem here is if you start something with a quote, it assumes that
quote is not part of the string and then will end the quote.
Thus you might find it easier to just escape quotes with \" or \'
The modprobe module is part of ansible-modules-extras, which means it's a
bit newer or less fleshed out than some modules.
This doesn't actually save anything but just runs the modprobe commands.
So you would want to use this system and also drop something in modprobe.d.
This should probably be
An alternative, which you may like, is to install Ansible Tower, and then
use ansible-tower-cli in your shell step.
It makes integration with Jenkins a one liner.
It will get you nicer output, particularly for a larger number of hosts,
than Jenkins, and also some nice ways to edit inventory and i
The stat module cannot take fileglobs, and must check a specific asset.
What you have with the test is probably reasonable.
On Fri, Nov 14, 2014 at 3:12 PM, faust wrote:
> Hi,
> is it possible to use the stat module with meta characters:
> - stat: path=/etc/rc2.d/S*init_script.sh
> register
What's the output of "ansible --version" ?
On Sat, Nov 15, 2014 at 1:31 AM, Steve Porter wrote:
> Having a bit of an issues with a Packer/Ansible/Vagrant build pipeline. I
> have been using Ansible for a while and can happily provision my dev VMs
> via Ansible.
>
> I have hooked Packer in the
If it makes sense, I'd be quite open to whatever it takes to make 'latest'
work here.
It is, I will say, not a primary OS for us -- but it's one we're definitely
committed to enabling development on.
On Sun, Nov 16, 2014 at 1:42 PM, Marcus Jaschen wrote:
> On 12.11.14 22:11, Laurentius Purba
Basically this isn't going to end well.
The 'raw' module is useful for sending to devices that look like Unix
shells, but some things are too weird to work this way.
The right way to go with Cisco is going to be to get modules speaking to
OnePK or NXOS APIs - similar to what has happened with Jun
Not that I'm aware of.
Anyone else seeing similar problems?
On Mon, Nov 17, 2014 at 3:17 PM, Dave Stern wrote:
> We've had a task to create EC2 instances running with no changes for
> weeks. Suddenly sometime after Thu Nov 13 04:11:43 UTC 2014, the module
> would timeout on all requests to cr
I don't think as inventory directories are an existing thing.
That being said, any alternative way of managing inventory you want can be
built using an inventory script.
On Fri, Nov 14, 2014 at 4:00 PM, Thomas Quinot wrote:
> Redirecting from -devel as advised.
>
> On Fri, Nov 14, 2014 at 6:1
We've had a task to create EC2 instances running with no changes for weeks.
Suddenly sometime after Thu Nov 13 04:11:43 UTC 2014, the module would
timeout on all requests to create new instances. This happens on both Mac
OS X and on Ubuntu. I've updated to the latest ansible, boto, awscli, etc.
You can do this:
when: foo is defined
On Mon, Nov 17, 2014 at 1:29 PM, Simón Muñoz wrote:
> Hi all,
>
> I'm trying to run a task only if a variable is defined (for example, I
> have some groups where it's defined and some others where it's not). I got
> to this (adding when: nginx_sites), th
This is what I was looking for! Thanks!
- Will
On Monday, November 17, 2014 5:31:22 AM UTC-5, Tore Olsen wrote:
>
> Hi Willard,
>
> Keeping information in one place, is there a reason why you cannot change
> it_users to be dictionaries?
>
> it_users:
> - { name: bill, uid: 501, passwd: hash, h
Hi all,
I'm trying to run a task only if a variable is defined (for example, I have
some groups where it's defined and some others where it's not). I got to
this (adding when: nginx_sites), that seems to work, but just asking in
case there is a better way.
- name: Enabling nginx sites accordi
Wouldn't running `su - USER -c true` suffice?
Andrew Latham napisał:
>For directory (LDAP, etc..) based authentication you can create the
>home directory and copy the skel over to it. Validating permissions of
>course.
>
>On Mon, Nov 17, 2014 at 7:26 AM, Greg Andrews
>wrote:
>> What about creati
Redirecting from -devel as advised.
On Fri, Nov 14, 2014 at 6:19 AM, Thomas Quinot wrote:
> As far as I understand the current state of source code, ansible_hosts
> can be:
> * the path to a dynamic inventory program
> * the path to a static inventory file
> * the path to an inventory dire
Redirecting from -devel as advised...
On Thu, Nov 13, 2014 at 2:27 PM, Thomas Quinot wrote:
> I am considering managing some network equipment (switches) with the
> 'raw' module. This requires sending commands to the switch in an
> interactive session (command streamed before receiving the switc
Hello Alex,
As Torsten said you, you can use "Shell buildstep" and invoke your
playbook (Ansible).
At ClinkerHQ (Hosted CI service based on Jenkins) you can available
Ansible Playbook.
Disclaimer: I work at ClinkerHQ.
Regards,
On 15 November 2014 09:47, Torsten Reinhard wrote:
> Hi,
>
> why do
Having a bit of an issues with a Packer/Ansible/Vagrant build pipeline. I
have been using Ansible for a while and can happily provision my dev VMs
via Ansible.
I have hooked Packer in the the pipeline and now with the same Ansible
scripts in local mode I am getting failures on conditional check
Hi,
is it possible to use the stat module with meta characters:
- stat: path=/etc/rc2.d/S*init_script.sh
register: i
- debug: msg="Path is a simlink"
when: i.stat.islnk
Or what is the elegant way of doing the following (without breaking the
very useful 'ansible-playbook --check' feature):
-
On 12.11.14 22:11, Laurentius Purba wrote:
> Hello all,
>
> I have question regarding pkgng for FreeBSD.
>
> The idea is I was trying to update php on one of our development
> servers. The current php version installed is 5.4.28, while we have on
> the port (/usr/ports/lang/php5) is 5.4.34.
>
>
For directory (LDAP, etc..) based authentication you can create the
home directory and copy the skel over to it. Validating permissions of
course.
On Mon, Nov 17, 2014 at 7:26 AM, Greg Andrews wrote:
> What about creating the user's home directory when you create the user's
> account? Will that
You can use 'Publish over SSH' module to call a remote system running
ansible.
Configure your ansible host in Jenkins -> Manage Jenkins -> Configure System
Then you can add a post build action called 'Send Build artifacts over
ssh'. Select your ansible host and then in the Transfers section, spe
What about creating the user's home directory when you create the user's
account? Will that not work? It would eliminate the need to perform the
extra step of logging in as the user and then logging back out again.
On Fri, Nov 14, 2014 at 8:28 AM, wrote:
> My virtual machine has a setting that
ok, but you are just defining the master node in one host, you probably
want group_vars:
[idc1_node:vars]
cluster_master=host1
[idc1_node]
host1
host2
host3
--
Brian Coca
--
You received this message because you are subscribed to the Google Groups
"Ansible Project" group.
To unsubscribe fro
Hi Willard,
Keeping information in one place, is there a reason why you cannot change
it_users to be dictionaries?
it_users:
- { name: bill, uid: 501, passwd: hash, home: /home/bill }
- { name: fred, uid: 501, ... }
- { name: sam, ... }
Now you can access these items in the user module or
Hi Wawrzek,
Thanks for your response. I believe my problem may have been caused by SSH
connections being silently broken by NAT. I just added "ServerAliveInterval
50" to my ~/.ssh/config file and will see how it works out. Regular SSH
connections would sometimes fail with a broken pipe, but of
Hi Its unclear where the modprobe module save the settings, I cant find a
list of modules to load att boot in /etc/modprobe.d/
There's also no info about this in the module website.
for example kernel_blacklist says:
blacklist_file,use this blacklist file instead of
/etc/modprobe.d/blacklist-an
I'm checking output of your commands on the phone in the bus so I could
miss something, but it looks like ssh is actually fine. Have you try to
debug on remote host?
Have you compare ansible with normal ssh?
Cherers,
Wawrzek
On 11 Nov 2014 12:54, "Tore Olsen" wrote:
> Hello,
>
> I'm having prob
Hi,
Not tested idea from a bus I'm going to work right now : try login into
existing account and then try to sudo to new account.
Cheers,
Wawrzek
On 14 Nov 2014 17:31, wrote:
> My virtual machine has a setting that when the first time a user logs in,
> it creates a home directory for the user a
67 matches
Mail list logo