Perl 6 - the future is here, just unevenly distributed

IRC log for #salt, 2016-07-29

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

All times shown according to UTC.

Time Nick Message
00:09 mosen joined #salt
00:11 ninjada joined #salt
00:15 flowstate joined #salt
00:19 teryx510 joined #salt
00:20 jenastar joined #salt
00:21 darkalia joined #salt
00:21 darkalia Hello
00:22 irctc198 joined #salt
00:22 irctc198 Any way to target nodegroup in salte state local.state.sls
00:25 nonades joined #salt
00:27 teryx510 joined #salt
00:34 tonybaloney joined #salt
00:36 tonybaloney joined #salt
00:37 tonybaloney joined #salt
00:39 tonybalo_ joined #salt
00:40 tonybaloney joined #salt
00:40 hemebond What is "salte state local.state.sls"?
00:42 tonybalo_ joined #salt
00:44 MTecknology Is there any way to link one grain to a key in another?  I'd like to have one grain called foo:  grains[foo] = {id: {name: yup, location: lol, ref_name: sd7, ref: grains[bar][sd7] } }  and then sd7 would be a key in grains[bar]
00:44 MTecknology I'm guessing probably not, but I need to at least ask
00:45 MTecknology it's only ~7 extra lines of jinja in the sls if I can't
00:46 tonybaloney joined #salt
00:47 tonybaloney joined #salt
00:49 tonybaloney joined #salt
00:50 tonybaloney joined #salt
00:52 tonybaloney joined #salt
00:53 tonybaloney joined #salt
00:55 tonybaloney joined #salt
00:56 tonybaloney joined #salt
00:56 tonybaloney joined #salt
00:57 tonybaloney joined #salt
01:04 teryx510 joined #salt
01:04 tonybaloney joined #salt
01:05 racooper joined #salt
01:07 ajw0100 joined #salt
01:10 subsignal joined #salt
01:15 cmek joined #salt
01:15 flowstate joined #salt
01:22 amcorreia joined #salt
01:24 catpigger joined #salt
01:28 tonybaloney joined #salt
01:29 teryx510 joined #salt
01:35 Brijesh1 joined #salt
01:36 mapu joined #salt
01:46 ponyofdeath joined #salt
01:46 flowstate joined #salt
01:48 raspy_ hi all, can anyone help me accomplish this? http://pastebin.com/mUu08HzD
01:48 benvejknrertbrrt joined #salt
01:53 antpa joined #salt
01:54 raspy_ i basically want to pass a variable over, this will be an adhoc state to setup google-authenticator
01:58 Lionel_Debroux joined #salt
02:00 ajw0100 joined #salt
02:04 anotherZero joined #salt
02:05 tonybaloney joined #salt
02:15 keldwud joined #salt
02:18 ALLmightySPIFF joined #salt
02:19 flowstate joined #salt
02:25 patrek joined #salt
02:25 teryx510 joined #salt
02:26 Brijesh2 joined #salt
02:32 cmarzullo you can pass in the variable as pillar.
02:33 cmarzullo Where I've seen google 2fa in the past, they just managed the files that are generated. The files are gpg encrypted in pillar.
02:34 tonybaloney joined #salt
02:41 tonybalo_ joined #salt
02:44 raspy_ cmarzullo: interesting really?
02:45 raspy_ i always thought the user had to run google-authenticator as them
02:46 bastiandg joined #salt
02:46 evilrob are batch orchestrations fixed yet?
02:47 ninjada joined #salt
02:48 nonades joined #salt
02:53 teryx510 joined #salt
02:56 raspy_ is there a way to return the output of the command back thru the salt-master in stdout?
02:57 sagerdearia joined #salt
02:59 raspy_ dangggg
02:59 raspy_ the google-authenticator returns a giant barcode
03:00 raspy_ but the barcode does not display in the stdout on master
03:00 raspy_ crapppp
03:01 raspy_ ok...
03:02 tonybaloney joined #salt
03:02 raspy_ salt cannot determine the users home directory when I do a runas, any way I can get salt to know the users homedir when executing a command as that user via cmd.run ?
03:02 raspy_ I get Cannot determine home directory
03:04 Andrew joined #salt
03:16 ZachLanich joined #salt
03:16 flowstate joined #salt
03:16 ZachLanich hemebond: You around? :)
03:16 hemebond yup
03:17 ZachLanich Feel free to point me to documentation when I can't seem to find it, but why is my salt:// portion not working here?: http://dp.wecreate.com/1lBZ7
03:17 ZachLanich I tried putting it in {{ }} too, no go
03:17 hemebond salt:// protocol is not available outside of salt.
03:18 hemebond You're running commands on the minion in a regular (bash?) shell.
03:18 ZachLanich I know you can do stuff like srouce: salt://... but it's not clear how I get that value into a cmd
03:18 hemebond The source: salt:// means Salt will read the file from the Salt file system and write it out to a file.
03:18 ZachLanich Yes, it defaults to running them in bash I believe. Everything I have works, expect that merge value
03:19 hemebond If you want those files on the minion, you need to put them on the minion using file.managed or something.
03:19 ZachLanich Oh wait, it's under /srv/saly
03:19 ZachLanich salt* I'm retarded
03:19 hemebond On the master, yes, but not on the minion.
03:19 ZachLanich It's a zip file. I just accidentally used the salt:// thing lol
03:20 ZachLanich Oh yea, not on the minion yet
03:20 ZachLanich Ok, it's a zip file that needs downloaded to the minion, then installed. What's the proper way to do that?
03:20 hemebond And then you use regular file path to access it.
03:20 hemebond file.managed to put the file on.
03:21 ZachLanich Ok
03:22 raspy_ is there a way to load the environment variables of the runas user being passed in cmd.run?
03:22 hemebond raspy_: You could explicitly source it.
03:23 raspy_ hemebond: apologies, how can that be done?
03:25 hemebond raspy_: What if you run the command (via salt) 'printenv' as the user you're trying to run a command as?
03:25 SpX joined #salt
03:28 raspy_ hemebond: http://pastebin.com/Vk6CjFt6
03:29 hemebond Did you say you were missing HOME?
03:29 hemebond Oh, that was a different question.
03:29 raspy_ ok thats weird... its there
03:29 hemebond Well I see environment variables.
03:30 raspy_ but... when i run a command, basically "google-authenticator" and runas:googletest
03:30 raspy_ it says it cannot find the home directory
03:30 raspy_ let me do a echo printenv command through the sls file and see what comes up
03:39 raspy_ hemebond: http://pastebin.com/vtiaZKGN
03:40 raspy_ running a statefile shows to be running as root
03:40 hemebond Uh, yes, that's not how runas works.
03:40 hemebond runas is a parameter to a state module.
03:40 hemebond Salt minion runs as root and does everything as root.
03:41 hemebond If you want to run a command as another user, you need to use the runas parameter on that cmd.run state.
03:41 raspy_ yep, i tried that, let me show ya
03:43 raspy_ hemebond: peep http://pastebin.com/zEPw90nS
03:44 hemebond Well that must be a bug. I've never used it myself but that seems pretty straight-forward broken.
03:45 raspy_ darn ok
03:45 raspy_ thx hemebond
03:45 hemebond I'm trying to test something now.
03:45 raspy_ kk
03:45 hemebond Have a search through the Github issues.
03:48 tonybaloney joined #salt
03:48 ninjada joined #salt
03:50 hemebond https://github.com/saltstack/salt/issues/32579
03:50 saltstackbot [#32579][MERGED] cmd.run module 'runas' vs state 'user' | Description of Issue/Question...
03:51 raspy_ shit that worked
03:51 raspy_ thx hemebond as always!
03:51 rdas joined #salt
03:51 pepoluan joined #salt
03:51 pepoluan hello
03:51 hemebond wait, what?
03:52 hemebond I was about to say that didn't seem to apply to your issue, but... it did?
03:52 hemebond Are you on an older version?
03:52 pepoluan is it possible to get the changes of a state if I use the pyobjects renderer?
03:52 pepoluan let's say I have this state: User.present('foo')
03:53 pepoluan I want to know if that state caused a change or not
03:53 raspy_ hemebond: yeah were using an older version of salt (its production) so we dont upgrade often and as you know upgrading might pose some risks with stuff being deprecated
03:53 Brijesh1 joined #salt
03:53 hemebond Ah I see. Which version?
03:53 raspy_ salt 2015.5.2 (Lithium)
03:54 hemebond Wow, okay. Note that with each question because it affects which version of the documentation we need to refer to.
03:54 raspy_ indeed
03:54 raspy_ thx again for the find
03:55 hemebond 👍
03:56 sagerdearia joined #salt
04:02 ninjada joined #salt
04:06 nonades left #salt
04:14 evle joined #salt
04:17 flowstate joined #salt
04:17 Brijesh1 joined #salt
04:23 keldwud joined #salt
04:25 raspy_ hemebond: think you can help me go to the finish line? :D just have 1 more Q
04:26 hemebond Sure.
04:26 raspy_ oh nm... ended up figuring it out :D
04:27 hemebond 👍
04:27 raspy_ thx hemebond time to hit the sack
04:41 tonybaloney joined #salt
04:42 justanotheruser joined #salt
04:44 rdas joined #salt
04:45 iggy ZachLanich: archive.extracted
04:46 AndChat164736 joined #salt
04:46 hemebond iggy: It's some sort of Wordpress process.
04:46 hemebond Not a manual extraction I don't think.
04:46 iggy ahh... too lazy to read pastes
04:49 tonybalo_ joined #salt
04:50 ZachLanich iggy: Huh?
04:51 phutse joined #salt
04:53 phutse How to change username
04:53 hemebond ZachLanich: There is a Salt module for extracting an archive, e.g., zip file, onto a minion.
04:53 hemebond But you appear to be using some wordpress process to process the zip.
05:11 kshlm joined #salt
05:13 hasues joined #salt
05:14 hasues left #salt
05:14 tonybaloney joined #salt
05:16 flowstate joined #salt
05:19 ALLmightySPIFF joined #salt
05:19 ALLmightySPIFF joined #salt
05:23 MK_FG joined #salt
05:26 ZachLanich hemebond: Yea, I'm way past that now :P
05:26 tonybaloney joined #salt
05:26 ZachLanich I'm now writing bash scripts to modify JSON objects and using wp cli to set WP Options to connect 2 sites together with the WP Migrate DB Pro plugin for automatically set up Database & Media Files migrations between environments
05:28 subsignal joined #salt
05:30 tonybaloney joined #salt
05:31 iggy jq is the best thing in the world for json on the cli
05:31 iggy thanks murrdoc <3
05:37 ninjada if i want a state to create directory whos path has the date at time of creation eg. /home/user/$(date +%Y%m%d), how would i achieve that?
05:37 hasues joined #salt
05:37 hasues left #salt
05:38 ninjada atm it's just creating it explicitly :)
05:38 ninjada or literally or whatever
05:40 tonybalo_ joined #salt
05:41 tonybalo_ joined #salt
05:41 iggy {{ True|strftime(...) }}
05:41 iggy or something
05:42 iggy sec
05:42 impi joined #salt
05:42 kawa2014 joined #salt
05:45 iggy {{ None|strftime }}
05:45 iggy https://docs.saltstack.com/en/latest/topics/jinja/index.html#filters
05:46 ivanjaros joined #salt
05:49 ninjada awesome! thanks man
05:50 Brijesh1 joined #salt
05:57 ninjada ended up goin for /home/user/{{ salt['cmd.run']('date +%Y%m%d-%H%M%S') }}
05:57 ninjada too many python libs needed for fuzzydates
05:57 tonybaloney joined #salt
05:57 iggy whatever works
05:59 Miouge joined #salt
06:03 felskrone joined #salt
06:10 tonybaloney joined #salt
06:10 ajw0100 joined #salt
06:13 POJO joined #salt
06:13 fracklen joined #salt
06:16 flowstate joined #salt
06:17 moneylotion joined #salt
06:21 tonybaloney joined #salt
06:23 jtang joined #salt
06:23 ribx joined #salt
06:27 penguinpowernz joined #salt
06:28 ronnix joined #salt
06:31 subsignal joined #salt
06:31 Miouge joined #salt
06:32 tonybaloney joined #salt
06:33 tonybaloney joined #salt
06:35 elias_ joined #salt
06:48 tonybaloney joined #salt
06:57 mpanetta_ joined #salt
07:13 ninjada_ joined #salt
07:15 flowstate joined #salt
07:22 fracklen joined #salt
07:23 fracklen joined #salt
07:28 tonybaloney joined #salt
07:32 subsignal joined #salt
07:35 tho joined #salt
07:37 sfxandy joined #salt
07:39 debian112 joined #salt
07:41 krymzon joined #salt
07:44 citaret joined #salt
07:47 JPT joined #salt
07:53 Hipikat joined #salt
07:57 impi joined #salt
07:58 impi joined #salt
07:58 ingslovak joined #salt
07:59 Rumbles joined #salt
08:01 ronnix joined #salt
08:06 garphy joined #salt
08:15 flowstate joined #salt
08:20 fredvd joined #salt
08:20 mpanetta joined #salt
08:21 ekkelett Hm. What's the best way to require a state, but simultaneously use watch_in on it, without me recursively killing the salt minion?
08:21 inad922 joined #salt
08:23 AndreasLutro ekkelett: can you give an example?
08:24 ekkelett Yup! :)
08:24 ekkelett I've got a tomcat.war_deployed state that deploys a war
08:24 ekkelett until said WAR is deployed, I shouldn't be editing any files "inside" the WAR as Tomcat will unpack it and create the directory structure for it
08:25 ekkelett so, I then need to use file.managed to edit a configuration file within the now unpacked directory, and after doing so I need to tell Tomcat to reload the application
08:25 ekkelett However, I do that, and all I end up with is RuntimeError: maximum recursion depth exceeded in cmp -- which I would imagine indicates I've dun goof'd somewhere along the road...
08:26 AndreasLutro okay, so make your file.managed states require the tomcat state, make your service state watch both the tomcat state and the file states
08:27 manji joined #salt
08:28 ekkelett ah right, buuuut I'm enumerating through possibly multiple instances, so the file.managed has watch_in pointing to the tomcat deployment, which should then reload
08:28 ekkelett I shouldn't need a service state in the picture, seeing as reloading the WAR app is done by tomcat and doesn't require restarting tomcat itself though
08:28 s_kunk joined #salt
08:29 AndreasLutro oh ok, so you need the tomcat.war_deployed to run, then the file.managed, then the same tomcat.war_deployed state needs to reload itself?
08:29 GreatSnoopy joined #salt
08:29 ekkelett yup!
08:29 AndreasLutro that's not possible
08:29 ekkelett (And AFAIK the tomcat state has mod_watch support, so watch should... work..?)
08:29 ekkelett :o
08:30 ekkelett damn -- I'm not seeing it though, can you give me a hint as to why?
08:30 AndreasLutro you can't have the same state run twice during a single highstate
08:30 AndreasLutro in your case, setting up the war initially and then reloading the war counts as 2 invocations
08:31 jhauser joined #salt
08:31 ekkelett Huh, I had entirely missed that. Is there anywhere in particular I can read up about that limitation in the docs?
08:32 subsignal joined #salt
08:33 AndreasLutro not sure
08:34 AndreasLutro wouldn't be surprised if it's not mentioned explicitly
08:34 babilen I think it is a fair assumption that a state doesn't execute multiple times
08:35 ekkelett For the curiosity: how'd you find out?
08:35 ekkelett I thought so too in regards to one without dependencies, but it didn't cross my mind with regards to watch_in.
08:36 AndreasLutro just realize that a watch implies a require
08:46 yuhlw_ joined #salt
08:48 tonybaloney joined #salt
08:50 antpa joined #salt
08:51 lero joined #salt
08:56 yuhlw_ joined #salt
09:01 nmadhok joined #salt
09:06 ronnix joined #salt
09:10 iggy use listen_in and the thing restarts at the very end of the highstate run (just before anything with `order: last`)
09:11 srenatus[m] joined #salt
09:12 kawa2014 joined #salt
09:15 flowstate joined #salt
09:16 ekkelett AndreasLutro: that I did discover, though I thought it was more of a fallback at least :)
09:17 ekkelett I tried using a fallback, but yeah -- the end result now is that I use the module to reload it with a prereq_in from file.managed, and they just require the WAR to be deployed and it worked :)
09:19 badon joined #salt
09:21 ekkelett thanks for the help and input :)
09:29 ninjada joined #salt
09:33 subsignal joined #salt
09:33 permalac joined #salt
09:36 rdas joined #salt
09:40 jtang joined #salt
09:45 antpa joined #salt
09:49 anotherZero joined #salt
09:51 gmoro joined #salt
10:03 antpa joined #salt
10:14 ekkelett Hm, it'd be nice if I had a combination of prereq and listen.
10:23 antpa joined #salt
10:29 irctc859 joined #salt
10:30 irctc859 plz help me .. new to salt
10:31 irctc859 my top.sls is in /srv/dev/
10:32 irctc859 want to include other files in top.sls .. please may I know how can I do that ?
10:33 ekkelett irctc859: include what sort of other files? Include "into" the top.sls, or specify as states for different machines and such?
10:33 viq irctc859: first you have to define file_roots in your master config, as the default location is in /srv/salt. Second, what exactly do you mean by "other files"?
10:34 subsignal joined #salt
10:37 antpa joined #salt
10:37 irctc859 :ekkelett  basically I want to split top.sls into multiple files
10:38 irctc859 :viq yes I have defined /srv/salt/dev in file_roots
10:39 viq irctc859: yet you're saying your top.sls is in /srv/dev
10:39 irctc859 viq: yes
10:39 viq irctc859: then your master won't be able to see it - it needs to be in a location defined in file_roots
10:40 colegatron joined #salt
10:40 colegatron hi all
10:40 mpanetta joined #salt
10:40 irctc859 viq: that is all fine .. I can include the states in top.sls and it works .. what I want is to split the top.sls into multiple files
10:42 irctc859 like in top.sls I can include another file which is in the same directory where top.sls exists
10:43 jtang joined #salt
10:44 ekkelett irctc859: AFAIK you can't include other top files, but you could have multiple file_roots in the same environment
10:44 ekkelett and they will then be merged IIRC.
10:44 pcdummy ekkelett: i tried that a while ago, didn't work
10:44 pcdummy ekkelett: had to use one top.sls for all saltenvs.
10:44 irctc859 ekkelett: okay thank you !!
10:44 hemebond You don't even need multiple entries for the same environment. All environment top files will be merged.
10:45 hemebond So be very careful.
10:45 ekkelett Yeah, you can easily end up with a untidy mess.
10:45 hemebond You can end up applying states and pillars to minions you don't want to :-)
10:46 irctc859 homebond: :)
10:47 rdas_ joined #salt
10:50 flowstate joined #salt
10:51 ravenx joined #salt
10:52 ravenx i'm using this right now:  https://docs.saltstack.com/en/2015.8/ref/clients/index.html#localclient
10:52 ravenx and i'm trying to do state.show_sls via:  local.cmd('vs1', 'state.show_sls super-app')
10:52 ravenx and it keeps saying that it isn't availab.e
10:52 ravenx however, i am able to run that from the shell:   salt 'vs1' state.show_sls super-app
10:52 ravenx anyone know why?
10:53 hemebond Shouldn't super-app be in an args list?
10:53 hemebond local.cmd('*', 'test.arg', ['arg1', 'arg2'], kwarg={'foo': 'bar'})
10:53 ravenx so:    local.cmd('vs1', 'state.show_sls' 'super-app')
10:53 ravenx like thT?
10:54 hemebond local.cmd('vs1', 'state.show_sls', ['super-app']) ?
10:54 hemebond Literally the first and second example at that link you pasted.
10:55 liskl joined #salt
10:55 ravenx oops
10:55 ravenx my apologies
10:55 ravenx my bad lol
10:55 hemebond No need to apologise.
10:58 quasiben joined #salt
10:58 ravenx my second question is, this local.cmd call, unlike the salt call from the command line returns a nicely formatted output?
10:58 ravenx with color?
10:59 ravenx looking at teh full list of builtin returners, it seems that they only write to services like cassandra, postgres, mongo, mysq2l, etc.
10:59 hemebond I doubt it. Isn't local client for developing your own applications and integrations?
10:59 hemebond It's a pure Python API, no?
10:59 ravenx it is, so i am writing a script so our engineers could deploy.
10:59 ravenx i suppose i would need to make a parser class then .
11:00 hemebond Well, you should get back a dict I believe.
11:00 ravenx yup
11:00 antpa joined #salt
11:00 ravenx but it looks minified haha
11:01 colegatron I am going to write a simple web gui for salt and I am wondering which of the netapi modules should I use, cherrypy or tornado.
11:01 badon joined #salt
11:01 colegatron tornado is better to see the eventbus in realtime, but cherrypy is more mature and (seems) more featured.
11:01 colegatron any advice?
11:03 paant joined #salt
11:06 ravenx hemebond: i see on the top of the same page:  https://docs.saltstack.com/en/2015.8/ref/clients/index.html#localclient  that there is ways for an 'outputter system' to retrieve structrured data.
11:06 ravenx and within it there is highstate return style which i really like.  off the top of your head, do you know how i can get output passed into that?
11:07 hemebond I'm afraid I've never used local client.
11:07 ravenx hm, alright, thanks anyways!
11:07 eseyman joined #salt
11:08 hemebond I think that the outputter is just a note that you don't need local client to get a different output format.
11:08 hemebond When you execute commands using Salt CLI you can specify the output format (the outputter).
11:08 ravenx aaah i see
11:09 hemebond So if you just wanted the output in an easy to parse format you don't need to use local client to get it.
11:13 eseyman joined #salt
11:14 ravenx gotcha
11:14 ravenx however, i do need to use the local client api, as i am writing a wrapper for our devs
11:14 ravenx so that they could deploy just by going:
11:14 p3rror joined #salt
11:14 ravenx ./deploy.py <app-name.
11:14 oida joined #salt
11:14 ravenx and get a pretty output like that  ;?
11:14 ravenx :/
11:15 hemebond That seems a little odd.
11:15 hemebond To me.
11:15 hemebond Does it have to work from anywhere or something?
11:22 amcorreia joined #salt
11:33 ravenx yeah
11:33 ravenx from their machines
11:33 BigBear joined #salt
11:35 subsignal joined #salt
11:36 lovecraftian joined #salt
11:38 jtang joined #salt
11:40 theblazehen joined #salt
12:02 p3rror joined #salt
12:09 eseyman joined #salt
12:11 Brijesh1 joined #salt
12:13 Garo_ joined #salt
12:15 PerilousApricot joined #salt
12:20 ninjada joined #salt
12:28 ssplatt joined #salt
12:30 haaj joined #salt
12:30 traph joined #salt
12:33 phx uhm, how do i query my pillar top.sls from the master?
12:35 remyd1 joined #salt
12:35 Garo_ joined #salt
12:35 subsignal joined #salt
12:36 remyd1 Hi. Some users of ext_pillar here ?
12:36 remyd1 I would like to update just a field in my mongodb without rewriting all the pillar
12:37 remyd1 is it possible ?
12:38 gh34 joined #salt
12:39 remyd1 Should I write my own custom module _ext_pillar to do that ?
12:42 Brijesh1 joined #salt
12:43 deus_ex joined #salt
12:45 numkem joined #salt
12:45 Garo_ joined #salt
12:45 kawa2014 joined #salt
12:52 ssplatt remyd1: you can use {% set %} to only map the one item
12:53 ssplatt and .update
12:53 remyd1 any documentation on how to use the update method ?
12:54 ssplatt for example, i load one of my external pillars into its own tree like {% set myexternal = salt['pillar.get’](‘myexternal’) %}
12:54 ssplatt in my map.jinja
12:55 subsignal joined #salt
12:56 ssplatt then below i do something like {% if myexternal.thingiwant is defined %} {% do mysql[‘this’][‘that’].update{{ ‘thething’: myexternal.thingiwant %}
12:56 ssplatt {% endif %}
12:57 remyd1 ssplatt, ok thanks. I think I have to read some documentations ^^ =)
12:58 subsignal joined #salt
12:58 impi joined #salt
13:00 subsignal joined #salt
13:01 flowstate joined #salt
13:04 flowstate joined #salt
13:05 numkem joined #salt
13:08 rem5_ joined #salt
13:09 racooper joined #salt
13:09 AndreasLutro who needs ntp anyway? salt '*' cmd.run "date --set \"$(date)\""
13:09 subsigna_ joined #salt
13:11 bbradley joined #salt
13:13 ssplatt …is it just me or does that set the date to exactly what `date` thinks it is right now
13:13 ribx joined #salt
13:14 dyasny joined #salt
13:14 ssplatt as in, it uses itself to set itself
13:17 subsignal joined #salt
13:18 BigBear joined #salt
13:18 AndreasLutro close
13:18 AndreasLutro $(date) gets expanded on the salt master, not the minion
13:18 AndreasLutro so it sets the date to whatever the date is on the master
13:20 ssplatt oh right. so only slightly better.
13:20 AndreasLutro don't do it by the way... just a dirty hack until we can set up proper aws network acl to allow ntp into our testing infrastructure :(
13:20 ssplatt nah, ntpd -gq or die
13:21 AndreasLutro aws's stateless firewalls are really annoying
13:21 teryx510 joined #salt
13:23 flowstate joined #salt
13:24 drawsmcgraw left #salt
13:27 cyborg-one joined #salt
13:29 p3rror joined #salt
13:29 DammitJim joined #salt
13:32 protoz joined #salt
13:36 tapoxi joined #salt
13:45 srenatus[m] left #salt
13:46 iceyao joined #salt
13:47 Brijesh1 joined #salt
13:48 perfectsine joined #salt
13:55 PerilousApricot joined #salt
13:59 Sketch if i use salt to drop a new file in minion.d, is there a way to tell the minion to reload it's config before continuing?
14:02 AndreasLutro "before continuing"? you can use the highstate to restart the salt-minion, that's about it
14:04 knine joined #salt
14:05 Tanta joined #salt
14:06 Ryndaxon joined #salt
14:06 mpanetta joined #salt
14:07 Ryndaxon Hi there. Is there any guarantee that the structure of the data that is returned by the Salt REST API will remain the same? Or might this structure change in future versions?
14:09 AndreasLutro Ryndaxon: I wouldn't trust anything to stay the same in salt, rest api or otherwise :)
14:09 ingslovak joined #salt
14:10 POJO joined #salt
14:11 bowhunter joined #salt
14:13 Ryndaxon I guess that's probably good advice. Better safe than sorry and all that.
14:14 Sketch AndreasLutro: won't that kill the execution of the current (high?)state, though?
14:14 AndreasLutro Sketch: it might, I don't know how good salt is at handling that sort of thing. for what it's worth, we use an "at" state to schedule a restart 1 minute in the future when salt config changes happen
14:17 Sketch heh, there's a bug for exactly what i am trying to do
14:17 Sketch https://github.com/saltstack/salt/issues/6179
14:17 saltstackbot [#6179][MERGED] a salt-minion deamon reboot should not be needed to make mysql config loaded | I think it's not a good idea that the mysql module use the grains file of the minion to load the configuration. It implies a reboot of the minion to take any configuration changes into account....
14:17 Sketch maybe i should just use mysql.connection_user etc
14:17 Sketch https://github.com/saltstack/salt/issues/570
14:17 saltstackbot [#570][OPEN] master/minion should accept a SIGHUP and reload config |
14:17 Sketch this would work too, but it's still open so it's not done yet ;)
14:18 mapu joined #salt
14:18 Sketch i guess now that i just put my mysql root password into pillar, i don't have to include it in the state file, i can just include it from pillar data
14:19 Sketch so at least i don't have passwords all over the place if i use the connection options
14:20 AndreasLutro mysql.default_file: /etc/mysql/debian.cnf
14:20 AndreasLutro solves all my issues for that
14:21 jenastar joined #salt
14:22 ninjada joined #salt
14:23 Sketch yeah, actually that's what i was going to put into minion.d/mysql
14:23 Sketch .conf
14:23 Sketch since i already have a file with the user/pass in it
14:23 Sketch i just noticed i can also use connection_default_file
14:23 Sketch in the state
14:24 Sketch which should also fix the chicken-and-the-egg problem of setting the root user pw
14:25 Sketch presumably, since i put the file creation after the password has been set in the state
14:25 mohae joined #salt
14:25 AndreasLutro which file?
14:25 Sketch /etc/mysql/debian.cnf
14:25 AndreasLutro I only set the mysql root password when the mysql package gets installed, and the package installation creates that file for me
14:25 Tanta so manage /etc/shadow
14:26 Sketch if the file doesn't exist, it ought to connect passwordless
14:26 Tanta oh, the mysql root password
14:27 teryx510 Hey guys, trying to code a runner for the first time and I'm a bit confused. When using RunnerClient.cmd how do I pass args to the function that I'm calling?
14:30 Andrew joined #salt
14:33 ivanjaros joined #salt
14:34 Tyrm joined #salt
14:36 Tyrm joined #salt
14:37 Garo_ joined #salt
14:38 Tyrm_ joined #salt
14:40 mpanetta_ joined #salt
14:41 Rumbles joined #salt
14:41 mpanetta_ joined #salt
14:42 flowstate joined #salt
14:42 ninjada joined #salt
14:46 Ryndaxon Is there any reason to use pip instead of the apt/yum/etc. repository provided by Salt or vice versa?
14:46 antpa joined #salt
14:51 cmarzullo if you are on a platform that doesn't have packages built.
14:56 nonades joined #salt
14:58 ze- hey. anyone using salt-syndic around?
14:58 ze- On a single node, I'd like to have a syndic (and master) and a minion working together.
14:59 ze- The syndic would obviously connect to the higher level master, but i'd like the minion to connect to the local master.
14:59 ze- In my version, it seems the minion tend to use the syndic master key, instead of its minion_master key... and rejects the local master...
15:03 corichar joined #salt
15:10 Brew joined #salt
15:11 Garo_ joined #salt
15:16 marie1972 joined #salt
15:19 marie1972 left #salt
15:21 cmarzullo we have several syndics tied into a master. I'm not sure I'm understanding your issue.
15:22 cmarzullo If a minion is paired to the master and you want it paired to the syndic just change it's master in /etc/salt/minion
15:22 cmarzullo then re-accept the key on syndic
15:24 Brijesh1 joined #salt
15:24 ajw0100 joined #salt
15:25 colegatron_origi joined #salt
15:27 al joined #salt
15:28 irctc179 joined #salt
15:28 corichar joined #salt
15:37 hasues joined #salt
15:37 hasues left #salt
15:37 lovecraftian joined #salt
15:37 lovecraftian joined #salt
15:43 catpig joined #salt
15:54 DammitJim joined #salt
15:55 votz How does the salt-ssh -i flag (that auto-accepts host keys) map to the Python API? That is, what kwarg should be provided to salt.client.ssh.client.SSHClient().cmd(..., kwargs) to accomplish the same thing as -i of the CLI?
16:02 Tyrm joined #salt
16:04 pcdummy votz: its opts ignore_host_keys
16:04 votz kwargs = {ignore_host_keys: True}? I'll try that.
16:04 pcdummy not sure its that
16:04 pcdummy its for salt.client.ssh.shell
16:04 Tyrm__ joined #salt
16:05 anotherZero joined #salt
16:09 barmaley joined #salt
16:21 mpanetta joined #salt
16:23 brotatochip joined #salt
16:23 jenastar joined #salt
16:26 writtenoff joined #salt
16:28 Brijesh1 joined #salt
16:29 POJO_ joined #salt
16:35 Tyrm joined #salt
16:37 Tyrm joined #salt
16:38 Tyrm joined #salt
16:43 DEger joined #salt
16:44 * MTecknology grumbles...
16:44 MTecknology How can I suck in a patch from a later version without updating and without breaking future updates?...
16:45 MTecknology and it's in salt/utils/ ..
16:46 antpa joined #salt
16:50 flowstate joined #salt
16:55 pcdummy MTecknology: i have a salt_patch state for that
16:55 pcdummy MTecknology: not sure i made it public... let me look
16:58 pcdummy MTecknology: i use that to patch salt https://github.com/pcdummy/saltstack-salt_patches-formula upgrades overwrite them (on Debian at least).
16:58 brotatochip joined #salt
16:58 antpa joined #salt
17:01 Cidan joined #salt
17:02 gableroux joined #salt
17:03 * MTecknology gets excited
17:04 hasues joined #salt
17:04 POJO joined #salt
17:08 hasues left #salt
17:20 mpanetta joined #salt
17:21 impi joined #salt
17:22 flowstate joined #salt
17:23 irctc410 joined #salt
17:29 Brijesh1 joined #salt
17:34 DEger joined #salt
17:37 tuxx joined #salt
17:43 edrocks joined #salt
17:43 heaje joined #salt
17:44 robawt is it bad form to specify more than one user on a state block?
17:44 robawt like say if i'm adding a server to known hosts, can i say -users:  - alpha - beta -charlie ?
17:44 heaje Are there any good helper functions in the salt source to parse a top.sls like file and perform matches based on the minion id?
17:45 heaje basically I'm looking for matching just like what is supported by pillar
17:45 ponyofdeath hi, is there a way to execute state only when another requires it?
17:45 robawt heaje IDs are kinda soft and change frequently, i like to match on grains and make a "role" grain
17:45 robawt ponyofdeath: don't include it in the top file but import it from the required state?
17:45 heaje robawt: I have a top.sls like file for a custom module that I'm parsing.
17:46 robawt custom module == all bets off.  I don't know what you're doing :)
17:46 ponyofdeath robawt: like require: -sls: blah.sls
17:46 robawt ponyofdeath: yes, and import the state at the beginning
17:46 ponyofdeath robawt: thanks
17:46 robawt when you import a state (last time i checked) it basically concatinates it to the state so all of those keys should exist
17:47 ssplatt joined #salt
17:47 sagerdearia joined #salt
17:48 mohae_ joined #salt
17:52 dyasny_ joined #salt
17:55 dyasny joined #salt
17:56 tapoxi joined #salt
17:57 tapoxi anyone using the slack engine? what's the format for running commands?
17:57 ponyofdeath robawt: {%- from 'chemaxon/blah.sls' import %}
17:57 ponyofdeath something like that
17:57 ponyofdeath or
17:58 whytewolf robawt: minion id is actually supposed to be a source of truth. matching on grain is actually considered a security issue because they can be changed minion side. [a compromised minion can do discovery attacks on pillars that are targetted by grains]. however in the state you can use pillars as a target.
17:58 whytewolf ponyofdeath: just the salt import not a jinja import.
17:58 robawt whytewolf: thanks for the heads up.  I have some changes to make :)
17:59 whytewolf ponyofdeath: https://docs.saltstack.com/en/latest/ref/states/include.html
18:00 ponyofdeath whytewolf: thanks
18:01 ponyofdeath whytewolf: thats not import
18:02 whytewolf ponyofdeath: well. import isn't a salt term. it is a jinja term and you are looking for include. which includes the sls states from the sls included
18:02 antpa joined #salt
18:03 robawt i should've been more clear, that's my mistake
18:03 robawt it's an include not an import
18:03 ponyofdeath robawt: inclue executes those as well
18:04 nmadhok joined #salt
18:05 whytewolf ponyofdeath: sounds like you need to grok this https://docs.saltstack.com/en/latest/ref/states/requisites.html as your request wasn't exactly clear to begin with
18:09 hasues joined #salt
18:09 ponyofdeath whytewolf: ok thanks
18:11 antpa joined #salt
18:14 amcorreia joined #salt
18:21 mpanetta_ joined #salt
18:24 hasues left #salt
18:31 dyasny joined #salt
18:31 BigBear joined #salt
18:33 Slimmons joined #salt
18:34 bowhunter joined #salt
18:35 Brijesh1 joined #salt
18:41 Slimmons if I have a salt state, that's starting a process on a windows minion, let's say I'm opening a word document for example.  Is there a way to stop that process, but by targeting specifically the one started by salt?  Like, save the process or job id in a pillar or something?  Any way you can think of?
18:42 s_kunk joined #salt
18:43 ponyofdeath anyone know why this https://bpaste.net/show/014881cbf022 does not actually execute /etc/init.d/jchem-psql init?
18:45 GreatSnoopy joined #salt
18:46 whytewolf um need the states
18:47 ponyofdeath whytewolf: its a cmd.wait i need to trigger based on another state which fails
18:47 ponyofdeath whytewolf: https://bpaste.net/show/96eb73ed1fc2
18:48 whytewolf okay. that kind of explains it. if the state it is watching is failing then cmd.wait won't run
18:49 ponyofdeath whytewolf: so i need to do onfail: then
18:50 whytewolf if you want it to run when the other state fails then yes
18:50 whytewolf also. cmd.wait is being depreceated. cmd.run with onchanges is meant to take it's place
18:51 whytewolf https://docs.saltstack.com/en/latest/ref/states/all/salt.states.cmd.html#should-i-use-cmd-run-or-cmd-wait
18:51 ponyofdeath that does not work either
18:51 ponyofdeath Comment: State was not run because onfail req did not change
18:51 ponyofdeath even tho that state is failing
18:52 whytewolf that doesn't sound right.
18:53 pipps joined #salt
18:53 ponyofdeath whytewolf: https://bpaste.net/show/98c159bf517d
18:53 jenastar joined #salt
18:54 ponyofdeath https://bpaste.net/show/1244e1318b12 is the state
18:54 iggy heaje: salt.modules.state.top ?
18:54 iggy !salt modules.state.top
18:54 saltstackbot https://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.state.html#salt.modules.state.top
18:56 edrocks joined #salt
18:56 whytewolf ponyofdeath: you have the line items of reqqs wrong. it should be "- cmd: check_jchem_psql_init" not "- check_jchem_psql_init" also your requires are not matching anything either
18:57 ponyofdeath i thought id works as well as specifying cmd:
18:57 whytewolf it needs both the module and ID
18:58 ponyofdeath whytewolf: that results in error
18:58 ponyofdeath https://bpaste.net/show/f053fd80d2d9
18:59 whytewolf spaces
18:59 ponyofdeath whytewolf: whoops, thanks
18:59 ponyofdeath so what was it matching before without that nothing?
19:00 fracklen joined #salt
19:00 whytewolf yeah nothing. not sure why it didn't error. it should have thrown an error
19:01 ponyofdeath whytewolf: so what do i specify for stats that have more than one module in them?
19:01 ponyofdeath in a require statement
19:01 whytewolf the module that you want to watch.
19:02 whytewolf or a line for each module
19:02 whytewolf depending on how you want it to react
19:02 ponyofdeath In version 2016.3.0, the state module name was made optional. If the state module is omitted, all states matching the ID will be required, regardless of which module they are using.
19:02 ponyofdeath whytewolf: is that not relevant here?
19:03 whytewolf humm. something i didn't know. but it looks like it wasn't working right
19:03 ponyofdeath def not working right
19:03 whytewolf I would say file a bug report on that if you are running 2016.3.0+
19:03 ponyofdeath 2016.3.1+ds-1
19:03 whytewolf that exaplins why it didn't error.
19:04 ponyofdeath cool, well thanks for your help man
19:04 whytewolf no problem.
19:05 corichar1 joined #salt
19:05 whytewolf humm. that does say require. maybe the other functions still require the module name. only require doesn't. if thats the case then the others should throw an error if it is omitted.
19:06 whytewolf if it isn't the case then the error is them not working with out the module
19:14 antpa joined #salt
19:16 jrb28 joined #salt
19:20 mpanetta_ joined #salt
19:31 irctc345 joined #salt
19:31 irctc345 any know issues with upgrading from 2015.8.8.2 to the newest?
19:32 LotR isn't that what you have a testing environment for? :)
19:33 irctc345 Yes but also what we have a community for. :)
19:34 protoz joined #salt
19:38 pipps joined #salt
19:41 perfectsine_ joined #salt
19:43 akashb joined #salt
19:43 akashb Hi everyone :)
19:44 akashb I actually have a question, which might be a little silly.... But if possible, do guide me a little. I have posted the question in stackoverflow:
19:44 akashb http://stackoverflow.com/questions/38631859/saltstack-highstate-top-sls-files-execution-when-merging-strategy-is-same
19:44 akashb Please can you take a look? If anyone is online here, that is.
19:44 rlarkin joined #salt
19:45 racooper joined #salt
19:46 rlarkin looking for a clue:  salt-run returns "'saltutil.sync_all' is not available" , psutils and python-psutil are both installed ( 2015.8.0 )
19:50 whytewolf rlarkin: saltutil.sync_all is a exacution module. not a runner module
19:51 tpaul joined #salt
19:51 rlarkin doh
19:51 rlarkin so the command is 'salt' ?
19:51 whytewolf salt '*' saltutil.sync_all
19:51 pcdummy or salt-call
19:52 whytewolf salt-call saltutil.sync_all
19:52 rlarkin ah
19:52 rlarkin thanks
19:52 mpanetta joined #salt
19:53 mpanetta joined #salt
19:53 akashb Can anyone take a look at the link I have posted?
19:53 akashb :(
19:54 cmarzullo akashb: I've looked at it.
19:54 cmarzullo env merging is a not as clear as I'd like. Personally I'm working through the same types of issues you are.
19:54 cmarzullo So I don't have the solution. But wanted to let you know you ain't alone.
19:54 pcdummy akashb: this is because "base" applies
19:55 pcdummy akashb: you need that '*' -files more specific for only base or put it in dev.
19:55 cmarzullo ahhh
19:55 akashb Actually I have added print and logs in states.py , the self.opts['environment'] points to default_top value in config, which in my case is 'base' , so it makes sense it is only listing base states, but the documentation said both will get listed.
19:56 pcdummy thats not true (for my experience at last), only the first env gets applied.
19:56 pcdummy with defaults settings
19:57 akashb I changed '*' from base to 'aa', instead of trying to match anything under 'dev', it returned empty.
19:57 pcdummy try to put the dev section in base
19:57 pcdummy just to try it
19:57 akashb Okay, let me try.
19:58 pcdummy i had where i had multiple envs one top.sls for all envs
19:58 pcdummy symlinked into each env folder.
19:58 pcdummy other things didn't work me at that time
19:59 akashb nah, still same issue, either listing only those matching 'default_top' , or none.
19:59 pcdummy with default settings?
20:00 akashb If i explicitly specify the env using saltenv=dev, then it is working fine. Or for merge strategy also it is working fine.
20:00 pcdummy ahh thats what i had too
20:00 akashb Yeah default setting is merge, there everything is working.
20:00 akashb The problem is with 'same'
20:00 akashb But at least feels good to know I am not alone :P
20:00 pcdummy i always had to specify saltenv if i didn't run highstate
20:00 pipps99 joined #salt
20:01 pcdummy akashb: if you run saltenv test=True you will see it works with dev
20:01 pcdummy highstate
20:01 orion left #salt
20:01 pcdummy akashb: now i have multi saltmaster per dev, works better for me.
20:02 pcdummy env
20:02 pcdummy i mean multiple saltmaster one per env.
20:03 akashb Hmn, not sure how it is working internally though...
20:04 pcdummy akashb: the thing is it works as expected, you just have to give saltenv=dev if you run a single command
20:05 pcdummy akashb: i think from saltmaster to minion i also had to give saltenv
20:05 pcdummy like "salt \* state.sls nginx.ng saltenv=pcdummy"
20:05 pcdummy pcdummy was my home env :)
20:12 ageorgop joined #salt
20:12 akashb But thanks :)
20:12 fracklen joined #salt
20:12 akashb Sorry was afk, didn't notice the newer messages
20:19 Sarphram joined #salt
20:23 ajw0100 joined #salt
20:25 tho joined #salt
20:26 cyborg-one joined #salt
20:27 flowstate joined #salt
20:31 tapoxi joined #salt
20:34 hasues joined #salt
20:44 johnkeates joined #salt
20:45 nidr0x joined #salt
20:49 teryx510 joined #salt
20:51 Sketch are there any best practices for laying out your states?  like, keep pkg installs, configs, and services for a single thing together, or split them up and put all your package installs in one place, configs in another, service states in another, etc
20:51 nmadhok joined #salt
20:54 ajw0100 joined #salt
20:54 iggy do whatever makes the most sense for you and your workflow
20:55 Sketch that's what i figured.  my coworker and i seem to have opposite ideas on some things, so i wondered if there was some standard :)
20:58 sagerdearia joined #salt
21:00 Raiden joined #salt
21:00 Guest24583 I have a small problem.. in my reactor I am calling a runner which generates some file, then I am executing file.recurse on minion which should get copied to the minion
21:01 Guest24583 but that always fails.
21:02 iggy gist code? Kind of curious what exactly you're doing
21:04 flowstate joined #salt
21:05 theblazehen joined #salt
21:05 cmarzullo Sketch: there's a number of things we do that improve our code.
21:06 cmarzullo generally follow the package, file, service model. Do all the installs. do all the config. then do all the service stuff.
21:06 cmarzullo We break everything down into discrete testable formulas that only do one thing. Usually a service.
21:07 cmarzullo Our formula's init.sls has a feature toggle where we check if the formula is enabled. So that if a risky formula is applied to a host. it won't activate unless there's pillar telling it to activate
21:07 cmarzullo the init then includes install.sls config.sls service.sls where we put the trifecta code
21:08 cmarzullo Of course sometimes you need to break out of that pattern. But it's the exception.
21:11 mrMute joined #salt
21:11 pipps joined #salt
21:15 Guest24583 sorry had to head out...
21:15 Guest24583 reactor code: {% set master_ip = data['data']['master_ip'] %} {% set env = data['data']['env'] %} create_cert:   runner.kube_certs.gen_cert:     - master: {{master_ip}}  copy_files:   local.state.sls:     - arg:       - kubernetes.copy_certs     - kwarg: { saltenv: {{env}} }     - tgt: '*'     - require:       - runner: create_cert
21:16 Guest24583 I am quite new to salt...any idea what should I do
21:19 sagerdearia joined #salt
21:19 robawt Guest24583: use a pastebin or gist so we can see it better
21:21 Guest24583 sorry...will do it
21:22 Guest24583 http://pastebin.com/FfK661dz
21:23 Guest24583 let me add runner and state code do...just a sec
21:24 Guest24583 http://pastebin.com/bss6pDW5
21:25 Guest24583 can you check now please
21:26 Guest24583 instead of cp.get_dir ...i am using file.recurse...pasted the wrong code.
21:27 Guest24583 my certificates are generated. but don't get copied. when I run the entire thing again when files are already there. it works
21:35 pipps joined #salt
21:36 pipps joined #salt
21:36 iggy maybe try throwing a cp.cache_dir inbetween the generation and the file.recurse?
21:37 iggy !salt modules.cp.cache_dir
21:37 saltstackbot https://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.cp.html#salt.modules.cp.cache_dir
21:37 robawt that's handy
21:37 pcdummy nice bot
21:38 ajw0100_ joined #salt
21:40 ageorgop joined #salt
21:43 Guest24583 okay will try that
21:43 Guest24583 thanks
21:47 fredvd joined #salt
21:50 _JZ_ joined #salt
21:53 flowstate joined #salt
21:54 knine What has been used to maintain an inventory of systems?  I want to keep track of things like production / non-production, these are the apache servers, these are the bind servers, etc.  Grains look useful, but it's not so easy to maintain separate /etc/salt/grains files on 300 systems.
21:55 knine a file full of pillar data that everything references is something I've considered
21:56 hasues left #salt
21:57 iggy write an external pillar to talk to your cmdb?
22:00 nonades joined #salt
22:00 mpanetta_ joined #salt
22:01 ahammond I'm trying to get salt-cloud azure module to work. It reports "[WARNING ] Missing dependency: 'azure'. The azure driver requires 'azure' to be installed." The saltmaster is on ubuntu 16.04 latest. I do not see a python-azure package. I use pip to install pyazure, but it doesn't appear to solve the requirement.
22:03 ahammond ah, the problem was my VM on Ubuntu 14.04. Working now.
22:10 Tyrm_ joined #salt
22:10 pipps joined #salt
22:14 flowstate joined #salt
22:20 Guest24583 iggy should I run cp.cache_dir using cmd.run state?
22:20 Guest24583 what will be the good way..can you give an example
22:28 pipps joined #salt
22:44 ponyofdeath hi, is it possible to deploy and set up a salt master using salt formula, and salt-ssh ?
22:44 ponyofdeath on a remote vm in the cloud
22:44 shanemhansen joined #salt
22:50 pipps joined #salt
22:51 robawt ponyofdeath: i was thinking of the same thing
22:51 robawt ponyofdeath: i was looking into doing it via masterless minion.  then i can have everything unroll and install itself from a repository
22:54 ponyofdeath robawt: yup what i am looking for
22:56 ponyofdeath salt-call --local you mean
22:58 robawt well a masterless minion is just a minion that is configured to pull files form itself
22:58 robawt from*
22:58 robawt you change about 4-5 likes in the master config file and you're donezo
22:59 ponyofdeath robawt: using the salt-formula to set up teh master on its self after that
22:59 robawt !salt salt masterless quickstart
22:59 robawt aww
22:59 robawt https://docs.saltstack.com/en/latest/topics/tutorials/quickstart.html
22:59 whytewolf humm I used to have something kind of like that. except i used a bootstrap set of states that would setup the master to use the the final set of states. coarse my master wasn't a masterless minion it was a master is itself
22:59 robawt i don't really use forulas, but that may be an approach
22:59 ponyofdeath robawt: yeah curently how i do it in vagrant i use salt-call --local
22:59 robawt cool OK
23:00 robawt whytewolf: does the master understand itself or does it require configuring a minion?
23:00 robawt i know it used to require running both
23:00 whytewolf still needs a minion
23:01 robawt OK cool, I've definitely done that setup before and it's slick
23:01 whytewolf honestly masterless still needs the minion anyway
23:01 robawt well yeah it's a minion configured to itself
23:01 whytewolf yeah
23:01 ponyofdeath so does that sound feasable, boot up new vm, bootstrap salt, use salt-call --local to set up master
23:02 whytewolf ponyofdeath: it actually isn't that dificult yes it is possable
23:02 Guest24583 any state to do cache again on minion
23:02 ninjada joined #salt
23:02 whytewolf you just create a bootstrap set of states that the masterless setup uses to setup the master
23:03 robawt yup
23:04 ponyofdeath is there a more "approved" approach ?
23:04 mpanetta joined #salt
23:04 robawt approved or prepackaged?
23:04 robawt :)
23:04 ponyofdeath i want to be able to pop up masters all over the place :)
23:05 edrocks joined #salt
23:05 iceyao joined #salt
23:05 whytewolf ponyofdeath: use https://github.com/saltstack/salt-bootstrap to create the masters.
23:06 whytewolf and a set of states [sounds like you like the salt-formula] that you use for actually setting up the master
23:06 robawt paint me old fashioned, but any of those bootstrap things creeps me out.  i'd rather write the salt states than pipe to root bash
23:07 ponyofdeath yeah that is kind of sketchy
23:07 ponyofdeath altho trusting a image from amazon is too
23:07 robawt yep, if you're not building it you need to know the risks
23:07 whytewolf salt-bootstrap is the bash script for installing salt. it is used by salt-cloud and actually is an official package
23:07 robawt atleast it's over https and you can force verify the cert
23:08 MTecknology dangit...
23:09 MTecknology I think I just wrote a patch for salt against master instead of develop :(
23:09 whytewolf oh ouch
23:09 MTecknology nope! default branch in delevop!!! :D
23:09 whytewolf lol
23:09 MTecknology was about to have to ask if it's possible to stash it and unstash in a different branch. :P
23:11 robawt or just use the checkout trick:  git checkout develop && git checkout <branch its in> -- <name of file>
23:11 MTecknology How can I properly attribute this to the company I'm working with? .. They have no issues with me pushing things up, but if it was something they sponsored, they'd like some attribution.
23:11 robawt then go back to the branch its in and drop the history
23:11 MTecknology robawt: and hope not much changed..
23:12 robawt heh, well if you specify the file it'll just wholesale copy the file to the branch
23:12 robawt works on directories too
23:12 nonades left #salt
23:12 jtang joined #salt
23:12 MTecknology I mean not much changing for that file. For all I know, it's been rewritten completely and checking out that file will give me a 600 line diff
23:13 MTecknology or worse yet... a 666 line diff
23:13 robawt gotcha
23:13 MTecknology it's like the 600 diff, but 66% worse and is evil
23:13 MTecknology robawt: sorry, I'm just kinda having fun with this now :)
23:14 robawt it's Friday :)
23:14 flowstate joined #salt
23:14 Edgan joined #salt
23:14 MTecknology I'm sure the attribution request isn't new. My first thought is just a blurb about who sponsored it in the PR
23:17 whytewolf I would say, put a blurb in the PR. add some documentation about the attribution. and hit up the contact page.
23:18 pipps joined #salt
23:21 MTecknology whytewolf: where would you document that? which contact page?
23:21 MTecknology sorry if those are questions of a dense person... I'm one of those :P
23:21 whytewolf https://saltstack.com/contact/
23:22 whytewolf not sure about the page though. I would think with the changes documentation. [as even with patches they should be documented]
23:22 brotatochip joined #salt
23:23 ninjada joined #salt
23:24 pipps joined #salt
23:26 whytewolf also, happy system admin day everyone!
23:26 MTecknology it's that day again?
23:26 whytewolf yeap
23:30 jenastar joined #salt
23:33 MTecknology :D https://github.com/saltstack/salt/pull/35073
23:33 saltstackbot [#35073][OPEN] Adding zfsroot option to lxc-create. | What does this PR do?...
23:34 jenastar joined #salt
23:37 robawt you too whytewolf
23:37 pipps99 joined #salt
23:37 johnkeates left #salt
23:39 brotatochip joined #salt

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