Try this
when: currentlimits.stdout|int < 20000

On Sun, Jun 14, 2015 at 08:27 nusenu <[email protected]> wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA512
>
> Hi,
>
> I'm checking the current sysctl value of kern.maxfiles and would like
> to rise this sysctl setting, if it is below 20000 [1]:
>
> - - name: Ensure system-wide runtime file descriptor limits are
> reasonable (OpenBSD)
> sudo: yes
> command: "sysctl kern.maxfiles=20000"
> when: currentlimits.stdout < 20000
>
>
> but even though kern.maxfiles is 7030 the setting is skipped due to
> 'when' check:
>
> from debug var output:
>             "stdout": "7030",
>             "stdout_lines": [
>                 "7030"
>
> is it supposed to be possile to compare stdout with '<' against a
> numeric value?
>
> If I invert the check
> stdout > 20000
> it actually runs even though 7030 is not greater than 20000.
>
> Is '>' non-numeric?
>
> thanks!
>
> [1]
>
> https://github.com/nusenu/ansible-relayor/blob/master/tasks/openbsd_install.yml#L22
>
> -----BEGIN PGP SIGNATURE-----
>
> iQIcBAEBCgAGBQJVfXMcAAoJEFv7XvVCELh0NiQP/im/9oGsx2AfKnX3Tysdl+cO
> krAOpLIO4OUlgxsJtDAi5imKAMHXzYko8O5H/FmpuEmTsTIZkaFPkogdrc6f5Iad
> 8X0VdiHAPHKFNvQZQmPODNuZycYm53xDT3kCmS6nlxC0v0Ls7+9EdtjN9Td+YLYC
> iMqmPQ0+XpEnY1eD4ivyj9vICc1WgADnUsXHrIicWkvm98BQjCF3m6/tbF80Rd+l
> n2UJSdKAdQQPFD4qr46zBKaq2QJJrCwOj/Pbxv7aIdjNX7kDN1KWmTWfEYcHpwGr
> z0wE/bpWbYGCY9bkhuyx+ALwvcOBIjJ2dXU1MrkNCiy+zK221nznhhDwVQKZqjdA
> 6tZeeAhlEG0DAEPb9m3NCWjpjsa04Wxyxm+e/daXHOCDqQe56tGbuaWh7M3yeUGo
> zWZYJhnqwajhKRvijEN52zigNXheOQGnkCBJyA+efbbYTv5yKe6tKPZqJerV/C9z
> cfolboUqySA50QwqS1FHltfZKhM6OM3pSk5oNHwLbN8EZ1Mi6VGkv/P/RV7zt4vp
> p2uRg6sgHLmSOn5Cm/h72P8X45m7TIoBwySZQMQ7y9SuhhVectrd+FP0IZ+O5EWI
> af8KvD6NzqAyrDQSR1rOtGcvllqyaMMrPbjOfkXTj0clyOnx6F+Ena06oU4/sR1k
> 1Nx7SgtuiERorf6VTFSY
> =oleT
> -----END PGP SIGNATURE-----
>
> --
> 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 [email protected].
> To post to this group, send email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/557D731D.6030505%40openmailbox.org
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAMtfUkaQnM9hJfS26GnbzXZjHWxKozbTHgzE1Kudc3-ix4Jtxw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to