Perl 6 - the future is here, just unevenly distributed

IRC log for #salt, 2016-12-02

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

All times shown according to UTC.

Time Nick Message
00:02 amontalban joined #salt
00:04 jbellone joined #salt
00:05 Rumbles joined #salt
00:11 jbellone joined #salt
00:16 J0hnSteel joined #salt
00:18 jbellone joined #salt
00:18 spuder joined #salt
00:21 J0hnSteel joined #salt
00:27 arif-ali joined #salt
00:28 jbellone joined #salt
00:37 MTecknology "func = super(LazyLoader, self)"  that's an entertaining line to read.
00:38 ssplatt joined #salt
00:39 jbellone joined #salt
00:41 jas02_ joined #salt
00:44 anotherzero joined #salt
00:44 jbellone joined #salt
00:47 oida joined #salt
00:48 dxiri joined #salt
00:49 Rubin_ so theres a cpan module.. but no cpan state
00:50 Rubin_ i just want to install a cpan module
00:56 jbellone joined #salt
00:58 spuder joined #salt
01:00 jbellone_ joined #salt
01:04 hasues joined #salt
01:04 hasues left #salt
01:08 scsinutz joined #salt
01:12 jbellone_ joined #salt
01:14 fuhnoo joined #salt
01:15 Aleks3Y joined #salt
01:16 jbellone joined #salt
01:18 lws joined #salt
01:19 fracklen joined #salt
01:36 jbellone joined #salt
01:37 lws joined #salt
01:53 jas02_ joined #salt
01:54 DEger joined #salt
01:54 oida joined #salt
01:56 fracklen joined #salt
01:58 nethershaw joined #salt
02:01 nickabbey joined #salt
02:12 MTecknology Is there any way to override this file?  /usr/lib/python2.7/dist-packages/salt/templates/debian_ip/debian_eth.jinja
02:13 Sammichmaker joined #salt
02:14 sh123124_ joined #salt
02:16 vodik joined #salt
02:18 catpiggest joined #salt
02:30 nethershaw joined #salt
02:33 seanz joined #salt
02:34 seanz Greetings, all. Is it required to specify a salt master key for vagrant provisioning?
02:34 seanz This one: https://www.vagrantup.com/docs/provisioning/salt.html#master_key
02:41 sebastian-w joined #salt
02:46 MTecknology seanz: defaults should be fine
02:46 seanz MTecknology: Thanks. Trying it now.
02:46 onlyanegg joined #salt
02:48 ilbot3 joined #salt
02:48 Topic for #salt is now Welcome to #salt! <+> Latest Versions: 2016.3.4, 2016.11.0 <+> Support: https://www.saltstack.com/support/ <+> Logs: http://irclog.perlgeek.de/salt/ <+> Paste: https://gist.github.com/ (please don't multiline paste into channel) <+> See also: #salt-devel, #salt-offtopic <+> Ask with patience as we are volunteers and may not have immediate answers
02:56 seanz MTecknology or anyone else: When would I want to use explicit keys then?
02:57 jas02_ joined #salt
03:01 MTecknology seanz: short answer... you'll know
03:01 seanz haha
03:01 seanz Great answer.
03:01 MTecknology You'll ask yourself, "how the crap can I ... oh."
03:13 seanz MTecknology: I'm looking forward to that day.
03:17 MTecknology don't
03:18 MTecknology it's not an elite day or anything special, it just becomes another option that you didn't know you wanted until you wanted it
03:27 orionx joined #salt
03:29 orionx_ joined #salt
03:31 evle joined #salt
03:32 seanz MTecknology: It just means more experience. That's what I'm looking forward to.
03:34 MTecknology ah, cool :)
03:35 MTecknology I just didn't want to leave you thinking I meant to imply needing special options was some elite status; just that, in general, options like that don't need explanation until you need them. I don't know the actual answer to your question because I prefer salt-cloud for dev work
03:38 mpanetta joined #salt
03:41 dxiri joined #salt
03:44 bastiandg joined #salt
03:45 wangofett joined #salt
03:49 seanz MTecknology: Good to know! I'm moving in that direction. I planned on learning what I could from vagrant + salt and then moving to salt-cloud for deployment. Do you think it's better to start straight off w/ salt-cloud? I was having trouble with all the layers I had to go through, learning-wise.
03:50 seanz salt-cloud is the final destination, for sure. I want to model my new machines locally and then deploy them with the same (or similar) configuration. At least with the same tools.
03:51 seanz I have to head out, but I'll check back.
03:51 seanz Thanks again.
03:57 flebel joined #salt
03:58 MTecknology Bye!
04:11 jbellone joined #salt
04:12 rem5 joined #salt
04:14 cyteen joined #salt
04:16 theblazehen joined #salt
04:18 amontalb1n joined #salt
04:21 Sammichmaker joined #salt
04:27 flebel joined #salt
04:36 dxiri joined #salt
04:57 chowmeined joined #salt
04:59 alvinstarr joined #salt
05:03 jas02_ joined #salt
05:04 dxiri joined #salt
05:09 rdas joined #salt
05:13 tobiasBora joined #salt
05:21 rodr1c joined #salt
05:21 rodr1c joined #salt
05:30 rodr1c joined #salt
05:30 rodr1c joined #salt
05:30 preludedrew joined #salt
05:32 rodr1c joined #salt
05:37 scoates joined #salt
05:44 sp0097 joined #salt
05:46 jbellone joined #salt
05:50 sp0097 joined #salt
05:54 jbellone joined #salt
05:57 jbellone_ joined #salt
06:00 tiwula joined #salt
06:10 jas02_ joined #salt
06:12 onlyanegg joined #salt
06:14 k_sze[work] joined #salt
06:28 dariusjs joined #salt
06:42 bocaneri joined #salt
06:43 impi joined #salt
06:44 fracklen joined #salt
06:48 jas02 joined #salt
06:50 MTecknology My highstate went from nearly ten minutes to <1 min by upgrading from a pi2b+ to a pi3
06:50 MTecknology that's exciting!
06:53 sh123124213 joined #salt
06:53 auzty joined #salt
06:54 dxiri joined #salt
07:00 felskrone joined #salt
07:04 pipps joined #salt
07:04 orionx joined #salt
07:09 jbellone_ joined #salt
07:22 jas02 joined #salt
07:33 xmj that's a solid improvement
07:36 www-bukolay-net joined #salt
07:37 fracklen joined #salt
07:38 jbellone_ joined #salt
07:41 darioleidi joined #salt
07:46 ernescz joined #salt
07:48 jas02_ joined #salt
07:51 tobiasBora joined #salt
08:00 pipps joined #salt
08:01 g0m3z joined #salt
08:03 g0m3z Hi there
08:04 fracklen joined #salt
08:05 orionx joined #salt
08:06 pcdummy hi g0m3z
08:07 ramSeraph joined #salt
08:07 ramSeraph hey there.. anyone know if file.managed state has facl support?
08:07 jhauser joined #salt
08:07 ramSeraph on linux
08:08 ramSeraph I dont see it, am I missing something?
08:14 fracklen joined #salt
08:16 g0m3z i dont think that is implemented
08:19 g0m3z i thoink you would have to use https://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.linux_acl.html
08:19 g0m3z respectively the state.linux_acl
08:24 samodid joined #salt
08:29 iggy !salt state.linux_Acl
08:29 saltstackbot https://docs.saltstack.com/en/latest/ref/states/all/salt.states.linux_Acl.html
08:29 cswang joined #salt
08:30 iggy !salt state.linux_acl
08:30 saltstackbot https://docs.saltstack.com/en/latest/ref/states/all/salt.states.linux_acl.html
08:30 iggy should make that do a lower()
08:30 ivanjaros joined #salt
08:44 ReV013 joined #salt
08:46 yuhlw left #salt
08:46 DEger joined #salt
08:50 jas02_ joined #salt
08:52 jbellone_ joined #salt
08:55 fracklen joined #salt
08:56 dxiri joined #salt
08:57 fracklen_ joined #salt
08:58 fracklen joined #salt
09:00 onlyanegg joined #salt
09:00 jbellone_ joined #salt
09:02 ramSeraph @g0m3z @iggy already saw that.. was wondering why it is not there in file.managed itself.. feels like it should belong there
09:03 mikecmpbll joined #salt
09:03 ramSeraph considering opening an issue
09:07 orionx joined #salt
09:08 ronnix joined #salt
09:08 krymzon joined #salt
09:11 o1e9 joined #salt
09:12 jbellone_ joined #salt
09:14 jbellone joined #salt
09:23 ivanjaros joined #salt
09:24 dariusjs joined #salt
09:27 s_kunk joined #salt
09:36 jas02_ joined #salt
09:37 iggy because... _linux_ acl?
09:37 demize joined #salt
09:38 sjohnsen joined #salt
09:38 muep joined #salt
09:39 jacksontj joined #salt
09:39 sjorge joined #salt
09:39 sjorge joined #salt
09:39 iggy i.e. the functionality needs to be usable across as many OSes as possible
09:39 colegatron_origi joined #salt
09:41 keimlink joined #salt
09:50 ventris joined #salt
09:59 thehaven joined #salt
09:59 cyborg-one joined #salt
10:00 dariusjs joined #salt
10:07 orionx joined #salt
10:09 Reverend joined #salt
10:17 J0hnSteel joined #salt
10:18 haam3r1 joined #salt
10:18 haam3r1 left #salt
10:22 amcorreia joined #salt
10:25 jbellone joined #salt
10:28 preludedrew joined #salt
10:33 joe__ joined #salt
10:37 jbellone joined #salt
10:39 jbellone_ joined #salt
10:47 jbellone_ joined #salt
10:51 jbellone joined #salt
10:52 cztanu joined #salt
10:52 jas02 joined #salt
10:53 jbellone_ joined #salt
10:54 Rumbles joined #salt
10:59 dxiri joined #salt
11:08 orionx joined #salt
11:10 jbellone_ joined #salt
11:10 jschoolcraft joined #salt
11:16 impi joined #salt
11:19 pipps joined #salt
11:20 pipps99 joined #salt
11:29 pipps joined #salt
11:31 impi joined #salt
11:32 dariusjs joined #salt
11:38 Dr_Jazz joined #salt
11:40 Reverend anyone canhazborrow - how would I go about triggering a push to a specific node group if a file is added or updated in a directory?
11:40 Reverend we want to automate the SSL pushing, and want to watch /etc/ssl/letsencrypt on salt master. if there's a new one, push to ssltermination nodegrou[/.
11:41 Reverend nodegroup*
11:41 AndreasLutro inotify beacon and reactors probably
11:41 Reverend thanks AndreasLutro - I'll check docs :) <3
11:42 Reverend much love
11:47 pipps joined #salt
11:47 gaghiel joined #salt
11:49 ws2k3 is it possible to exclude some minions with salt? for example salt --exclude "web1,web2" --batch-size 1'*' cmd.run "df -h"
11:50 keimlink joined #salt
11:50 Reverend you can use 'not' i think in your globs
11:54 pipps joined #salt
11:54 jas02 joined #salt
12:03 jbellone_ joined #salt
12:05 stooj joined #salt
12:08 sjorge joined #salt
12:08 sjorge joined #salt
12:09 orionx joined #salt
12:10 Dr_Jazz joined #salt
12:11 aidin joined #salt
12:12 dxiri joined #salt
12:14 jbellone_ joined #salt
12:15 aidin joined #salt
12:16 mikecmpbll joined #salt
12:19 stooj joined #salt
12:25 Dr_Jazz_ joined #salt
12:26 stooj joined #salt
12:26 sjorge joined #salt
12:26 sjorge joined #salt
12:28 numkem joined #salt
12:32 jbellone_ joined #salt
12:33 pipps joined #salt
12:33 sjorge joined #salt
12:33 sjorge joined #salt
12:38 pipps99 joined #salt
12:39 dariusjs joined #salt
12:41 jas02 joined #salt
12:42 jas02 joined #salt
12:43 jas02 joined #salt
12:44 jas02 joined #salt
12:44 cyteen_ joined #salt
12:54 ssplatt joined #salt
13:00 cyteen_ joined #salt
13:10 orionx joined #salt
13:11 cyteen__ joined #salt
13:11 jbellone_ joined #salt
13:14 jbellone joined #salt
13:16 cyteen_ joined #salt
13:19 ronnix joined #salt
13:20 davromaniak joined #salt
13:22 cyteen__ joined #salt
13:25 jbellone joined #salt
13:29 cyteen joined #salt
13:34 DEger joined #salt
13:37 armyriad joined #salt
13:37 cyteen_ joined #salt
13:38 _Cyclone_ joined #salt
13:43 cyteen__ joined #salt
13:44 dxiri joined #salt
13:45 jas02 joined #salt
13:46 cyteen_ joined #salt
14:04 rem5 joined #salt
14:10 orionx joined #salt
14:11 faizy joined #salt
14:16 pipps joined #salt
14:22 rim-k joined #salt
14:22 rim-k hello everyone
14:22 rim-k I just upgraded to carbon and a salt '*' state.sls my_state doesn't work anymore
14:23 rim-k Instead I get : Passed invalid arguments to state.sls: call_high() takes exactly 2 arguments (3 given)
14:23 rim-k does anyone had the issue?
14:25 jbellone joined #salt
14:25 nickabbey joined #salt
14:25 Rumbles joined #salt
14:27 XenophonF Reverend: would you share your final config w/r/t letsencrypt?
14:27 nicksloan joined #salt
14:27 XenophonF That sounds like how I was going to approach it, but I haven't had time to set up each individual part.
14:27 Reverend tbh, it probably won't help many people. I'm building it -around- a highly available system with reverse proxies everywhere and stuff
14:27 XenophonF ah
14:27 Reverend i can do... once i've pseudo'ed it tho, if you need :)
14:28 Reverend more than happy if it speads some know ledges
14:29 Reverend XenophonF - we have 2+ ssl termination boxes that reverse proxy /.well-known to a single letsencrypt server (for verification). salt pushes all of the domains for the cluster to letencrypt that deals with teh aquisitions via a python script and syncs them to master using salt.cp. the last step of pushing it out to the boxes is killing me :P
14:29 dariusjs joined #salt
14:30 hlub hmm, I have a CentOS 7 master and I'm trying to use gitfs but it fails cloning via HTTP/HTTPS. :/ It gives errorabout failed authentication while I'm very sure that I configured the credentials correctly.
14:30 Reverend ~/.ssh/config ?
14:30 Reverend not sure if it's needed, but I've had problems with git perms due to fucked up configs before
14:31 hlub I also noticed that the same happended when cloning with git command. The same command works on aonther machines with newer git version (1.8-1.9 fail and something like 2.6 works).
14:32 Reverend whats the error?
14:32 Reverend pastebin meh
14:32 hlub also git clone via ssh works without problems but I'd prefer https here.
14:33 hlub it only says "fatal: Authentication failed for '<the url i gave to it>'" even with --verbose
14:33 XenophonF Reverend: thanks for the clue
14:33 hlub after asking for user and pw
14:35 Reverend have you configured your user and pw?
14:35 Reverend :P
14:35 hlub yes, in salt-master's config
14:36 jbellone joined #salt
14:42 pipps joined #salt
14:46 jas02 joined #salt
14:49 jbellone joined #salt
14:49 jas02_ joined #salt
14:51 pipps joined #salt
14:52 rim-k anyone?
14:54 ReV013 joined #salt
14:54 jbellone joined #salt
14:55 Reverend rim-k - am i missing something?
14:55 racooper joined #salt
14:58 rim-k I just upgraded to carbon and a salt '*' state.sls my_state doesn't work anymore
14:58 rim-k Instead I get : Passed invalid arguments to state.sls: call_high() takes exactly 2 arguments (3 given)
14:59 hlub I probably solved my problem..
15:03 hlub yeah, clone works now using pygit2 but git clone (version 1.8.x) still fails.
15:03 Tanta joined #salt
15:04 ronnix_ joined #salt
15:11 Rumbles joined #salt
15:11 dariusjs joined #salt
15:11 pipps joined #salt
15:11 cyteen_ joined #salt
15:13 pipps joined #salt
15:14 tapoxi how are you guys debugging/testing?
15:17 mpanetta joined #salt
15:17 dariusjs_ joined #salt
15:20 hlub depends on the issue
15:22 mpanetta joined #salt
15:25 jessexoc_ joined #salt
15:26 dariusjs joined #salt
15:29 spuder joined #salt
15:32 jessexoc joined #salt
15:33 nicksloan joined #salt
15:37 racooper howdy. I'm having a problem with an stunnel config file using a jinja template.  https://gist.github.com/racooper/97b9ff8d0532867d6d17044ff7787fe5 is the file.
15:38 Salander27 joined #salt
15:38 CampusD joined #salt
15:38 racooper The issue seems to be around line 21, {% if 'mysql' or 'mysql56' in grains['roles'] -%}, being ignored and the entire server config getting stuck into clients too
15:39 racooper Salt version is 2015.5.10
15:40 tapoxi hlub: just in a 'how do you test code before deploying to prod' sense
15:40 tapoxi or do linting/validation while writing states
15:42 CampusD Hi guys, had a quick question, is there a way to check whether a certain file or directory is available on the master? I am thinking jinja on a state file checking for a path on the master like salt://my/directory/path
15:45 jessexoc_ joined #salt
15:47 jas02 joined #salt
15:50 tapoxi campusd: salt.states.file
15:51 tapoxi namely file.directory and file.exists
15:51 pipps joined #salt
15:52 racooper ok to somehwat answer my own question...if I change line 21 to {% if 'mysql' in grains['roles'] or 'mysql56' in grains['roles'] -%} then it works.
15:54 mpanetta_ joined #salt
15:55 sp0097 joined #salt
15:55 CampusD tapoxi, would something like this then work? https://gist.github.com/UtahCampusD/f302aff11900f31e433794839ef87f67
15:56 tapoxi CampusD: I don't think you can use the fileserver path, I think you'd need to use the actual unix path
15:56 orionx joined #salt
15:57 pipps joined #salt
15:57 CampusD tapoxi, how would i reference the master? won't it think to check on the minion only if I use the unix path?
15:57 pipps joined #salt
15:58 tapoxi CampusD: not sure what you're trying to do. I was assuming you had a minion on the master and you could check locally
15:59 jbellone joined #salt
16:00 nickabbey joined #salt
16:00 tapoxi CampusD: might be able to pull it off with salt.modules.cp
16:00 CampusD tapoxi, I am having the minions get files from the master which are custom some some minions only. It's based on the minion id, so I wanted to check the master to see if it had a folder with the minion id name, then grab the files
16:01 tapoxi CampusD: salt.modules.cp.list_master_dirs
16:02 CampusD tapoxi, cool, I'll take a look at that option, thx
16:07 CampusD tapoxi, that option might work, I can see the dirs on the master that I need, I guess I'll have to invoke it with "module.run" inside the state, thx
16:07 pipps joined #salt
16:07 rem5 joined #salt
16:07 tapoxi CampusD: yeah no problem, that's probably how you have to do it (with module.run)
16:09 spuder joined #salt
16:10 eprice joined #salt
16:11 rem5 joined #salt
16:11 tercenya joined #salt
16:12 jas02 joined #salt
16:12 anotherzero joined #salt
16:14 sarcasticadmin joined #salt
16:18 sp0097 joined #salt
16:20 amontalban joined #salt
16:20 amontalban joined #salt
16:21 dendazen joined #salt
16:23 pipps joined #salt
16:25 Electron^- joined #salt
16:26 onlyanegg joined #salt
16:30 jessexoc joined #salt
16:33 jas02 joined #salt
16:36 fracklen joined #salt
16:37 ronnix joined #salt
16:39 JPT joined #salt
16:43 jessexoc joined #salt
16:48 mcspiff_ joined #salt
16:48 jas02 joined #salt
16:49 nicksloan joined #salt
16:50 samodid joined #salt
16:51 voxxit joined #salt
16:51 seanz joined #salt
16:51 seanz Howdy, humans.
16:51 XenophonF GREETINGS FELLOW HUMAN
16:51 seanz haha!
16:52 seanz Does anyone have a recommendation for bootstrapping salt masters? Most of the tutorials show manually provisioning it, but I was hoping to automate even that.
16:52 seanz I was looking into vagrant for this purpose, as there is a plugin to provision servers in AWS.
16:52 pcdummy seanz: use "salt-ssh" with saltstack-salt-formula
16:52 XenophonF I BELIEVE IN AUTOMATING EVERYTHING THUS HAVE I ALSO AUTOMATED SALT MASTER DEPLOYMENTS
16:52 XenophonF er
16:52 XenophonF it actually hurts to type like that
16:52 seanz I believe you, because you're screaming.
16:52 seanz haha
16:52 XenophonF hang on let me pull up the gist
16:53 pcdummy :) :) shouting the giving own stuff :)
16:53 seanz pcdummy: I learned about salt-ssh, and I saw mention of saltstack-salt-formula. So this is a combination I can store in a repo somewhere?
16:53 XenophonF seanz: https://gist.github.com/xenophonf/d8da7f47ea29d9ad46e7
16:53 seanz Checking.
16:53 XenophonF seanz: https://gist.github.com/xenophonf/95357d87b6e0b5e2b0e6
16:54 XenophonF my configs are all on github/s3/codecommit
16:54 seanz # FIXME: C shell scripting is evil in the eyes of the LORD.
16:54 seanz Have you verified this? :)
16:54 pcdummy seanz: to be True, i haven't used that tech (yet) but i know others do that with salt-ssh
16:54 XenophonF It's in the Bible.
16:54 gtmanfred oh man, tcsh
16:55 XenophonF Like, in Leviticus or something.
16:55 gtmanfred everything is in leviticus
16:55 seanz This looks promising. I guess the thing I like about vagrant is I can take the same configuration and test it locally first. Then, by using --provider=aws I can provision a new machine in AWS.
16:55 seanz Is it possible to do something like that w/ this setup?
16:55 XenophonF I'm sure it is.
16:56 seanz Interesting. I'll have to play around with this.
16:56 seanz I actually don't know the *same* configuration will work in vagrant. It just looks like it'll take a minimal of tweaking between dev and "prod".
16:57 XenophonF I'm using salt-formula etc. so Salt manages itself.
16:58 XenophonF All the script does is (1) create the VM, (2) install the Salt packages, (3) lay down enough of the config to get the Salt master to talk to GitHub/S3/CodeCommit, (4) manually run salt-formula's salt.formulas/salt.master SLSes.
16:58 seanz Ah, I'd heard about this initiative a few years ago.
16:59 cyteen__ joined #salt
16:59 XenophonF The script is really my DR plan for re-creating the master.
16:59 pipps joined #salt
16:59 XenophonF I need to update it because now I'm using GPG to encrypt selected Pillar values.
16:59 seanz Salt states are still ordered, right? Or did that change?
16:59 seanz We used 0.16.4 at my last job, and having to manage ordering was a huge pain. Not that we weren't able to do it - it was just a lot more overhead.
17:00 XenophonF I don't know? I always use requisites when order matters to me.
17:01 seanz I'll have to test. I like the order I see being the order it runs (with some exceptions to that, I'm sure).
17:02 XenophonF I think it orders state IDs as listed in an SLS file, top to bottom, but i tend to assign multiple states to the same state ID, which breaks that ordering (if I recall correctly).
17:02 XenophonF like I said, if order matters I use a requisite
17:02 XenophonF otherwise I assume they can run in any order
17:03 seanz Ah, ok. I am used to placing one state per block, so that would be a difference. I see examples online of people doing both. I'm guessing there's no real preference either way?
17:03 XenophonF I'm not sure.
17:03 seanz I definitely see lots of require statements still.
17:05 XenophonF this is probably the best example of my coding style - https://github.com/irtnog/openssh-formula/blob/master/sshd/init.sls
17:05 cmarzullo comments. gross
17:06 cmarzullo ;)
17:06 XenophonF here's a more complex example - https://github.com/irtnog/shibboleth-formula/blob/master/shibboleth/idp/init.sls
17:07 XenophonF cmarzullo: not just comments - i put jinja comments in the templates, but also regular comments in the rendered files
17:07 cmarzullo gross! /s
17:07 cmarzullo those are some nice looking state files
17:07 XenophonF https://github.com/irtnog/openssh-formula/blob/master/sshd/files/moduli
17:07 cmarzullo XenophonF: ++
17:07 lws joined #salt
17:07 jas02 joined #salt
17:07 scsinutz joined #salt
17:07 XenophonF thanks!
17:08 XenophonF i need to circle back to my other formulas and update them to match
17:08 XenophonF and then i need to figure out how to teach my colleagues how to write salt states
17:08 cmarzullo and I picked up a trick from you. I didn't realize you don't have to do \ on cmd.run for continuations
17:08 XenophonF oh yeah!
17:09 XenophonF YAML strings are... weird
17:09 whytewolf I'm not a fan of the multiple states per id. but that is just a personal prefence. other wise decent looking
17:10 cmarzullo yeah I do multiple state ids. But they way those linked states look, it kinda changes my mind a bit.
17:11 XenophonF I found myself doing a lot of something_pkg: pkg.installed, then something_file: file.recurse, then something_service: service.running
17:11 Sketch i like how you can put multiple things in a state, but dislike how you can't put multiple things of the same type.
17:12 whytewolf because I"m doing openstack install i find a have a lot of seperate file.managed that would be under the same state id. which just doens't work
17:12 cmarzullo ^^ yeah that's it. That's why I switched. (I think)
17:12 XenophonF I end up trying to use file.recurse instead of file.managed in those cases
17:13 whytewolf thats nice if they are going into the same directory :P
17:13 XenophonF true
17:13 XenophonF it doesn't really work for dynamically created states, either
17:13 XenophonF i have a lot of state IDs that look like something_{{ loop.index }}
17:13 cmarzullo we do that a lot too.
17:14 XenophonF esp. in shibboleth-formula, where i try to support inline metadata or signing keys
17:16 cmarzullo I find myself doing that lot.
17:16 dyasny joined #salt
17:16 pipps joined #salt
17:17 o1e9 joined #salt
17:20 brasticstack joined #salt
17:22 brasticstack Hi! Is it possible to capture the output of a state module to use it as data in one of my states? In particular I'm trying to gather the output of postgres.db_list. TIA!
17:28 tapoxi I namespace my ids which looks a little weird but works
17:28 tapoxi e.g. base.packages.utilities.installed: and web.services.nginx.running:
17:29 Reverend have a FABULOUS weekend ladies and gents
17:29 Reverend love you all - take it easy.
17:30 tapoxi why not Reverweekend
17:31 [SYN\ACK] joined #salt
17:33 whytewolf brasticstack: postgres.db_list is not a state module.
17:33 brucevein joined #salt
17:33 brasticstack D'oh! You're right
17:34 brucevein left #salt
17:35 seanz XenophonF: I really like the map.jinja file you're using - it looks like a great example of that feature.
17:35 whytewolf the direct answer to your original question about state module output as input for other states is no.
17:35 seanz (I've had a chance to look more closely at the links you sent)
17:35 whytewolf however. you can use jinja to gather data from exacution modules. [jinja is rendered before the states run]
17:36 brasticstack @whytewolf: Awesome! Should I be able to find an example in the docs somewhere?
17:37 whytewolf brasticstack: https://docs.saltstack.com/en/latest/ref/renderers/all/salt.renderers.jinja.html https://docs.saltstack.com/en/latest/topics/jinja/index.html
17:37 whytewolf brasticstack: https://docs.saltstack.com/en/latest/topics/jinja/index.html#calling-salt-functions would be the direct link to calling salt functions
17:38 brasticstack ah, that last one was the bit of info I was missing. I figured I needed to do salt['something'], but I didn't know I could execute modules from there.
17:38 Edgan joined #salt
17:39 brasticstack Huge thanks @whytewolf!
17:42 lubyou_ joined #salt
17:43 mikecmpbll joined #salt
17:45 pipps joined #salt
17:46 nicksloan joined #salt
17:47 fracklen joined #salt
17:48 jbellone joined #salt
17:49 jas02_ joined #salt
17:52 XenophonF seanz: i use the default.yaml/map.jinja/init.sls pattern everywhere
17:52 XenophonF i think i got it from other state formulas
17:53 XenophonF i don't break things down like template-formula though, because i don't think it makes sense to split package installation and configuration and service management into separate SLS IDs
17:54 XenophonF unfortunately, defaults can only go so far
17:54 XenophonF i have a lot of places in my formulas where i need to set a default but can't do it in defaults.yaml or map.jinja
17:54 XenophonF e.g., when looping through a list of metadata providers in shibboleth-formula
17:55 XenophonF so i end up making heavy use of the |default Jinja filter
17:56 lubyou_ is pkg.refresh_db broken on windows for 2016.11?
17:56 eprice joined #salt
17:58 pmcg joined #salt
18:01 nickabbey joined #salt
18:01 KajiMaster joined #salt
18:03 faizy joined #salt
18:03 jas02 joined #salt
18:04 tom29739 joined #salt
18:04 brasticstack @whytewolf: I can't quite get what I need to out of those docs. I'm attempting to do {{ salt['postgres.list_dbs']() }} in my .sls, but I receive this error: Jinja variable 'salt.utils.templates.AliasedLoader object' has no attribute 'postgres.list_dbs'
18:05 brasticstack I'm missing something obvious, I can tell
18:06 whytewolf postgres.db_list https://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.postgres.html#salt.modules.postgres.db_list
18:07 brasticstack oh jeez
18:07 tercenya joined #salt
18:07 scsinutz joined #salt
18:09 KajiMaster joined #salt
18:09 brasticstack My brain took a vacation. Thanks, and sorry about the dumbosity!
18:09 whytewolf no problem i have issues rememebering things all the time
18:10 brasticstack That's what computers are for, right?
18:10 whytewolf exactly
18:15 MTecknology Anyone happen to have any guess why this line would be commented out of the template?  https://github.com/MTecknology/salt/blob/2016.11/salt/templates/debian_ip/debian_eth.jinja#L23
18:16 pipps joined #salt
18:17 pipps joined #salt
18:17 whytewolf were you not getting a hwaddr? or maybe if you use binding getting the same hwaddr multiple times and confusing later on?
18:17 CampusD question, is this jinja syntax valid? {% set host = grains['host'] %}  {% if salt['cp.list_master_dirs']('prefix','some/path/to/files/custom/{{ host }}') %}
18:17 * whytewolf really doesn't know. just guessing
18:18 whytewolf CampusD: no
18:18 CampusD not sure about {{ host }} inside the statement
18:18 whytewolf {% set host = grains['host'] %}  {% if salt['cp.list_master_dirs']('prefix','some/path/to/files/custom/'~ host ) %}
18:18 Trauma joined #salt
18:19 CampusD thanks whytewolf, I always forget about those ~
18:28 pipps joined #salt
18:28 dariusjs joined #salt
18:29 jas02 joined #salt
18:32 pipps joined #salt
18:33 pipps joined #salt
18:33 s_kunk joined #salt
18:36 s_kunk joined #salt
18:40 cyborg-one joined #salt
18:40 pipps joined #salt
18:42 fracklen joined #salt
18:43 MTecknology whytewolf: I don't use hwaddr. I'm in the file for other reasons and just noticed that a documented option would be silently dropped because it's not part of the template.
18:43 jas02 joined #salt
18:43 rim-k joined #salt
18:44 * whytewolf shrugs.
18:44 mirceaulinic joined #salt
18:45 MTecknology I just noticed another bug...
18:46 lubyou_ joined #salt
18:47 mirceaulinic Hello salt-ers, just in case you missed the late addition to the Carbon release notes: https://docs.saltstack.com/en/develop/topics/releases/2016.11.0.html#network-automation-napalm - hope this would be helpful for you or your colleagues/friends etc :)
18:48 jas02 joined #salt
18:49 jas02_ joined #salt
18:53 MTecknology neat
18:58 _JZ_ joined #salt
19:04 onlyanegg joined #salt
19:07 whytewolf thats a kewl thing, not at all useful for me. but kewl none the less
19:09 dariusjs joined #salt
19:16 mirceaulinic Haha this is for people working with network devices (mostly network engineers). If you know anyone that might be interested, feel free to spread this info
19:19 spuder_ joined #salt
19:19 cliluw joined #salt
19:19 orionx joined #salt
19:19 chowmein__ joined #salt
19:20 cscf So you can manage switches and routers in Salt?
19:20 nickabbey joined #salt
19:22 SaucyElf joined #salt
19:22 MTecknology salt-ssh has always been able to do that
19:25 cscf Really?  I didn't know that.
19:26 jas02 joined #salt
19:26 cscf Do you mean with -r raw commands, or actual states?
19:27 MTecknology I've heard of using actual states, but never tried any of it.
19:27 MTecknology This might be what I've been waiting for... I hope.
19:27 jas02 joined #salt
19:28 jas02_ joined #salt
19:28 MTecknology I /really/ wanna manage switch configs with salt
19:28 ronnix joined #salt
19:29 cscf http://grokbase.com/t/gg/salt-users/154nxx9gqw/salt-for-networking-devices
19:31 tapoxi_ joined #salt
19:31 tapoxi_ hi everyone, anyone using a formula for couchbase?
19:32 XenophonF how do i tell salt to do a yum groupinstall?
19:33 CampusD yumpkg.group_install
19:33 CampusD maybe? https://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.yumpkg.html
19:34 XenophonF ah thanks
19:34 Edgan Xenohttps://docs.saltstack.com/en/latest/ref/states/all/salt.states.pkg.html
19:34 Edgan XenophonF: ^
19:34 Edgan XenophonF: You want the state not the module
19:35 XenophonF fantastic thanks!
19:35 CampusD Edgan is right, the state seems to have salt.states.pkg.group_installed
19:36 jbellone joined #salt
19:38 tercenya joined #salt
19:40 wiqd joined #salt
19:40 OliverMT joined #salt
19:43 bbhoss joined #salt
19:45 jbellone joined #salt
19:46 CampusD question, I am getting this error https://gist.github.com/UtahCampusD/b43543c4a1eb2a781b2df01a5d39c2e4
19:46 spuder joined #salt
19:46 CampusD The variable not being Iterable but when run from CLI, I get list/dict from cp.list_master_dirs
19:46 simonmcc joined #salt
19:46 CampusD do I need to do some kind of .getitems or something like it in jinja?
19:51 linovia joined #salt
19:51 samkottler joined #salt
19:52 nahkiss joined #salt
19:53 Edgan CampusD: https://stackoverflow.com/questions/11628958/python-typeerror-argument-of-type-function-is-not-iterable
19:55 Edgan CampusD: Looks like you want some (), https://github.com/saltstack/salt/issues/3029
19:55 saltstackbot [#3029][OPEN] Better error when a state includes salt['foo.bar'] without () | Example naiive state:...
19:55 Edgan CampusD: It is fun when python-isms bleed through the abstraction.
19:55 sjorge joined #salt
19:55 sjorge joined #salt
19:59 CampusD yeah, isn't jinja or is it python, I guess it's both
19:59 CampusD thanks Egdan, that worked
20:01 jas02 joined #salt
20:01 tcolvin joined #salt
20:01 thejrose1984 joined #salt
20:01 jas02 joined #salt
20:04 krobertson joined #salt
20:21 bltmiller joined #salt
20:24 tapoxi joined #salt
20:24 seanz joined #salt
20:26 racooper joined #salt
20:27 tercenya joined #salt
20:35 seanz joined #salt
20:36 mirceaulinic @cscf yes, through a proxy minion
20:37 mirceaulinic @MTecknology via ssh and scraping the CLI is not network automation
20:39 netcho joined #salt
20:41 cscf mirceaulinic, so the defined proxy minion uses this 'Napalm' API to talk to the switches?
20:42 mirceaulinic Yes, exactly
20:46 Xopher joined #salt
20:47 Xopher joined #salt
20:48 cscf mirceaulinic, how many switches support Napalm?
20:48 mirceaulinic What do you mean? How many vendor platforms?
20:49 edrocks joined #salt
20:49 mirceaulinic http://napalm.readthedocs.io/en/latest/support/index.html#supported-devices here's the complete list of supported operating systems
20:50 mirceaulinic The most used switches are running eOS (Arista), IOS (Cisco) and JunOS (Juniper)
20:52 mirceaulinic + NX-OS and Pluribus
20:53 Sketch that's pretty good support
20:53 MTecknology mirceaulinic: ... I didn't say it was, did I?
20:54 tercenya joined #salt
20:54 CampusD thanks Egdan, that worked
20:54 jas02 joined #salt
20:54 mirceaulinic @MTecknology True :)
20:58 sjorge joined #salt
20:58 sjorge joined #salt
20:58 sc250024 joined #salt
20:59 sc250024 Is there a `saltstack-formula` maintainer in the chat? I have an update on the `php-formula` that could use some eyes
20:59 sc250024 https://github.com/saltstack-formulas/php-formula/pull/113
20:59 saltstackbot [#113][OPEN] New structure for new Ubuntu PPA and other fixed | Overview...
21:01 ivanjaros joined #salt
21:02 austin_ joined #salt
21:04 austin_ in a multimaster setup, job cache is by default local to that master. so if you have 2 masters, the cache is unique to each system. not shared. so executing something on master1 should always return to master1 or master 1 and master2 ?
21:08 bltmiller joined #salt
21:10 DEger joined #salt
21:12 dariusjs joined #salt
21:20 keimlink joined #salt
21:21 jas02 joined #salt
21:22 sc250024 joined #salt
21:25 bltmiller I have a question about environment variables and salt agents
21:26 bltmiller I'm using squid on my VMs and that is set via HTTP_PROXY and HTTPS_PROXY env vars, and it totally works...except when remotely executing a curl from my master to a minion
21:27 bltmiller what's even stranger is that the problem goes away when I start my minion with `salt-minion -d ` instead of with systemd `systemctl start salt-minion`
21:27 bltmiller seems to me that salt is not picking up the proxy env vars that I have already set on the system
21:27 jbellone joined #salt
21:27 bltmiller wondering if there's something I'm missing
21:28 whytewolf rare event: I'm asking a question [aka I'm to lazy to do the work to find the answer myself] :P is it possable to use saltify to make a siloed master? [aka a master that does not have a syndic or other master to talk to, and the minion on it responds to itself.]
21:28 whytewolf bltmiller: curl from the master to the minion?
21:28 whytewolf http proxy?
21:28 DEger joined #salt
21:28 bltmiller whytewolf: yup: `salt 'minion' cmd.run 'curl google.com'`
21:29 bltmiller where the http proxy is already set on the minion
21:29 whytewolf ahhh. okay. issue. salt has it's own enviroment not the enviroment of a user
21:30 bltmiller well I think the issue in question is: what's different about environment between starting salt under Systemd vs. daemonizing directly using `salt-minion -d`
21:31 gtmanfred systemd doesn't have any extra environment variables from your .bashrc?
21:31 gtmanfred and systemd handles backgrounding the start command
21:31 DEger joined #salt
21:31 whytewolf bltmiller: systemd  doesn't load an enviroment for the subsystem. while with salt-master -d uses your already loaded enviroment of the user you are running as
21:32 btorch left #salt
21:32 bltmiller gtmanfred: printing out my environment with `printenv | grep -i proxy` shows my settings for the current user which is the same user that my salt minion is running under
21:34 bltmiller whytewolf: and what's *also* interesting about this is that some *other* minions of mine have *no problem at all* with my remote cmd.run curl
21:34 bltmiller ¯\_(ツ)_/¯
21:35 ALLmightySPIFF joined #salt
21:35 whytewolf so find what is different. that could be a matter of /etc/bashrc vs ~/bashrc
21:35 bltmiller I've even tried setting proxy bits in my systemd salt-minion.service file, to no effect
21:36 bltmiller heh yeah I've been ripping hairs out trying to find the incongruity to no avail so far...
21:36 ALLmightySPIFF joined #salt
21:36 whytewolf you are remembering to reload the systemd configs and then restart after words right?
21:36 bltmiller yyyyup
21:36 bltmiller afterwards even ;)
21:36 gtmanfred and you see the environment variables when you do `systemctl cat salt-minion.service` ?
21:37 ALLmightySPIFF joined #salt
21:37 bltmiller yyyup: https://gist.github.com/blaketmiller/aaf34668232bf15deb3c4aea31c26e22
21:37 gtmanfred hrm, yup that should work
21:37 bltmiller right!?
21:37 bltmiller I feel like I'm taking crazy pills
21:38 sp0097 left #salt
21:38 bltmiller were I to file a bug, I wouldn't even know what to label it
21:38 whytewolf you are it is called systemd :P
21:38 bltmiller ^this guy
21:38 gtmanfred can you gist the curl -vvv to a random link? because that should show it trying to use the proxy...
21:39 tapoxi_ joined #salt
21:39 tapoxi_ anyone using thorium?
21:39 bltmiller gtmanfred: the remote call doesn't ever return though, not sure how I'd capture that output of the failure
21:39 whytewolf also does salt 'minion' cmd.run printenv show your the env you are expecting?
21:40 bltmiller whytewolf: yup
21:41 yuhll joined #salt
21:42 whytewolf I don't know then.... unless some setting for curl isn't being setup. telling it to use the proxy if the env is there
21:42 whytewolf but i thought that was default behavour
21:42 CeBe joined #salt
21:44 bltmiller thanks for the assist whytewolf and gtmanfred. I'll holler back if I ever nail it down
21:45 gtmanfred yeah, that is werid
21:45 gtmanfred weird...
21:45 llua could someone help me with getting more info for this bug https://github.com/saltstack/salt/issues/33708 ?
21:45 saltstackbot [#33708][OPEN] visudo check command leaves cache file in /tmp | Description of Issue/Question...
21:46 MTecknology How do unit tests work? Can I have a couple tests in each unit test and let them fail on self.assertListEqual?
21:47 gtmanfred you can, but it will fail the test that fails the assert
21:47 gtmanfred and wont run any more asserts in that function
21:47 whytewolf llua: isn't -f used for telling visudo to use an alternate file? and you aren't giving it an alternate file so is it even returning
21:47 MTecknology perfect :)
21:48 MTecknology I'm looking here ( https://github.com/MTecknology/salt/blob/2016.11/tests/unit/modules/debian_ip_test.py#L152 ) the mocked stuff on 160 seems like a good test and should probably happen first, but I want to also add a much larger test that includes bonding
21:48 MTecknology I'm also considering just adding def test_get_interface_bonded()
21:48 gtmanfred just add another function
21:48 gtmanfred yeah
21:49 gtmanfred i would do that
21:50 MTecknology I suppose then I can copy/paste the whole block and not have to understand what's actually going on; just know input/output
21:50 gtmanfred yeah
21:50 MTecknology I also need to write a test to check what it wants to write to disk. I'm more scared of that one.
21:51 gtmanfred that shouldn't be too bad
21:51 gtmanfred just mock and make sure that the input file is what you expect it to be
21:52 MTecknology I feel like it would be much easier if I understood python unit testing ... or any unit testing
21:52 gtmanfred yeah it would
21:52 MTecknology I just understand people write them and I don't want to make them fail. :P
21:53 gtmanfred MTecknology: https://docs.saltstack.com/en/latest/topics/development/tests/unit.html
21:53 gtmanfred MTecknology: https://www.toptal.com/python/an-introduction-to-mocking-in-python
21:53 llua whytewolf: i think the filename is passed as an argument to the command since it does error when template generates an incorrect sudoers file. the sudoers-formula also uses it https://github.com/saltstack-formulas/sudoers-formula/blob/master/sudoers/init.sls#L14
21:53 MTecknology Nice! :D
21:53 MTecknology gtmanfred: Thanks!!!
21:54 gtmanfred llua: the file name is not passed, that -c is just checking all the sudo files because there is the #include statement int he sudoers file
21:55 gtmanfred actually
21:55 gtmanfred i am wrong
21:55 gtmanfred The specified command will be run with an appended argument of a temporary file containing the new managed contents
21:55 gtmanfred so it looks like the file.managed is not cleaning up the tmp file for some reason
21:56 jas02 joined #salt
21:58 gtmanfred i don't see anyway it would get out of the file.managed function without deleting the tmp_filename though :/
21:59 whytewolf llua: if you use -l trace do you see anymore?
22:00 whytewolf [I'm not sure if -l all includes trace]
22:03 whytewolf llua: for the record the temp file is made here https://github.com/saltstack/salt/blob/develop/salt/states/file.py#L2052
22:04 llua -l all includes trace, i didn't see anything relevant though http://sprunge.us/HOBL
22:04 pipps joined #salt
22:05 pipps joined #salt
22:07 whytewolf humm, only way i see the temp file being saved is if it throws an error during any of the steps that it checks
22:07 whytewolf or ... if for some strange reason os.remove is broken on the system
22:09 llua i was just able to use os.remove successfully
22:09 whytewolf also, i remeber trace being a lot more noisy then what is in that file you posted
22:10 bltmiller waited awhile and curl finally returned the failure, but I don't think it's anything *particularly* useful: https://gist.github.com/blaketmiller/cd298563708f167a1da053b9bcfe03c2
22:10 hemebond joined #salt
22:12 whytewolf gtmanfred: just my opinion but that section of file.managed could use a couple of log.debugs sprinkeled about it
22:13 spuder joined #salt
22:14 jas02 joined #salt
22:14 MTecknology My head is ouchy! I think I need to go lay down and cry for a few minutes.
22:14 MTecknology Or get whiskey if I had any
22:15 whytewolf I was that way yesterday
22:17 Xopher joined #salt
22:19 orionx_ joined #salt
22:20 Sammichmaker joined #salt
22:23 pmullins joined #salt
22:26 DEger joined #salt
22:33 jas02 joined #salt
22:39 writtenoff joined #salt
22:40 netcho joined #salt
22:40 netcho joined #salt
22:48 gtmanfred whytewolf: agreed
22:48 gtmanfred MTecknology: make an old fashioned
22:49 gtmanfred https://www.youtube.com/watch?v=mf1ax7y0yyI
22:49 gtmanfred maple syrup old fashioned
22:49 MTecknology I don't have any whiskey available :(
22:49 gtmanfred ahh, unfortunate, i have 7 whiskeys in my collection
22:50 gtmanfred also, i have a bunch of big clear icecubes
22:53 netcho joined #salt
22:53 gtmanfred i have a cat in my lap, or I would go make an old fashioned
22:54 MTecknology I may find myself voyaging out soon to purchase some whiskey and make one.
22:54 MTecknology once I finish this thought...
22:55 gtmanfred if you find some 10 year whistlepig rye... my favorite right now
22:55 pipps joined #salt
22:56 DEger joined #salt
22:56 gtmanfred i need an absinthe spoon
22:57 jas02 joined #salt
22:57 MTecknology I got mine from a bottle of lucid... I'm ashamed to have purchased lucid, but the spoon workrs.
22:57 MTecknology works*
22:59 jas02 joined #salt
23:06 writtenoff joined #salt
23:07 gtmanfred heh
23:14 yuhll joined #salt
23:16 jbellone joined #salt
23:16 pipps joined #salt
23:21 honestly shouldn't the choice drink of #salt be tequila
23:23 spuder joined #salt
23:35 jas02 joined #salt
23:35 * Llmiseyhaa shudders at mention of tequila.  Getting roofied in a tequila drink has put her off of the stuff forever!
23:36 * MTecknology grumbles
23:39 jbellone joined #salt
23:42 netcho_ joined #salt
23:45 ivanjaros joined #salt
23:50 justan0theruser joined #salt
23:56 * MTecknology blinks
23:56 MTecknology How do you guys specify bond slaves in a debian config?
23:58 MTecknology This is what I've always used, but it doesn't seem like it's possible to use "slaves" with salted network configs

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