Perl 6 - the future is here, just unevenly distributed

IRC log for #salt, 2017-12-17

| Channels | #salt index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:00 saltslackbridge joined #salt
00:13 pipps joined #salt
00:27 pipps joined #salt
00:28 cyteen_ joined #salt
00:49 pseudonymous joined #salt
00:53 mxxz joined #salt
00:54 ry joined #salt
01:08 mikecmpbll joined #salt
01:11 pseudonymous joined #salt
01:14 mikecmpb_ joined #salt
01:14 major joined #salt
01:36 pipps joined #salt
01:40 motherfsck joined #salt
01:45 pipps joined #salt
02:56 ilbot3 joined #salt
02:56 Topic for #salt is now Welcome to #salt! <+> Latest Versions: 2016.11.8, 2017.7.2 <+> Support: https://www.saltstack.com/support/ <+> Logs: http://irclog.perlgeek.de/salt/ <+> Paste: https://gist.github.com/ <+> See also: #salt-devel, #salt-offtopic, and https://saltstackcommunity.herokuapp.com (for slack) <+> We are volunteers and may not have immediate answers
03:12 pipps joined #salt
03:40 zerocoolback joined #salt
03:45 zerocoolback joined #salt
03:55 oida joined #salt
04:05 shiranaihito joined #salt
04:24 MochaLoca joined #salt
04:33 felskrone1 joined #salt
04:36 pipps joined #salt
04:52 tiwula joined #salt
04:58 pipps99 joined #salt
05:00 pipps_ joined #salt
05:00 gmacon joined #salt
05:05 karlthane joined #salt
05:23 major joined #salt
06:07 pipps joined #salt
06:35 Bobb243 joined #salt
06:49 felskrone joined #salt
06:55 nethershaw joined #salt
06:58 shripadr joined #salt
07:33 pipps joined #salt
07:54 doubletwist joined #salt
08:13 pipps joined #salt
08:14 Lionel_Debroux joined #salt
08:15 lastjedi joined #salt
08:18 zerocoolback joined #salt
08:22 pseudonymous joined #salt
08:26 Lionel_Debroux joined #salt
08:44 zerocoolback joined #salt
08:45 pseudonymous joined #salt
09:14 diamvw joined #salt
09:15 pseudonymous joined #salt
09:17 diamvw joined #salt
09:17 diamvw left #salt
09:22 djandrea_117 joined #salt
09:25 mig416 joined #salt
09:29 `ziguawa232 joined #salt
09:32 ]puffol668 joined #salt
09:34 sjorge joined #salt
09:37 honor768 joined #salt
09:38 lim296 joined #salt
09:39 anan78 joined #salt
09:42 kar657 joined #salt
09:43 nars234 joined #salt
09:44 greybac162 joined #salt
09:46 demonki729 joined #salt
09:50 NYRDi963 joined #salt
09:52 petsh37 joined #salt
09:55 rausma181 joined #salt
10:03 pseudonymous joined #salt
10:54 karlthane joined #salt
11:31 chowmeined joined #salt
11:31 darix joined #salt
11:39 mikecmpbll joined #salt
11:52 taiw106 joined #salt
12:45 alkerman joined #salt
12:45 alkerman joined #salt
12:46 alkerman joined #salt
12:56 mikecmpbll joined #salt
13:31 KingJ joined #salt
13:43 zerocoolback joined #salt
14:11 sayyid9000_ joined #salt
14:24 sayyid9000 left #salt
14:25 zerocoolback joined #salt
14:33 pseudonymous joined #salt
14:35 mikecmpbll joined #salt
14:53 shiranaihito joined #salt
15:00 sayyid9000_ joined #salt
15:00 sayyid9000_ test
15:01 sayyid9000_ any idea why var nfs_mount doesn't work in a situation like this?
15:02 sayyid9000_ {% set nfs_mount = 'MYSERVER' %}
15:02 sayyid9000_ - device: {{ salt['pillar.get']('nfs:mount:{{ nfs_mount }}:location') }}
15:08 cyteen_ joined #salt
15:11 dmaphy sayyid9000_, i'd say you don't need the {{}}-stuff twice
15:11 dmaphy one basically should be enough
15:12 dmaphy {{ salt['pillar']['nfs']['mount'][nfs_mount]['location'] }}
15:12 dmaphy a wild guess, not 100% sure if this will work, but try writing it somehow like this
15:18 IdoKaplan joined #salt
15:18 sayyid9000_ thanks - this works - - device: {{ pillar['nfs']['mount'][nfs_mount]['location'] }}, but not with [pillar.get] - go figure, appreciate the assist
15:19 IdoKaplan left #salt
15:19 sayyid9000_ don't yet grok the diff between pillar and pillar.get
15:20 dmaphy i'm not sure either, but as far as I understood it's kinda programming detail
15:21 dmaphy pillar.get must be something like a function or method, while you're accessing the pillar[]-array directly now
15:22 babilen sayyid9000_: pillar.get is a convenience function that allows you to access nested keys (i.e. 'foo:bar:baz')
15:23 babilen pillar.get('foo', ..) or pillar['foo'] doesn't allow for nested keys, so you'd typically use salt['pillar.get'](KEYSEQ, DEFAULT)
15:24 babilen So pillar['nfs']['mount'][nfs_mount]['location'] would be salt['pillar.get']('nfs:mount:nfs_mount') and you probably also want to define a default return value
15:25 babilen pillar['nfs']['mount'][nfs_mount]['location'] is awkward to write and breaks as soon as a single key isn't defined
15:26 babilen So to summarise: 1. pillar is a dictionary containing your pillar data. It can be accessed "Python style" with either pillar.get('foo') or pillar['foo'] while the former supports providing a default return value if the key is missing
15:28 babilen 2. salt['pillar.get'] is a convenience function provided by Salt to overcome the (horrendous) limitation of Python's .get() function to allow for lookup of values in a nested datastructure with 'foo:bar:baz'
15:29 babilen Well, s/function/method really
15:34 alexlist joined #salt
15:34 sayyid9000_ ty, that is great - appreciate the time spent
15:45 wevanscfi joined #salt
16:12 Diaoul joined #salt
16:25 nethershaw joined #salt
16:50 Manor joined #salt
16:51 Manor_ joined #salt
17:13 DanyC joined #salt
17:20 tiwula joined #salt
17:21 Manor joined #salt
17:26 cyteen_ joined #salt
17:43 iggy I think {{ salt['pillar.get']('nfs:mount:' ~ nfs_mount ~ ':location') }} is better personally
17:50 Manor joined #salt
18:03 cyteen_ joined #salt
18:07 Manor joined #salt
18:16 rem5 joined #salt
18:17 hammer065 joined #salt
18:29 mikecmpbll joined #salt
18:30 Hybrid1 joined #salt
19:08 miruoy joined #salt
19:14 Manor joined #salt
19:18 tiwula joined #salt
19:18 rem5 joined #salt
19:19 yuhl joined #salt
19:19 tiwula joined #salt
19:25 rylnd left #salt
19:25 sayyid9000 joined #salt
19:26 sayyid9000 left #salt
19:27 sayyid9000 joined #salt
19:37 Trauma_ joined #salt
19:38 Manor_ joined #salt
19:39 Manor joined #salt
19:48 cyteen_ joined #salt
19:55 rem5 joined #salt
20:11 pipps joined #salt
20:17 pipps joined #salt
20:39 DanyC joined #salt
20:47 sayyid9000 i'm new to salt and only writing states so far, but am intrigued by events and reactor, but not sure how to go about using them. what could they be used for ??
20:49 jhauser joined #salt
21:01 major joined #salt
21:06 * whytewolf sighs
21:23 aldevar left #salt
21:25 stickyfingaz joined #salt
21:32 tiwula joined #salt
21:33 mikecmpbll joined #salt
21:33 tiwula joined #salt
21:35 tiwula joined #salt
21:37 tiwula joined #salt
21:39 `EyE` joined #salt
21:49 Hybrid1 joined #salt
21:52 pipps joined #salt
22:03 pipps joined #salt
22:12 mikecmpb_ joined #salt
22:16 pipps joined #salt
22:18 hemebond joined #salt
22:21 nethershaw joined #salt
22:29 `EyE` left #salt
22:42 Trauma_ joined #salt
22:42 mikecmpbll joined #salt
22:56 c4rc4s joined #salt
22:56 jwon joined #salt
22:57 pseudonymous joined #salt
22:57 rodr1c joined #salt
22:57 rodr1c joined #salt
22:58 chutzpah joined #salt
22:58 vaelen joined #salt
22:59 packeteer joined #salt
22:59 pseudonymous joined #salt
22:59 esharpmajor joined #salt
23:15 aneeshusa joined #salt
23:19 XenophonF joined #salt
23:28 cyteen_ joined #salt
23:34 karlthane joined #salt
23:38 pipps joined #salt
23:58 Whissi joined #salt

| Channels | #salt index | Today | | Search | Google Search | Plain-Text | summary