Perl 6 - the future is here, just unevenly distributed

IRC log for #salt, 2017-01-10

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

All times shown according to UTC.

Time Nick Message
00:00 ninjada joined #salt
00:00 TheBarKeep hello what is salt?
00:01 whytewolf salt salt is a python based configuration manegment software, and remote execution engine use in infrastructure as code
00:02 TheBarKeep oh
00:02 TheBarKeep so my builds can be kept straight?
00:03 iggy maybe a little bi-curious
00:04 whytewolf lol
00:04 whytewolf TheBarKeep: basicly think puppet,chef and ansiable. plus cloud tools the ability to exacute commands remotly as well as reaction tools
00:05 iggy and built-in orchestration (which some other tools don't have)
00:05 cypher543 @whytewolf Turns out all I have to do is make an execution module that returns a virtual module name from __virtual__ if it's being loaded by my proxy minion.
00:06 cypher543 So def __virtual__(): return 'pkg' does the trick.
00:06 bltmiller joined #salt
00:06 ponyofdeath hi, is there a way to activate a state file only on salt's second+ run
00:06 whytewolf okay, wasn't sure if the standard of __virtual__ carried through
00:07 iggy ponyofdeath: set a grain on the first one and check that?
00:07 TheBarKeep oh.. I see now.  Question: why should I trust my network to an open source configuration management software?
00:07 ponyofdeath iggy: thanks
00:08 whytewolf TheBarKeep: because almost all trusted configuration manegment software are open source
00:08 iggy TheBarKeep: you might get better answers to these types of questions by contacting SaltStack sales
00:08 TheBarKeep gotcha thanks for the info
00:09 hemebond Does anyone else get data for 'grains.get disks'?
00:09 TheBarKeep left #salt
00:09 whytewolf i do
00:10 TheoSLC joined #salt
00:10 whytewolf but all my minions are in centos 7.2
00:10 iggy yeah
00:10 hemebond Hmm. What does it contain for you?
00:10 whytewolf the devid of the disk
00:10 whytewolf such as dm-0 or vda
00:11 iggy a list of disks (sometimes including ram0-15 and loop0-7
00:11 hemebond Hmmm, strange.
00:11 whytewolf hemebond: https://gist.github.com/whytewolf/c4cf93c418963d20d5887a22dea40a71
00:12 iggy I think disks might be a newer grain
00:12 iggy yeah, 2015.8+
00:12 netcho joined #salt
00:15 djgerm joined #salt
00:19 ninjada_ joined #salt
00:20 hemebond It's empty on all my AWS minions (at least)
00:22 whytewolf what version are you running hemebond? that zabbix host in my case is a openstack instance so it should work in clouds
00:25 iggy I tested bare metal, openstack, regular kvm, DO, vultr minions
00:26 iggy the only minion that didn't show _something_ was a 2015.5 one
00:26 iggy (and wtf is that minion at 2015.5...)
00:26 whytewolf slipped through the cracks?
00:27 hemebond whytewolf: 2016.3.4
00:27 hemebond I'm starting up some non-AWS minions to test with them.
00:29 whytewolf okay, looking from what i see it only supports freebsd and linux
00:29 hemebond The AWS minions are running Debian Jessie.
00:29 whytewolf okay, then definty utils.is_linux should return true
00:31 spuder joined #salt
00:31 whytewolf anything in SSDs
00:32 hemebond No ssd keys.
00:32 hemebond Oh wait, there it is.
00:33 hemebond Yes, there is an entry in "SSDs"
00:33 hemebond Okay so disks is just for... other disk types I guess.
00:33 whytewolf it is for any disk that is flag by the disk as an HDD
00:34 whytewolf apperently your disks are marked as SSD
00:34 whytewolf [which is the only 2 status that it currently understands]
00:36 whytewolf it basicly parses /sys/block/*/queue/rotational to get each disks flag
00:37 whytewolf on freebsd it uses geom to get disk info
00:38 lorengordon joined #salt
00:38 yuhl__ joined #salt
00:39 fracklen joined #salt
00:41 hemebond That's a tad annoying.
00:43 whytewolf I have always used the disk module so didn't even know that grain existed.
00:59 chowmein__ joined #salt
01:01 flowspec-r joined #salt
01:02 alexanderilyin joined #salt
01:03 pipps joined #salt
01:14 DEger joined #salt
01:18 edrocks joined #salt
01:26 ninjada joined #salt
01:33 bltmiller joined #salt
01:38 mavhq joined #salt
01:39 binocvla1 joined #salt
01:44 _W_ left #salt
01:45 dyasny joined #salt
01:47 ninjada joined #salt
01:53 mpanetta_ joined #salt
01:54 swills joined #salt
01:59 mpanetta joined #salt
02:08 jimklo_ joined #salt
02:18 om2 joined #salt
02:25 catpigger joined #salt
02:26 onlyanegg joined #salt
02:36 debian112 joined #salt
02:37 ubernets joined #salt
02:39 ubernets I have a sql script in my file server and want to use it in a cmd.run to simply execute "psql db < db.sql" where db.sql is in the salt file server. How can I do this?
02:48 ilbot3 joined #salt
02:48 Topic for #salt is now Welcome to #salt! <+> Latest Versions: 2016.3.4, 2016.11.1 <+> 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:51 canaar joined #salt
02:55 canaar What is the meaning of the arguments of this https://docs.saltstack.com/en/latest/ref/clients/index.html#localclient function ? In the python client api?
02:56 hemebond "meaning of the arguments"?
02:58 canaar whats an ioloop?
02:59 hemebond That appears to be when using the Salt client inside an existing application that has its own loop of some sort.
02:59 hemebond Seems to be explained in that "Note" box.
02:59 sh123124213 joined #salt
03:02 cypher543 According to the module docs, loading a module with a virtual name that matches one of the built-in modules is supposed to override the built-in one. So I have a custom module (https://gist.github.com/docbrown/36499e2e8f45ac1aa0b0458b1c305d6f) to override salt.modules.network, but it doesn't get loaded. 'network.interfaces' still returns the data for the
03:02 cypher543 host system.
03:04 iggy ubernets: wonder if cmd.script and setting shell to psql would work
03:05 ubernets iggy, - shell: psql ?
03:06 iggy that's what I  was thinking... not sure how well it'll work though
03:06 ubernets Sounds good. I'll give it a go
03:07 iggy the other way would probably be file.managed the sql file and then just cmd.run it
03:08 ubernets For script I have to use source: salt:///... like that?
03:09 iggy yeah
03:10 iggy might have to set env variables to set the db (i.e. PGDATABASE, PGHOST, PGPORT, PGUSER)
03:11 canaar hemebond : So it means if I call LocalClient inside a loop, then I'll need to do ioloop=ioloop.current() for each iteration of the loop?
03:12 hemebond canaar: No idea. I've not used the client like that myself.
03:12 hemebond In fact I've mostly used it just to fill in gaps in documentation :-D
03:13 DEger joined #salt
03:13 canaar hemebond: Oh Okay. Actually, I have a script where it accepts a minion, and then calls salt.client.LocalCLient()
03:13 ubernets iggy, Shell psql is not available. I'll save the file managed first. And do it that way.
03:14 canaar I then call client.cmd() on the minion to load grain info.
03:14 hemebond ubernets: Even with the full path to the executable?
03:14 canaar hemebond: However, client.cmd() gives an error saying the given minion is not there.
03:15 hemebond Not there?
03:15 canaar its not present in the grains dictionary
03:15 canaar but I do key.accept just a line above it
03:16 canaar However, if I wait for say time.sleep(13), it has the minion in the dict? Any idea what takes it so much time?
03:17 hemebond Grains are fetched from the minion.
03:19 ssplatt joined #salt
03:20 sh123124213 joined #salt
03:22 sh123124213 joined #salt
03:28 canaar hemebond : right. But the LocalClient should know that the machine accepted just now is now an accepted minion.
03:29 canaar hemebond: Here's, the paste : https://gist.github.com/55abhilash/e8964dfb5c61cd03a20363fac81a3289
03:30 hemebond That's three separate requests to the minion. Might want to query once for all grains and then pick out what why you want.
03:32 hemebond *what you want.
03:33 bastiandg joined #salt
03:33 stooj joined #salt
03:38 sh123124213 joined #salt
03:40 sh123124213 joined #salt
03:42 mavhq joined #salt
03:51 sh123124213 joined #salt
03:53 sh123124213 joined #salt
03:58 mavhq joined #salt
04:12 evle joined #salt
04:15 mavhq joined #salt
04:25 DEger joined #salt
04:26 smkelly joined #salt
04:29 eprice joined #salt
04:33 fracklen joined #salt
04:35 iggy ubernets: dank :/ Although, that would be a good feature request
04:35 iggy *dang
04:37 netcho joined #salt
04:38 antpa joined #salt
04:40 mavhq joined #salt
04:44 bltmiller joined #salt
04:48 canaar hemebond: there?
04:48 canaar I tried it, still it doesn't work
04:55 hemebond canaar: You tried a single query?
04:55 hemebond You said if you wait it works, right?
04:55 hemebond I see that you're accepting the minion immediately before you try to use it.
04:56 hemebond Perhaps you're encountering a run thingy...
04:56 hemebond um...
04:56 canaar yes it works if i wait
04:56 hemebond Race condition
04:56 canaar but i need to wait atleast 10 secs
04:56 canaar how come?
04:57 hemebond After you accept the minion that still needs to go back to the minion.
04:57 onlyanegg joined #salt
04:57 hemebond So the master puts an event on the bus saying "you've been accepted" and then the minion will check in again in a little bit.
04:57 hemebond If you pre-accept the minion does the rest of your code work the first time?
04:57 canaar Oh yes
04:58 hemebond What is triggering your code?
04:58 hemebond (also what is the end-goal of your script?)
05:00 canaar I am making a gui
05:00 canaar front end for salt commands
05:01 canaar A web based front end using python django. So the code is triggered when user needs to view unaccepted minions and then accept them
05:02 canaar I store the minion information in a db after it is accepted
05:02 hemebond Then I think you probably want something that will submit and then poll jobs.
05:03 hemebond I think you can use the local client async function to do that.
05:04 hemebond Maybe some background process like Celery (via Django Celery) that can submit and watch jobs for you.
05:05 hemebond Or maybe just an object to store the job info that can be recalled later if a page wants info that Django doesn't have yet.
05:05 hemebond Basically you need to make it asynchronous :-)
05:08 canaar hemebond : Okay
05:09 canaar You mean like keep a process running in the background which will keep on polling for the grains info, and then when the info is needed we take the output from it? Right?
05:09 om2 joined #salt
05:09 antpa joined #salt
05:10 hemebond Hmm. Either make your script retry until the data is there, or, better yet, have your Django frontend put in a request for the data but return some message to the user if the data isn't there yet.
05:12 hemebond cmd_async will return a job ID, you can check that job for data the next time that page is requested.
05:12 hemebond Then put the data into the database if it's there.
05:12 hemebond e.g., caching the data in Django.
05:15 canaar hemebond : Thanks a ton. I am going to try it now. :-) How long are you up?
05:15 hemebond Good luck ???? I'll be around for a while.
05:16 mavhq joined #salt
05:16 canaar Okayzz
05:18 rdas joined #salt
05:19 sh123124213 joined #salt
05:23 sh123124213 joined #salt
05:28 alexanderilyin joined #salt
05:29 mavhq joined #salt
05:42 alexanderilyin joined #salt
05:46 preludedrew joined #salt
05:58 onlyanegg joined #salt
06:02 alexanderilyin joined #salt
06:07 iggy the problem with Django is it's a bit tough to tack on thinks like websockets, etc... so your app becomes a mess of page refreshes or timed events
06:08 iggy imo anyway
06:11 LordOfLA joined #salt
06:16 oaklndr1 joined #salt
06:16 hemebond Well it's like any web frontend for something like Saltstack.
06:18 hemebond Most things will use Javascript to poll in the background for you to save you refreshing.
06:20 onlyanegg joined #salt
06:24 PatrolDoom joined #salt
06:24 alexanderilyin joined #salt
06:31 rawzone joined #salt
06:32 ivanjaros joined #salt
06:36 fracklen joined #salt
06:38 alexanderilyin joined #salt
06:46 DEger joined #salt
07:01 raspado joined #salt
07:03 mavhq joined #salt
07:13 alexanderilyin joined #salt
07:16 ReV013 joined #salt
07:19 hlub joined #salt
07:30 alexanderilyin joined #salt
07:31 debian112 joined #salt
07:32 eprice joined #salt
07:34 impi joined #salt
07:36 ewapptus joined #salt
07:37 ewapptus Hello salters, is there any insight on when 2016.11.2 might be released?
07:38 alexanderilyin joined #salt
07:44 keimlink joined #salt
07:48 fracklen joined #salt
07:50 mavhq joined #salt
07:52 fracklen joined #salt
07:54 canaar joined #salt
08:00 ronnix joined #salt
08:00 fracklen joined #salt
08:01 PatrolDoom joined #salt
08:03 alexanderilyin joined #salt
08:13 cyteen joined #salt
08:15 alexanderilyin joined #salt
08:17 fracklen joined #salt
08:21 fracklen_ joined #salt
08:21 Dagna joined #salt
08:23 fracklen joined #salt
08:25 armyriad joined #salt
08:26 JohnnyRun joined #salt
08:29 fracklen joined #salt
08:31 bocaneri joined #salt
08:41 cyteen joined #salt
08:50 mavhq joined #salt
08:55 druonysus joined #salt
08:55 druonysus joined #salt
08:56 Reverend quick  - someone hit me with jinja elif syntax
08:56 Reverend pls b elif
08:56 hemebond elif
08:56 Reverend WIN
08:56 Reverend love you
08:58 justanotheruser joined #salt
09:00 orichards joined #salt
09:08 cyborg-one joined #salt
09:10 Rumbles joined #salt
09:16 saltnewbie No handlers could be found for logger "pip.utils"     error: [Error 2] The system cannot find the file specified
09:16 saltnewbie anyone encountered this error while installing windows minion
09:16 saltnewbie this error is from getting the pre-req
09:19 keimlink joined #salt
09:20 sjorge joined #salt
09:20 sjorge joined #salt
09:23 hemebond On Windows? Have you installed PIP?
09:24 candyman88 joined #salt
09:24 amontalban joined #salt
09:24 amontalban joined #salt
09:32 DEger joined #salt
09:34 ronnix joined #salt
09:35 GnuLxUsr joined #salt
09:35 Rumbles joined #salt
09:35 bryguy joined #salt
09:37 dwfreed joined #salt
09:37 netcho joined #salt
09:37 Garo_ joined #salt
09:37 j4son joined #salt
09:37 ksa joined #salt
09:37 __number5__ joined #salt
09:37 kgoetz joined #salt
09:37 kgoetz joined #salt
09:37 TyrfingMjolnir joined #salt
09:37 Ludo- joined #salt
09:37 gtmanfred joined #salt
09:37 ahammond joined #salt
09:37 masber joined #salt
09:37 adelcast joined #salt
09:37 rhand joined #salt
09:37 rwaweber joined #salt
09:37 tbrb joined #salt
09:38 J0hnSteel joined #salt
09:38 tehsu joined #salt
09:38 ujjain joined #salt
09:38 ujjain joined #salt
09:38 citaret joined #salt
09:38 graffic joined #salt
09:38 darix joined #salt
09:39 ksa joined #salt
09:39 yidhra joined #salt
09:39 tooth joined #salt
09:39 jhujhiti joined #salt
09:39 toabi joined #salt
09:39 jab416171 joined #salt
09:39 gmoro joined #salt
09:39 concernedcitizen joined #salt
09:39 concernedcitizen joined #salt
09:39 trent_ joined #salt
09:39 Micromus_ joined #salt
09:39 honestly joined #salt
09:39 honestly joined #salt
09:39 basepi joined #salt
09:39 smcquay joined #salt
09:39 diegows joined #salt
09:39 MajObviousman joined #salt
09:39 stickmack joined #salt
09:39 rofl____ joined #salt
09:39 phx joined #salt
09:39 dimeshake joined #salt
09:39 sarlalia1 joined #salt
09:39 Vaelatern joined #salt
09:39 vifon joined #salt
09:39 gnord joined #salt
09:39 peters-tx joined #salt
09:39 quarcu joined #salt
09:39 degorenko joined #salt
09:39 rideh joined #salt
09:39 Qwazerty joined #salt
09:40 denkijin joined #salt
09:40 J0hnSteel joined #salt
09:40 garphy`aw joined #salt
09:42 chowmeined joined #salt
09:42 druonysus joined #salt
09:43 llua joined #salt
09:44 psy0rz joined #salt
09:44 xmj joined #salt
09:44 xmj joined #salt
09:44 elh9 joined #salt
09:46 ToeSnacks joined #salt
09:48 elh9 joined #salt
09:49 tom29739 joined #salt
09:51 s_kunk joined #salt
09:51 s_kunk joined #salt
09:54 justanotheruser joined #salt
10:00 tom29739 joined #salt
10:06 Rumbles joined #salt
10:14 mavhq joined #salt
10:27 tyler-baker joined #salt
10:28 canaar joined #salt
10:29 CrummyGummy joined #salt
10:31 hoonetorg joined #salt
10:34 eprice joined #salt
10:35 abednarik joined #salt
10:36 ronnix joined #salt
10:37 jeddi joined #salt
10:38 theblazehen joined #salt
10:50 Hybrid joined #salt
10:52 necronian joined #salt
10:56 keimlink_ joined #salt
11:04 arount joined #salt
11:06 arount Hi, is there a way to add custom field in minions logs ? I would like to add custom field in log_fmt_logfile, '%(asctime)s %(my_custom_thing)s'. https://docs.saltstack.com/en/latest/ref/configuration/logging/ refere to logging internals (https://docs.saltstack.com/en/latest/topics/development/logging.html#logging-internals) but page is empty
11:17 canaar hemebond : Running cmd_async does the job wonderfully. Thanks a lot again :) :)
11:18 antpa joined #salt
11:22 ronnix joined #salt
11:24 N-Mi_ joined #salt
11:25 amcorreia joined #salt
11:29 hoonetorg joined #salt
11:44 mikecmpbll joined #salt
11:45 alias joined #salt
11:45 frygor joined #salt
11:47 cyborg-one joined #salt
11:53 netcho joined #salt
11:57 amcorreia joined #salt
11:57 ronnix joined #salt
12:09 starbucksusually joined #salt
12:11 sebastian-w joined #salt
12:22 DEger joined #salt
12:26 hoonetorg joined #salt
12:30 toanju joined #salt
12:32 ninjada joined #salt
12:37 chowmein__ joined #salt
12:38 swills joined #salt
12:43 ninjada joined #salt
12:58 zulgabis joined #salt
13:06 _Cyclone_ joined #salt
13:06 keimlink joined #salt
13:07 cyteen joined #salt
13:08 arount left #salt
13:11 ninjada joined #salt
13:11 numkem joined #salt
13:11 chowmein__ joined #salt
13:18 gableroux joined #salt
13:26 ninjada joined #salt
13:28 amontalban joined #salt
13:28 amontalban joined #salt
13:30 rdas joined #salt
13:34 mpanetta joined #salt
13:35 qwertyuiop joined #salt
13:35 Guest26072 Hi. Does anyone know if SaltPad should work with salt/saltapi-2016.11.1?
13:37 eprice joined #salt
13:39 ssplatt joined #salt
13:40 gableroux_ joined #salt
13:41 mikecmpbll joined #salt
13:44 debian112 joined #salt
13:48 evle1 joined #salt
13:54 djgerm joined #salt
13:54 mvensky joined #salt
13:54 mvensky joined #salt
13:57 beardedeagle joined #salt
13:59 zer0def joined #salt
14:00 mpanetta joined #salt
14:01 racooper joined #salt
14:02 bookwar joined #salt
14:05 Reverend any reason this onlyif will attempt an install regardless of whether or not the folder exists:
14:05 Reverend - onlyif: test ! -e /usr/share/elasticsearch/plugin/analysis-phonetic
14:05 Reverend ?
14:05 Reverend typo
14:05 Reverend derp
14:06 amontalban joined #salt
14:09 daxroc Can salt-call be executed as non-root?
14:09 N-Mi_ joined #salt
14:09 daxroc I'm wanting to run a state.highstate mocked=True to validate syntax
14:10 zer0def joined #salt
14:15 beardedeagle @daxroc: https://docs.saltstack.com/en/latest/ref/configuration/nonroot.html
14:19 gableroux joined #salt
14:20 gableroux joined #salt
14:23 Rumbles Hi,I just added a salt minion to my master and as soon as I did the salt-minion service got stuck in a restart loop. I tried running it in debug, but it's not telling me much more than it was before. https://paste.fedoraproject.org/525037/ I get entries like 'NoneType' object is not iterable then the minion restarts....
14:38 DEger joined #salt
14:40 ronnix joined #salt
14:42 bookwar joined #salt
14:44 wangofett are there any states, besides cmd.run, that will do a `go get.../go instal...`?
14:45 wangofett Rumbles: that's more helpful than you might think
14:45 Rumbles maybe to you wangofett :)
14:45 Rumbles what does it tell you?
14:46 wangofett `I need to start some proxies for None` that tells me to grep the salt source for "I need to start some proxies" ;)
14:48 Reverend can salt watch a state? as in, if I am running a command, can I restart a service if the command runs?
14:48 catpiggest joined #salt
14:49 Reverend i.e. requires: \n  - plugin-head
14:49 Reverend or somethinog
14:49 Reverend that'd be pretty tidy
14:50 wangofett looks like it's in minion.py
14:50 wangofett what version are you on?
14:51 Reverend carbon i think
14:51 Reverend yeah
14:51 Rumbles Lithium I think
14:51 Reverend oph
14:51 Reverend wait
14:51 Reverend LOL sorry
14:51 Rumbles yeah salt-master 2015.5.3 (Lithium)
14:51 Rumbles we need to update
14:51 Rumbles I know :/
14:51 wangofett Reverend: Well, a state can watch another state... I'm not familiar enough with reactors, but I suspect that if you're doing like `state.apply <thing>` you'll need reactors
14:51 Rumbles on my (very long) to do list
14:52 wangofett Reverend: but if you're doing `state.highstate` then you can just use the `watch` requisite
14:52 Reverend Rumbles: yum update salt :P
14:52 _JZ_ joined #salt
14:52 Rumbles nope
14:52 Reverend wangofett: perfect. thank you
14:52 wangofett the syntax is tricky (at least it was for me)
14:52 Rumbles it's from the PPA that someone decided to stop using
14:52 wangofett say you have something like `fnord: file.managed: ...`
14:52 Rumbles that's the latest version available on the PPA
14:53 _JZ__ joined #salt
14:53 amontalban joined #salt
14:53 amontalban joined #salt
14:53 wangofett Reverend: then your watch would be `watch: - file: fnord` *not* `watch: - file: /path/to/some/file`
14:53 wangofett of course if your state ID is the filename then it's the same thing
14:54 rwaweber joined #salt
14:54 Brew joined #salt
14:54 wangofett Rumbles: https://github.com/cro/salt/blob/2015.5/salt/minion.py#L744
14:54 Reverend wangofett: can I not just do "watch: - state"
14:55 Reverend it's not a file I'm watching, see
14:55 Reverend it's just if a command runs on the highstate
14:55 wangofett looks like you have `proxy` in your pillar somewhere, maybe the minion config?
14:55 Tanta joined #salt
14:55 wangofett Reverend: a `cmd.run` state?
14:55 Reverend yeah
14:55 wangofett that would be `watch: - cmd: <state name>`
14:56 Reverend taaaaaaa
14:56 wangofett The docs could use a bit of explanation there. I don't remember if the tutorial has cleared up that point, but I remember struggling like mad with that concept when I first came across it
14:57 wangofett but it's `- <state>: <id>`
14:57 Reverend well, you learned so I didn't have to.
14:57 Reverend thank yoy xD
14:57 Reverend aha
14:57 wangofett so `cmd: do-the-thing` `file: my-cool-file` or even `file: my-cool-directory`
15:00 DEger joined #salt
15:00 wangofett Rumbles: did you find your empty proxy setting?
15:00 Rumbles thanks wangofett, do you know if that is taken from local config or config on the salt-master?
15:01 Rumbles I don't use proxies :/
15:04 Rumbles wait, is that looking for something in the pillar called proxy?
15:04 Rumbles as I did create a new pillar the other day called proxy :/
15:05 wangofett there you go :P
15:06 Rumbles wow that was unexpected :/
15:06 Rumbles thanks :)
15:06 wangofett that's apparently where the problem is.
15:06 wangofett try removing that pillar (you may have to delete the cache on your minion)
15:07 ewapptus Ne
15:07 ewapptus Hello again, any ideas who I can nudge to get 2016.11.2 released?
15:08 mavhq joined #salt
15:08 Rumbles yes, perfect, thanks wangofett !
15:08 krymzon joined #salt
15:08 wangofett Rumbles: https://docs.saltstack.com/en/latest/topics/proxyminion/index.html#configuration-parameters yeah, looks like proxy is for proxy minions ;)
15:09 wangofett You can probably use proxy as a subkey, like `somehost: proxy: ...`
15:09 wangofett or `someapp: proxy: ...`
15:09 Rumbles I'll rename it, should be fine
15:10 wangofett Turns out that `NoneType` is not iterable was more helpful than you thought, eh? ;)
15:10 Rumbles no, but you were very helpful :)
15:10 wangofett (of course having a good knowledge of Python helps)
15:11 wangofett I'd say I have a good-to-great knowledge of Python... and more often than not I find reading the Salt source code *waaaay* more informative than reading the Salt docs ;)
15:12 wangofett the source is actually really well written in all the cases I've come across
15:12 wangofett don't be afraid to use the source, Luke!
15:12 bbradley joined #salt
15:16 om2 joined #salt
15:17 brousch__ joined #salt
15:18 AndreasLutro is there a salt module that will read arbitrary yaml files from the minion's filesystem?
15:18 nickabbey joined #salt
15:21 mdpolaris joined #salt
15:22 raspado joined #salt
15:23 catpigger joined #salt
15:25 mavhq joined #salt
15:25 mdpolaris I am trying to call the cloud runner in Jinja and i am having trouble with the syntax. I have the command working on the CLI. Here is the working command on the CLI:
15:26 mdpolaris salt-run cloud.action show_instance instance=INSTANCE_NAME
15:26 mdpolaris I tried may forms of this without success:
15:27 mdpolaris {% set instance_info = salt['saltutil.runner']('cloud.action', 'show_instance','instance=INSTANCE_NAME) %}
15:27 mdpolaris this produces:       TypeError: runner() takes exactly 1 argument (3 given)
15:27 saltnewbie Do we have modules to create MSSQL DB?
15:28 g3cko joined #salt
15:29 g3cko joined #salt
15:29 wangofett AndreasLutro: and do what with them?
15:30 mdpolaris {% set instance_info = salt['saltutil.runner']('cloud.action show_instance instance=nv-envhub-demo-dev') %} produces the following error:       KeyError: 'cloud.action show_instance instance=nv-envhub-demo-dev'
15:30 AndreasLutro wangofett: deserialize them into a python dict
15:30 wangofett and then?
15:31 AndreasLutro do stuff with the data in custom modules and/or jinja templates
15:31 wangofett (sounds like you've got a bit of an XY problem here)
15:31 wangofett You just want pillar
15:31 AndreasLutro nope
15:31 AndreasLutro I need the data to be on the minion
15:31 DanyC joined #salt
15:31 wangofett Why not?
15:31 wangofett Pillar data *is* on the minion
15:31 AndreasLutro I mean, the source of the data needs to be on the minion
15:31 wangofett it gets transferred to the minion on highstate calls
15:31 AndreasLutro pillars are rendered on the master
15:32 kalessin joined #salt
15:32 AndreasLutro seems like writing my own module function is the easiest way
15:32 wangofett what's the problem that you're facing?
15:32 mikecmpbll joined #salt
15:33 wangofett i.e. what are you *actually* trying to do?
15:34 AndreasLutro quite complicated! but I've found my solution in writing a custom module function. thanks in any case
15:34 wangofett I'm sure there may be a legitimate reason to want to do what you're trying to do, but personally every time that I've wanted to do something like that when I've thought about it for a few minutes I was just being silly
15:34 AndreasLutro yeah well trust me this has been thought out for weeks
15:35 wangofett like, "oh noes, it will be more secure if I put this information only on the minion... oh right, the master has root access to the minion, never mind"
15:36 wangofett I'm actually really interested to know if you've found a scenario that won't end in tears ;)
15:36 AndreasLutro I'm trying to facilitate a convenient and easy process, security is low priority
15:36 wangofett easy process for *what*?
15:36 AndreasLutro ... for this particular use-case
15:37 wangofett because adding information to a pillar is pretty darn easy
15:37 AndreasLutro mostly setting up developer installations of our application(s) directly on the minion
15:38 wangofett have you looked a git pillars? https://docs.saltstack.com/en/latest/ref/pillar/all/salt.pillar.git_pillar.html
15:38 AndreasLutro we're using git pillars
15:39 wangofett because combine git pillars and environments https://docs.saltstack.com/en/latest/ref/states/top.html#multiple-environments
15:39 AndreasLutro and gitfs, and custom external pillars. for this particular thing I just need the data on the minions for speed and convenience
15:39 AndreasLutro that's not really related but we've banned salt environments in any case
15:40 * wangofett shrugs.
15:42 wangofett Well, good luck with it in any case.
15:42 AndreasLutro cheers
15:42 Xenophon1 joined #salt
15:43 AndreasLutro (turns out import_yaml works with absolute paths on the minion)
15:43 Sketch joined #salt
15:46 sh123124213 joined #salt
15:49 keltim joined #salt
15:50 bbradley joined #salt
15:50 spuder joined #salt
15:51 tercenya joined #salt
15:52 DanyC joined #salt
15:52 ekristen joined #salt
16:00 DEger joined #salt
16:01 Xenophon1 joined #salt
16:02 XenophonF joined #salt
16:02 antpa joined #salt
16:03 oaklndr1 joined #salt
16:04 sarcasticadmin joined #salt
16:07 DEger joined #salt
16:09 strobelight joined #salt
16:11 DEger joined #salt
16:11 hackel joined #salt
16:12 catpiggest joined #salt
16:12 jimklo joined #salt
16:19 mikecmpbll joined #salt
16:25 PatrolDoom joined #salt
16:28 spuder joined #salt
16:29 mdpolaris Any thoughts on pulling EC2 instance info in a state file? I know the cloud runner can do it, but i am having trouble getting this to work via Jinja.
16:32 Cottser joined #salt
16:34 ssplatt like from the mine?
16:37 ronnix joined #salt
16:38 onlyanegg joined #salt
16:38 alvinstarr joined #salt
16:41 foundatron joined #salt
16:47 nidr0x joined #salt
16:51 eprice joined #salt
16:52 impi joined #salt
16:54 pcn mdpolaris: we did a #!py .sls file and just imported boto3
16:55 mdpolaris I was just pointed to the ec2 grains module in contrib, i think this is really what i am looking for: https://github.com/saltstack/salt-contrib/blob/master/grains/ec2_info.py
16:56 pcn OK, I thought you meant *other* ec2 instances
16:56 pcn Yeah, we use the ec2 grains for the instance you're on.
16:58 pcn That grain only reaches out to the local metadata service.  You may end up writing grains to get tags or anything else that isn't in the metadata.
16:59 pcn Also, we have a separate grain to pull out ec2 disk info, because the data is messy to reason about in its default format
17:05 DanyC joined #salt
17:07 numkem joined #salt
17:12 dxiri joined #salt
17:15 JamieH Hey
17:15 cprior joined #salt
17:16 JamieH Does anyone know what I'm doing wrong here? https://github.com/saltstack-formulas/users-formula/issues/138
17:16 saltstackbot [#138][OPEN] Rendering SLS "base:users" failed: Jinja variable 'dict object' has no attribute 'user'; line 41 | I'm getting the following error when running `salt-call -l debug state.highstate`...
17:16 SpX joined #salt
17:20 pipps joined #salt
17:20 whytewolf JamieH: on the minion that is having that error. what is the version of salt returned by salt-call --versions?
17:21 JamieH https://www.irccloud.com/pastebin/HVlPe69Y/
17:21 JamieH that's an old version of Salt isn't it :/ that's my issue isn't it ????
17:21 whytewolf that could be let me look up when salt.module.function became a thing.
17:22 whytewolf and yes that is an old version
17:22 whytewolf yeap thats it
17:22 JamieH i'm sad now
17:22 JamieH oh well. time to use salt to update salt
17:22 thasnake joined #salt
17:22 whytewolf salt.module.function was introduced in 2014.7.0
17:25 thasnake trying to use __salt__ in a custom module. Getting this error. NameError: global name '__salt__' is not defined. any thoughts
17:25 babilen thasnake: In module or function scope?
17:26 thasnake babilen:python execution module
17:27 abednarik joined #salt
17:27 TheoSLC joined #salt
17:27 babilen Sure, but where are you using __salt__ ?
17:27 whytewolf thasnake: basiclly are you trying to use __salt__ with in a function. or are you trying to use it the headers when trying to setup the module?
17:27 babilen Feel free to paste your code to one of http://paste.debian.net, https://gist.github.com, http://sprunge.us, …
17:28 thasnake babilen: sorry, in a function. def salttest(): return __salt__['cmd.run']('ls /root')
17:31 mavhq joined #salt
17:31 whytewolf thasnake: you are trying to call the module through salt right? not directly on the command line outside of salt?
17:32 babilen thasnake: Okay, it won't be a monkey patching problem then. Which steps have you performed to get that error?
17:36 woodtablet joined #salt
17:39 dxiri hey everyone, quick question, how can I use the libvirt driver for salt-cloud? do I have to install something special? getting a warning currently
17:39 dxiri [WARNING ] The cloud driver, 'libvirt', configured under the 'local-kvm' cloud provider alias, could not be loaded. Please check your provider configuration files and ensure all required dependencies are installed for the 'libvirt' driver.
17:41 whytewolf dxiri: sounds like you are missing dependencies to use the libvirt driver
17:41 thasnake babilen: put script in /srv/salt/_modules. --> salt '*' saltutil.sync_all. -->  salt-call -l debug modules.patch_cycle
17:41 dxiri whytewolf: the only dependency is libvirt isn't it?
17:42 ivanjaros joined #salt
17:42 whytewolf can you import libvirt from the python that salt uses?
17:42 thasnake babilen: have import salt in script also
17:42 whytewolf dxiri: https://github.com/saltstack/salt/blob/develop/salt/cloud/clouds/libvirt.py
17:43 CrummyGummy joined #salt
17:43 whytewolf thasnake: shouldn't need to import salt
17:44 dxiri whytewolf: k I can't, but why? do I need a specific libvirt python package or something?
17:45 whytewolf dxiri: yes, there is a python libvirt library
17:45 ronnix joined #salt
17:45 whytewolf apperently you don't have it
17:46 whytewolf most likely something like libvirt-python might depend on your os
17:46 babilen thasnake: Shouldn't that be "salt-call -l debug patch_cycle.salttest" ?
17:47 dxiri whytewolf: k it was python-libvirt, just installed and reloged in, but still same thing, however, going into python and importing manually does work now
17:48 whytewolf odd. restart some salt deamons, just in case
17:48 utahcon_ joined #salt
17:50 dxiri all I have in this box is the salt-master
17:50 dxiri just restarted it, but same thing
17:51 dxiri "In rare cases, this could indicate the 'libvirt.get_configured_provider()' function could not be found."
17:51 dxiri how can I test that the function is there? import salt.scripts manually and try that function?
17:52 JamieH whytewolf: cheers - you fixed my issue
17:52 morissette joined #salt
17:53 thasnake babilen: I removed import salt and called the function "salt-call -l debug patch_cycle.salttest". It is working. Thanks for your help!
17:53 TheoSLC_ joined #salt
17:54 duckfez joined #salt
17:54 babilen thasnake: Very good :)
17:56 whytewolf dxiri: libvirt.get_configured_provider is a salt function.
17:56 whytewolf if the libvirt cloud driver can be enabled it should exist
17:56 lws joined #salt
17:57 _KaszpiR_ joined #salt
17:57 whytewolf dxiri: what version of salt are you using
17:57 dxiri ok I am looking at the docs, and libvirt says its part of "develop" and I have:
17:57 dxiri salt-cloud 2016.11.1 (Carbon)
17:57 dxiri is that a problem?
17:57 pipps joined #salt
17:57 whytewolf yes
17:58 whytewolf yes that would be a problem
17:58 whytewolf libvirt doesn't exist outside of develop it looks like
17:59 scarcry joined #salt
18:02 tercenya joined #salt
18:04 dxiri ok how do I install that version then? I have this repo: deb http://repo.saltstack.com/apt/ubuntu/16.04/amd64/latest xenial main
18:04 dxiri is there a different one for develop?
18:05 pipps joined #salt
18:06 pipps99 joined #salt
18:06 dimeshake joined #salt
18:07 whytewolf develop isn't in a repo
18:08 whytewolf https://docs.saltstack.com/en/latest/topics/development/hacking.html
18:11 TheoSLC_ left #salt
18:11 snergster joined #salt
18:13 nickabbey joined #salt
18:16 nickabbey joined #salt
18:17 whytewolf you could also use the bootstrap script to install develop
18:18 whytewolf but honestly unless your actually doing development work on saltstack you might just want to wait. a lot of things are unstable in salt develop
18:22 dxiri whytewolf: so I can use the bootstrap and run "sudo sh install_salt.sh -P -git"
18:22 dxiri that seems easy enough
18:22 mavhq joined #salt
18:23 whytewolf sudo sh install_salt.sh -P -git develop
18:23 dxiri well what I am trying to do may require some development on my side and I must work with VMs directly, so I don't see any other way of using stable and libvirt in saltstack at the same time
18:25 bbradley joined #salt
18:26 dxiri root@sjociara03:~# ./install_salt.sh -P -git develop
18:26 dxiri * ERROR: Installation type "develop" is not known...
18:26 dxiri does the branch has a different name?
18:27 whytewolf develop is the git branch
18:27 whytewolf develop is even listed in the documentation for the bootstrap script https://github.com/saltstack/salt-bootstrap
18:28 dxiri ah I see...needed to remove the "-" from git
18:28 dxiri so its ./install_salt.sh -P git develop
18:29 abednarik joined #salt
18:31 dxiri looks like this now: salt-cloud 2016.11.0-605-g682e81b (Carbon)
18:31 dxiri so I guess it worked :)
18:32 Reverend why in hell is my master telling minion to apply a config that it's not even got in top
18:32 Reverend >_<
18:32 whytewolf yeap. the most likely have not gotten to the nitrogen tag yet.
18:32 whytewolf Reverend: includes?
18:32 Reverend i doubt it.. .let me check
18:33 whytewolf state.show_highstate
18:33 Reverend ooooo
18:33 iggy using environments?
18:33 Reverend nops :(
18:33 Reverend hmmm
18:33 Reverend "sshkeys"
18:34 Reverend YAY
18:35 Reverend whoever mentioned showstate
18:35 Reverend you're a hero
18:35 Reverend maybe
18:35 Reverend will a requires sls include it for me?
18:37 whytewolf if you require an entire sls file
18:37 Reverend hmm.
18:38 Reverend I know what it is - I had an old nodegroup called "sharecode" and left the subnets configured as a nodegroup. I've now repurposed those subnets
18:38 Reverend and the nodegroup is matching on 2 sections of the top...
18:38 Reverend http://pastebin.centos.org/63571/
18:39 Reverend how did I not see that
18:41 whytewolf it is easy to miss odd matching systems when they are in many diferent files
18:42 XenophonF how do you all handle upgrading windows minions?
18:42 Reverend i don't ;)
18:42 XenophonF i didn't realize winrepo lacks support for pkg.upgrade :(
18:45 whytewolf huh, win_pkg has pkg.upgrade
18:45 tapoxi whats with the salt formula, it uses a directory structure thats different from an installed salt pkg and the bootstrap script
18:46 * whytewolf shrugs.
18:46 whytewolf I don't use any formulas so couldn't tell you
18:47 ninjada joined #salt
18:47 s_kunk joined #salt
18:49 s_kunk joined #salt
18:49 s_kunk joined #salt
18:49 pipps joined #salt
18:50 anotherzero joined #salt
18:50 iggy tapoxi: be more specific?
18:51 iggy (also, I haven't touched that formula in a long time, so not sure on it's current state)
18:51 iggy actually, I haven't touched any formulas in a long time
18:51 iggy :/
18:52 om2 joined #salt
18:56 tapoxi iggy: deploying via bootstrap you get a /etc/salt/master and /etc/salt/minion with all comments removed. with the formula /etc/salt/master is all commentsls
18:56 dxiri joined #salt
18:56 tapoxi ugh typed ls in irc
18:57 tapoxi anywho with the formula it only uses master.d and minion.d with engine.conf  f_defaults.conf  lxc_profiles.conf  reactor.conf
18:57 iggy yeah... the way it should be
18:58 druonysus joined #salt
18:58 iggy if you are editing /etc/salt/{minion,master} you are going to constantly have to deal with changes coming from the package
18:58 iggy so keep all your changes in the .d dirs
19:03 anotherzero joined #salt
19:04 XenophonF whytewolf: win_pkg doesn't implement pkg.upgrade()
19:05 whytewolf it would help if i actually read the doc instead of just finding the function
19:07 Edgan joined #salt
19:10 Rev_sleeps nanight guys
19:10 Rev_sleeps sleepw ell when you do :)
19:10 Rev_sleeps <3
19:15 XenophonF joined #salt
19:27 keimlink joined #salt
19:28 spuder_ joined #salt
19:28 oododa joined #salt
19:30 Praematura joined #salt
19:33 morissette joined #salt
19:33 lws joined #salt
19:35 pipps joined #salt
19:38 dyasny joined #salt
19:43 Deliant joined #salt
19:45 lws joined #salt
19:45 beardedeagle joined #salt
19:46 evidence joined #salt
19:46 pcn joined #salt
19:47 ropes joined #salt
19:55 whytewolf bind rndc list addzone zones
19:55 whytewolf ack
19:55 whytewolf wrong screen
20:02 zw0bot joined #salt
20:04 whytewolf ugh, really hate rndc and love it at the same time
20:05 nicksloan joined #salt
20:11 abednarik joined #salt
20:22 lws joined #salt
20:23 Trauma joined #salt
20:32 pipps joined #salt
20:35 Rumbles joined #salt
20:37 dxiri whytewolf: ok I am just trying to run salt-cloud to clone a vm as in this page: https://docs.saltstack.com/en/develop/topics/cloud/libvirt.html
20:37 dxiri libvirt: QEMU Driver error : Domain not found: no domain with matching name 'centos6-clone'
20:37 dxiri [ERROR   ] There was a profile error: 'NoneType' object has no attribute 'text'
20:37 dxiri but I am getting that
20:38 dxiri first message is very puzzling, of course there is no centos6-clone, I am trying to create it
20:38 toastedpenguin joined #salt
20:39 whytewolf i have never used the libvirt driver and since it is in develop you might want to actually start looking at the code. and figure out what it is actually trying to do. make heavy use of -l trace and -l debug
20:40 whytewolf most likely the Domain error is refering to base_domain?
20:41 whytewolf I honestly have no idea
20:41 whytewolf base_domain being the domain that you are copying from
20:42 dxiri base domain is centos6-base :) sure I can look at the code and see what I can find, just exposing the problem here in case the main developer is in here
20:44 whytewolf don't think i have ever seen rklaren here. but i could be wrong.
20:50 mavhq joined #salt
20:52 dxiri whats the difference between trace and debug?
20:52 whytewolf ...
20:52 hemebond trace > debug > crit > warn > info
20:52 hemebond Something like that.
20:52 cscf um, normally crit would be at the end
20:53 hemebond Oh true.
20:53 whytewolf yeah crit would be higher then error
20:53 whytewolf which you left off compleatly :P
20:53 hemebond trace > debug > info > warn > crit
20:53 hemebond lol
20:53 dxiri lol
20:53 hemebond THE POINT IS!....
20:53 hemebond trace is more verbose than debug :-D
20:54 dxiri I asked cause I ran both and saw the exact same output so couldn't tell :P
20:54 whytewolf or if everything is confusing you canjust use all
20:54 hemebond Presumably trace would also show which functions/methods were being called.
20:55 whytewolf trace used to actualy list each and every salt function that was called. but latly it is just a higher level then debug.
20:55 whytewolf not sure when that changed
20:57 whytewolf anyway the real point is read this and understand it https://docs.saltstack.com/en/latest/topics/troubleshooting/
20:59 whytewolf there is also https://docs.saltstack.com/en/latest/topics/cloud/troubleshooting.html
21:02 KyleG joined #salt
21:02 KyleG joined #salt
21:06 dxiri joined #salt
21:06 pipps joined #salt
21:07 Nei_ joined #salt
21:07 dxtr_ joined #salt
21:07 Reverend_fail joined #salt
21:08 shakalaka_ joined #salt
21:11 Cidan joined #salt
21:13 lws joined #salt
21:16 dxtr Can grain values be set like.. Ad-hoc? Can I just set grains['foo'] to some value and use it from my states and pillars?
21:18 PatrolDoom joined #salt
21:19 nicksloan joined #salt
21:19 dyasny joined #salt
21:19 orichards joined #salt
21:20 jalaziz joined #salt
21:21 orichards joined #salt
21:24 lws joined #salt
21:25 Sarph joined #salt
21:26 amontalban joined #salt
21:26 amontalban joined #salt
21:27 orichards joined #salt
21:35 lws joined #salt
21:36 ninjada joined #salt
21:37 nicksloan joined #salt
21:38 orichards joined #salt
21:40 orichards joined #salt
21:42 orichards joined #salt
21:43 keimlink joined #salt
21:43 swills joined #salt
21:46 lws joined #salt
21:46 onlyanegg joined #salt
21:48 hemebond dxtr: Yes, look in the docs for "custom grains"
21:48 nicksloan joined #salt
21:52 nicksloan left #salt
21:52 netcho joined #salt
21:54 lws joined #salt
21:55 jaybocc2 joined #salt
21:58 whytewolf dxtr: yes* [*: not with in the same state run, but you can create custom grains on the system and use those in your runs]
21:59 mavhq joined #salt
21:59 sarcasticadmin joined #salt
22:06 ninjada joined #salt
22:08 utahcon joined #salt
22:11 onlyanegg joined #salt
22:12 nickabbey joined #salt
22:14 ronnix joined #salt
22:18 cliluw joined #salt
22:19 hackel joined #salt
22:21 armguy joined #salt
22:31 falstaff_ joined #salt
22:33 sh123124213 joined #salt
22:33 falstaff_ Hi, I'm running into an issue with ssh keys I'm templating into minions from the master.
22:34 falstaff_ I've verified that the minions have what I think are well-formatted private and public keys from the pillar, using the literal multiline from YAML (the '|' character)
22:35 PatrolDoom i use file.manage for ssh keys rather than putting them into pillars
22:35 falstaff_ On the master, using those keys works with `ssh -T -i minion_key git@github.com`, but running git.latest with the same after creation gives me a publickey error
22:35 PatrolDoom primary reason being that i'm lazy & don't want to have to copy/paste/format pillars
22:36 falstaff_ Yeah the YAML stuff there was tricky
22:36 falstaff_ Are there any security issues with keeping them outside the pillar?
22:36 hemebond Yes, pillars are shown only to the minions that should get them.
22:37 hemebond States and their files can, and might, be cached by all minions.
22:37 PatrolDoom if you apply the state to all minions
22:37 hemebond Maybe not a big deal if it's just public keys.
22:37 * PatrolDoom has that issue now... sigh... never do a blanket "service/blah" in top file...
22:38 hemebond PatrolDoom: That's common. It would be strange to create a new SSH state for each combination of SSH keys.
22:38 falstaff_ I might be confused about SSH, but doesn't the machine logging in have to have the privkey matching the pubkey?
22:38 PatrolDoom indeed, for ssh it's ok, i'm talking about other services i have
22:38 PatrolDoom they end up cached on minions that don't need them
22:38 whytewolf even if they are not applied to all minions all minions can look up all information in the state tree
22:38 falstaff_ i.e., if I tell GitHub a pubkey, I have to give the minion the privkey also?
22:38 PatrolDoom cause we're not using pillar matches in top file
22:39 hemebond falstaff_: If you are connecting to the Git repo from the minion then yes, it will need the private key.
22:40 falstaff_ Phew, okay. I'm on the right track then, sort of
22:40 hans_ joined #salt
22:40 whytewolf note, for gitfs only the master connects to git
22:40 whytewolf unless you are masterless
22:41 dfgsfg joined #salt
22:41 djgerm joined #salt
22:42 anotherzero joined #salt
22:42 falstaff_ Here's what my git related states look like: http://pastebin.com/Q5VkDkAf
22:43 hemebond Isn't there a Salt way to add SSH keys?
22:44 falstaff_ There's ssh_auth, but that's for the authorized_keys file afaik
22:44 whytewolf yeah that is auth keys
22:44 hemebond Ah
22:45 hemebond Does your state create the proper file output?
22:45 falstaff_ I believe so. If I call `salt -G 'roles:app*' cmd.run 'cat .ssh/id_rsa'` I get an RSA privkey that has output identical to whitespace
22:46 falstaff_ Same as for salt -G 'roles:app*' cmd.run 'cat .ssh/id_rsa.pub', although pubkeys are one line
22:46 falstaff_ but `salt -G 'roles:app*' cmd.run 'ssh -i .ssh/id_rsa -T git@github.com'` comes back with pubkey auth failure
22:47 PatrolDoom joined #salt
22:48 oododa I have some AWS instances that run salt-minion on boot, and for some reason, salt-minion starts 4 'scheduled' highstates in quick succession, all of which appear to successfully start.
22:48 sh123124213 joined #salt
22:49 hemebond oododa: That seems odd. It shouldn't do any highstates automatically.
22:49 hemebond Must be something in your config.
22:49 PatrolDoom joined #salt
22:49 seanz joined #salt
22:49 hans_ joined #salt
22:49 oododa 2017-01-10_22:39:09.94489 [INFO    ] (PID: 1385) Running scheduled job: highstate 2017-01-10_22:40:59.02347 [INFO    ] (PID: 2895) Running scheduled job: highstate 2017-01-10_22:41:42.93832 [INFO    ] (PID: 5788) Running scheduled job: highstate 2017-01-10_22:43:14.10831 [INFO    ] (PID: 7757) Running scheduled job: highstate
22:50 hemebond oododa: Are you scheduling things for your minions?
22:50 oododa hm, I may know why.
22:50 whytewolf falstaff_: https://gist.github.com/whytewolf/a885a6cd9a668840e984308d9a26932f try this
22:50 oododa There's _schedule.conf and schedule.conf
22:51 PatrolDoom joined #salt
22:51 whytewolf falstaff_: also make sure that the permisions on /root/.ssh are 700
22:52 oododa hemebond: rubber duck debugging worked ... I think I figured it out. Thank you!
22:52 hemebond ????
22:52 falstaff_ Wow, that contents_pillar directive is great
22:53 falstaff_ I also thought that file.managed always needed a source argument
22:54 whytewolf nope. source defaults to None. for things like using contents_pillar
22:54 falstaff_ That's great, and it worked too
22:55 lws joined #salt
22:55 whytewolf yeah, contents_pillar was invented for exactly this reason
22:56 whytewolf apperently 2014.7.0 also introduced contents_grains
22:57 whytewolf file.managed has a ton of options. it is one of those things that every update should be reread
23:01 hackel joined #salt
23:04 abednarik joined #salt
23:06 lws joined #salt
23:17 lws joined #salt
23:18 mavhq joined #salt
23:23 sc250024 joined #salt
23:23 sc250024 Does anyone know how to return the first index name of `salt-call network.interfaces` ?
23:23 sc250024 Or any other way to grab the name of the primary interface?
23:23 lws joined #salt
23:24 lkannan joined #salt
23:25 dxtr What'd be the best way to share a rather large git repository with the minions? Right now I'm trying file.recurse from the salt:// source (gitfs) but it's unbearably slow
23:25 czchen joined #salt
23:25 sc250024 @dxtr Could you not have the minions check out the repo themselves?
23:26 whytewolf sc250024: in jinja or or on the cli?
23:26 d3c4f joined #salt
23:27 sc250024 In Jinja, but I was just testing on the CLI at first
23:27 sc250024 Can be a module (network.interfaces) or a grain
23:27 tercenya_ joined #salt
23:28 whytewolf in jinja it would be {% set interface = salt.network.interfaces()|first %}
23:28 sc250024 Awesome, thank you whytewolf!
23:29 dxtr sc250024: hmm, maybe
23:31 spuder joined #salt
23:32 sc250024 dxtr Depends on what you're trying to do with the repo. Do the minions have to have all of the files in the Git repo, or just some parts of it?
23:33 sc250024 And do all the minions have access to the Git repo, or just your master?
23:33 antpa joined #salt
23:34 lws joined #salt
23:34 sh123124213 joined #salt
23:35 sh123124213 joined #salt
23:45 eprice joined #salt
23:47 antpa joined #salt
23:49 spuder joined #salt
23:50 Val_ joined #salt
23:56 johnkeates joined #salt
23:59 djgerm joined #salt

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