Perl 6 - the future is here, just unevenly distributed

IRC log for #salt, 2014-06-06

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

All times shown according to UTC.

Time Nick Message
00:01 obimod joined #salt
00:01 obimod hey guys!
00:01 bmatt hey guy!
00:01 obimod whatup bmatt?
00:01 bmatt about to make like a tree and blow this popsicle stand!
00:02 obimod ha! sweet kicks
00:02 agliodbs anyone?   This seems like yet another user bug introduced in 2014.1.1, but I want to verify that before I file it as a bug
00:02 obimod man, i'd love to be able to generate lxc containers and bootstrap 'em as minions on a single box!
00:03 obimod lxc of dockerio of kvm or vagrant or anything other than having everything in the same environment
00:03 manfred obimod: there is an lxc salt-cloud driver in develop
00:03 obimod sweet!
00:03 obimod thanks manfred
00:03 manfred it will be in helium
00:03 forrest obimod, we use lxc at work with a custom runner, I don't know the status of the salt cloud river
00:03 forrest *driver
00:03 forrest oh nice manfred
00:04 manfred https://github.com/saltstack/salt/blob/develop/salt/cloud/clouds/lxc.py
00:04 mikemar10 joined #salt
00:05 obimod man that can't come soon enough : ) looks like it's pretty active!
00:06 manfred obimod: helium rc1 is supposed to be out around the 18th
00:06 agliodbs forrest: so I'm running into another issue, where on running highstate, salt appears to be trying to set a user's groups to the empty set, which is failing.  The users.sls entry in question does not have a groups: directive at all.  Thoughts?
00:08 forrest agliodbs, well, you should be creating the group
00:08 obimod of june?
00:08 forrest does it not exist?
00:08 CeBe joined #salt
00:08 manfred obimod: this month
00:08 manfred yeah
00:08 agliodbs creating what group?
00:08 forrest the user's group
00:09 agliodbs forrest: well, the users in this system are controlled by LDAP, which also defines their groups
00:09 forrest ahh ldap
00:09 forrest of course
00:09 forrest so the groups don't actually exist on the machine
00:09 forrest sigh
00:09 redondos joined #salt
00:09 agliodbs forrest: yeah, which is why I don't want salt to touch them
00:09 forrest I honestly don't know how to workaround that, I can't remember what it is :(
00:10 agliodbs I couldn't find one
00:10 forrest yea
00:10 forrest there should be a way to add the user and not have it try to add the group
00:10 forrest and user.present doesn't take kwargs
00:10 agliodbs forrest: annoyingly, it's not even adding the user
00:11 agliodbs forrest: the user is already there.  but it's trying to redefine the groups for the user
00:11 forrest right because it 'exists' or whatever
00:11 agliodbs note that this didn't happen with 0.17
00:11 forrest hmm, that seems odd
00:11 forrest might be worth checking the issue tracker
00:11 agliodbs forrest: there's a bunch of vaguely related stuff, but nothing exactly the same
00:12 agliodbs but the users code was heavily modified in the 2014 release
00:12 CeBe1 joined #salt
00:12 agliodbs sounds like I should file a bug
00:12 forrest I'd make sure one doesn't exist first
00:13 oz_akan__ joined #salt
00:15 agliodbs forrest: hard to tell, given Github's lack of issue search
00:15 forrest well, you can kind of search through the issues :P
00:15 forrest but yea
00:16 forrest whiteinge, use your power of salt to get the github search to be less crappy
00:16 fragamus_ joined #salt
00:16 agliodbs forrest: there's 418 open bugs right now
00:16 forrest only that many??
00:16 forrest oh just bugs
00:16 forrest not issues
00:16 forrest I was gonna say
00:19 bhosmer joined #salt
00:21 agliodbs forrest: found the issue and the workaround
00:21 agliodbs remove_groups: false
00:22 forrest ahh cool
00:22 forrest that's an odd workaround, but ok
00:22 agliodbs forrest: do you know if there's a good reason why remove_groups doesn't default to false?  oh, wait, never mind, I can figure that out myself ...
00:22 forrest :P
00:22 agliodbs https://github.com/saltstack/salt/issues/11378
00:23 agliodbs forrest: I do think that salt shouldn't take any action on groups if there's no groups: directive present, but I can imagine that some people would not agree with me
00:23 dmick that is kind of unexpected behavior, agreed, agliodbs
00:24 agliodbs I'll propose it ... is the best way to do so through an issue?
00:26 forrest yes
00:26 dmick I think at least remove_groups should be false.  That's an action-at-a-distance default.
00:27 dmick (default to false, I mean)
00:28 rgarcia_ joined #salt
00:28 mgw joined #salt
00:30 agliodbs dmick: well, it *shouldn't* be false if there's a groups: clause
00:31 dmick I think it should; the most-natural interpretation of that spec to me is "make sure the user is in these groups", not "make sure the user is in these *and only these* groups"
00:31 dmick I mean it's nice to have that functionality, but it's not the obvious interpretation to me
00:31 dmick and it could be quite dangerous
00:32 dmick (you mean I added him to the database group and you took him out of sudo?  wtf?)
00:32 agliodbs dmick: well, there's optional_groups for "just add him"
00:32 agliodbs but that runs afoul of this same issue
00:32 agliodbs unless you remember to set remove_groups to false
00:33 dmick that has other implications, too (as in silent failure)
00:33 agliodbs the issue is that if there *is* a groups: directive, you don't want to default remove_groups to false
00:33 dmick yeah, I know what you're saying, but I just disagree.
00:33 dmick I would expect the state to mean "add him to these groups, fail if the groups don't exist or you can't, but do not remove him from other groups unless explicitly asked"
00:34 dmick not a big deal either way, and these things are always opinion
00:34 dmick but that's mine :)
00:34 agliodbs dmick: well, we're talking about two different managment styles here.  some salt admins use groups: to indicate exactly the groups someone is in
00:35 agliodbs anyway, comment on this: https://github.com/saltstack/salt/issues/13276 if you care
00:35 dmick ...and they can specify groups: and remove_groups: true
00:37 agliodbs well, comment on that issue with your solution
00:37 dmick done
00:37 dmick it's all good
00:40 agliodbs thanks, all!
00:40 tdegrunt joined #salt
00:45 dccc joined #salt
00:49 chamunks joined #salt
00:49 nvmme joined #salt
00:53 agliodbs I have a salt mine.get which is failing.  Is there any way to do a mine.get interactively to see if I can figure out why?
00:56 schmutz joined #salt
00:59 manfred salt-call mine.get \* <command>
00:59 manfred or salt web\* mine.get \* <command>
00:59 manfred it is just a module
01:04 dmick is there an easy way to get command output from a cmd.run with interleaved stdout/stderr (i.e. the way the command would have output it)?
01:06 dmick (I would assume one of the --out outputters, but none of them seem to describe doing that)
01:08 mgw joined #salt
01:08 dmick (and really it's not an outputter issue, it's that the output is packaged up into the dict, when I'd like it not to be)
01:11 manfred --out is just for organizing the out put differently, i don't believe cmd.run does what you are looking for
01:11 dmick manfred: yeah, that's what I was thinking
01:12 manfred actually, it looks like it should split it
01:12 manfred nm https://github.com/saltstack/salt/blob/develop/salt/modules/cmdmod.py#L485
01:12 manfred it does put stderr to stdout
01:13 agliodbs why would mine.get return nothing on the master?
01:13 manfred there appears to be a cmd.run_stderr and cmd.run_stdout
01:13 agliodbs seems like I need to resync the mine or something
01:13 manfred agliodbs: did you setup mine_functions?
01:13 manfred i believe only the minions can reach the mine
01:14 oz_akan_ joined #salt
01:14 agliodbs manfred: I'm doing salt '*' mine.get '*' grains.items
01:14 agliodbs it finds the list of minions, but none of them have any items
01:15 agliodbs if I just do salt '*' grains.items it works fine, though
01:16 ajprog_laptop joined #salt
01:17 agliodbs same happens if I run it on the minion itself using salt-call
01:19 dmick manfred: I think cmdmod != cmd, first
01:20 dmick although perhaps cmdmod is more flexibly bent to my will
01:22 dmick it looks like cmdmod.run() would do it
01:22 dmick https://github.com/saltstack/salt/blob/develop/salt/modules/cmdmod.py#L595
01:23 agliodbs what would cause a minion to have a completely empty mine?
01:25 nvmme joined #salt
01:25 TyrfingMjolnir joined #salt
01:31 mgw joined #salt
01:31 taion809 joined #salt
01:34 l0x3py joined #salt
01:36 ipalreadytaken joined #salt
01:41 tdegrunt joined #salt
01:55 shaggy_surfer joined #salt
02:01 mgw joined #salt
02:08 bhosmer joined #salt
02:09 jcsp1 joined #salt
02:13 fxhp joined #salt
02:15 oz_akan_ joined #salt
02:34 londo__ joined #salt
02:36 rgarcia_ joined #salt
02:41 tdegrunt joined #salt
02:42 Furao joined #salt
02:44 TyrfingMjolnir joined #salt
02:46 malinoff joined #salt
02:48 dsolsona joined #salt
02:58 ldlework Remind me, when you have a folder of salt files, how do you specify what order they should run?
02:58 ldlework salt state files I mean
03:04 ldlework okay I see, maybe you just drop an init.sls in there, and the init.sls includes each of the sibling files in the right order
03:06 ldlework nice relative includes
03:06 ldlework all coming back to me now
03:12 n8n_ joined #salt
03:13 catpigger joined #salt
03:14 shaggy_surfer joined #salt
03:16 oz_akan_ joined #salt
03:34 mateoconfeugo joined #salt
03:38 zain_ joined #salt
03:40 schimmy joined #salt
03:41 ipalreadytaken joined #salt
03:42 tdegrunt joined #salt
03:44 schimmy1 joined #salt
03:47 ramteid joined #salt
03:56 bhosmer joined #salt
03:57 zain_ joined #salt
03:57 kermit joined #salt
04:01 ckao joined #salt
04:07 freelock wait, Nodegroups aren't available in a compound match???
04:14 manfred dmick: yes it does https://github.com/saltstack/salt/blob/develop/salt/modules/cmdmod.py#L35
04:14 manfred that is what __virtualname__ is for
04:14 dmick totally don't understand the salt naming space then
04:14 manfred agliodbs: there isn't anything in the mine, unless you put it there using mine_functions
04:15 manfred dmick: the file is the name of the module, unless you have __virtualname__, then that is the name of the module
04:15 manfred take lvm for example https://github.com/saltstack/salt/blob/develop/salt/modules/linux_lvm.py#L13
04:15 dmick but...
04:15 dmick http://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.cmdmod.html
04:15 manfred exactly that
04:16 manfred cmdmod.py is the cmd module from the command line
04:16 manfred because of __virtualname__
04:16 manfred read the examples
04:16 dmick "from the command line"....
04:16 manfred salt.modules.cmdmod.has_exec(cmd)¶
04:16 manfred salt '*' cmd.has_exec cat
04:16 oz_akan_ joined #salt
04:17 manfred cmdmod is just the filename as a for how you would reference it inside of python
04:18 dmick ok, then I don't understand the current behavior, but I guess I have to figure it out more clearly
04:18 manfred the function inside of python is salt.modules.cmdmod.has_exec(), but because of the way salt uses the __virtualname__ you refer to the module with just cmd.has_exec on the command line
04:18 dmick (or in a state file)
04:18 manfred modules aren't used in state files
04:19 manfred you want states
04:19 manfred https://github.com/saltstack/salt/blob/develop/salt/states/cmd.py
04:19 manfred http://docs.saltstack.com/en/latest/ref/states/all/salt.states.cmd.html
04:20 dmick ok.  so I guess that's what I'm talking about
04:20 malinoff joined #salt
04:20 manfred but those will just call the modules to do what you tell them to
04:20 manfred https://github.com/saltstack/salt/blob/develop/salt/states/cmd.py#L669
04:20 manfred useing __salt__
04:20 manfred and it just passes cmd_kwargs
04:22 dmick ok.  so it seems like the state cmd.run calls the module cmdmod.run_all, which doesn't seem to offer the interface of combining stdout and stderr?...is that correct?
04:22 manfred yes
04:23 manfred and now i am going to bed
04:23 dmick ok.  thanks for the explanations
04:23 vsyrakis joined #salt
04:27 travisfischer joined #salt
04:28 FeatherKing joined #salt
04:28 FeatherKing left #salt
04:33 malinoff joined #salt
04:33 n8n joined #salt
04:43 tdegrunt joined #salt
04:55 combusean joined #salt
05:01 svs_ joined #salt
05:04 Kelsar_ joined #salt
05:08 notbmatt joined #salt
05:08 crane joined #salt
05:09 steveoliver joined #salt
05:09 dsolsona joined #salt
05:10 mgarfias joined #salt
05:19 aiqa joined #salt
05:20 Shenril joined #salt
05:20 stanchan joined #salt
05:20 rizumu joined #salt
05:21 lionel joined #salt
05:21 Spark joined #salt
05:21 Heartsbane joined #salt
05:26 MTecknol1gy joined #salt
05:26 jforest joined #salt
05:26 kossy_ joined #salt
05:26 nliadm joined #salt
05:26 dpac|away joined #salt
05:26 codekoala joined #salt
05:26 [vaelen] joined #salt
05:26 Jahkeup joined #salt
05:26 berto- joined #salt
05:26 vsyrakis joined #salt
05:26 zain_ joined #salt
05:26 fxhp joined #salt
05:26 dmick joined #salt
05:26 thayne joined #salt
05:26 happytux joined #salt
05:26 seanz joined #salt
05:26 MrTango joined #salt
05:26 djinni` joined #salt
05:26 ahale joined #salt
05:26 thomaso joined #salt
05:26 faulkner joined #salt
05:26 CaptTofu joined #salt
05:26 gldnspud joined #salt
05:26 xzarth joined #salt
05:26 dusel joined #salt
05:26 twinshadow joined #salt
05:26 basepi joined #salt
05:26 gamingrobot joined #salt
05:26 copelco joined #salt
05:26 modafinil joined #salt
05:26 jmccree joined #salt
05:26 Sway joined #salt
05:26 tmmt joined #salt
05:26 emostar joined #salt
05:26 ze- joined #salt
05:26 balltongu_ joined #salt
05:26 mariusv joined #salt
05:26 terminalmage joined #salt
05:26 retr0h joined #salt
05:26 shano joined #salt
05:26 marcinkuzminski joined #salt
05:26 manfred joined #salt
05:26 scooby2 joined #salt
05:26 lz-dylan joined #salt
05:26 codysoyland joined #salt
05:26 tonthon joined #salt
05:26 emilisto_ joined #salt
05:26 __number5__ joined #salt
05:26 alainv joined #salt
05:26 luminous joined #salt
05:26 londo joined #salt
05:26 Doqnach joined #salt
05:26 lazybear joined #salt
05:26 dcolish joined #salt
05:26 nhubbard joined #salt
05:26 zdong joined #salt
05:26 fxdgear joined #salt
05:26 carmony joined #salt
05:26 tedski joined #salt
05:26 johtso joined #salt
05:26 nadley joined #salt
05:26 torrancew joined #salt
05:26 64MAAQFHR joined #salt
05:26 eightyeight joined #salt
05:26 hillna_ joined #salt
05:26 delkins joined #salt
05:26 frozenice joined #salt
05:26 wiqd_ joined #salt
05:26 kaictl joined #salt
05:26 stotch_ joined #salt
05:26 AlcariTheMad joined #salt
05:26 etw joined #salt
05:26 goodwill joined #salt
05:26 drags joined #salt
05:26 AlexM850 joined #salt
05:26 __alex joined #salt
05:26 terinjokes joined #salt
05:26 renoirb joined #salt
05:26 ixokai joined #salt
05:26 r4vi joined #salt
05:26 joshbaptiste joined #salt
05:26 d3vz3r0 joined #salt
05:26 Dinde joined #salt
05:26 tharkun joined #salt
05:26 hoodow joined #salt
05:26 jasonrm joined #salt
05:26 whitepaws joined #salt
05:26 dcmorton joined #salt
05:26 rawtaz joined #salt
05:26 dstokes joined #salt
05:26 Gareth joined #salt
05:26 _blackjid joined #salt
05:26 neilf_ joined #salt
05:26 techdragon joined #salt
05:26 cwyse joined #salt
05:26 Sacro joined #salt
05:26 juice joined #salt
05:26 hellome joined #salt
05:26 jgarr joined #salt
05:26 ScrumpyJack joined #salt
05:26 aqua^^ joined #salt
05:26 FarrisG joined #salt
05:26 Valdo joined #salt
05:26 smferris joined #salt
05:26 Sypher joined #salt
05:26 seventy3 joined #salt
05:26 NV joined #salt
05:26 sirtaj joined #salt
05:26 JordanTesting joined #salt
05:26 Dattas joined #salt
05:26 smkelly joined #salt
05:26 antonw joined #salt
05:26 Teknix joined #salt
05:26 agh joined #salt
05:26 pjs joined #salt
05:26 zsoftich2 joined #salt
05:26 FL1SK joined #salt
05:26 anteaya joined #salt
05:26 borgstrom joined #salt
05:26 MK_FG joined #salt
05:26 chuffpdx joined #salt
05:26 patrek_ joined #salt
05:26 jchen joined #salt
05:26 whiteinge joined #salt
05:26 bwq- joined #salt
05:26 z3uS joined #salt
05:26 flebel joined #salt
05:26 joehh joined #salt
05:26 jnials joined #salt
05:26 bstromski joined #salt
05:26 gmoro joined #salt
05:26 jeremyBass joined #salt
05:26 rlarkin joined #salt
05:26 chutzpah joined #salt
05:30 mihait joined #salt
05:31 blast_hardcheese joined #salt
05:33 MTecknol1gy joined #salt
05:33 jforest joined #salt
05:33 kossy_ joined #salt
05:33 nliadm joined #salt
05:33 dpac|away joined #salt
05:33 codekoala joined #salt
05:33 [vaelen] joined #salt
05:33 Jahkeup joined #salt
05:33 berto- joined #salt
05:33 vsyrakis joined #salt
05:33 zain_ joined #salt
05:33 fxhp joined #salt
05:33 dmick joined #salt
05:33 thayne joined #salt
05:33 happytux joined #salt
05:33 seanz joined #salt
05:33 MrTango joined #salt
05:33 djinni` joined #salt
05:33 ahale joined #salt
05:33 thomaso joined #salt
05:33 faulkner joined #salt
05:33 CaptTofu joined #salt
05:33 gldnspud joined #salt
05:33 xzarth joined #salt
05:33 dusel joined #salt
05:33 chutzpah joined #salt
05:33 rlarkin joined #salt
05:33 jeremyBass joined #salt
05:33 gmoro joined #salt
05:33 bstromski joined #salt
05:33 jnials joined #salt
05:33 joehh joined #salt
05:33 flebel joined #salt
05:33 z3uS joined #salt
05:33 bwq- joined #salt
05:33 whiteinge joined #salt
05:33 jchen joined #salt
05:33 patrek_ joined #salt
05:33 chuffpdx joined #salt
05:33 MK_FG joined #salt
05:33 borgstrom joined #salt
05:33 anteaya joined #salt
05:33 FL1SK joined #salt
05:33 zsoftich2 joined #salt
05:33 pjs joined #salt
05:33 agh joined #salt
05:33 Teknix joined #salt
05:33 antonw joined #salt
05:33 smkelly joined #salt
05:33 Dattas joined #salt
05:33 JordanTesting joined #salt
05:33 sirtaj joined #salt
05:33 NV joined #salt
05:33 seventy3 joined #salt
05:33 Sypher joined #salt
05:33 smferris joined #salt
05:33 Valdo joined #salt
05:33 FarrisG joined #salt
05:33 aqua^^ joined #salt
05:33 ScrumpyJack joined #salt
05:33 jgarr joined #salt
05:33 juice joined #salt
05:33 Sacro joined #salt
05:33 cwyse joined #salt
05:33 techdragon joined #salt
05:33 neilf_ joined #salt
05:33 _blackjid joined #salt
05:33 Gareth joined #salt
05:33 dstokes joined #salt
05:33 rawtaz joined #salt
05:33 dcmorton joined #salt
05:33 whitepaws joined #salt
05:33 jasonrm joined #salt
05:33 hoodow joined #salt
05:33 tharkun joined #salt
05:33 Dinde joined #salt
05:33 d3vz3r0 joined #salt
05:33 joshbaptiste joined #salt
05:33 r4vi joined #salt
05:33 ixokai joined #salt
05:33 renoirb joined #salt
05:33 terinjokes joined #salt
05:33 __alex joined #salt
05:33 AlexM850 joined #salt
05:33 drags joined #salt
05:33 goodwill joined #salt
05:33 etw joined #salt
05:33 AlcariTheMad joined #salt
05:33 stotch_ joined #salt
05:33 kaictl joined #salt
05:33 wiqd_ joined #salt
05:33 frozenice joined #salt
05:33 delkins joined #salt
05:33 hillna_ joined #salt
05:33 eightyeight joined #salt
05:33 64MAAQFHR joined #salt
05:33 torrancew joined #salt
05:33 nadley joined #salt
05:33 twinshadow joined #salt
05:33 basepi joined #salt
05:33 gamingrobot joined #salt
05:33 copelco joined #salt
05:33 modafinil joined #salt
05:33 jmccree joined #salt
05:33 Sway joined #salt
05:33 tmmt joined #salt
05:33 emostar joined #salt
05:33 ze- joined #salt
05:33 balltongu_ joined #salt
05:33 mariusv joined #salt
05:33 terminalmage joined #salt
05:33 retr0h joined #salt
05:33 shano joined #salt
05:33 marcinkuzminski joined #salt
05:33 manfred joined #salt
05:33 scooby2 joined #salt
05:33 lz-dylan joined #salt
05:33 codysoyland joined #salt
05:33 tonthon joined #salt
05:33 emilisto_ joined #salt
05:33 __number5__ joined #salt
05:33 alainv joined #salt
05:33 luminous joined #salt
05:33 londo joined #salt
05:33 Doqnach joined #salt
05:33 lazybear joined #salt
05:33 dcolish joined #salt
05:33 nhubbard joined #salt
05:33 zdong joined #salt
05:33 fxdgear joined #salt
05:33 carmony joined #salt
05:33 tedski joined #salt
05:33 johtso joined #salt
05:34 codekoala joined #salt
05:34 georgemarshall joined #salt
05:36 jforest joined #salt
05:36 MTecknology joined #salt
05:37 bmonty joined #salt
05:40 felskrone joined #salt
05:43 georgemarshall joined #salt
05:44 tdegrunt joined #salt
05:45 bhosmer joined #salt
06:06 zsoftich1 joined #salt
06:06 Teknix joined #salt
06:17 oz_akan_ joined #salt
06:20 jdmf joined #salt
06:22 bcolfer joined #salt
06:22 n8n joined #salt
06:25 Shenril joined #salt
06:26 schimmy joined #salt
06:31 Ryan_Lane joined #salt
06:32 Ryan_Lane joined #salt
06:35 seanz joined #salt
06:36 schimmy joined #salt
06:39 CeBe joined #salt
06:39 schimmy1 joined #salt
06:43 jalaziz joined #salt
06:44 tdegrunt joined #salt
06:45 ndrei joined #salt
06:47 matrix3000 joined #salt
06:49 matrix3000 i am trying to configure zabbix on all my hosts using the top.sls file, can i do something like this http://pastebin.com/T3UedChU
06:54 linjan joined #salt
06:54 picker joined #salt
07:02 happytux_ joined #salt
07:07 mgw joined #salt
07:10 Hipikat hi - so salt-cloud was rolled into salt in 2014.1.0, and i’ve got a freshly bootstrapped master on 2014.1.4, and there doesn’t seem to be a salt-cloud executable installed anywhere. my question is: what’s up with that?
07:12 robinsmidsrod joined #salt
07:12 ml_1 joined #salt
07:13 tinuva joined #salt
07:16 joehh Hipikat: maybe you need to install the salt-cloud package?
07:18 oz_akan_ joined #salt
07:22 kaictl joined #salt
07:24 Hipikat joehh: huh… so is the situation just that *some* of salt-cloud has been pulled into salt proper and this page is inherently misleading – http://docs.saltstack.com/en/latest/topics/cloud/install/index.html – because an extra package is required?
07:25 Hipikat except that the ‘clouds’ page in saltcloud.clouds and salt.cloud.clouds seem to have the same modules, so i assumed the pypi package was deprecated by post-2014.1.0 salt versions…
07:28 jcockhren Hipikat: yep
07:29 jcockhren yep as in, pulled into salt
07:29 Hipikat yet there’s a scripts/salt-cloud file in the salt (proper) repo…
07:31 jcockhren that's not exactly a bad thing
07:32 jcockhren but the merge was so that it could have tighter integration with the rest of salt
07:32 jcockhren I haven't tested the script usage post-merge
07:33 jcockhren so... at the risk of a horrible pun, take what I say with a grain of salt. :p
07:33 Hipikat utterly confused. so salt proper does have the script it just doesn’t create the link to it in a bin directory on install? i just assuemd maybe it was because apache-libcloud wasn’t installed during the bootstrap, but i re-bootstrapped and nothing…
07:34 bhosmer joined #salt
07:34 joehh Hipikat: I see your confusion - from an end users point of view (on some oses), salt-cloud was always a separate package and is still
07:35 joehh the fact that it all now comes fro mthe one source package doesn't changemuch for many users
07:36 AviMarcus joined #salt
07:36 Hipikat joehh: it comes from one source package? so the salt-cloud package on pypi somehow comes out of what’s in github/saltstack/salt?
07:37 Hipikat okay. i don’t actually need to work out what’s going on here never mind. :)
07:39 joehh Hipikat: yeah (to your last one) - I thnk the salt-cloud on pypi is old andsalt-cloud is now built out of the salt source package on pypi
07:39 chiui joined #salt
07:42 Hipikat right. and salt/setup.py looks distinctly like ‘scripts/salt-cloud’ should be included in SETUP_KWARGS['scripts'] unless IS_WINDOWS_PLATFORM, so i’m back to wondering why it isn’t installed
07:45 tdegrunt joined #salt
07:49 TyrfingMjolnir joined #salt
07:49 darkelda joined #salt
07:51 Lomithrani joined #salt
07:53 ndrei joined #salt
07:54 TyrfingMjolnir joined #salt
07:55 Ryan_Lane joined #salt
07:57 Ryan_Lane1 joined #salt
07:57 freelock joined #salt
08:03 Nazzy_ joined #salt
08:03 Nazzy_ joined #salt
08:07 ipalreadytaken joined #salt
08:17 ghartz joined #salt
08:19 seanz joined #salt
08:20 _ale_ joined #salt
08:22 n8n joined #salt
08:25 _ale_ hi guys, do you have a suggestion for an IDE or plugins to VIM to use with saltstack ?
08:26 malinoff _ale_, standard python plugins - jedi, rope, python-mode
08:28 alanpearce joined #salt
08:29 kadel joined #salt
08:37 kedo39 joined #salt
08:43 _ale_ malinoff: thanks ! just installed em all and looks awesome :)
08:43 _ale_ is there one to validate valid jinja syntax ?
08:45 camphene joined #salt
08:45 camphene hi.
08:45 malinoff _ale_, uhm, just found https://github.com/saltstack/salt-vim
08:45 camphene i need ideas for a good way to fuck with someone, and this seemed like the perfect place to ask.
08:45 camphene not doxxing
08:46 tdegrunt joined #salt
08:49 camphene sigh
08:49 camphene i'll stick with psychological torture
08:50 camphene left #salt
08:52 msciciel_ joined #salt
08:52 kedo39 joined #salt
08:57 orbit_darren joined #salt
08:57 orbit_darren left #salt
08:59 _ale_ malinoff: oh cool :) ... and installed too :)
09:03 giantlock joined #salt
09:17 xt joined #salt
09:20 oz_akan_ joined #salt
09:23 bhosmer joined #salt
09:40 alanpearce joined #salt
09:41 dsolsona joined #salt
09:45 ahale joined #salt
09:47 tdegrunt joined #salt
09:55 tdegrunt joined #salt
10:00 CeBe joined #salt
10:02 thayne joined #salt
10:05 masterkorp Guys can i install 2 packages on a pkg state ?
10:06 masterkorp I get  Name pkg in sls openvpn.server is not a dictionary
10:09 kevinjcash joined #salt
10:10 jcockhren masterkorp: yep
10:10 jcockhren use the '-names' key and provide a list of packages
10:11 jcockhren sorry. it's 'pkgs'
10:11 masterkorp hmm
10:11 masterkorp like pkgs:
10:11 masterkorp - installed
10:11 jcockhren https://salt.readthedocs.org/en/latest/ref/states/all/salt.states.pkg.html#module-salt.states.pkg
10:11 masterkorp - names: pkg1 pkg2 pk3 ?
10:12 jcockhren it has an example down by the 'pkgs' description
10:15 ghartz joined #salt
10:16 Tekni joined #salt
10:16 CeBe1 joined #salt
10:21 krow joined #salt
10:27 dsolsona joined #salt
10:32 Furao joined #salt
10:37 ggoZ joined #salt
10:38 oz_akan_ joined #salt
10:45 ahale_ joined #salt
11:02 CeBe1 joined #salt
11:08 masterkorp Where is the documentation about the templates
11:10 masterkorp namely getting pillar data to them
11:11 masterkorp i basically using the salt formula as example
11:12 bhosmer joined #salt
11:13 bhosmer_ joined #salt
11:19 taion809 joined #salt
11:19 CeBe1 joined #salt
11:24 Whissi joined #salt
11:24 Lomithrani joined #salt
11:30 matrix3000 joined #salt
11:32 masterkorp ok found it, i am so dumb sometimes
11:39 bhosmer joined #salt
11:39 oz_akan_ joined #salt
11:46 ndrei joined #salt
11:50 picker joined #salt
11:50 bhosmer joined #salt
11:51 bhosmer_ joined #salt
11:54 TyrfingMjolnir_ joined #salt
11:55 ndrei joined #salt
12:02 tdegrunt joined #salt
12:03 N-Mi joined #salt
12:03 N-Mi joined #salt
12:10 vbabiy joined #salt
12:11 jrdx joined #salt
12:12 taion809 joined #salt
12:14 Teknix joined #salt
12:16 viq graaah. fuck this. I'll just have a 10 line file setting up redis instead of spending days on rewriting the redis-formula
12:17 alanpearce joined #salt
12:18 mortis how do i match a single subvalue in a pillar? i mean i have something like-> stuff: subvalue: examplevalue ..and i want to do something like {% pillar.get('stuff','subvalue') %} but cant find out how the syntax is :x
12:18 mortis since its only one value, i dont feel like looping through .items()
12:19 happytux joined #salt
12:19 malinoff mortis, {% if pillar.get('stuff', 'subvalue') == 'something' %}
12:19 malinoff ah
12:19 malinoff sorry
12:19 mortis just wondering about the syntax :)
12:19 mortis so mine was correct?
12:20 malinoff mortis, {{ __salt__['pillar.get']('stuff:subvalue') }}
12:20 mortis ooooh
12:20 mortis i'll try that
12:20 malinoff or, with pure python/jinja {{ pillar.get('stuff', {}).get('subvalue') }}
12:20 mortis cheesus :)
12:21 mortis jinja confuses me
12:21 malinoff try to use mako
12:21 malinoff jinja is not very comfortable template engine, really
12:22 mortis i cant really say, since i havent used it much, but im struggling as a noob, thats for sure
12:23 malinoff mortis, than you don't even know about jinja's whitespace hell :)
12:23 mortis malinoff: worked :D
12:23 mortis thanks man
12:23 mortis haha
12:23 mortis no, i guess not
12:25 jaimed joined #salt
12:31 tdegrunt joined #salt
12:39 Shyam joined #salt
12:40 oz_akan_ joined #salt
12:46 ipmb joined #salt
12:49 oz_akan_ joined #salt
12:52 saravanans joined #salt
12:55 tdegrunt joined #salt
12:57 oz_akan_ joined #salt
12:58 miqui joined #salt
12:58 AdamSewell joined #salt
13:06 jaycedars joined #salt
13:07 yetAnotherZero joined #salt
13:13 racooper joined #salt
13:14 jslatts joined #salt
13:16 taion809 joined #salt
13:24 Networkn3rd joined #salt
13:28 to_json joined #salt
13:32 zirpu joined #salt
13:33 saravanans joined #salt
13:37 workingcats joined #salt
13:40 elfixit joined #salt
13:44 happytux_ joined #salt
13:46 lazybear joined #salt
13:52 cheus joined #salt
13:56 mgw joined #salt
13:56 tdegrunt joined #salt
13:57 kaptk2 joined #salt
14:04 ale__ joined #salt
14:09 GradysGhost joined #salt
14:09 toddejohnson joined #salt
14:13 spiette joined #salt
14:15 masterkorp How do you guys reuse pillar data
14:17 masterkorp like a pillar item is a directory and then a pillar items is a file inside that directory ?
14:17 masterkorp can i specify that on the yaml
14:17 masterkorp ?
14:17 ndrei joined #salt
14:20 cheus masterkorp, pillars are just jinja+yaml files so one way it to use jinja variables  and then import that variable if you need to use it in multiple pillars
14:21 featherc joined #salt
14:21 DammitJim joined #salt
14:22 featherc Hi all, I will be attending the salt training next week in Salt Lake City. I was wondering, any of you that have taken that training, is there something I should read through online before hand to get more out of the training?
14:23 mr_chris left #salt
14:23 masterkorp cheus: hmm, thanks for the hint
14:23 rgbkrk joined #salt
14:23 cheus featherc, No particular documentation but it helps to have used salt even in a limited capacity
14:24 cheus I really wouldn't recommend going in cold. You'll have a better experience if you've used the major parts, eg, states, execution modules, grains, and pillars.
14:24 toddejohnson joined #salt
14:25 featherc we started using both puppet and salt about a month ago, setting up a limited proof-of-concept in house. We settled on salt but it is pretty basic. I have a basic setup with about 5 minions, a dev/prod environment and a few items in the pillar that we added
14:25 featherc i have no idea if i am doing any of it correctly however ;)
14:25 featherc it seems to work for the testing
14:26 cheus featherc, Then you should be in good shape. Do you know who's leading the class?
14:26 featherc i dont
14:26 featherc it is at their corporate office
14:26 diegows joined #salt
14:26 carmony featherc: are you based out of SLC?
14:26 SEJeff_work2 joined #salt
14:27 cheus It'll probably either be Dave or Seth; I've been in classes with both and they're both great instructors.
14:27 featherc yes, i live about 10 mins away
14:27 SEJeff_work joined #salt
14:27 chiui joined #salt
14:28 gothix joined #salt
14:31 featherc cheus: i dont think i have used execution modules yet, so i will look in the documentation about that
14:31 featherc but i think i have setup a top.sls and a few other states, a couple custom grains, and some pillar data
14:31 vejdmn joined #salt
14:32 cheus featherc, You probably have but you just didn't know it (eg, execution modules are what you use on the cli). For example the state execution module has the highstate function so using state.highstate is using an execution module. ;-)
14:32 cheus So is cmd.run()
14:34 featherc cheus: maybe i have then and just didnt know the terminology, this one one we are using on our centos 6.5 vms http://pastebin.com/TuWmfNVA
14:36 vejdmn joined #salt
14:37 featherc except i have those line is an sls file
14:37 toddejohnson_ joined #salt
14:37 cheus featherc, So that's a state and uses the *state* module, cmd and function run. It's just a small delineation since many state modules have the same names and functionality of the execution modules but the exec modules are what are used with salt or salt-call on the cli so, salt '*' cmd.run "echo 'Hello World'" uses the cmd execution module instead of the cmd state module you have there. I'd recommend playing with the salt command  or salt-call
14:37 featherc seems modules belong in a different spot
14:37 featherc ah
14:38 featherc so that sample i sent
14:38 featherc can you use pillar data in a module
14:38 featherc maybe it is better suited to a module than in a state
14:38 cheus featherc, Absolutely but you can use pillars in states too (in fact it's highly encouraged)
14:39 featherc salt 'resin*' spacewalk-actiavte $0 $1
14:39 featherc something like that
14:40 dsolsona joined #salt
14:40 cheus featherc, Yep! That's an execution module. It offers the realtime command interface to your minions whereas states deal with maintaining consistent packages/profiles/states, etc
14:40 featherc makes sense
14:41 featherc i worry about getting too deep in the documentation on my own, at risk of developing bad habits this early
14:41 cheus featherc, Agreed. Let your instructor guide you.
14:41 whiteinge featherc: hiya! i'm the one conducting the training next week
14:42 cheus featherc, ^ You're in good hands.
14:42 Ahlee Indeed
14:42 featherc great, i was asking earlier about any prep reading or things to help get more from the training
14:42 featherc if you have any thoughtx
14:42 whiteinge :)
14:43 featherc also it seems like there are many new lunch places over there
14:43 whiteinge (reading the scroll-back)
14:43 featherc i am excited for both the training and any lunching opportunities
14:44 whiteinge haha, awesome. there's a bunch of good places for lunch around there
14:45 Ahlee is the question things to do before a training session to maximize the gain from said training?
14:45 featherc ^ correct
14:46 featherc i have only installed and played with it in the last 3-4 weeks, and it has been fairly limited
14:46 featherc proof-of-concept type things
14:46 Ahlee You've written basic states?
14:47 thedodd joined #salt
14:47 Ahlee Familiarize yourself that http://salt.readthedocs.org/en/latest/salt-modindex.html exists
14:47 Ahlee i think that's single handedly the greates resource there is
14:48 featherc i have a top.sls and a couple other states. i am using directory recursion in one state to keep files correct. I have scheduling highstate running in a state, and some pillar data added. And a few custom grains
14:48 featherc about 5 minions
14:48 featherc all centos currently
14:48 quickdry21 joined #salt
14:48 Ahlee You're in a better place than my coworkers were, then, when we brought whiteinge out for our training
14:49 featherc ok great
14:49 featherc we use alot of vmware here, so i am also wondering about integration that way if any. I havent read too much into it yet
14:49 Ahlee You're way ahead of where we were.  We didn't get pillars going until the last day of the training, and they're still a mystery to most of my coworkers
14:49 featherc ah i see
14:50 featherc i stumbled on them really, looking to store a key somewhere on the master that i need on minions, but i didnt want to store it on them
14:50 alunduil joined #salt
14:51 Ahlee yeah.  We have an issue where management feels external pillar is too complicated to maintain (i.e., we have to write our own), yet not wanting to dictate salt as the source of the truth
14:51 Ahlee fun times
14:51 Ahlee anyawy, if you've gotten that far, you probably don't need to go through the quick start or similar
14:51 yetAnotherZero Ahlee: salt-modindex, is that a list of built ins?
14:52 jalbretsen joined #salt
14:52 carmony featherc: sweet, I work downtown.
14:52 featherc ok, i am mostly concered about all my structure. I dont feel i have any order and i do not want to develop bad habits yet
14:52 whiteinge pre-prep certainly isn't necessary. there's a *ton* of stuff to cover in three short days though so pre-prep will help with retention since you'll be less overloaded
14:52 gothix_ joined #salt
14:52 featherc carmony: i work out by the airport in the internation center area
14:52 Ahlee yetAnotherZero: yeah, that's everything
14:52 featherc international*
14:53 yetAnotherZero awesome
14:53 cheus Ahlee, woof. That's not fun. I've been playing with the idea of a few external pillars on our end but we always come back to the security issue which is why we always end-back on a git, local to the master, that doesn't respond to non-localhost commits.
14:53 carmony featherc: nice, I work for Deseret Digital Media, we do KSL.com and DeseretNews.com
14:53 carmony so down at the KSL building
14:54 featherc carmony, cool, i work for a company called Lightspeed we have software that runs motorcycle, boat, rv, snowmobile, etc dealerships
14:54 cheus carmony, Were you the one who gave the Salt for Devs talk?
14:54 timoguin lightspeed nxt... that's a name i have't heard since i worked in powersports 10 years ago
14:54 whiteinge featherc: there's a couple bad habits you might pick up from the docs (stuff we're hoping to address in the docs sprint next month), nothing huge though.
14:55 featherc whiteinge: thanks, i wont move too much further then. I just didnt want to show up and be learning all the terms the first day, that kind of thing
14:55 carmony cheus: depends on which conf, but yes, I've given a Mentoring Devs into DevOps talk at some confs :)
14:55 cheus carmony, SaltConf specifically. Great talk.
14:55 schristensen_ left #salt
14:55 featherc timoguin: yes i have been here about 7 years, started on the unix systems if you used that before nxt
14:55 carmony cheus: yup. Thanks man :)
14:55 cheus carmony, I really enjoyed that.
14:55 yetAnotherZero sorry, Ahlee: are these like recipes? http://salt.readthedocs.org/en/latest/ref/states/all/salt.states.host.html#module-salt.states.host for example
14:56 timoguin featherc: we didn't use the software, but i remember it well from the big dealer expo booths in Indianapolis
14:56 timoguin was too much money for us, i think
14:56 ml_1 joined #salt
14:57 whiteinge featherc: i agree with Ahlee, sounds like you'll be just fine. i'd suggest: be comfortable with the different module types and have an understanding of which ones do what (and where), and play with states and pillar beforehand.
14:57 featherc timeoguin: yes we still have a presence there. now most of our dealerships are hosted in a couple datacenters. I have around 1500 vm's i think. mix of windows/ubuntu/centos
14:57 timoguin very nice
14:57 featherc so i think salt will be great
14:57 toddejohnson joined #salt
14:57 featherc i tried to run a sql the other day and it took like 4 hours
14:58 featherc on only 500 vms or so
14:58 dddaaaannn joined #salt
14:59 featherc whiteinge: do you mean the various built in modules from what Ahlee had sent?
14:59 dddaaaannn hi all, I'm having an issue while attempting to define the runnerclient via the python api "self.runner = salt.runner.RunnerClient()"
14:59 dddaaaannn I'm receiving the error: "AttributeError: 'module' object has no attribute 'runner'"
14:59 whiteinge featherc: exactly
15:00 Ahlee whiteinge linking that at saltconf is likely the only reason I passed the SSCE ;)
15:00 whiteinge haha
15:01 featherc whiteinge: ok great. I will look through that this weekend
15:01 Ahlee yetAnotherZero: so that is an eample of the host state module
15:01 Ahlee it gives an example of the yaml formatting in the state file
15:02 jcockhren Ahlee: how much is SSCE?
15:03 whiteinge dddaaaannn: what does 'self' refer to there? are you making a custom class?
15:03 yetAnotherZero thanks Ahlee
15:03 dddaaaannn whiteinge: yeah I am
15:03 Ahlee jcockhren: I'm not sure.  I believe it was included iwth the pre-registration part of the conference
15:04 Ahlee jcockhren: I just signed up for stuff, company wrote the check so I honestly don't know. Sorry
15:04 whiteinge dddaaaannn: your path looks fine. how are you passing in opts?
15:05 featherc jcockhren: i think it was like 225
15:05 featherc i didnt sign up for it, but i saw it listed when i registered for the training
15:05 Heartsbane joined #salt
15:06 alunduil joined #salt
15:06 taion809 joined #salt
15:07 dddaaaannn whiteinge: Yeah I believe so .....            self.opts = salt.config.master_config('/etc/salt/master')             self.runner = salt.runner.RunnerClient(self.opts)
15:07 davidone joined #salt
15:07 davidone good afternoon
15:07 taion809 joined #salt
15:07 davidone I was playing with event_module
15:07 davidone issueing event.fire_master 'string' 'event'
15:08 GradysGhost joined #salt
15:08 davidone all I see using the eventlistener.py is a Tag: salt/auth
15:08 whiteinge dddaaaannn: use salt.config.client_config instead
15:08 davidone and no action taken
15:08 davidone do I need to regenerate keys?
15:08 taion809 joined #salt
15:08 dddaaaannn whiteinge
15:09 dddaaaannn no change
15:10 whiteinge dddaaaannn: your syntax is good. can you try it at the python shell to see if it works there?
15:11 dddaaaannn I just tried "salt-run manage.up"
15:11 dddaaaannn and that returned a list of available minions
15:11 jcockhren when I first saw dddaaaannn I read: "dddaaaammmmn"
15:12 jcockhren featherc, Ahlee: thanks
15:16 KennethWilke joined #salt
15:17 taion809 joined #salt
15:20 davidone is there anything I could watch to?
15:22 seanz left #salt
15:29 davidone ok, seems that reissuing keys helped
15:30 tyler-baker joined #salt
15:30 davidone but now when from the master I issue a state.highstate, states are executed on minions but the master returns to the prompt
15:30 davidone I'm using the latest salt release
15:30 davidone idea?
15:31 timoguin probably just timing out because the states are still running. the CLI defaults to a 5-second time
15:32 timoguin you can do --timeout=NUMSECONDS at the CLI
15:32 CeBe1 joined #salt
15:33 davidone cool, trying now
15:33 malinoff joined #salt
15:34 mateoconfeugo joined #salt
15:34 davidone great, thank you timoguin
15:34 davidone I hope there is a config parameter
15:35 davidone found it!
15:35 davidone thanks
15:36 conan_the_destro joined #salt
15:39 Networkn3rd joined #salt
15:40 rglen joined #salt
15:42 wendall911 joined #salt
15:42 troyready joined #salt
15:43 dddaaaannn is there anyway I can run salt commands from a server that is not the saltmaster?
15:43 dddaaaannn using authentication or something
15:44 jcockhren salt-api
15:45 Ahlee yeah, salt-api sets up a restful API - we use it extensively
15:45 Ahlee you can also configure the master to allow minions to broker commands
15:48 tligda joined #salt
15:57 masterkorp Guys where is the documentation about cycles on templates ?
15:58 taion809 joined #salt
15:58 pdayton joined #salt
16:00 jY what do people use if your minions run a highstate each say 10 minutes.. to make sure everything is running correctly?
16:02 masterkorp and keep stuff up to date and consistent
16:03 malinoff masterkorp, http://jinja.pocoo.org/docs/
16:06 Sp00n joined #salt
16:06 CeBe joined #salt
16:08 zain_ joined #salt
16:08 davidone Isn't an ord() function available in jinja?
16:08 kballou joined #salt
16:09 davidone I'm checking in http://jinja.pocoo.org/docs/
16:09 agronholm davidone: if it gets too difficult with jinja2, you can try mako which allows arbitrary python
16:10 masterkorp malinoff: thanks
16:11 davidone agronholm: I am creating a state using {% for ... %}
16:12 Sp00n left #salt
16:12 davidone I have a char and I need its ascii value
16:12 davidone in python I use ord/chr
16:12 agronholm and ord() did not work?
16:13 malinoff davidone, you can't do that with pure jinja, only with custom filters (which can't be done with salt), so you should use mako or something else to render your templates
16:13 kedo39 joined #salt
16:13 davidone {% set number = ord(dev[-1])-96 %}    <======================
16:13 davidone dev is something like 'sdc'
16:13 agronholm so, again, use mako
16:14 davidone ok, I'll take a look: just to be sure that it wasn't possible with jinja :)
16:15 masterkorp Guys can I run python code inside formulas ?
16:16 ipalreadytaken joined #salt
16:17 jhulten joined #salt
16:17 davidone well, I used a custom grain so I'll include my code there :)
16:20 whiteinge masterkorp: a great pattern for that is to make a custom execution module and call it from jinja. it's a quick process and it helps to keep logic out of jinja
16:20 whiteinge the steps are:
16:20 whiteinge mkdir -p /srv/salt/_modules
16:20 whiteinge touch /srv/salt/_modules/myutils.py
16:21 whiteinge <add a function "myfunction" that returns something>
16:21 whiteinge salt '*' saltutil.sync_modules
16:21 whiteinge then use it in jinja:
16:21 whiteinge {% set myvar = salt['myutils.myfunction'](optional, args, here) %}
16:21 mateocon_ joined #salt
16:22 KyleG joined #salt
16:22 KyleG joined #salt
16:24 benturner joined #salt
16:25 forrest joined #salt
16:25 masterkorp wow that is a great tip thank whiteinge
16:27 malinoff or you can use mako and do not care about a module distribution
16:28 Ahlee woah
16:28 Ahlee whiteinge: thanks.
16:28 davidone whiteinge: cool. thanks :)
16:29 forrest malinoff, mako? NOoooooooooooo
16:29 malinoff forrest, ok, just pure python
16:30 malinoff everything better than writing a salt module just to workaround that salt can't use custom jinja filters :)
16:30 forrest heh
16:30 malinoff also, | ord filter is not very logical, so it can be shipped with jinja
16:30 whiteinge i have a goal to get that pattern better documented during the docs sprint. i'm a fan of separating logic from presentation as much as possible
16:31 malinoff Each action should be adequate. Writing and distributing a salt module just to have an ability to call ord on a variable is not very adequate
16:32 whiteinge the dilemma with custom jinja filters is getting that code distributed to minions (since jinja is rendered on the minion). a custom execution module or a custom jinja filter are 98% the same thing, just have a slightly different execution contract. see: https://github.com/saltstack/salt/issues/12761
16:33 whiteinge malinoff: ^^ i'd be interested if you have any feedback on that ticket
16:33 smcquay joined #salt
16:33 malinoff that returns us that it's better to use something python-able, like mako
16:34 tdegrunt joined #salt
16:35 malinoff whiteinge, I like that approach with modules, but it is really useful when you have some complex logic, or if you want something self-explained. If you need something very little, like ord call, it's a huge overhead
16:36 joehillen joined #salt
16:36 thayne joined #salt
16:37 Ahlee Will time be spent expanding on mako renderer during the docs sprint?
16:37 agronholm meaning?
16:37 whiteinge malinoff: it makes sense to ship with a baseline of common functionality but allow that to be extended where individual/specific needs differ. the pattern is true for execution modules or jinja filters
16:37 shaggy_surfer joined #salt
16:37 whiteinge ord() may be a good built-in, for example
16:38 whiteinge Ahlee: i haven't heard of anyone interested in taking on mako stuffs for the sprint
16:39 malinoff whiteinge, the problem is that you can't imagine how people will use them. Someone needs ord, and someone needs hex, but hey, you don't have hex built-in!
16:40 malinoff And if you will implement the whole python's builtins, isn't better just to use a renderer that allows to run arbitrary python code?
16:40 Ahlee whiteinge: that's what i figured. thanks for confirming
16:41 whiteinge malinoff: you can't guess every possibility, no. which is why you have an extensible system for custom functionality. if something custom is a common need, you add it to core.
16:41 bmonty joined #salt
16:41 malinoff whiteinge, you don't need something custom if you can run a python ode
16:41 malinoff code*
16:41 agronholm the whole selling point in jinja2 is that people familiar with django will be right at home with the syntax
16:41 n8n joined #salt
16:42 vejdmn joined #salt
16:42 malinoff Don't you think that salt is much more used by system administrators than Django programmers?
16:42 agronholm I would think so
16:42 malinoff here we ho
16:42 malinoff go
16:42 davidone whiteinge: uhm... I've got an error
16:42 agronholm so why did they choose jinja2 over mako as the default renderer?
16:42 malinoff because it's default
16:42 davidone {% set number = salt['myutils.ord'](dev,97) %}
16:43 agronholm malinoff: default on what?
16:43 malinoff agronholm, default in salt
16:43 malinoff Every example uses jinja
16:43 agronholm malinoff: my question was, why did Salt choose jinja2 over mako as the default renderer
16:43 malinoff When you write a state without shebang, it uses jinja
16:43 davidone http://pastebin.com/vE3yHTXW
16:43 malinoff agronholm, I don't know - I'm not a salt core guy
16:44 whiteinge davidone: looking
16:44 davidone the error is: Rendering SLS "base:bminit" failed: Jinja variable 'dict object' has no attribute 'myutils.ord'; line 30
16:44 davidone whiteinge: thanks
16:44 cheus As a matter of best practice, is it acceptable to rely on include-order processing or should requires be explicit?
16:44 malinoff imho, because jinja was more documented, or more known by the salt developers, i really don't know
16:45 whiteinge davidone: syntax looks good. what do you see when you run: salt '*' saltutil.sync_modules
16:45 davidone I usually issue a sync_all
16:45 davidone no modules synced
16:45 forrest agronholm, because jinja is easier for non programmers to use
16:45 forrest compare jinja to mako
16:45 agronholm forrest: is it really?
16:45 malinoff forrest, It's a lie
16:45 forrest *shrug*
16:45 agronholm where did you get that idea
16:45 forrest I've talked to several people who felt more comfortable with jinja than mako
16:46 agronholm programmers or not?
16:46 forrest non
16:46 agronholm did they say why?
16:46 Ahlee cheus: I prefer specific requires because i'm paranoid
16:46 whiteinge malinoff: we obviously can't please 100% of people which is why the renderer system is pluggable. use whichever you like. *shrug*
16:46 malinoff Come on, there are tons (https://wiki.python.org/moin/Templating) of template engines, and you're comparing just two of them!
16:46 cheus Ahlee, As do I but boy sometimes can it be difficult to force them in.
16:46 forrest because even just looking at mako's examples is confusing for people who aren't familiar with python?
16:46 Ahlee cheus: agreed.
16:47 redondos joined #salt
16:47 redondos joined #salt
16:47 Ahlee I hate working with jinja, and would much prefer if it was straight python, but we like python
16:47 whiteinge davidone: did you see that module sync over when you first added it?
16:47 Ahlee and before salt, never used jinja
16:47 davidone whiteinge: no
16:47 forrest so use python Ahlee
16:47 malinoff whiteinge, of course, that's why I suggest people to use mako when they need something more that jinja can give. But custom filters is not something that should be implemented, i think
16:48 Ahlee forrest: right, and then we lose the googlability :)
16:48 forrest malinoff, if you're doing something more than what jinja can provide, just use python
16:48 forrest Ahlee, that's fair
16:48 Ahlee I find the 'just use' a misnomer
16:48 malinoff forrest, that's how I do complex things
16:48 forrest with mako?
16:48 forrest or with python
16:48 malinoff with python
16:48 forrest so what's the complaint then?
16:48 davidone trying to restart salt-master
16:49 forrest this sounds like an argument from some developer who uses chef
16:49 dude051 joined #salt
16:49 malinoff forrest, I'm not complaining :)
16:49 forrest ok
16:49 malinoff just arguing, since whiteinge asked for my opinion
16:49 forrest ahh
16:50 patarr do any of you guys use salt to integrate with jenkins and some sort of continous integration and deployment process?
16:50 Ahlee i think the sysadmin vs dev comment is valid, and for me to be a broken record in that salt targets developers but is used by sysadmins
16:50 forrest patarr, there are a couple people who do that, but you have to trust jenkins to run commands as the salt user (or use acls) so it does have a few downsides
16:51 forrest Ahlee, hmm that's interesting, I always felt like it was still more sysadmin friendly than chef or puppet are
16:51 Ahlee I use atlassian bamboo, and have bamboo interface with salt via salt-api to push successful builds
16:51 forrest ahh yea I forgot you were one of those people Ahlee
16:51 patarr how do you guys handle rollback?
16:52 forrest patarr, depends, you could store the version data in pillar, and then just change that value and rerun the state
16:52 Ahlee patarr: I yum install the last successful rpm of the software
16:52 malinoff forrest, it is MUCH more friendly than chef/puppet, but there is something that can be done better
16:52 Ahlee And that is how we do it
16:52 patarr Ahlee: ah, you build and package your application in an rpm? That's clever.
16:52 Ahlee we have an external pillar that is updated that tracks the "blessed" version of our software stack
16:53 Ahlee patarr: Not really clever, we have no web apps. :)
16:53 Ahlee i have three apache servers total, and those are the machines that handle the repos :)
16:53 davidone still issue
16:54 malinoff whiteinge, will you ever have a source code review sprint? Or am I asking wrong person?
16:54 cheus Ahlee, re: your broken record comment, I think the conjunction you were looking for is 'and' not 'but' and that's kind-of what makes it a successful solution
16:55 whiteinge malinoff: not sure i follow. review the salt source code?
16:55 malinoff whiteinge, yep. Review, target dirty places and improve them
16:56 whiteinge davidone: are you using a custon file_roots config?
16:57 Ahlee cheus: That's an interesting take on it
16:57 whiteinge malinoff: that kind of cleanup is a constant on-going process (see commits by cvrebert among others)
16:58 tdegrunt joined #salt
16:58 davidone whiteinge: no,
16:58 schimmy joined #salt
16:58 chiui joined #salt
16:58 davidone whiteinge: probably I should change the name of the function :/
16:59 malinoff whiteinge, of course you have ongoing cleanups, but I'm talking about something that could help to, for example, decrease master.py/minion.py slocs
16:59 cheus Ahlee, I'm not a sysadmin by any means nor are any of my the people in my department but they 'get' salt and it saves us hours of work in development alone since we can write our own deployments but systems can use it too for general orchestration
17:00 davidone grains:
17:00 davidone modules:
17:00 davidone outputters:
17:00 davidone nothing
17:00 Ahlee cheus: nice.  For us, we have our operations team mostly consuming it, and the standard developers can't be bothered with it.  I fall somewhere between those two camps
17:00 davidone # grep ^file_root /etc/salt/master
17:00 davidone file_roots:
17:00 malinoff Ahlee, it is called 'devops' :)
17:01 schimmy1 joined #salt
17:01 Ahlee i hate that word.
17:01 Ahlee But, yes.
17:01 whiteinge davidone: try renaming the .py file and running sync_modules
17:01 chamunks joined #salt
17:01 malinoff Ahlee, why?
17:02 Ahlee malinoff: sadly i don't have the time or ability to effectively rant on that
17:02 nvmme joined #salt
17:03 cheus Ahlee, I have the benefit of being in charge of the developers... so, well, I can dictate that sort of thing. ;-) Still, I could never have shoved puppet or chef on them. Salt was a good middle ground and our operations folks love it too. They also love not having to read incomplete README files on how to install software/prepare app servers. ;-)
17:03 cheus Ahlee, As I suspected, the devs prefer to write formulas to README's
17:04 davidone whiteinge: done, same result
17:04 davidone time to go, here
17:04 malinoff Ahlee, :)
17:04 davidone I'll take care later
17:04 davidone thank you, anyway
17:04 forrest cheus, I'm confused, are you saying that salt has incomplete readmes? Or other config management tools do?
17:04 forrest or just that your devs dont' like to write documentation
17:05 philipsd6 no, I think he's saying that devs are happier writing formulas to install their product, rather than READMEs that describe how to do it manually. :)
17:05 Ahlee cheus: I can see the draw.  Well written states do have a self documenting nature to them
17:05 Ahlee until you get into jinja hell, I find
17:05 forrest devs, WHY YOU NO LIKE DOCUMENTATION
17:05 cheus forrest:  philipsd6 got it
17:05 matrix3000 joined #salt
17:06 Ahlee sadly, i wind up with states that look like: https://gist.github.com/jalons/b777b4de44b563a04e48
17:06 philipsd6 it's not just DEVs forrest, I'm a DBA in Ops, and there's a lot of poor, out-dated documentation on our end too.
17:06 Ahlee anyway
17:06 Ahlee demo with the C levels in two hours
17:06 forrest :( I actually like writing docs
17:06 Ahlee better at least look like i started the presentation
17:06 forrest but probably because I don't memorize stuff.
17:06 whiteinge Ahlee: gl!
17:07 * whiteinge heads back to work too
17:07 fxhp joined #salt
17:08 helderco joined #salt
17:09 cheus forrest, It's not even just a matter of being outddated, either, devs are not always aware of the arguably more complicated hosting arrangements up in operations so documenation can be sorely lacking. They also dont' always start with clean environments so dependencies aren't always caught if they came with some other piece of work they're doing simultaneously.
17:10 cheus That can all show negatively in docs. So, the formula route is easy. Write a formula, try in an lxc container. If it worked there we can try it in production.
17:10 oz_akan_ joined #salt
17:11 forrest fair enough
17:19 smcquay joined #salt
17:20 masterkorp hello
17:21 masterkorp i have a cmd.run state that is not obeying the creates parameter
17:21 masterkorp i am using kitchen-salt with lastest salt
17:21 masterkorp http://docs.saltstack.com/en/latest/ref/states/all/salt.states.cmd.html
17:21 masterkorp from this page
17:21 Ryan_Lane joined #salt
17:22 masterkorp "The creates option will be supported starting with the feature release codenamed Helium"
17:22 masterkorp i think this already affters this case
17:25 masterkorp any ideas ?
17:27 shaggy_surfer joined #salt
17:28 combusean joined #salt
17:30 torbock joined #salt
17:30 whiteinge masterkorp: helium isn't out yet. the first RC is a couple weeks out still
17:31 masterkorp hmm
17:31 masterkorp how can i emulate this behauviour until then »
17:31 masterkorp *?
17:32 ZombieFeynman joined #salt
17:33 thedodd joined #salt
17:33 felskrone whiteinge: did you get the link to the "salt at scale" documentation?
17:33 stanchan joined #salt
17:33 whiteinge felskrone: yeah! great start
17:33 masterkorp felskrone: i like that title, share :)
17:34 felskrone ok, was just wondering :-)
17:34 schmutz joined #salt
17:34 felskrone hehe sure, sec
17:34 forrest felskrone, are you updating the issue for that as well?
17:34 forrest I can't remember if I made that one, or if someone else did
17:34 masterkorp ls
17:34 whiteinge masterkorp: try using  "unless: test -f /path/to/file" instead
17:35 felskrone forrest: what do you mean? add a link to point to the doc to the issue?
17:35 to_json joined #salt
17:36 felskrone masterkorp: there you go. https://github.com/felskrone/salt/blob/salt_at_scale_doc/doc/topics/tutorials/intro_scale.rst but its in its early stages
17:37 forrest felskrone, no just mention you're working on it in the issue
17:37 forrest so that we don't duplicate work
17:37 masterkorp felskrone: whiteinge thanks guys
17:38 tdegrunt joined #salt
17:39 forrest this looks good felskrone! Let me know if you want a review once you're done with it.
17:39 felskrone forrest: im not actually working on an issue right now. i'm working on minion failover code for multiple masters (no multimaster though). what issue exactly are you talking about?
17:40 felskrone forrest: will do :-)
17:40 forrest felskrone, https://github.com/saltstack/salt/issues/10024
17:40 forrest While it doesn't exactly hook up, it should still be mentioned
17:40 felskrone forrest:  didnt even know about that yet :-)
17:41 felskrone adding a comment now
17:42 schmutz joined #salt
17:44 forrest felskrone, awesome
17:47 druonysus joined #salt
17:47 ml_1 joined #salt
17:47 agliodbs so, having an issue that the mine is empty even though there's plenty of data when I iterate through grains.items
17:48 agliodbs I found a couple incidents of this via google, but none of the listed fixes worked for me
17:48 patarr any idea why ip.get_routes doesnt work on my centos boxes?
17:50 zain joined #salt
17:50 kedo39 joined #salt
17:51 bhosmer_ joined #salt
17:53 alainv a quick thank you to whoever fixed the Dash docset for Saltstack
17:53 GradysGhost joined #salt
17:54 felskrone forrest: there you go :-)
17:54 forrest yep just got the email!
17:54 forrest thanks
17:55 felskrone my pleasure :-)
17:55 bhosmer joined #salt
17:55 felskrone in the end i will fully publish our setup. i think it will be quite interesting for others
17:56 whiteinge alainv: that would be the readthedocs folks
17:57 whiteinge we just link to their build
17:57 alainv whiteinge: ah, thanks. Well it's helpful anyway
18:01 dlam joined #salt
18:02 kedo39 joined #salt
18:04 dlam super salt noob, i wanna set up a staging for my production environment:  should they both use the same salt master?  or should my staging thing have different master
18:05 rookie joined #salt
18:05 rookie howdy
18:05 rookie can someone guide me the right direction on understanding mines
18:06 oz_akan_ joined #salt
18:09 chrisjones joined #salt
18:09 thayne joined #salt
18:11 patarr any idea why ip.get_routes doesnt work on centos boxes?
18:13 KyleG1 joined #salt
18:15 KyleG joined #salt
18:15 KyleG joined #salt
18:19 ipmb joined #salt
18:21 mgw joined #salt
18:23 AdamSewell joined #salt
18:25 hopthrisC joined #salt
18:29 jaycedars joined #salt
18:33 viq What does salt use to run commands as a specific user?
18:35 to_json joined #salt
18:37 rgarcia_ joined #salt
18:38 schimmy joined #salt
18:40 agliodbs viq: you specific that, actually
18:40 dsolsona joined #salt
18:40 agliodbs if you don't, it uses whatever that user's default shell is
18:40 to_json joined #salt
18:40 viq agliodbs: yes, but _what_ does it _use_ to do that?
18:41 viq How, how does it change EUID ?
18:41 agliodbs oh!  don't know
18:41 jalaziz joined #salt
18:41 agliodbs probably just su, I'd expect
18:41 kedo39 joined #salt
18:42 viq Because someone's saying a formula doesn't work for him as sudo is not installed, and I'd like to verify that information, as it sounds plausible, but unlikely
18:43 Joseph_ joined #salt
18:43 whiteinge https://github.com/saltstack/salt/blob/develop/salt/modules/cmdmod.py#L321
18:43 whiteinge viq: ^^
18:44 Joseph_ I did a git PR to update the openstack topic about the need for ssh_interface. It was cathartic
18:44 Joseph_ :)
18:44 whiteinge it's usually su, like agliodbs mentioned, except for osx
18:44 * viq hands whiteinge a drink as he goes to investigate
18:49 oz_akan_ joined #salt
18:51 viq whiteinge: thanks. I saw that earlier, but wasn't 100% certain so wanted to verify
18:52 * whiteinge nods
18:54 viq https://github.com/saltstack-formulas/gitlab-formula/issues/7 is why I'm asking
18:54 forrest damn you and your spam viq!
18:56 * viq spams, hams and mushrooms forrest
18:56 Joseph_ who uses debian anyway? <shifty eyes>
18:57 Joseph_ I thought everyone was on centos (I joke I joke!)
18:57 viq Joseph_: I use both actually, and BSD if I have a choice ;)
18:57 Joseph_ viq: BSD? Really? Next thing you are going to tell me use solaris. I have no opinion on BSD but solaris was evil.
18:59 viq I haven't really had a chance to get into solaris. The only box I could see putting it on is my storage box, and put SmartOS there, but that's pointless as their implementation of KVM doesn't support AMD
18:59 viq But ZFS is nice
18:59 Joseph_ all evil is said to have some redeeming quality to it....:)
18:59 viq Well, ZFS works nicely on FreeBSD ;)
19:00 Joseph_ however, someone gave me a choice between windows dos and solaris zsheel
19:00 Joseph_ zshell
19:00 Joseph_ then i'd pick the lesser of two evils and opt for solaris
19:00 Joseph_ but that's like a prisoners dilemma kind of thing
19:00 viq Aye, that at least pretends to be unixy
19:00 Joseph_ viq: agreed
19:00 Joseph_ viq: i don't know how sys admins function on windows
19:01 Joseph_ viq: I work on hadoop and sometimes i'll encounter people who did nothing but windows AD type stuff
19:01 Joseph_ viq: and then they hit linux admin + hadoop and i find myself explaining SSH to them
19:01 Joseph_ viq: sad, funny, or both?
19:01 rjc joined #salt
19:01 viq Well, different worlds
19:01 Joseph_ True dat
19:02 viq You have your ssh to practially be on a machine and be able to do everything there.... They click in a couple of places and all machines connected to AD change their configuration.
19:03 Joseph_ I will give the devil its due. OpenLDAP is a horrifying user experience compared to AD when it comes to identity management.
19:03 Joseph_ Microsoft even makes kerberos relatively pain free to set up. Kerberos!!
19:04 forrest everyone knows that ldap is garbage
19:04 forrest it's not a secret
19:04 Joseph_ forrest: groupofnames!!!
19:04 Joseph_ forrest: do you know how long it took me to figure out that that was the group implementation in openldap?
19:04 agliodbs Joseph_: I don't agree with you about AD
19:04 agliodbs it's a nightmare too
19:04 viq Joseph_: I believe MS makes you noteven aware there's kerberos underneath
19:04 Joseph_ viq: correcdt and bless their hearts for it
19:05 Joseph_ agliodbs: everything sucks...some software sucks less than others.
19:06 Joseph_ viq: you can't imagine the joy of trying to set up MIT kerberos, with openldap as the baack end DB, and then getting hadoop daemons use it.
19:06 Joseph_ viq: saltstack would have actually come in mighty hand for that now that i think about it
19:06 viq oh?
19:07 Joseph_ viq: yea a lot of the pain was generating a certain number of keytab files, copying them to certain locations on certain machines, making sure permissions were set correctly etc AND updating kerberos conf files
19:07 Joseph_ just about all of that should have been automatable with salt i woudl expect
19:08 viq True. Though I'm still not certain of proper way to go about generating client certs for all of my machines, which sounds like a similiar issue
19:08 viq Well, distributing the keytab files _securely_ is a bit of an issue
19:08 viq As that probably should be done via pillars - and that poses a bit of a challenge
19:09 Joseph_ viq: what about the TLS salt module?
19:09 Joseph_ viq: does that not work?
19:09 Joseph_ viq: yea keytab in pillars....that's actually an interesting use case.
19:10 kula figuring out a better way of managing things like keytabs using salt has been on my list for a long time. having large blobs in pillars feels weird to me.
19:10 viq Joseph_: sure, it will generate keys and certs, probably on a central machine, say salt master. How do you securely distribute them to machines then?
19:10 Joseph_ viq: canned answer is you put them in a pillar. Does that not work in practice?
19:10 viq Joseph_: _how_ do you put them in a pillar?
19:11 viq http://garthwaite.org/virtually-secure-with-openvpn-pillars-and-salt.html is the best idea I've seen so far
19:11 Joseph_ reading
19:13 kula that's an interesting idea.
19:13 Joseph_ yea but pretty ugly even so
19:13 Joseph_ i don't know why it needs to be that complicated
19:13 Joseph_ well i mean i know why
19:13 bhosmer joined #salt
19:13 Joseph_ but couldn't they make that more user friendly
19:13 Joseph_ "they" being us i guess ha!
19:14 Joseph_ "securely, confidentially pull data from external source and then set it in a pillar"
19:14 Joseph_ that seems like a pretty generic common use case
19:14 kula what i really want is a salt fileserver-like thing that, a) doesn't give you a list of every file it knows about but b) allows you to say "get salt://some/thing/ key=<somekey>", and the keys could be nonces known to the fileserver and given to appropriate minions via pillar
19:15 Joseph_ in other words, access control on the fileserver?>
19:15 Joseph_ based on minion id perhpas?
19:15 kula perhaps. i rather like it simply being some random blob, and you can decide in your pillar how to distribute it (per-minion id, to a group of minions, based on a role, etc.)
19:16 viq Well, the problem is pillars need to be variables, you can't really feed them the files themselves
19:16 ZombieFeynman joined #salt
19:16 viq There are external pillars, where you could store said keys in a database, or ldap, or something... But again you'd have to get them there in the first place.
19:18 rookie under the cmd.run module, - unless: means if the statement under "unless" fails run the cmd.run statement, correct?
19:19 n8n joined #salt
19:19 kedo39 joined #salt
19:19 Joseph_ yes if non zero exit code then run
19:20 Joseph_ kula: so basically to "get" a file in your description, you'd pass the nonce as a pillar variable which then 'entitles' the minion to get that file?
19:21 cheus Alright whiteinge, it's a bit later than expected but just dropped another formula with the new pattern (and then some)
19:21 rookie thanks @Josepth
19:22 joehillen joined #salt
19:23 kula Joseph_: yeah
19:24 kedo39 joined #salt
19:27 kula I want something kinda like this: https://gist.github.com/tlk2126/353692a78407c362bbd0
19:27 ipmb joined #salt
19:32 Joseph_ that would be an improvement
19:32 Joseph_ but combining that with access control on minion id would be really cool
19:32 Joseph_ access control would be optional
19:32 Joseph_ kula: made a feature request yet? :0
19:32 Joseph_ :)
19:35 kula I'll drop a feature request soon
19:35 xzarth joined #salt
19:37 manfred kula: secure pillar data is something that is being worked on
19:37 manfred last i heard*
19:40 kedo39 joined #salt
19:41 ndrei joined #salt
19:41 Joseph_ manfred: secure pillar? compared to insecure pillar? :) whats that exactly?
19:42 ggoZ joined #salt
19:43 manfred Joseph_: similar to this http://www.ansible.com/blog/2014/02/19/ansible-vault
19:43 Theo-SLC joined #salt
19:43 to_json joined #salt
19:44 Joseph_ so you have a special command similar to salt-key to encrypt a config file
19:44 Joseph_ how does a minion decrypt?
19:44 Theo-SLC Hello saltines
19:44 manfred Joseph_: i said it was being worked on, or talked about, i didn't say i knew how it would work
19:44 Joseph_ Theo-SLC: lol haven't heard that one before
19:44 Joseph_ manfred: :( aww
19:44 Joseph_ manfred: i figured you'd be the source of all saltstack knowledge. :)
19:45 viq I saw there was a talk of gpg-renderer. I saw some people using... I think it was called hiera-eyaml as external pillars for that
19:45 Joseph_ viq: oh interesting gpg ring implementation
19:45 Joseph_ that could work
19:46 Joseph_ distributing keys could be annoying though
19:46 zain joined #salt
19:47 Theo-SLC question- Any problems with using a private Github repo as my gitfs backend?  Security?
19:48 manfred Theo-SLC: there shouldn't be, you should be able to tell gitfs what your stuff is, and use sshkey's to login and pull from it
19:49 manfred not sure if it works in 2014.1, but it should in develop and in about two weeks or so 2014.2rc1
19:50 Ahlee It works in 0.17.5
19:50 viq manfred: you mean 2014.6.rc2 ;)
19:50 manfred heh
19:50 viq unless it would be 7
19:50 viq erm, rc1
19:51 Ahlee We use atlassian stash, and used gitfs from 0.17.0 through to 0.17.4 before going back to local checkout on the master
19:51 viq I use gitfs with 2014.1
19:52 jaycedars joined #salt
19:53 bhosmer_ joined #salt
19:58 zsoftich_ joined #salt
20:01 jforest joined #salt
20:01 borgstrom joined #salt
20:02 faulkner joined #salt
20:02 juice joined #salt
20:02 vejdmn joined #salt
20:03 vbabiy Hey guys is there a way to run salt-call without requiring root?
20:03 MTecknology joined #salt
20:04 Valdo joined #salt
20:04 vbabiy I need to run a mine function to get all my frontend ips from a process that is not executed by the root user
20:04 Joseph_ sudo?
20:04 manfred ^^
20:04 manfred %salt ALL=(root) /usr/bin/salt-call*
20:05 vbabiy manfred thanks, I need to look in to this
20:05 Theo-SLC joined #salt
20:06 manfred not sure if it would, but it might be worth checking out how you could make calls to salt-api and how that returns data to you
20:07 vbabiy manfred which api are you talking about?
20:07 manfred https://github.com/saltstack/salt-api
20:07 manfred http://salt-api.readthedocs.org/en/latest/
20:07 vbabiy manfred thanks
20:07 manfred https://github.com/saltstack/pepper
20:07 manfred it exposes most of what you can do in salt through an api
20:16 ghartz_ joined #salt
20:21 londo_ joined #salt
20:24 the_lale1u joined #salt
20:24 Xiao_ joined #salt
20:24 eculver_ joined #salt
20:24 zsoftich1 joined #salt
20:24 toddnni_ joined #salt
20:24 mgarfias_ joined #salt
20:24 sdebot_ joined #salt
20:26 toastedpenguin joined #salt
20:26 aiqa joined #salt
20:29 ilako joined #salt
20:32 chrisjones joined #salt
20:34 ZombieFeynman joined #salt
20:37 ekristen joined #salt
20:38 ekristen 2014.1.4 broke docker registry authentication
20:38 ekristen anyone know how I can install 2014.1.3 from apt repo? the ppa seems to not keep old versions?
20:39 smcquay joined #salt
20:40 manfred there is not a way, launchpad doesn't keep old versions around
20:41 n8n joined #salt
20:41 ekristen manfred: so frustrated, it took me 5 hours to track this down today
20:43 to_json joined #salt
20:43 tamentis left #salt
20:43 ekristen basepi: you around?
20:44 basepi ekristen: mmgmm
20:44 basepi mmhmm*
20:44 ekristen https://github.com/saltstack/salt/issues/13305
20:44 ekristen backstory: I setup a new server and my usual states weren’t working
20:45 ekristen I finally decided to look at the salt-minion version and realized that the new one was 2014.1.4 and one that was working was 2014.1.3
20:45 ekristen I upgraded the 2014.1.3 (after I pulled an image just to make sure it was still working) and once it was on 2014.1.4 is no longer works
20:46 ekristen *it no longer works
20:47 basepi honestly, i know nothing about the docker modules/states.  but if the 2014.1.3 versions were working for you, you could sync them to your minions as custom modules/states, using the _modules and _states directories
20:47 basepi or, if you just want to downgrade to 2014.1.3, you could use the bootstrap script to install from the git tag
20:48 basepi curl -o install_salt.sh -L https://bootstrap.saltstack.com
20:48 basepi sudo sh install_salt.sh git v2014.1.3
20:48 ekristen oh, hrm, interesting, how does the _modules and _states work? are their docs for that?
20:49 conan_the_destro joined #salt
20:50 manfred ekristen: http://docs.saltstack.com/en/latest/ref/file_server/dynamic-modules.html
20:50 ekristen oh so just like the _grains folder?
20:51 ekristen so I can just grab https://github.com/saltstack/salt/blob/v2014.1.3/salt/states/dockerio.py
20:51 ekristen and drop it in _states and sync it to the minion?
20:51 pdayton joined #salt
20:54 basepi yep
20:55 basepi just remember in the future if you want the latest features you need to remove it from that directory and sync again
20:55 sigma_ joined #salt
20:55 basepi custom modules/states will override the builtin, so you can get non-standard versions that way
20:56 sigma_ left #salt
20:56 mogman1 joined #salt
20:57 ZombieFe_ joined #salt
20:59 ekristen basepi: ok its not the state/module that is the problem
20:59 ekristen I just put the old ones on
20:59 ekristen all I did to break it was update salt-minion to 2014.1.4
20:59 basepi did you run a `salt '*' saltutil.sync_all`?
20:59 ekristen yup
20:59 basepi and it listed those
20:59 basepi "new" modules?
20:59 ekristen yes
20:59 basepi hrm......
20:59 ekristen and then I ran docker.pull and got the same error
21:00 ekristen so maybe pillar parsing for the docker-registries changed?
21:00 ekristen would that be outside the state and module?
21:00 basepi pillar parsing hasn't changed as far as I know, that would be a big deal
21:00 basepi can you add the erroring output of your various commands to that issue?
21:00 basepi i want to see the exact errors
21:01 ekristen one sec
21:01 mogman1 joined #salt
21:04 ekristen basepi: its not an “error” in the traditional sense, docker states/modules no longer use the auth creds to authenticate
21:04 ekristen https://gist.github.com/ekristen/650a39868891fee94367
21:04 ekristen first file is 2014.1.3
21:04 ekristen and second is 2014.1.4
21:05 ekristen basepi: I’m installing 2014.1.3 again to make sure it works again once back on that version
21:06 basepi ekristen: cool
21:06 jalaziz joined #salt
21:06 travisfischer joined #salt
21:06 basepi your installed version of docker didn't change, did it?
21:07 * basepi is trying to find which external dependent file might have changed
21:07 ekristen basepi: no — I litterally did my docker.pull test
21:07 ekristen then upgraded to 2014.1.4
21:07 ekristen did it again and it failed
21:07 basepi right, but did you do a full system upgrade or *only* upgrade salt
21:07 basepi i guess is what i was trying to clarify
21:07 ekristen apt-get install salt-minion*
21:07 basepi kk
21:08 mogman1 Hey, I'm having some troubles using salt-cloud to spin up new minions and have them communicate with the master, I'm wondering if someone could help me work through it.
21:12 ekristen basepi: hrm — now its not working with 2014.1.3 installed
21:14 * ekristen pulls hair out
21:16 basepi if you're getting 403 errors, are you sure it's not just a service outage?
21:16 repl1cant joined #salt
21:16 * basepi doesn't even know what you're hitting to get those 403 errors
21:17 ekristen basepi: docker.pull is hitting a http service to pull down the docker image
21:17 ekristen the same script is working right now on 6-10 other servers
21:17 basepi right.  so do you own that http service or does someone else?
21:17 basepi oh
21:17 ekristen against the same url
21:17 ekristen I host it
21:17 basepi ya, that definitely puts a wrench in that theory....
21:17 jchen it's probably something really dumb that you'll facepalm later about, dont worry :)
21:17 ekristen I can see that in my broken salt minions that auth header is not being sent
21:17 ekristen my one server was working perfectly
21:17 ekristen then I upgraded it to 2014.1.4 and it stopped working
21:18 alainv what is best practice between modules and grains in a templated config file? e.g. network.get_hostname() vs grains['fqdn']
21:18 ekristen I downgraded it back to 2014.1.3 and it still doesn’t work
21:21 bhosmer_ joined #salt
21:21 forrest Is anyone using a CI tool here internally that isn't Java based?
21:22 forrest and isn't buildbot with it's inability to do real job supprot
21:22 forrest *support
21:22 basepi ekristen: my mind is officially boggled.  can you try stopping the minion, removing the /var/cache/salt/ directory, and restarting the minion?  Maybe it's a caching issue of some sort...
21:22 ekristen hrm caching I can do that
21:26 forrest whiteinge, I feel as though we may need to start charging you a comment toll every time you use x is dead! long live x!
21:27 kermit joined #salt
21:28 whiteinge out with the slightly old, in with the slightly newer!
21:29 ekristen basepi: so I just found one of my old servers still running 2014.1.3 that still works
21:29 ekristen what is the best way to debug this — I have at least one that is still working, and 3 that used to work but are now broken
21:31 forrest whiteinge, now we just need to ssl the docs!
21:32 ekristen basepi: docker-py version is the same
21:32 ekristen basepi: python version is the same
21:33 basepi ekristen: anything in the debug log?
21:33 whiteinge forrest: technically they are now but the HTTP redirect sends you back to the non-ssl. if you settle on a page you can change to ssl
21:33 basepi on the minion that's failing?
21:33 forrest ahh ok
21:34 whiteinge forrest: that said, i'm moving docs over to the same servers that boostrap.saltstack.com is on. process is mostly done
21:34 whiteinge (that's all in the salt-docs-formula)
21:34 ekristen basepi: unfortunately not, technically the states are executing and modules are executing properly —- but for some reason they are neglecting to send authentication information anymore
21:37 basepi ...hrm
21:37 basepi did you delete the "custom" versions of the state/module from your _states and _modules directories?
21:37 forrest whiteinge, awesome
21:37 forrest kicking ass and taking names
21:38 whiteinge that's how i roll. slowly...
21:38 ekristen basepi: I have not, I can and try again
21:40 rgbkrk_ joined #salt
21:40 basepi ekristen: do that, sync again, and try again
21:41 basepi wondering if perhaps you pulled the wrong version or something random like that
21:41 agliodbs joined #salt
21:41 ekristen possible
21:41 basepi because again, i'm at a total loss.  if it's not the cache, and you downgraded to a working version.....
21:44 ekristen well next step is for me to start hacking the docker module
21:45 ekristen because the behavior is that it isn’t finding the auth info
21:45 ekristen and using it with the client instantiation
21:47 ekristen basepi: no joy
21:48 basepi curses
21:48 ekristen where are the modules kept locally?
21:49 ekristen ok better question
21:50 ekristen how do I log from the dockerio module?
21:53 ekristen basepi: if I edit a module do I have to restart salt-minion?
21:53 ZombieFeynman joined #salt
21:54 basepi Pretty do a saltutil.refresh_modules
21:54 basepi to trigger a reload
21:54 ekristen what if I’m editing locally instead
21:55 ekristen ok I think I found the problem!
21:55 ekristen nope nm
21:55 ekristen false alarm
21:55 viq forrest: you may want to ask about a CI tool on ##infra-talk. I heard http://www.go.cd/ may be interesting, but it's again java based
21:56 forrest yea java is not going to fly
21:56 forrest and buildbot is just garbage
21:56 forrest so it's either find something, or make buildbot work
21:56 oz_akan_ joined #salt
21:58 ZombieFe_ joined #salt
21:59 googolhash_w joined #salt
21:59 viq forrest: have you looked at https://en.wikipedia.org/wiki/Continuous_integration
21:59 forrest I did
21:59 dmick should sudo -E salt-call state.highstate make the calling shell's env vars available to the jobs in the state tree?
22:00 forrest viq, on that they don't sort by language, or by features at all
22:01 viq true
22:01 KyleG1 joined #salt
22:01 viq forrest: I suggest you try asking on ##infra-talk
22:01 dmick (I mean in a masterless config)
22:01 forrest viq, yea good plan
22:02 forrest dmick, well sudo -E should pass the env variables
22:02 dmick it passes to salt-call, but, does salt-call pass the parent env along to cmds run from highstate, is the question
22:03 KyleG joined #salt
22:03 KyleG joined #salt
22:03 Gareth forrest: Jenkins isn't a viable solution?  It is java but does work.
22:04 dmick (not sure how to refer to an env in an .sls to test it)
22:04 forrest Gareth, unfortunately not
22:04 KyleG joined #salt
22:04 KyleG joined #salt
22:08 shaggy_surfer joined #salt
22:08 dmick environ.get, apparently undocumented.  ok.
22:09 ekristen basepi: I’ve got no idea
22:09 forrest dmick, http://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.environ.html
22:10 ldlework joined #salt
22:10 dmick *ARGH*.  Again, I cannot grok how states and modules relate
22:10 dmick thx
22:11 viq dmick: module "do something on system _now_"; state "put it in sls, system should be in this state; based on modules"
22:12 viq dmick: salt \* pkg.install - this is pkg module. salt \* state.sls mysql ; where in mysql.sls you have eg pkg.installed - this is pkg state
22:12 ekristen basepi: I’ve downgraded docker-py too to test that, but no joy
22:15 dmick viq: ok.  so a test with module.run can show me what I need, apparently, cool.
22:16 ekristen basepi: I’ve tried mulitple servers now
22:17 ekristen anytime I upgrade it stops working
22:18 basepi ekristen: does your authentication information (docker-registries and its children) show up with a pillar.items call?
22:18 ekristen basepi: yup
22:18 ekristen basepi: I’ve tried docker-py version 0.3.0 and 0.3.1
22:18 schristensen joined #salt
22:19 ekristen basepi: I’ve also confirmed that the dockerio.py is gathering the auth information
22:22 basepi well, i'm stumped.  next step for me would be to blow away the minion install comppletely, and then install a fresh 2014.1.3
22:22 basepi otherwise, i'm out of ideas for the moment.  doesn't help that i have Friday-afternoon brain
22:23 ekristen yeah
22:23 ekristen I’m tempted to do that
22:34 kermit joined #salt
22:38 KyleG joined #salt
22:38 KyleG joined #salt
22:41 ekristen basepi: I think I found it
22:42 ekristen oh nope — damnit, this is aggrevating
22:42 basepi dangit, got my hopes up!
22:42 ekristen as far as I can tell the docker client is getting the same config option
22:47 ekristen basepi: https://gist.github.com/ekristen/f50a6fe6c6170e67f1a2
22:48 ekristen both are 2014.1.3
22:48 ekristen the not working one was 2014.1.3 > 2014.1.4 > 2013.1.3
22:48 perfectsine joined #salt
22:49 ekristen hrm
22:50 perfectsine joined #salt
22:50 ekristen basepi: idea
22:50 ekristen I wonder if something from salt-common is causing the problem
22:51 ekristen I’m going to have to try and install a system with 2014.1.3 cleanly to test I guess
22:51 agliodbs joined #salt
22:52 basepi ekristen: ya, not sure
22:53 basepi ekristen: but i have to head out, i'll let my subconscious work on it this weekend
22:55 ekristen kk
22:56 UtahDave joined #salt
23:02 mgw1 joined #salt
23:03 pdayton joined #salt
23:10 jcsp joined #salt
23:16 redondos joined #salt
23:18 joehillen joined #salt
23:20 mogman1 joined #salt
23:32 _dougg joined #salt
23:33 ZombieFeynman joined #salt
23:35 Thiggy joined #salt

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