Perl 6 - the future is here, just unevenly distributed

IRC log for #salt, 2014-10-16

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

All times shown according to UTC.

Time Nick Message
00:00 manfred it is in develop
00:00 manfred don't use paramiko
00:00 manfred why not use ipmi?
00:00 manfred sshing into dracs is meh, you should be able to control it through ipmi more easily
00:00 manfred https://pypi.python.org/pypi/pyipmi
00:01 pipps joined #salt
00:01 murrdoc :)
00:01 murrdoc left #salt
00:01 murrdoc joined #salt
00:01 manfred http://web.mit.edu/cron/documentation/dell-server-admin/en/DRAC_5/racugc4.htm#87856
00:01 murrdoc have u tried this ?
00:01 murrdoc with dell dracs
00:01 manfred it would be better to use straight racadm from the server that the drac is connected to
00:01 manfred or ipmi to manage it
00:02 manfred because ssh on dracs is soo finiky
00:02 murrdoc ssh dracip 'racadmn' is what i end up doing
00:02 manfred you can run racadmn from the server if you have the dell tools installed
00:02 manfred instead of sshing into the drac
00:02 murrdoc say you had a fresh server
00:02 murrdoc u needed to wipe and provision
00:02 murrdoc how would u do it
00:02 manfred sure
00:03 manfred i wouldn't ssh to the drac
00:03 murrdoc i get that
00:03 murrdoc :)
00:03 manfred i well, i would make sure my servers are setup to kickstart
00:03 murrdoc and hook up to cobbler or some such
00:03 manfred then just set the boot device to netboot first
00:04 manfred yeah
00:04 murrdoc how would u get the server to be able to kickstart
00:04 manfred set the next boot to have netboot first
00:04 to_json joined #salt
00:04 manfred then it will install, and once the install is done, and reboots, it comes into the os
00:04 murrdoc by logging on to the servers lifecycle ?
00:04 murrdoc or logging into the drac ?
00:04 manfred well, i would configure it through the drac
00:05 manfred but if you are automating it, there isn't any reason you couldn't use ipmi
00:05 murrdoc i grant u that
00:05 Outlander joined #salt
00:05 murrdoc but basically the context here is non trivial number of hardware
00:05 murrdoc so i cant login or nothing
00:05 kusams joined #salt
00:05 murrdoc i mean i could
00:05 manfred right
00:05 murrdoc but i dont want to
00:05 manfred all i am saying is making paramiko a requirement for that module isn't necessary
00:05 Singularo joined #salt
00:06 murrdoc i ll check out ipmi lib
00:06 murrdoc paramiko works fine for ssh
00:06 manfred you could just as easily use subprocess.call(['racadm'])
00:06 manfred yeah, but sshing to a drac doesn't always work as well
00:06 manfred that is all i am saying
00:06 murrdoc not disagreeing
00:06 manfred if you can get away with not having to ssh, and not having to require an extra library, that is what I would do
00:07 murrdoc yeah
00:08 murrdoc now u gotta tell me why u dont like paramiko
00:08 manfred oh, i like paramiko
00:08 murrdoc thanks for the pip for ipmi
00:08 manfred i am just saying, using it for dracs is going to be a pain, paramiko is fine, but the other end of the equation is where the problem is
00:10 ramishra joined #salt
00:13 rangertaha joined #salt
00:17 aparsons joined #salt
00:19 Whissi joined #salt
00:20 pipps joined #salt
00:22 nitti joined #salt
00:23 Emantor joined #salt
00:23 mapu joined #salt
00:23 tafa2 joined #salt
00:26 rojem joined #salt
00:31 vbabiy joined #salt
00:32 bra1nout joined #salt
00:33 vbabiy joined #salt
00:34 whitenite joined #salt
00:35 vbabiy joined #salt
00:38 ingwaem joined #salt
00:41 jgelens_ joined #salt
00:44 ph8 joined #salt
00:51 fannet joined #salt
00:52 ramishra joined #salt
00:52 kusams joined #salt
00:53 whitenite joined #salt
00:56 druonysuse joined #salt
00:57 jgelens_ joined #salt
00:59 otter768 joined #salt
00:59 Emantor joined #salt
01:05 malinoff joined #salt
01:05 murrdoc joined #salt
01:11 bhosmer joined #salt
01:13 Mso150 joined #salt
01:19 mapu joined #salt
01:20 ahammond is there a clean way to find out the home directoy for a user in salt?
01:20 cb joined #salt
01:21 malinoff ahammond, cmd.run "echo ~username" ?
01:22 whitenite joined #salt
01:22 ahammond malinoff I'm looking for something less interactive to use in a formula (given a user name, find their home directory and put a file there)
01:22 cads joined #salt
01:22 murrdoc oh
01:23 malinoff ahammond, i think you can use "~username/" notation in file.managed dest argument
01:24 ahammond malinoff I'll give it a try. Thanks!
01:32 ramishra joined #salt
01:32 ntt joined #salt
01:33 otter768 joined #salt
01:40 jgelens_ joined #salt
01:42 iggy manfred: doesn't salt already include paramiko for salt-ssh?
01:46 manfred not afaik
01:46 manfred i am pretty sure that salt-ssh just sshes in and doesn't depend on paramiko
01:46 mapu joined #salt
01:46 manfred i know it just added it's own sshpass thing, so that the sshpass dependency could be removed from salt-ssh
01:46 iggy cool, we were talking about stuff in here the other day, must have gotten some wires crossed
01:46 manfred ╘═???? git grep paramiko                                                                                                         (⌐■_■)
01:46 manfred doc/man/salt.7:rather the name of the package (i.e. "dev\-python/paramiko").
01:46 manfred doc/spelling_wordlist.txt:paramiko
01:46 manfred doc/topics/cloud/releases/0.6.0.rst:salt libs, libcloud, and paramiko.
01:46 manfred salt/modules/ebuild.py:    rather the name of the package (i.e. "dev-python/paramiko").
01:46 manfred yeah, it doesn't use paramiko anywhere
01:46 Emantor joined #salt
01:46 manfred all home grown and i believe it just runs ssh directly like in salt.utils.cloud.bootstrap()
01:46 whitenite joined #salt
01:46 manfred it is worth noting, it only transfers enough information to exectute and run a zeromq instance to connect back to the salt-ssh device
01:46 manfred iggy: https://github.com/saltstack/salt/blob/develop/salt/client/ssh/__init__.py#L105
01:48 ilbot3 joined #salt
01:48 Topic for #salt is now Welcome to #salt | 2014.1.10 is the latest | Help us test the 2014.7 RC! http://bit.ly/salt-rc | Please be patient when asking questions as we are volunteers and may not have immediate answers | Channel logs are available at http://irclog.perlgeek.de/salt/
01:48 kusams joined #salt
01:50 manfred https://github.com/saltstack/salt/blob/develop/salt/client/ssh/wrapper/state.py
01:50 manfred looks like it bundles everything up and then transfers it over
01:50 aparsons joined #salt
01:55 fannet guys is there a way to see what exactly salt is doing w/ gitfs ? I keep getting “No Top file or external nodes data matches found”
01:58 iggy show_top
01:58 iggy cp.list<something>
01:58 iggy there's some useful stuff in the state _module_ and the cp module
02:00 diegows joined #salt
02:00 fannet local:
02:00 fannet ----------
02:01 fannet what does that mean
02:01 fannet haha
02:02 ramishra joined #salt
02:04 fannet I never see the salt master trying to connect to git :-/
02:16 ahammond nope, file.* requires absolute paths. so... I'm still looking for a clean way to pull a user's home directory. Sigh.
02:16 otter768 joined #salt
02:18 malinoff ahammond, you can use this hack {% set info = salt['user.info']('username') %}
02:18 malinoff http://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.pw_user.html#salt.modules.pw_user.info
02:18 baconbeckons i have a state that ensures that a service is running. another state requires the first state because it will hang if the service isn’t running. something somewhere is killing the service from the first state and i can’t figure out where. how can i figure out what state is killing the service?
02:19 ahammond malinoff thanks, I'll give it a shot
02:21 ingwaem joined #salt
02:23 kusams_ joined #salt
02:25 anotherZero joined #salt
02:26 fannet I found my git issue:   git fetch' returned exit status 128: ssh: Could not resolve hostname saltgitrepo.test.org:saltmasters: Name or service not known
02:26 fannet notice its trying to resolve saltgitrepo.test.org with the colon
02:29 fannet any idea where this is coming from - the colon is NOT in the /etc/salt/master  - its a ‘forward slash’ there
02:34 jalaziz joined #salt
02:36 Nexpro joined #salt
02:40 hawk10314 joined #salt
02:41 jgelens_ joined #salt
02:46 hawk10314 question regarding salt and environment variables.  when running " salt 'lab-server-0' cmd.run 'env' "  it prints out a list of vars. how would I add set new variables to be included.  If i use the state environ.set module it returns "unavailable".  I'm running 2014.1.10 at master and minion
02:49 jeffspeff i have 3 environments set up in master.conf. base, dev and prod. i have winrepo set up in base. when i call a highstate from my dev environment the package install fails saying that it can't find the installation file in the dev environment. i copied my winrepo to the dev environment folder, but i still get the same error
02:52 bhosmer joined #salt
02:57 whitenite joined #salt
02:57 kusams joined #salt
02:58 ramishra_ joined #salt
02:59 adsisco joined #salt
03:00 bhosmer joined #salt
03:01 adsisco anybody have any idea why i keep getting "data failed to compile:" even through the process seems to be running on minion?
03:02 jasonrm joined #salt
03:03 mosen joined #salt
03:07 davet joined #salt
03:13 adsisco hi?
03:14 mechanicalduck_ joined #salt
03:14 hasues joined #salt
03:17 Emantor joined #salt
03:29 fannet is it possible to have multiple git sources as external pillar sources ?
03:32 ramishra joined #salt
03:35 kusams joined #salt
03:38 pdayton joined #salt
03:41 programmerq joined #salt
03:44 jgelens_ joined #salt
03:50 jeddi joined #salt
03:53 kusams joined #salt
03:53 ingwaem joined #salt
03:54 jalbretsen joined #salt
03:55 ingwaem joined #salt
03:56 ingwaem joined #salt
04:00 mohae joined #salt
04:02 cb joined #salt
04:06 murrdoc joined #salt
04:12 colttt joined #salt
04:19 whitenite joined #salt
04:20 Emantor joined #salt
04:26 pravka joined #salt
04:27 gildegoma joined #salt
04:27 whitenite joined #salt
04:28 pravka_ joined #salt
04:29 Emantor joined #salt
04:29 TyrfingMjolnir joined #salt
04:37 ingwaem joined #salt
04:38 ingwaem left #salt
04:39 ingwaem joined #salt
04:42 felskrone joined #salt
04:45 jgelens_ joined #salt
04:49 bhosmer joined #salt
04:54 aranhoide joined #salt
05:02 programmerq joined #salt
05:04 Daemonik joined #salt
05:07 dukeofnuts joined #salt
05:08 mohae joined #salt
05:10 dukeofnuts left #salt
05:11 sunkist joined #salt
05:12 cb joined #salt
05:12 pipps joined #salt
05:14 whitenite joined #salt
05:15 dukeofnuts joined #salt
05:16 sunkist What if you set data in a pillar but your states can't see it?
05:17 sunkist I've checked pillar_roots, renamed pillar/top.sls and got an error; that tells me that salt sees my top.sls
05:18 sunkist pillar/top.sls references another file, users.sls, which has the docs example data in it.
05:19 sunkist If I change the name of the pillar/users.sls file, salt complains.  So, salt is reading my top.sls file and correctly looking for (and reading) pillar/users.sls.
05:19 sunkist When I run salt-call --local -l debug saltutil.refresh_pillar, I can see my pillar data getting parsed into a dict!
05:20 sunkist So that tells me my pillar_roots, top.sls, and users.sls files are all being read.
05:20 sunkist However, when I do a salt-call --local pillar.items | grep users, there is no output!
05:21 ramishra joined #salt
05:21 sunkist And when I try to loop through the users data in jinja from a file.managed or in a .sls file to generate states, pillar.get(users, {}) always returns an empty dict.
05:22 sunkist pillar.get('users', {testuser:1000}) only returns the dict with testuser...
05:22 dukeofnuts sunkist: I'm having this issue, also. My pillar data is being loaded into OrderedDicts in the debug output, but I don't see them in pillar.items
05:23 sunkist dukeofnuts: thanks for confirming my sanity!!!
05:23 sunkist Have you tried multiple versions of salt?
05:23 sunkist I'm thinking of upgrading to the devel branch...
05:23 sunkist Right now I'm running Hydrogen.
05:24 dukeofnuts I'm on 2014.1.11, too
05:24 dukeofnuts Are you running on a masterless setup?
05:26 sunkist dukeofnuts: yes, it's masterless.
05:27 sunkist My one advantage is that I'm developing a formula, so I actually have a clean repo I could send...
05:27 sunkist it has a vagrant file for testing, so really easy to verify the issue.
05:28 sunkist I just switched salty-vagrant's salt version from 'stable' to 'daily'.
05:28 sunkist We'll see if this helps.
05:28 sunkist dukeofnuts: what's your timezone?
05:28 sunkist I'm sitting in UTC-600.
05:29 dukeofnuts I think that's what I'm in too? US central
05:30 sunkist well, updating my vagrantfile didn't fix it...
05:31 dukeofnuts darn
05:31 sunkist do you have any other ideas?
05:31 dukeofnuts I'm at a loss, at the moment. I'm positive this VM worked when I shut it down in April. I haven't touched it since then, aside from updating packages today
05:32 sunkist I absolutely must get this fixed as well... but it seems like it might be why my sudo_rules aren't updating from pillar into my users-formula...
05:33 sunkist It's just the standard issue from the salt site.
05:33 sunkist Since I've got this repo, I might see if I can't send the whole thing to a developer tomorrow.
05:34 sunkist This is the first time salt has broken this bad for me... Usually I don't use bleeding edge features, so it's been very stable for me.
05:35 dukeofnuts Me too
05:35 dukeofnuts It looks like there's an open issue on GitHub: https://github.com/saltstack/salt/issues/16656
05:37 Daemonik left #salt
05:38 AmericanJuggalo joined #salt
05:38 AmericanJuggalo Are there States for illumos SMF  (Service Management Facility)  ??
05:41 sunkist dukeofnuts: how did you find the issue so quickly?
05:42 sunkist dukeofnuts: that is, how did you associate your own problem with the github issue so quickly?
05:43 dukeofnuts Oh, the title of the issue was familiar. That was the error message my states were giving me. I found it by searching for "pillar"
05:43 dukeofnuts I think i just got lucky that it was near the top :)
05:43 whitenite joined #salt
05:45 sunkist I know that Ryan_Lane runs the wikimedia stuff in masterless mode... so there should be someone in here tomorrow to whom it is important to assure a fix.
05:45 shookees joined #salt
05:51 Emantor joined #salt
06:03 ttrumm joined #salt
06:04 schimmy joined #salt
06:05 ttrumm_ joined #salt
06:05 nebuchadnezzar joined #salt
06:07 dukeofnuts left #salt
06:09 schimmy joined #salt
06:11 adsisco joined #salt
06:11 adsisco anybody have any idea why i get "Data failed to compile" even though the process is running on my minion when i do salt '*' state.sls ... ?
06:12 pipps joined #salt
06:14 __number5__ adsisco: that's what you get when you have hidden syntax errors in your state files
06:14 adsisco what do you mean by hidden syntax errors and how do i identify them?
06:15 __number5__ adsisco: try salt -l debug oneminion state.show_sls your_sls
06:17 adsisco looks ok except for this line [INFO    ] jid 20141016021611651746 minions set(['vagrant-ubuntu-trusty-64', 'logstash']) did not return in time
06:18 tld_wrk joined #salt
06:19 __number5__ adsisco: try run state.sls with -l debug flag then.
06:21 adsisco same output ... but the errors are not showing now, I think it only happens when i run the minion in debug mode
06:22 adsisco [DEBUG   ] Checking whether jid 20141016022158692275 is still running
06:22 adsisco [DEBUG   ] get_returns for jid 20141016022203699871 sent to set(['vagrant-ubuntu-trusty-64', 'oceanlog', 'logstash']) will timeout at 02:22:08
06:22 adsisco [INFO    ] jid 20141016022203699871 minions set(['vagrant-ubuntu-trusty-64', 'logstash']) did not return in time
06:22 adsisco is this normal?
06:38 bhosmer joined #salt
06:39 lcavassa joined #salt
06:42 rattmuff joined #salt
06:45 ITChap joined #salt
06:48 colttt joined #salt
06:51 ITChap joined #salt
06:52 pravka joined #salt
06:55 CycloHex joined #salt
06:55 bra1nout joined #salt
06:57 ramishra joined #salt
07:02 slav0nic joined #salt
07:02 slav0nic joined #salt
07:06 knot joined #salt
07:07 duncanmv joined #salt
07:16 jgelens joined #salt
07:17 tomspur joined #salt
07:17 ramishra joined #salt
07:20 bagackiz joined #salt
07:20 davidone joined #salt
07:25 chiui joined #salt
07:26 tld_wrk joined #salt
07:28 trikke joined #salt
07:32 CycloHex When using smtp_return, is it possible to se a custom message instead of the ugly formatted result I get from a highstate?
07:35 flyboy joined #salt
07:38 ramishra joined #salt
07:45 PI-Lloyd joined #salt
07:45 mikeywaites joined #salt
07:45 mikeywaites left #salt
07:49 Mso150 joined #salt
07:51 j-saturne joined #salt
07:52 oyvjel joined #salt
07:53 oyvjel1 joined #salt
07:57 giannello joined #salt
08:09 cberndt joined #salt
08:13 gyre007_ joined #salt
08:15 intellix joined #salt
08:27 bhosmer joined #salt
08:28 flyboy82 hey guys, asked this also yesterday but didn't have the time to hang around much. No matter what I try, my multi-line pillar value keeps being translated to a single line with "\n" instead of actual newlines  http://pastebin.com/Kzqg8fvL
08:29 flyboy82 any ideas?
08:31 flyboy82 ah, yea, it's on 2014.1.11
08:38 smcquay joined #salt
08:41 ITChap joined #salt
08:43 ramishra joined #salt
08:45 Tangresh joined #salt
08:48 tinuva joined #salt
08:49 flyboy82 found it! need to call the pillar key enclosed in " "  in my state.... duuuh
08:54 duncanmv joined #salt
08:54 CycloHex Is there a way to require a cmd.run state?? Or can requisites only have files, sls and services?
08:54 bhosmer joined #salt
08:59 giantlock joined #salt
08:59 N-Mi joined #salt
09:03 TheThing joined #salt
09:04 Tangresh Hello #salt! I am experiencing strange behaviour with salt-call, file_client: local and pillar data. Specifically, the cmd "sudo salt-call pillar.items" only shows me data under "master:", my actual pillar data is missing and all my states with pillar data fail
09:05 Tangresh When I execute the commands with -l debug, I see my pillar data getting rendered, but it is not applied. Has anyone experienced this before?
09:12 agend joined #salt
09:12 ajprog_laptop joined #salt
09:17 whitenite joined #salt
09:20 ze- Hey. I am starting to play with acl. I can have the user call salt minion command, but salt-run doesn't seem to like it. Is it possible? if so, how :)
09:23 flyboy82 CycloHex: you can require whatever previous state you want... So if you have a " list:\n   cmd.run:\n    -name: ls -la"  you can require it with a "- require:\n  - cmd: list"
09:24 CycloHex whatup with your \n :D, flyboy82.. Oh, I get it now.. So if I have a cmd.run with id test, I can require it using cmd: test?
09:25 duncanmv joined #salt
09:25 flyboy82 yup
09:27 CycloHex flyboy82: thanks man!
09:28 flyboy82 anytime
09:30 tld_wrk joined #salt
09:33 agend joined #salt
09:37 CycloHex I want to slice my minion-id, but not sure how to achieve what I want. eg: minion-ids = foo-bar-baz, ofo-bra-bax, oof-arb-bry. Of all these ids I'd like to just have the last part (baz, bax, bry). I thought it'd be easy, just start from the back, up to the first '-'.. But I couldn't find anything that achieves this
09:38 ingwaem` joined #salt
09:39 ujjain joined #salt
09:41 simmel_ joined #salt
09:46 ze- CycloHex:  .split('-')[-1] ?
09:46 CycloHex That's not possible using jinja, right?
09:47 ze- i wouldn't see why not.
09:47 ze- you have a python string, and just need to call methods on it.
09:47 CycloHex Didn't realise you could just call python methods in a jinja tmeplate
09:47 ze- what you can't do is call python functions out of nowhere.
09:47 ze- but if you have an object, you can call its methods.
09:48 CycloHex ze-: ok, thanks, i'll try it now
09:50 whitenite joined #salt
09:51 CycloHex ze-: thanks a lot! not only did it work, but I now know that I can call python modules in jinja
09:52 che-arne joined #salt
09:54 fredvd joined #salt
10:00 mosen joined #salt
10:00 techdragon joined #salt
10:00 loz--_ joined #salt
10:07 rattmuff Sometimes when I run 'salt' command I get to return what so ever. The prompt simply drops back to where it was. Anyone else experience this on 2014.01?
10:07 rattmuff root@host:~# salt '*' state.highstate
10:07 rattmuff root@host:~# salt '*' state.highstate test=True
10:07 rattmuff root@host:~#
10:15 bhosmer joined #salt
10:16 ggoZ joined #salt
10:28 ramishra joined #salt
10:35 Outlander joined #salt
10:41 johtso joined #salt
10:46 johtso hmm, can anyone recommend a good way to sync my code to my virtual machine when developing locally
10:46 johtso I'm usually using gitfs but that's obviously not practical for making changes and testing them out
10:46 cofeineSunshine vagrant
10:47 cofeineSunshine it uses virtualbox
10:47 cofeineSunshine so you can easily setup
10:47 johtso I'm using vagrant, and I'm syncing the code to my masterless minion's fileserver
10:47 johtso and using file.recurse
10:47 esogas_ joined #salt
10:48 johtso but that seems to be really slow
10:48 cofeineSunshine you can syn folder with your host machine
10:48 johtso probably because of all the .git files
10:48 johtso cofeineSunshine: but I need salt to detect that the files have changed so that it can restart all the relevant processes
10:48 johtso and for that to happen I need to use something like file.recurse I think
10:54 TheThing|24-7 joined #salt
10:57 ramishra joined #salt
11:14 sander^work joined #salt
11:20 sander^work How can I create users with the right ssh public keys on remote servers with salt?
11:20 ITChap joined #salt
11:21 bigl0af joined #salt
11:29 TheThing|24-7 store the public keys in pillars/etcd?
11:38 martoss joined #salt
11:41 johtso Is there a way to suppress change output for a specific state?
11:44 martoss1 joined #salt
11:45 emning joined #salt
11:46 rawkode joined #salt
11:47 sander^work TheThing|24-7, the public ssh keys should be stored inside the .ssh directory.
11:47 sander^work of each user.
11:47 diegows joined #salt
11:47 younqcass joined #salt
11:48 CeBe joined #salt
11:50 sander^work TheThing|24-7, I havent set up salt at all.. so I need some basic help too. But is salt good for doing this kinda stuff?
11:50 lcavassa joined #salt
11:51 TheThing|24-7 salt is pretty good to use for doing stuff as long a you want it to do the stuff for you <_<
11:51 TheThing|24-7 As for your question, you can use salt state to install group of users onto a machine for you with ssh key and really whatever you want
11:52 sander^work TheThing|24-7, Cool. Can you tell me how I can do it? or if you can point me to some guide?
11:52 younqcass Does any know how to pass cmd args within the docker installed state
11:52 TheThing|24-7 yeah, just give me a moment
11:54 TheThing|24-7 sander^work: https://github.com/nfp-projects/salt-states/blob/master/ssh/init.sls here is an example of how to insert ssh keys onto machines
11:54 TheThing|24-7 if you store a list of users in a pillar
11:55 TheThing|24-7 you could do something like this:
11:55 giantlock joined #salt
11:57 TheThing|24-7 {% for user in pillar['users'] %}
11:57 TheThing|24-7 {{user}}_user:
11:57 TheThing|24-7 user.present:
11:57 TheThing|24-7 - name: {{user}}
11:57 TheThing|24-7 file.managed:
11:57 TheThing|24-7 - source: salt://ssh/users/{{ user }}.pub
11:57 TheThing|24-7 {% endfor %}
11:57 TheThing|24-7 whops
11:57 TheThing|24-7 missing a line there
11:58 TheThing|24-7 sander^work: http://pastie.org/9652476
11:58 TheThing|24-7 as a very rough example
11:58 TheThing|24-7 check out pillars and user module
11:58 TheThing|24-7 as well as file module
12:01 ingwaem` joined #salt
12:01 sander^work TheThing|24-7, ah, seems like what I want :)
12:02 sander^work Where do I put this file?
12:02 TheThing|24-7 You put salt states in your installation salt state folder if that makes sense <_<
12:03 sander^work I just installed salt-ssh
12:03 TheThing|24-7 ahh, you don't have a salt master do you <_<
12:03 sander^work No.
12:03 TheThing|24-7 in that case
12:04 sander^work I can install it if needed.
12:04 bhosmer joined #salt
12:04 TheThing|24-7 http://docs.saltstack.com/en/latest/topics/ssh/ here, this will get you started on how to use state files with salt-ssh :)
12:05 TheThing|24-7 in any case, I'm no expert but it seems you should be able to create state files as you normall would
12:05 TheThing|24-7 and then use salt-ssh to run it onto your machines
12:06 bluenemo joined #salt
12:07 TheThing|24-7 gotta go o/
12:09 CycloHex Hello guys, I set a custom_grain to a specific value manually, Then I check if the grain is value foo, else if value bar, ... else do w/e. My problem now is that the file skips every check and just always runs the else clause. I can't get my head around this. I don't think I'm making a typo anywhere :( http://pastie.org/private/a5u4m8famsywbhqeg8v8q
12:09 giomandaz joined #salt
12:10 giomandaz hi guys, i have a state where at a point it starts loading package names from a pillar
12:11 giomandaz i use a for loop to get the packages from pillar and then use the pkg.installed in order to install them
12:11 giomandaz no winside the pillar i have two if statements
12:12 giomandaz i do this in order to split which packages are going to be installed on which server
12:12 bluenemo hi guys. I have a most probably simple problem with an if statement not working, and just cant find out why: http://paste.debian.net/hidden/6f8d9d80/ Salt gives me back 'Unable to manage file: Jinja variable 'dict object' has no attribute 'Warning', which is true, no Warning defined in the pillar file, but thats why i had {% if log.Warning %} in it. Hope you have a hint :)
12:13 giomandaz so inside the pillar ia have one if statement which gets the hostname of the grain fqdn and if it starts with name "production_srv" will install the relevant packages
12:14 giomandaz the second if is quite same, an if statment which gets the hostname from fqdn name and of name has "test_srv" installs the other packages in the pillar
12:14 bhosmer joined #salt
12:15 giomandaz thing is that when i try to run the state for a host that does not match any cretearia in the pillar i then get the following error
12:15 giomandaz Rendering SLS "blah blah" failed: Jinja error: 'NoneType' object is not iterable
12:15 bluenemo giomandaz, your pillar file is then empty. you might want to put some if statements around your for loops to check if any data is set at all. thats kind of what my paste above is about too ;)
12:16 intellix joined #salt
12:16 bluenemo you try to iterate over something that does not exist, thats why it fails
12:16 giomandaz this is normal since the for loop which gets the values from the pillar is empty
12:16 ramishra joined #salt
12:16 bluenemo yes, but if I say {% for foo in bar.barz %} and barz is not set it will fail
12:16 giomandaz how can you tell the for loop "if no match on the fqdn can be found on the pillr, then do nothing?"
12:17 salt-n00b joined #salt
12:17 bluenemo giomandaz, stupid example as it does not work atm for me :D dunno why, but it works in my other formulas: http://paste.debian.net/hidden/6f8d9d80/ line 28
12:17 giomandaz thanks will have a look at it
12:17 bluenemo you need an if loop, as in {% if bar.barz %}.
12:18 bluenemo giomandaz, if you find my error tell me ;P
12:18 giomandaz an if loop within the for or before the for loop?
12:23 funzo joined #salt
12:23 PI-Lloyd {% if pillar['foor']['bar'] == 'some_value' %}
12:24 PI-Lloyd before the for loop, so if "some_value" matches, then run your state, if it's anything else do nothing
12:26 CycloHex If you nest an if elif elif elif else in a for loop, do you need indentation?
12:26 martoss joined #salt
12:26 CycloHex My if loop always resorts to the else clause. I cannot find what is wrong with my syntax
12:26 smcquay joined #salt
12:26 PI-Lloyd CycloHex: no you don't need to ident it further
12:27 PI-Lloyd inedent*
12:27 PI-Lloyd ffs
12:27 CycloHex http://pastie.org/private/a5u4m8famsywbhqeg8v8q
12:27 CycloHex this are my if headers, why on earth is this always going to the else
12:28 cpowell joined #salt
12:28 badon joined #salt
12:29 gmcwhistler joined #salt
12:30 spo0nman joined #salt
12:31 CeBe1 joined #salt
12:32 PI-Lloyd CycloHex: do a salt-call -g on the minion and check that the 'custom_grain' is set
12:33 bluenemo PI-Lloyd, can you take a look at my if loop? :) line 28 in http://paste.debian.net/hidden/6f8d9d80/ wont work, and the for loop gives me an error.
12:33 TheRealBill joined #salt
12:34 cb joined #salt
12:34 TheThing joined #salt
12:34 bluenemo funnily the for loop fails with not having defined 'Warning' in the pillar file.. thats what I want the if to test for in the first place
12:34 cpowell joined #salt
12:34 CycloHex PI-Lloyd: positive they're set.. Whatever, i'm just letting it resort to the else clause for now
12:35 CeBe2 joined #salt
12:37 martoss1 joined #salt
12:37 Emantor joined #salt
12:42 bluenemo sry, not if loop, if statement..
12:43 sander^work salt-ssh -E '.*' [ options ] sys.doc cmd <-- What is the sys.doc parameter here?
12:43 CeBe1 joined #salt
12:43 rawkode joined #salt
12:45 dccc joined #salt
12:45 CeBe2 joined #salt
12:49 XenophonF function call
12:50 XenophonF hang on let me get you the documentation link
12:51 XenophonF i think sys.doc in particular returns the docstring of "cmd"
12:53 XenophonF http://docs.saltstack.com/en/latest/ref/modules/index.html#documentation
12:53 younqcass How does one apply the cmd parameters to a docker installed state?
12:53 bluenemo lol fail, {% if log.warning is defined %} is working m)
12:54 ramishra joined #salt
12:59 XenophonF so this is a little confusing: under Hyper-V, Linux guests have grains['virtual'] set to "VirtualPC", while Windows guests have it set to "HyperV"
12:59 racooper joined #salt
12:59 slav0nic joined #salt
12:59 sander^work XenophonF, how do I just execute a command at several servers?
13:00 XenophonF sander^work: do something like - salt * cmd.run 'ls -l /'
13:01 miqui joined #salt
13:01 XenophonF there should be a ton of better examples in the docs
13:01 sander^work XenophonF, ah. and what about a script?
13:01 bluenemo sander^work, well, that script has to be present on those hosts first, as in file.present, if I'm not misstaken
13:02 bhosmer joined #salt
13:02 bluenemo you can then use cmd.script, which will execute a script. In a state, you could also use cmd.run: | and then use the following lines, intendendet by 4 whitespaces, to define your script (should be in the docs)
13:02 sander^work bluenemo, XenophonF: How do I make the script available trough salt-ssh's file share then, and execute it.
13:02 XenophonF sander^work: there's also the cmd.script state
13:03 CeBe1 joined #salt
13:04 istram joined #salt
13:05 Ahlee sander^work: if you define cmd.script salt will copy the script served off salt's fileserver (built in) to a temporary file in /tmp (configurable) and execute it
13:05 XenophonF sander^work: http://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.cmdmod.html#salt.modules.cmdmod.script
13:06 Ahlee I would caution against relying on cmd.script as you lose a lot of the benefits of salt's error reporting, change recording, etc
13:06 Ahlee but admittedly my states are full of those short cuts, too.
13:06 bluenemo ah yes, then I was wrong before. only need to specify salt://script.sh, no need to put it there via file.present. sorry.
13:06 smcquay joined #salt
13:06 Ahlee bluenemo: either way works :)
13:07 bluenemo Ahlee, yes, but cmd.script seems better practice, as having .sh scripts fly around on the minions only for salt seems.. unwanted :)
13:07 bluenemo (cmd.script removes the file in /tmp again, right?)
13:08 Ahlee bluenemo: Correct.  The temporary file is removed, hence my caution against using it
13:08 smcquay joined #salt
13:09 bluenemo I used to have /etc/salt/scripts to store those..
13:09 bluenemo on the minions
13:09 Ahlee I have a scripts directory managed for those items that just aren't worth converting to states
13:10 bluenemo those jinja minus whitespace control things are driving me nuts..
13:13 vejdmn joined #salt
13:14 bhosmer_ joined #salt
13:16 mpanetta joined #salt
13:16 PI-Lloyd bluenemo: how so?
13:16 bluenemo I do get it, but its so super unintuitive somehow..
13:17 bluenemo but I dont want to start the templating engine discussion ;)
13:19 sander^work Ahlee, XenophonF bluenemo: Why do I get: IOError: [Errno 13] Permission denied: '/var/cache/salt/master/thin/salt-call' I added localhost in roster with a user with sudo NOPASSWD access.. and executed: salt-ssh "*" cmd.script "ssh://script.sh" the script is located in: /etc/salt/script.sh
13:20 kusams joined #salt
13:21 ramishra joined #salt
13:21 XenophonF sander^work: sorry, i don't use salt-ssh
13:21 XenophonF oh
13:21 PI-Lloyd try with sudo on the salt-ssh command :p
13:21 PI-Lloyd sudo salt-ssh
13:21 XenophonF sander^work: that should be salt://script.sh
13:21 XenophonF and the script should be under /usr/local/etc/salt/states or whatever it is on your system
13:22 bluenemo by defaults salt:// = /srv/salt, if i'm not misstaken
13:22 PI-Lloyd ^^ this
13:22 bluenemo or /srv/salt/base? :) base is default env, so I think its that one.
13:23 PI-Lloyd no base folder in my state, on any of the master i've been using
13:23 cheus joined #salt
13:23 PI-Lloyd depends on how you've got it setup i guess
13:24 dccc joined #salt
13:24 PI-Lloyd but to answer the question /srv/salt/files/script.sh would map to salt://files/script.sh
13:24 bluenemo salt compiles all pillars given in /srv/salt/base/top.sls right? it does not care if i'm only executing a specifc state, requiring a specific pillar?
13:25 hobakill joined #salt
13:26 manfred correct
13:26 Ahlee I also have no experience with salt-ssh
13:26 bluenemo k. now I get why my highstates take forever ;)
13:27 CeBe1 joined #salt
13:27 sander^work localhost: ERROR: sudo expected a password, NOPASSWD required
13:27 Ahlee Yes, every run compiles all pillars into a dict on the master and ships that dict down to the minion
13:28 Ahlee first hit on google: https://github.com/saltstack/salt/issues/8882
13:28 sander^work I have "%admin ALL=(ALL) NOPASSWD: ALL" in the sudoers file.
13:29 sander^work And i'm in the admin group.
13:29 Ahlee Add a comment to the github link i just pasted, sander^work.  Looks like that bug is still an issue
13:29 scottpgallagher joined #salt
13:30 CeBe2 joined #salt
13:30 rawkode Anybody know if it's possible to have Salt run a command on just one minion, matching from a grain?
13:30 slav0nic joined #salt
13:30 slav0nic joined #salt
13:30 Ahlee rawkode: does the one minion have a uniquely identifiable grain? if yes, just target that grain
13:31 rattmuff rawkode: you could check grains['id'] I guess
13:31 rawkode Ahlee: Sadly not, I'm trying to run a job on any one production box
13:31 Ahlee if the grain isn't globally unique you'll need some unique identifier
13:31 Ahlee rawkode: pick a node and add anohter grain?  salt -C "G@grain:1 and G@grain:2"
13:32 rawkode Ahlee: AutoScaling, can't predict a single node :(
13:32 Ahlee hrm.
13:33 Ahlee can autoscaling be configured to ensure criteria is met, such as "one node of this type always exists?"
13:33 rawkode That could be one way, I guess. Would have been nice to tell salt "Run this command, on any one random host matching this criteria"
13:33 SkyRocknRoll__ joined #salt
13:34 rawkode Think the easiest way in the interim is to call a web address and run the task
13:34 flyboy82 joined #salt
13:34 linjan joined #salt
13:36 istram rawkode: do you want that in a state?
13:36 Ahlee hrm.
13:36 flyboy82 joined #salt
13:36 Ahlee rawkode: i suppose there'd be a way to do it through the reactor or mine
13:36 manfred Ahlee: drop the cloud.created
13:37 istram rawkode: you can script that on a master by helper script. select right minions and then rand() and send command.
13:37 manfred it can make sure that a cloud server of that type exists in your environment
13:37 Ahlee but honestly that all seems needlessly complex
13:37 jgelens joined #salt
13:37 Ahlee manfred: hm?  Sorry, I was musing to rawkode, I have no cloud infrastructure
13:37 phblj joined #salt
13:38 rawkode It's an hourly cronjob that I need to run once an hour, but only on one machine.
13:38 rawkode The job runs in a Docker container, which my production boxes all have - so it'd be nice if it happened on one of them.
13:38 Ahlee ah.  The joys of the limits of cron.
13:38 rawkode Though I could just configure the salt-master to have the containers also, and use the master as the one box
13:39 mapu joined #salt
13:39 Ahlee rawkode: might be overkill, but airbnb's chronos
13:42 istram rawkode: we have people solving the synchronization thru mine or dynamodb. but we don't really like it so we're trying to elminate this kind of designs.
13:42 thedodd joined #salt
13:42 sander^work Ahlee, I'm running salt-ssh 0.17.5
13:42 ozzzo joined #salt
13:43 sander^work Ahlee, I cant get it to work with or without sudo or NOPASSWD
13:44 XenophonF sander^work: why the old version of salt?
13:44 sander^work XenophonF, because it's included in ubuntu 14.04
13:45 Ahlee I also run 0.17.5, though I do not use salt-ssh.
13:45 sander^work Ok.. I'll add the salt repo.
13:45 XenophonF sander^work: http://docs.saltstack.com/en/latest/topics/installation/ubuntu.html
13:46 manfred salt-ssh in 0.17.5 is super alpha
13:49 nitti joined #salt
13:54 sander^work now i'm on salt-ssh 2014.1.11 (Hydrogen)
13:54 sander^work sudo: no tty present and no askpass program specified  ERROR: sudo expected a password, NOPASSWD required
13:56 krissaxton joined #salt
13:57 sander^work ssh -t localhost "sudo date" made me type in the password two times.
13:58 jslatts joined #salt
13:59 sander^work I have installed ssh-askpass
13:59 jgelens joined #salt
14:00 perfectsine joined #salt
14:01 lacrymology joined #salt
14:02 lacrymology is there a module function that'll return the text of a rendered state?
14:02 ndrei joined #salt
14:02 lacrymology like with the grains resolved, and whatnot
14:02 sander^work Oh. I had two sudo rules.. the one without NOPASSWD came first in the groups file..
14:02 sander^work OSError: [Errno 13] Permission denied: '/var/cache/salt/master/jobs/1f'
14:02 ingwaem` joined #salt
14:02 higgs001 joined #salt
14:06 desertigloo joined #salt
14:07 whitenite joined #salt
14:08 perfectsine joined #salt
14:08 dude051 joined #salt
14:09 ramishra joined #salt
14:12 ericof joined #salt
14:13 hasues joined #salt
14:19 student__ hi all, I have a problem with writing python states - media-libs/tiff:   tryslot.slotinstalled:   - slot:3 when tryslot.slotinstalled is a python function. Returned Too many functions declared in state "tryslot" in sls test1
14:20 jgelens joined #salt
14:20 student__ tryslot - python file
14:20 student__ in tryslot only one function - slotinstalled
14:21 Ahlee sander^work: Did you see https://github.com/saltstack/salt/issues/8882
14:24 ipmb joined #salt
14:24 student__ I have written like in http://docs.saltstack.com/en/latest/ref/states/writing.html#full-state-module-example
14:25 cheus joined #salt
14:29 philipsd6 joined #salt
14:30 whitenite joined #salt
14:31 thedodd joined #salt
14:31 hobakill if i wanted to search for all minions with a certain version of salt how would i do that? i know there is a grain called "saltversioninfo" but i'm not sure how to format the search....salt -G "saltversioninfo:2014.1.10.0" test.ping doesn't work nor does the 20141100 string.
14:32 anotherZero joined #salt
14:32 flyboy82 salt -G 'saltversion:2014.1.10' test.ping
14:33 jensnockert joined #salt
14:33 hobakill flyboy82: thanks. i'm not sure why that works tho since the grain is 'saltversioninfo'
14:33 flyboy82 there are 2 grains
14:34 hobakill ah
14:34 flyboy82 one is the saltversion that holds the version in one line
14:34 flyboy82 the other is saltversion info which splits major, minor etc in different lines
14:34 hobakill flyboy82: brilliant. thanks.
14:36 flyboy82 you can refine your targeting even further if you want... if you run "    salt-call grains.items     " on a minion you'll see the exact form in which grains are returned
14:36 flyboy82 so you could do         salt -G 'saltversioninfo[2]:10' test.ping   (don't know if that actually works)
14:37 hobakill flyboy82: i was using that from the master but didn't bother to grep for anything. just eyeballed. gave up early and asked the room. i really appreciate the help!
14:37 johtso Hmm.. I'm getting some very strange service.running behaviour. When I run with test=True.. it says that nginx needs to be started, but when running out of test mode, it says "Service nginx is already enabled, and is running".. and when I check the status of the nginx service, I get "Command 'service nginx status' failed with return code: 3" "output:  * nginx
14:37 johtso is not running"
14:37 johtso what could be going on
14:37 johtso *?
14:40 jaimed joined #salt
14:41 djstorm joined #salt
14:45 elfixit joined #salt
14:46 StDiluted joined #salt
14:49 bstr joined #salt
14:50 kaptk2 joined #salt
14:50 mechanicalduck joined #salt
14:50 bstr Hey guys, anyone have an ETA on helium release date by chance?
14:50 SheetiS joined #salt
14:51 eunuchsocket joined #salt
14:53 Ozack1 joined #salt
14:54 tomspur joined #salt
14:56 tomspur joined #salt
14:56 tomspur joined #salt
14:56 iggy 2 weeks is what I've heard (for the last 5 weeks)
14:57 ajolo joined #salt
14:58 iggy anybody know of any decent examples of using the orchestrate runner? (beyond all the stuff in the official docs which I've read numerous times)
14:59 perfectsine joined #salt
15:00 vejdmn joined #salt
15:02 jeffspeff what command do you use to see the return output of a jid ?
15:04 hobakill jeffspeff: salt-run jobs.lookup_jid <job id number>
15:04 johtso Opened an issue for the above https://github.com/saltstack/salt/issues/16677
15:05 davet1 joined #salt
15:06 jeffspeff hobakill, if that doesn't return anything, does that mean the job hasn't finished yet?
15:06 viq joined #salt
15:08 thehaven joined #salt
15:10 ramishra joined #salt
15:11 interociter joined #salt
15:11 ndrei joined #salt
15:11 interociter Hi
15:12 interociter Anyone here?
15:12 fannet joined #salt
15:12 Ahrotahntee 572 users present
15:12 Ahrotahntee two speaking (for the moment)
15:12 hobakill hahahha
15:12 interociter Looking for help with the rest_tornado API
15:13 hobakill jeffspeff: that could be part of it but i couldn't be 100% sure.
15:14 interociter I've added rest_tornado to the master config file, but it appears to do nothing
15:14 interociter anyone familiar with this API?
15:16 jalbretsen joined #salt
15:17 iggy interociter: did you restart the master?
15:17 interociter yep
15:19 interociter I think I know the problem now
15:19 MK_FG joined #salt
15:19 interociter running a older version of salt
15:19 interociter ubuntu apt-get installed a crusty version
15:20 ek6 joined #salt
15:20 iggy there's a ppa somewhere (or use salt-bootstrap, it will install the latest version using a distro specific method)
15:21 Nazzy this is somewhat off topic, does anyone know of a tool like tripwire that I can use to "fingerprint" and verify an entire server?
15:22 Nazzy my thought is to find some way to verify the state against what it's supposed to be
15:24 Jellyfrog someone know if halite is a dead project?
15:25 Nazzy halite is merged with mainline now, isn't it?
15:25 interociter iggy: thanks, looks like bootstrap-salt is doing its thing
15:25 cb joined #salt
15:26 iggy Jellyfrog: it's not getting as much love as it should right with the release taking so long, but it's definitely not dead
15:27 Jellyfrog ok, i remember last time trying it (long time ago) it left...a lot..to wish for ( i know its still pre-alpha)
15:28 jgelens joined #salt
15:28 aparsons joined #salt
15:28 iggy yeah, it's got a way to go before it's useful for everything, but it's currently useful for little things (most importantly letting managers see it to avoid having to answer their questions daily ;)
15:29 hobakilllll joined #salt
15:30 aparsons joined #salt
15:31 Jellyfrog ok, thanks for the answer
15:33 VSpike if you're building multiple hosts, and the config files of some should contain the ip address of others, what salt technology should I be googling for there? :)
15:33 VSpike Is it salt mine? Or something else?
15:34 iggy Jellyfrog: if you have suggestions for features you'd like added, feel free to open tickets for them
15:34 wendall911 joined #salt
15:34 Jellyfrog iggy: ok, good to know, i barley use salt (or anything else) today, but im looking to start deploying it a bit bigger
15:35 Jellyfrog these recent bash/openssl problems are annoying to patch
15:35 Jellyfrog manually :)
15:36 iggy once $work gets our product released later this month, I'm hoping to have some time to work on halite a little
15:38 briner joined #salt
15:38 cb joined #salt
15:38 Jellyfrog sounds good
15:41 jngd joined #salt
15:42 Jellyfrog someone know why "salt.modules.aptpkg.install" have install_recommends as true
15:42 Jellyfrog when its not apt default behavior
15:43 Jellyfrog atleast not on ubuntu 14.04
15:44 ek6 joined #salt
15:45 to_json joined #salt
15:46 Supermathie joined #salt
15:46 Supermathie Morning everyone!
15:46 Supermathie Has anyone tried to listen for/fire events on Windows? https://github.com/saltstack/salt/issues/16682
15:46 StDiluted joined #salt
15:50 Jellyfrog iggy: master gave me 404 on like..all js files :(
15:51 iggy Jellyfrog: I'm pretty sure install recommends is default on ubuntu
15:51 vu_ joined #salt
15:51 housl joined #salt
15:51 iggy Jellyfrog: I used the install instructions for development (fwiw)
15:53 Jellyfrog iggy: http://pastebin.com/81yQr9sv
15:53 tligda joined #salt
15:53 higgs001 joined #salt
15:54 TheThing joined #salt
15:54 Supermathie Do we need to upgrade master first or minion first? I forget.
15:55 iggy Supermathie: master
15:56 gildegoma joined #salt
15:58 UtahDave joined #salt
15:59 iggy Jellyfrog: I did not install from pip, I did the git clone, etc. steps
16:02 whitenite joined #salt
16:02 Jellyfrog that works a lot better iggy
16:03 perfectsine joined #salt
16:03 dustinrc joined #salt
16:04 ze- damn. Exception AttributeError: "'NoneType' object has no attribute 'LINGER'" in <bound method SREQ.__del__ of <salt.payload.SREQ object at 0x34aad10>> ignored
16:04 ingwaem` joined #salt
16:05 ze- anyone has seen that? my module seems to work, but I get that message at the end of my salt-call ...
16:06 bra1nout joined #salt
16:07 pipps joined #salt
16:08 jergerber joined #salt
16:10 Supermathie So when we fire events to minions, we're actually just submitting a job to each minion to fire the event at itself?
16:13 gmoro joined #salt
16:14 to_json joined #salt
16:15 troyready joined #salt
16:15 felskrone joined #salt
16:18 to_json joined #salt
16:19 thayne joined #salt
16:21 ramishra joined #salt
16:22 fannet joined #salt
16:23 felskrone joined #salt
16:26 elfixit joined #salt
16:27 Supermathie What's the right way to actually listen for events in jobs on minions? The code I tried worked on Windows but not on Linux
16:28 Supermathie salt.utils.event.MinionEvent(sock_dir='/var/run/salt/minion')
16:29 nrb1 joined #salt
16:30 jgelens joined #salt
16:31 nrb1 saltstack's documentation on the mysql returner has the DB connection entered in plain text in the config files. Is there a way to hide this more?
16:33 KyleG joined #salt
16:33 KyleG joined #salt
16:33 iggy nrb1: put it in a file in master.d and lock down perms/mode
16:35 ndrei joined #salt
16:41 chayak joined #salt
16:42 Mso150 joined #salt
16:44 ndrei joined #salt
16:46 TheThing joined #salt
16:46 nrb1 ok
16:46 chayak left #salt
16:46 tld_wrk joined #salt
16:47 jgelens joined #salt
16:47 nrb1 iggy, do you then add the filename to some parameter in the config file?
16:47 tomspur_ joined #salt
16:48 vbabiy joined #salt
16:50 perfectsine joined #salt
16:53 pdayton joined #salt
16:55 teepark joined #salt
16:59 perfectsine_ joined #salt
17:00 rypeck joined #salt
17:01 BrendanGilmore joined #salt
17:01 schimmy joined #salt
17:02 obimod joined #salt
17:03 schimmy1 joined #salt
17:05 Ryan_Lane joined #salt
17:05 ingwaem` joined #salt
17:06 jgelens joined #salt
17:08 iggy nrb1: everything in /etc/salt/master.d is included by default
17:08 ingwaem`` joined #salt
17:08 notpeter_ joined #salt
17:11 nrb1 thanks
17:12 Pork__ joined #salt
17:14 Pork__ Hey, anyone able to get salt-virt working on an Ubuntu minion? Seems like the VM is being seeded, but the the hypervisor is unable to find the VM
17:14 Pork__ Digging through the code on Github, but I cant find the source of the error message "ERROR: The specified vm is not present"
17:17 SheetiS joined #salt
17:18 thedodd joined #salt
17:19 deepz88 joined #salt
17:20 jgelens joined #salt
17:20 mike25de joined #salt
17:20 forrest joined #salt
17:21 Supermathie hmmmm.... in a minion job, how do I find the current job id?
17:21 jhulten joined #salt
17:22 jergerber joined #salt
17:23 jngd joined #salt
17:25 tafa2 joined #salt
17:27 spookah joined #salt
17:27 calvinh joined #salt
17:28 cpowell joined #salt
17:29 jgelens joined #salt
17:30 unpaidbill I've seen it mentioned that using salt returners instead of the job-cache 'loses salts encryption'.  Is this accurate and what does it mean?  The job-cache files on my master are not encrypted and I don't see any option for encrypting them in the master config.  Thanks
17:35 Setsuna666 unpaidbill: From what I understand, returners are a way to return information with different protocol than the one used by Salt, so for exemple if you use SMTP to return information, it could be return un-encrypted
17:36 aw110f joined #salt
17:37 unpaidbill Oh I think I understand now, the returners are executed on the minion, not the master?
17:38 unpaidbill or is the data sent minion -> master encrypted, then the returner needs to be responsible for encrypting the data to whatever storage mechanism it uses
17:38 Setsuna666 unpaidbill: As far as I know, it is executed on the minion
17:38 unpaidbill ok, thanks
17:39 unpaidbill i'll have to play around with it a little but that explains some - as long as the returner employs encryption of some kind then there's no increased risk of leaking information over the network
17:39 unpaidbill assuming it's as strong as the encryption salt is using, anyway
17:40 UtahDave unpaidbill: Yeah, Setsuna666 is right. With a returner, the minion itself sends the return data to whatever database you specify
17:41 * robawt highfives UtahDave
17:41 UtahDave In the next release there will be a master job cache, where the returns go back to the master through the normal zmq channel, and then the master sticks that data in the database
17:41 UtahDave Hey, robawt!
17:42 robawt UtahDave: when are you guys doing that LA training thinger?
17:42 baconbeckons joined #salt
17:42 unpaidbill utahdave - cool, i was looing at salt-eventsd for that type of functionality but if it's going in to the next release i'll hold off.
17:43 KyleG joined #salt
17:43 KyleG joined #salt
17:43 UtahDave salt-eventsd is pretty awesome, too.
17:43 davidone joined #salt
17:43 UtahDave robawt: Hm. I think we just did a training in LA. Let me look at the schedule
17:44 robawt wuuut?  then I missed it :(
17:44 unpaidbill yeah it's good but i'd rather use something that i dont have to think about during upgrades :)
17:50 UtahDave Looks like the next training is here in Salt Lake on the 20th.
17:50 UtahDave robawt: Yeah, I think whiteinge taught a class in LA just a few weeks ago
17:51 UtahDave robawt: Make sure to sign up for SaltConf, too! http://saltconf.com/
17:51 robawt aw bummer
17:51 kusams joined #salt
17:52 Setsuna666 UtahDave: Will SaltConf be live streamed ?
17:52 primechuck joined #salt
17:52 UtahDave Setsuna666: I'm not sure. I think some of the talks were recorded last year, but I'm not sure what the plans are for that for this year.
17:53 robawt i was hoping to get emailed about the LA training, must have been a corporatey thing :(
17:54 ndrei joined #salt
17:58 kusams joined #salt
17:58 UtahDave Yeah, sorry about that. It would have been awesome to have you there.
17:59 robawt eh, next time
18:00 robawt we have a handful of folks interested in training here ;)
18:00 fannet hey guys - all of a sudden this morning when launching GCE instances I’m getting “ * ERROR: salt-minion was not found running” during the bootstrap
18:01 murrdoc joined #salt
18:01 UtahDave robawt: cool.
18:01 kusams joined #salt
18:01 primechuck Is the RPM build scripted enough that is as easy as rpmbuild -ba salt/pkg/rpm/salt.spec or do I really need to modify spec file with versions and paths, etc, etc
18:02 UtahDave fannet: what version of Salt?  Was there any changes to Salt since it stopped working?
18:02 fannet some of my minions are using the same name as before - is it possible salt-cloud -d didn’t properly clean up the old minion IDs and keys?
18:03 UtahDave primechuck: I'm not sure. I haven't done an rpm build myself in quite a while
18:03 fannet UtahDave - 2014.1.11
18:04 UtahDave fannet: salt-cloud is usually pretty good about removing IDs and keys. That error sounds like the new vm doesn't have salt-minion running.
18:05 repl1cant joined #salt
18:05 thedodd joined #salt
18:06 fannet cleared the cache and restarted the master and trying again - will post the log in a pastebin
18:06 UtahDave cool
18:06 hobakill what's the haps UtahDave ?
18:07 hobakill any word on when 2014.1.11 will get out of EPEL testing?
18:09 UtahDave hey, hobakill.    Soon...     :)
18:09 jgelens joined #salt
18:09 hobakill UtahDave: gracias....! karma that thing up
18:10 UtahDave :) definitely
18:10 SheetiS Soon™
18:10 SheetiS :D
18:11 apergos I'm looking at salt/keys.py and wondering what the difference is between "managed keys" and "local keys" as I read the code
18:11 higgs001 joined #salt
18:11 intellix joined #salt
18:12 apergos i.e. there is 'list_keys' which lists 'managed' keys and there is 'local_keys' which lists the 'local' keys
18:13 UtahDave apergos: based off the contents of the local_keys() function, I'm guessing that local keys are the master's private/public keys
18:14 UtahDave but I'm not 100% sure. I haven't worked on that code at all
18:15 druonysus joined #salt
18:15 apergos ok, I can always dump some of the returns and see when it's called and what it gives back
18:15 apergos thanks
18:15 shookees joined #salt
18:15 shookees joined #salt
18:16 UtahDave you're welcome
18:16 aranhoide joined #salt
18:22 calvinh joined #salt
18:22 clone1018_ joined #salt
18:23 iondrip joined #salt
18:24 vbabiy joined #salt
18:30 perfectsine joined #salt
18:32 gildegoma joined #salt
18:32 mgw joined #salt
18:33 mgw I'm having an issue with minions losing contact with master, seemingly during a call to saltutil.refresh_pillar
18:33 mgw I'm running 2014.7 branch from about a month ago
18:33 mgw I can and probably should upgrade, but has anyone seen this?
18:34 jslatts joined #salt
18:34 babilen What do you mean by losing contact? Will they not react to anything from the afterwards or "just" nor return from the refresh_pillar call? What do you see in the minion's debug log?
18:34 babilen (and yeah, does that happen with current HEAD too? are you using raet? ...)
18:35 ramishra joined #salt
18:36 Ahlee apergos: might also be the difference between accepted (managed) and present (local)
18:36 forrest joined #salt
18:36 mgw manage.down shows them down
18:36 mgw so no test.ping
18:36 mgw babilen: ^
18:37 mgw no raet
18:37 mgw I'm building a deb from current 2014.7 now to deploy
18:37 babilen ack
18:38 mordonez joined #salt
18:40 pipps joined #salt
18:42 tomspur_ joined #salt
18:43 Emantor joined #salt
18:43 saurabhs joined #salt
18:45 diegows joined #salt
18:46 kusams joined #salt
18:47 primechuck Looks like it isn't that easy :(
18:47 faust joined #salt
18:50 murrdoc joined #salt
18:51 tafa2 joined #salt
18:53 ilbot3 joined #salt
18:53 Topic for #salt is now Welcome to #salt | 2014.1.10 is the latest | Help us test the 2014.7 RC! http://bit.ly/salt-rc | Please be patient when asking questions as we are volunteers and may not have immediate answers | Channel logs are available at http://irclog.perlgeek.de/salt/
18:54 younqcass joined #salt
18:58 tld_wrk joined #salt
18:58 vbabiy joined #salt
19:01 jalaziz joined #salt
19:02 kballou joined #salt
19:03 mechanicalduck_ joined #salt
19:03 Mso150_x joined #salt
19:04 rallytime joined #salt
19:07 Emantor joined #salt
19:08 jsm joined #salt
19:09 pipps joined #salt
19:12 ckao joined #salt
19:14 hasues joined #salt
19:15 hasues joined #salt
19:15 hasues What is a good way of testing salt-cloud?  Just running the command?
19:16 kusams joined #salt
19:16 hasues Because, I get an error concerning a provider.
19:17 cpowell hasues: you can do test=True
19:17 cpowell nm, thats for salt-cloud
19:17 cpowell disregard
19:17 hasues Well, I was talking about salt-cloud?
19:19 hasues So I'm trying to communicate with vSphere.  Maybe I need python-vsphere/PySphere.
19:19 hasues Just looking for the package that provides it.
19:19 murrdoc joined #salt
19:20 bhosmer_ joined #salt
19:22 iggy hasues: pip install pysphere
19:23 hasues iggy: Ah, I ended up grabbing python-psphere, but I'll make a note.
19:23 cberndt joined #salt
19:23 babilen hasues: There is *nothing* wrong with using a packaged version of the library
19:23 iggy as long as it's a high enough version
19:24 iggy (and the libcloud docs don't say anything about a minimum required version, so you should be fine)
19:24 hasues babilen: I typically would use something like pip to do it via the language's system due to versioning, but yeah.
19:24 hasues Historically, using packaged versions of libraries vs using those provided gets me in trouble in Ruby, anyway.
19:24 babilen I only use pip in virtualenvs
19:25 hasues 'vsphere.get_configured_provider()' could not be found. Removing it from the available providers list
19:25 babilen And I have rarely, if ever, had problems with the Python modules that are packaged in Debian
19:25 babilen hasues: The question is: Which vSphere module does it require? psphere of pysphere?
19:26 hasues babilen: aren't they the same?
19:26 iggy libcloud says pysphere
19:26 babilen hasues: No, they aren't.
19:26 pdayton joined #salt
19:26 hasues Hm, let me back out the package then.
19:27 mpanetta I think I found a bug in orchestration...
19:27 jsm joined #salt
19:27 babilen https://pypi.python.org/pypi/pysphere vs https://pypi.python.org/pypi/psphere
19:27 iggy pysphere looks much more complete
19:27 mpanetta If the orchestration runner runs a state on the minion that causes it to go away, the next state says it succeds
19:27 jalaziz joined #salt
19:28 iggy mpanetta: define "causes it to go away"
19:28 Emantor joined #salt
19:29 babilen Ryan_Lane: ping
19:30 Ryan_Lane babilen: howdy
19:30 babilen \o/
19:32 babilen Ryan_Lane: I've had the pleasure of using the pecl module/states today and saw that it is was you that implemented the channel support. Unfortunately it doesn't really work well if you are trying to install from channels that have not been discovered and I wanted to ask you about your assumptions when you written that.
19:32 Ryan_Lane hm
19:32 Ryan_Lane I think I had autodiscover enabled
19:33 Ryan_Lane I stopped using pear like a week after I wrote that
19:33 babilen Ryan_Lane: In particular the lines.pop(0) in there doesn't work if a channel has not been added at all (throws an exception) and one also cannot use the pecl state for pear.
19:33 Ryan_Lane yeah, you need to discover the channel before the state runs
19:33 Ryan_Lane just add a cmd.run state above it :)
19:34 Ryan_Lane and use an unless that checks to see if it's been discovered already
19:34 babilen Ryan_Lane: Yes, I would have liked to use pear right now too and I have a PR almost ready, just thought I discuss the design decisions with you for a second. First I'd like to switch between the "pear" and "pecl" command if the channel is "pear" (that would make it necessary to specify the channel for pear stuff though)
19:34 Ryan_Lane that would be something useful to add to the state
19:34 Ryan_Lane but really, pear is dead
19:34 babilen I know
19:34 babilen Customer uses it and I can't be arsed to not use salt :)
19:35 Ryan_Lane ah
19:35 Ryan_Lane the biggest thing to consider is backwards compatibility
19:35 Ryan_Lane otherwise, you probably have pretty free reign
19:36 Ryan_Lane you could also just add a pear state/module
19:36 Ryan_Lane which means you don't need to care about backwards compat
19:36 babilen Okay, I assumed that you had auto_discover enabled, because it just fails miserably if you don't.
19:36 Ryan_Lane yeah. i did
19:36 Ryan_Lane back in a bit. lunch
19:36 babilen Ryan_Lane: That is how I implemented it right now (the auto_discover thing should still be fixed though)
19:37 Supermathie unghghhg. Is there a way to open the push/pull event sockets from the minion so it opens them once and leaves them open? I'm switching users in a minion job and from then on I can't receive/publish events.
19:37 babilen Ryan_Lane: That was more or less it anyway, enjoy lunch :)
19:38 Supermathie event = salt.utils.event.MinionEvent(**__opts__), then switch user, then can no longer use 'event' ;(
19:42 pipps_ joined #salt
19:42 jsm joined #salt
19:43 jeffspeff setting "refresh: True" in the pkg details in a state file should cause the minion to do the equivelant of pkg.refresh_db before running the package right?
19:43 martoss joined #salt
19:45 forrest Has anyone else been seeing EPEL metadata retrieval errors when bootstrapping? Works fine when you change epel to use HTTP, but fails completely on HTTPS
19:46 Supermathie jeffspeff, yeah that's
19:46 Supermathie jeffspeff, yeah that's what I've done, pretty sure it works :)
19:46 pwf joined #salt
19:47 pwf how can i specify multiple patterns on my target for remote execution?
19:47 rap424 joined #salt
19:47 jeffspeff Supermathie, I'm noticing that it's not working on windows minions (the only minions i have)
19:47 pwf like "salt 'some-machine-* OR other-machine-*' cmd.run 'ls'"
19:48 jeffspeff Supermathie, i saw an example in a forum where someone put "refresh: True" in the init.sls file for the winrepo package. but I haven't seen that documented anywhere. Are both needed?
19:48 iggy pwf: salt -C 'foo or bar' func
19:48 iggy i.e. compound matcher
19:48 iggy very powerful
19:48 pwf ty
19:49 iggy also very dangerous....
19:49 iggy I know I've seen it somewhere, how do you a watch/watch_in on something that's in a different state?
19:50 Supermathie jeffspeff, yeah refresh=True should do it (looking at the source) but I haven't played around with *any* win repos.
19:50 pwf yeah, i run an ls before i run my actual command, to make sure all the machines i meant to match return
19:50 babilen iggy: You *always* watch a different state
19:50 iggy different state file?
19:50 babilen iggy: But if you mean SLS file then include it and off you go.
19:50 iggy I can't include it
19:50 bhosmer_ joined #salt
19:51 iggy I mean I supposed I could, but it would be redundant
19:51 Supermathie jeffspeff, run with debug on?
19:51 pdayton1 joined #salt
19:51 pipps joined #salt
19:51 Supermathie iggy, sounds like a question someone asked recently about watching for the presence of /dev/ipmi0 to install a package
19:52 babilen iggy: Well, it allows you to define requirements on states defined in there. Why is doing so problematic?
19:52 winmutt ive got some pretty ugly escaping going on thanks to jinja
19:52 winmutt multiline problems
19:52 babilen winmutt: Write the state/pillar in Python? But just paste it somewhere (e.g. http://refheap.com ) so that we know what you refer to
19:53 wnkz_ joined #salt
19:53 winmutt its a multiline pillar value that gets templated out in an state
19:53 jeffspeff Supermathie, does it matter the order of the refresh in the state file? are single quotes needed? here's my state file http://pastebin.com/17Rn7H23 and here's the packages init.sls http://pastebin.com/h2txSgtq
19:53 winmutt well ive reverted it all do to an array and iterate over them
19:54 iggy I'm using the salt-formula, but I want to add some extra stuff to the config without hacking up the salt-formula any further (for now at least) the formula gets included elsewhere, I don't want to include it again (is that even safe?)
19:54 ramishra joined #salt
19:55 XenophonF joined #salt
19:55 XenophonF howdy yall
19:55 XenophonF so some setting changes require rebooting the minion
19:55 Supermathie jeffspeff, no idea honestly, but I'd highly recommend running the minion in debug mode and watching the output to help figure this out
19:55 Ahlee Thoughts on a way to disable the source_hash on file.managed http repos?
19:56 XenophonF like, after disabling SSL 3.0 in the Windows registry settings for SCHANNEL.DLL
19:56 XenophonF so my question is, how do I schedule a reboot for the _end_ of the highstate run?
19:56 jeffspeff Supermathie, would that make the output in my master console or would that be in the logs on the minion?
19:56 Ahlee er, sorry, not repos there.  Should I just patch it out and ship an updatd file.py state to all minions?
19:57 ajolo_ joined #salt
19:57 vbabiy joined #salt
19:57 Supermathie jeffspeff, in the logs in the minion. (Get-Content -Wait -Tail 10 /path/to/minion/log). Or, stop the service and run it by hand (salt-minion -l debug)
19:57 babilen iggy: You can include things as often as you like.
19:58 Pork__ Has anyone been able to get salt-virt working on an Ubuntu minion?
19:58 jeffspeff Supermathie, thanks
19:58 Pork__ I've been on this one all day
19:58 babilen iggy: requirements simply change the *order* of states and some of them will trigger state runs under certain circumstances (e.g. the prereq one)
19:59 iggy it just seems like what I want to do should be possible
19:59 XenophonF perhaps having salt reboot a minion is a bad idea
19:59 TheRealBill_here joined #salt
19:59 Ahlee XenophonF: yeah, but sometimes necessary.
20:00 scoates is this the proper way to get 2014.7 via bootstrap? `sudo sh ./install_salt.sh git 2014.7` ? mine ends in error
20:00 iggy I don't see anything in the docs that says you have to put everything you want to watch/require/use/prereq/onchanges/etc all in the same file (or otherwise include)
20:00 Ahlee XenophonF: I cmd.run at now+1min reboot - order: last
20:00 Ahlee when applying a firmware to disable hyperthreading
20:00 scoates ah v2014.7.0rc3
20:00 babilen iggy: You don't have to do that. You simply have to include it (why don't you try it?)
20:01 XenophonF ah order last!
20:01 XenophonF awesome
20:01 Ahlee XenophonF: yeah, http://docs.saltstack.com/en/latest/ref/states/ordering.html
20:01 iggy I don't want to... don't ask me why
20:01 Ahlee XenophonF: you might want to look into a custom runner though that interfaces with the servers IPMI/management interface/etc
20:02 perfectsine joined #salt
20:02 iggy doing that just seems like it's asking for some sort of circular dependency that I'll end up having to track down later
20:03 aparsons_ joined #salt
20:03 XenophonF Ahlee: can you point me toward any examples?
20:03 XenophonF Also, does salt have a platform-agnostic reboot function?
20:03 XenophonF I want to be able to do this on more than just Linux.
20:03 XenophonF but i can work around easily enough with a filter_by map
20:04 scoates XenophonF: system.reboot
20:04 jslatts joined #salt
20:04 XenophonF awesome
20:04 XenophonF thanks scoates!
20:04 babilen XenophonF: http://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.system.html#salt.modules.system.reboot
20:04 XenophonF and thanks babilen
20:04 babilen Ah .. shouldn't have gone for the doc :)
20:04 XenophonF no docs are good
20:04 scoates heh good but SLOW
20:04 scoates (-;
20:04 babilen indeed
20:04 * babilen chuckles
20:04 XenophonF i like being told to rtfm as long as the manual is truly fine :)
20:05 babilen Navigating the salt documentation is getting rather tricky. I often run into "I am sure I read that somewhere. If only I could find it again!" moments
20:06 XenophonF if i had a complaint, it is that the table of contents doesn't go deep enough
20:06 ekristen joined #salt
20:07 XenophonF although i don't know how one would expand the TOC without making it really overwhelming to navigate
20:08 Ryan_Lane my main complaint is that documentation for similar topics is spread across multiple topics
20:08 babilen ^ this
20:08 Ryan_Lane and that the docs are basically 100% written for master/minion
20:09 scoates FWIW, I almost exclusively just use google to find stuff in the salt docs
20:09 Supermathie Ryan_Lane, certain things are really hard to find, agreed. We could really use a number of 'walkthrough' kind of tutorials for common use cases.
20:09 ecdhe Ryan_Lane, were you affected by the issue of pillar not loading on masterless?
20:09 Supermathie That and documentation for a lot of the functions - I have no idea what's even available most of the time without some sort of introspection or source diving.
20:10 Ryan_Lane ecdhe: nope
20:10 Ryan_Lane I maintain my own versions
20:10 ecdhe Wise man.
20:10 Ryan_Lane I create frozen pip venvs via a forked clone
20:11 Ryan_Lane and maintain my own branch
20:11 Ryan_Lane which right now is just the 2014.7 branch renamed as "stable"
20:11 winmutt babilen: template--
20:11 winmutt {%  for location, rules in site.locations.iteritems() %}
20:11 winmutt location {{ location }} {
20:11 winmutt {{ rules }}
20:11 winmutt }
20:11 winmutt joined #salt
20:11 winmutt that was the wrong buffer :(
20:12 ecdhe Ryan_Lane, that's a good call, makes a lot of sense for production.
20:12 XenophonF it seems like a lot of people run salt masterless
20:12 XenophonF why is that?
20:12 to_json joined #salt
20:12 iggy vagrant
20:12 iggy 80%
20:12 XenophonF what's vagrant?
20:12 XenophonF nvm i'll google it
20:12 ecdhe XenophonF, vagrant, my personal laptop, my work desktop, etc.
20:12 winmutt https://www.refheap.com/6bd676a633f8e3dcc832363c8A
20:12 winmutt there we go
20:12 Ryan_Lane ecdhe: I use it for every environment, and can change it per environment :)
20:13 winmutt work on a mac all day and come home to linux boxen with multiple buffers and better keys
20:13 forrest_ joined #salt
20:13 XenophonF interesting
20:13 ecdhe Ryan_Lane, if I ever need a salt engineer, I'll hire you.
20:14 Ryan_Lane :D
20:15 Ahlee I hear ya there Ryan_Lane, though mine is a fork off of 0.17.5 ;)
20:15 Ahlee i do'nt need your steenking bug fixes
20:15 * Ryan_Lane twitches
20:17 Ahlee so what will go wrong when I run this state to run file.managed to replace file.py state
20:17 Ahlee theories?
20:18 iggy black hole?
20:19 forrest didn't Ryan_Lane tell you he's working as a contractor on the side, for MILLIONS OF DOLLARS
20:19 phblj joined #salt
20:19 Ryan_Lane :D
20:19 Ryan_Lane I am allowed to consult
20:20 Ryan_Lane I just don't have any time for it
20:22 Pork__ Hmm
20:22 Pork__ If I'm distributing an image with salt-virt, does it need to be in qcow2 format?
20:23 Ahlee forrest: educate me: https://groups.google.com/forum/#!topic/salt-users/ZBYIY6FG00s
20:24 gyre007_ joined #salt
20:24 shookees joined #salt
20:24 che-arne joined #salt
20:25 winmutt babilen: and now i got it working lol
20:25 winmutt amazing what the next day can bring
20:25 babilen even better
20:25 winmutt maybe a bit of sobriety has something to do with it
20:25 winmutt :)
20:26 iggy why are tech people such huge booze hounds?
20:26 apergos we are?
20:26 babilen slainte!
20:26 * apergos always goes for the milk instead of the booze
20:27 jeffspeff iggy, because we think the people who don't understand what we consider simple to be stupid, and it takes a lot of alcohol to drown out the stupid
20:27 iggy I didn't say everybody is
20:28 XenophonF speaking of,
20:28 XenophonF it's close enough to five, so i'm outta here and into my cups
20:28 XenophonF ttyl!
20:28 gyre007_ joined #salt
20:29 kusams joined #salt
20:30 jeffspeff can anybody show me an example of http://docs.saltstack.com/en/latest/ref/states/all/salt.states.pkg.html#salt.states.pkg.uptodate  in a state file? it's not working for me
20:30 cpowell New in version 2014.7.0.
20:31 cpowell what version are you using...
20:31 cpowell 2014.7.0 hasn't been released yet, I believe
20:31 jeffspeff i'm using 2014.1.10
20:31 jeffspeff ugh
20:32 babilen jeffspeff: I would recommend to perform system upgrades manually (via salt) and not as part of the highstate
20:32 babilen (but that depends on your requirements)
20:33 jeffspeff babilen, i'm not trying to upgrade, i'm trying to install packages. setting "refresh: True" is not actually refreshing the repo cache
20:33 cpowell it should install the newest pkg if you don't define a version
20:33 jeffspeff cpowell, it needs to refresh the repo cache first to know what the latest versions are
20:35 jeffspeff babilen, here's the package file http://pastebin.com/KP5KwZLN and here's the state file http://pastebin.com/Xwpm3WHR
20:35 cpowell hmm, the refresh: True should do the trick
20:35 Supermathie everybody keeps saying 'should' :D
20:36 jeffspeff if i manually run "salt minion-name pkg.refresh_db" then run the highstate, it works fine
20:36 cpowell its Windoze?
20:36 jeffspeff yup
20:36 rhand joined #salt
20:36 mpanetta iggy: "acuses it to go away" in this case means a FW rule change that kills the connection from minion to master for a few minutes. (No idea why yet)
20:36 cpowell there's the problem, salt's pkg is doing a repo update, so its looking for a linux pkg mangager
20:37 jeffspeff cpowell, salt has a winrepo module
20:37 jeffspeff that's what i'm using
20:37 cpowell Currently, this option is supported for the following pkg providers: apt, ebuild, pacman, yumpkg, and zypper.
20:37 cpowell i am not familar with winrepo...sry
20:37 jeffspeff cpowell, which option were you just referring to?
20:38 cpowell http://docs.saltstack.com/en/latest/ref/states/all/salt.states.pkg.html#salt.states.pkg.installed
20:38 cpowell the version option
20:39 cpowell http://docs.saltstack.com/en/latest/topics/windows/windows-package-manager.html
20:39 jeffspeff cpowell, i'm not using the version option of pkg.installed
20:39 cpowell each windows machine needs to have pkg.refresh_db executed against it to pick up the latest version of the package database.
20:40 SheetiS jeffspeff: do you have '- refresh: True' defined on the packages state?
20:40 SheetiS That should tell the underlying package manager to try and refresh.
20:40 jeffspeff SheetiS, ye
20:41 jeffspeff SheetiS, here's the package file http://pastebin.com/KP5KwZLN and here's the state file http://pastebin.com/Xwpm3WHR
20:41 pipps joined #salt
20:42 scoates is there an "upgrading to 2014.7" guide somewhere? looks like "." is no longer allowed in e.g. `/foo: mount.unmounted` ?
20:43 scoates I guess the dot is not the actual problem (that's just the error message…)
20:43 SheetiS jeffspeff:  well you could try and work around it by doing something like this: {% do salt['pkg.refresh_db']() %} in the jinja.  If that doesn't work it might need it's output stored in a variable like this {% set output = salt['pkg.refresh_db']() %}
20:45 SheetiS If that state is also applied in some fashion to non-windows systems, you may need to wrap that in an if statement that checks for the os_family grain or something.
20:45 jeffspeff SheetiS, that worked like a charm! THANK YOU!!!!
20:46 jeffspeff i set {% do salt['pkg.refresh_db']() %} as the first line in the state file, did a highstate and it returned properly
20:46 SheetiS jeffspeff: glad to help, but that might still be a bug with the winrepo pkg module and pkg state that it doesn't respond to refresh: True, so it might be worth looking into further
20:46 SheetiS I haven't looked at the code to see how they interact
20:46 deepz88 joined #salt
20:46 SheetiS (I'm in os_family RedHat most of the time)
20:47 SheetiS so all of my pkg stuff goes through the yum pkg module.
20:47 scoates this is a working state in pre-2014, but fails with "Invalid requisite type 'mount.unmounted' in state '/dev/sda5', in SLS 'fk.dev'. Requisite types must not contain dots, did you mean 'mount'?" in 2014.7. Any ideas?
20:47 scoates -> http://paste.roguecoders.com/p/6ffc7654fd500b521519b84229110ed3.txt
20:47 jeffspeff SheetiS, ok, i'll get this done and to a stopping point, then set up a test vm to replicate the issue and file a bug report
20:49 jalaziz joined #salt
20:49 iggy scoates: aside from the indentation looking off, it looks fine
20:49 iggy is that _all_ of that file?
20:49 perfectsine joined #salt
20:49 scoates no
20:49 scoates ahhhh
20:49 SheetiS It says state '/dev/sda5'
20:50 scoates thanks. that was dumb of me (-:
20:50 scoates iggy: thanks
20:50 iggy yeah, couldn't tell if that was just a paste mistake or how it was
20:50 scoates SheetiS: yep. it was there. thanks.
20:51 scoates fwiw, I had: `require: - mount.mounted: /swapfile` ; changed to `require: - mount: /swapfile`
20:51 iggy ahh
20:51 SheetiS Figured it was in a requisite ;-)
20:52 iggy easy fixes are great
20:52 SheetiS :D
20:53 hasues joined #salt
20:53 scoates is there a way for me to make `file`'s `makedirs` globally true? (I have a bunch of places where it assumes it's true in my old states)
20:53 scoates or perhaps I should just not do that for some reason, I guess
20:54 glyf joined #salt
20:55 ramishra joined #salt
20:55 forrest Ahlee: seems like a cool idea, I don't have an answer to your question though :P
20:56 pipps joined #salt
20:56 hasues Is the vsphere cloud driver released for salt-cloud or not?
20:56 Ahlee curses.
20:57 Ahlee This just feels so brittle
20:58 Ahlee i just want to do something where I'm surprised when it breaks, not surprised every time it works
20:58 SheetiS Ahlee: what's brittle?
20:59 Ahlee SheetiS: this system i'm developing
20:59 unpaidbill brittle in the middle gotta take a step back
20:59 unpaidbill sir mix a lots guide to states
21:00 iggy I laughed a little more than I feel I should have
21:00 SheetiS :D
21:00 hasues joined #salt
21:01 hasues joined #salt
21:01 vbabiy joined #salt
21:02 UtahDave hasues: yes, vsphere is included with salt-cloud
21:02 hasues UtahDave: Thanks, I'm having an issue, and so far the results I pulled up from searches were people not realizing that the driver was only in development.
21:03 UtahDave what version are you on?
21:03 aparsons joined #salt
21:03 hasues UtahDave: Hydrogen
21:05 UtahDave .11?
21:05 Jellyfrog is there any big cons using salt-ssh? (except for the performance one)
21:05 hasues .10
21:05 Jellyfrog looking at a new setup, not sure which way to go
21:05 iggy Jellyfrog: yeah, it has some limitations
21:05 Jellyfrog most seem taken care of?
21:06 Jellyfrog in the rc
21:06 UtahDave hasues: actually, it looks like it isn't in Hydrogen.  It's included starting in Helium.  2014.7  branch
21:06 UtahDave Jellyfrog: yeah, salt-ssh has been really improved in the RC
21:07 iggy Jellyfrog: targeting is one of the big ones for me, but maybe different for some
21:10 hasues UtahDave: Okay, cool.  So rather than using install_salt.sh, I should instead be using git to fetch salt?
21:10 UtahDave hasues: the bootstrap script can install a specific version from git for you.
21:11 Jellyfrog salt-ssh + agent forward + pam ssh agent seems like a nice way to go
21:13 floWenoL joined #salt
21:14 iggy we use grain and mine data heavily in our states... I wonder if salt-ssh allows that
21:15 iggy (I would think no)
21:16 UtahDave grains, yes.  Let me ask about the mine.
21:18 manfred i do not believe it allows the mine
21:18 manfred because there isn't something reporting the data back to the master…
21:18 manfred since there isn't really a master
21:18 manfred the only thing that opens back up once the connections is made, is a zeromq instance, but that is only for events from what I saw yesterday while digging
21:19 hasues UtahDave: It looks a bit better now.  Thank you again for your help.  I'll diagnose more tomorrow.
21:20 UtahDave yeah, it doesn't work currently, but we do plan on having it working at some point not too terribly far in the future
21:20 UtahDave hasues: cool!
21:20 DaveQB joined #salt
21:21 TheThing joined #salt
21:21 perfectsine joined #salt
21:22 viq joined #salt
21:23 micah_chatt joined #salt
21:28 jgelens joined #salt
21:28 iggy UtahDave: re: doesn't work currently... mine? or where you talking to someone else?
21:29 whitenite joined #salt
21:29 UtahDave iggy: Yeah, sorry.  The mine currently doesn't work with salt-ssh, but we plan on implementing it.
21:31 iggy good to know, not that we are looking to move to it, but I can at least throw that in people's faces
21:32 jalaziz joined #salt
21:32 UtahDave :)
21:32 UtahDave It's a great option to have.
21:33 iggy I'm sure it's useful for some people
21:36 peters-tx joined #salt
21:36 cads joined #salt
21:37 vbabiy joined #salt
21:37 nitti_ joined #salt
21:38 PI-Lloyd joined #salt
21:39 TheThing joined #salt
21:39 skyler I am using gitfs. When I make uncommitted changes to that repository, should those changes affect what happens when I run the state?
21:40 iggy like you make changes locally, don't commit them, and you're asking if they somehow make it into salt?
21:41 PI-Lloyd evening. Working on a side project, using the develop branch of salt due to the digital ocean api changes, running into " Failed to get the output of 'digital_ocean.avail_images()': 'name'" when running "salt-cloud --list-images do" - anyone have any ideas on how to fix?
21:42 PI-Lloyd all other salt-cloud --list- commands work fine, just when i try to get the avail images, or when I try to spin up a new system.... always comes back with this 'name' rubbish for the image
21:42 cheus Justi curious: is anyone using Salt with Docker? I keep trying to understand what Docker buys me but am having a hard time seeing something it can do that I'm not already capable of doing through orchestration. Am I missing something?
21:42 UtahDave PI-Lloyd: can you try running the command with   -l debug appended to it?
21:43 TheRealBill_he-1 joined #salt
21:43 kusams joined #salt
21:44 PI-Lloyd UtahDave: https://bpaste.net/show/32e6be4facb9
21:47 thedodd joined #salt
21:47 iggy cheus: we've all been there I'm sure... docker is great for spinning up servers that don't have much state and when things are in flux a lot (during development, etc)... it doesn't magically cure every devops problem that exists
21:48 UtahDave PI-Lloyd: can you pastebin a sanitized version of your digitalocean provider config?
21:48 PI-Lloyd sure one moment
21:49 cheus iggy, I keep running scenarios on the white board and it seems like the standard process is to do all source/config management on the docker host with orchestration (eg, salt). So if that's already happening there, it seems like docker's adding complexity and extra work unless I'm missing some part of the devops equation that it's doing better than full vm's managed by salt/formulas.
21:49 Jellyfrog its not a full vm..thats half the point :)
21:50 iggy here's the thing it took me a long time to figure out... docker isn't going to replace all of your infrastructure any time soon
21:50 iggy don't try to shoehorn everything into docker containers
21:50 iggy somethings work great in it
21:50 mechanicalduck joined #salt
21:51 iggy some don't
21:51 Jellyfrog https://blog.docker.com/2014/10/docker-microsoft-partner-distributed-applications/
21:51 Jellyfrog dont be so sure iggy :D
21:51 PI-Lloyd UtahDave: https://bpaste.net/show/f6f3e68e9659 pretty standard using the v2 api
21:51 Jellyfrog but no.. thats a good advice
21:51 iggy go through the tutorials, do some playing with it, then put it down
21:51 cheus Jellyfrog, Yep. I know that, but hardware isn't our issue, it's time/energy spent with config management and the devops pipeline.
21:51 iggy as you start working on your day to day stuff, you'll see ways you can leverage it
21:51 Jellyfrog its nice to run as a dev
21:52 Jellyfrog on a lappy
21:52 Jellyfrog i got one one container running salt-master and one running minion now for example
21:52 cheus iggy, Have done both. We've been discussing a pilot run and today was the first real planning day spent on how it would work and I kept running into this seeming fact that at the end of the day I'm still having to fully configure a host, perhaps not to serve the apps, but to manage all source and config files.
21:53 UtahDave ok, PI-Lloyd I'm going to test that on my system here as well, but I think this may be a bug.
21:53 UtahDave PI-Lloyd: would you mind opening an issue for this? Including all the info you've shared here?
21:53 PI-Lloyd UtahDave: it would certainly appear to be, or DO have changed their API again
21:53 PI-Lloyd sure no problem
21:54 cheus I've been happily using it in the Python course I teach for the uni where it's fantastic for building containers for unit/lint testing student-submitted work (especially the errant infinite loop)
21:54 skyler iggy: I suppose that doesn't makea lot of sense. It seemed like it made sense to me because the git repos are just folders on the local machine... But I suppose that makes no difference.
21:54 cheus But that's a real edge case.
21:54 UtahDave thanks, PI-Lloyd!
21:55 iggy cheus: so far I've been using it mostly for testing salt stuff and building packages
21:55 iggy so...
21:55 ramishra joined #salt
21:59 AmericanJuggalo In the instance where there is not a State for something, can I substitute the state with a shell command and a second shell command that "tests" the imposed state?
22:01 UtahDave AmericanJuggalo: sure
22:01 thayne joined #salt
22:01 nitti joined #salt
22:03 AmericanJuggalo UtahDave, Could you link to whatever doc page on this?
22:04 UtahDave so you'll want to look at the cmd.run state's docs here: http://docs.saltstack.com/en/latest/ref/states/all/salt.states.cmd.html#salt.states.cmd.run
22:05 AmericanJuggalo UtahDave, Okay cool I saw that but just wanted to be sure that was the right direction.  Thanks Dave!
22:05 UtahDave You'll probably want to look at 'onlyif', 'unless', 'creates' options
22:05 AmericanJuggalo awesome
22:05 PI-Lloyd UtahDave: issue submitted - https://github.com/saltstack/salt/issues/16696
22:06 UtahDave thanks, PI-Lloyd!  I'm setting up creds to test it right now, too
22:14 aparsons joined #salt
22:15 funzo joined #salt
22:17 deepz88 joined #salt
22:22 knot` joined #salt
22:23 higgs001 joined #salt
22:23 jalaziz joined #salt
22:25 dustinrc joined #salt
22:25 pfallenop joined #salt
22:25 sunkist joined #salt
22:26 sc` joined #salt
22:26 p2 joined #salt
22:27 AmericanJuggalo joined #salt
22:27 naegelin joined #salt
22:28 naegelin I have an issue with my master not properly accepting a minion which used to have the same name
22:28 FL1SK joined #salt
22:28 kaptk2 joined #salt
22:28 MatthewsFace joined #salt
22:28 mitsuhiko joined #salt
22:28 mitsuhiko joined #salt
22:29 kballou joined #salt
22:30 housl joined #salt
22:30 PI-Lloyd fannet: have you cleared the old minion key from the master's cache and restarted the master?
22:31 klj joined #salt
22:31 aparsons joined #salt
22:31 Emantor joined #salt
22:31 klj joined #salt
22:32 klj joined #salt
22:33 PI-Lloyd /etc/salt/pki/master/minions/<minion>/ and also the old key from /etc/salt/pki/master/minions/<minion>/
22:33 jslatts joined #salt
22:33 PI-Lloyd gah.... /var/cache/salt/master/minions/<minion>/
22:34 PI-Lloyd sry, it's late, i'm tired ;)
22:36 cberndt joined #salt
22:39 Rockj joined #salt
22:40 KyleG joined #salt
22:40 KyleG joined #salt
22:41 vbabiy joined #salt
22:47 ignarps joined #salt
22:48 seblu joined #salt
22:48 Nazzy joined #salt
22:48 whitenite joined #salt
22:49 cb joined #salt
22:49 Emantor joined #salt
22:52 elfixit joined #salt
22:55 pdr joined #salt
22:55 ntt joined #salt
22:55 fannet pi-lloyd ya I had to put the master in open-mode for it to clear the error
22:55 pdr left #salt
22:55 fannet PITA
22:56 ramishra joined #salt
22:57 ipmanx joined #salt
22:57 ipmanx hi - new to Salt - can I do remote admin from anywhere on a machine using Salt?  Or are my only options 1) change settings on the salt master, or 2) use salt-call locally on the machine itself?
22:58 __number5__ ipmanx: you can do salt command targeting any minion on salt master
22:59 __number5__ salt-call is mainly for masterless minion or debugging
23:00 ipmanx __number5__: so I would first log in to the master, then run salt from there... target machines instead of '*'
23:01 ipmanx if i was deploying a very small infrastructure with just one server, would i run both master & minion on same box, or would i be better off using masterless?
23:02 iggy I would run both on the same box
23:02 iggy it's easier to expand from that
23:03 __number5__ ipmanx: for learning masterless is more easy to understand. for the long run you'll want a master
23:03 iggy (and masterless has a few limitations)
23:04 scoates looks like http://docs.saltstack.com/en/latest/topics/releases/releasecandidate.html is out of date as of rc4 (-:
23:04 ipmanx ok thanks.  we're looking at ansible too.  does anybody have any thoughts on why salt is better?  :-)
23:05 iggy somebody wrote a blog... maybe ryandlane
23:05 ipmanx i read a bunch including a good one by the lyft guy
23:06 iggy specifically about salt vs ansible
23:06 ipmanx http://ryandlane.com/blog/2014/08/04/moving-away-from-puppet-saltstack-or-ansible/
23:06 ipmanx that one definitely made salt look better
23:07 Outlander joined #salt
23:07 mosen joined #salt
23:07 iggy that's the one
23:07 __number5__ ipmanx: if you only have one server forever, ansible probably the better choice
23:08 ipmanx i have several projects, some with many servers, some with just one... trying to get my head around limitations and best practices in general
23:08 TheRealBill_here joined #salt
23:09 ipmanx i set up vagrant to create a master & minion with preseeded keys and install a couple things on highstate, so i've got a good testbed going
23:10 ipmanx the git backend is interesting.  is that used commonly?  i assume ppl fork the repos and reference those.
23:10 mylungsarebad joined #salt
23:10 iggy we only use gitfs backend
23:10 iggy and yeah, for formulas, you want to fork your own copies
23:11 ipmanx nice.  i didn't totally grok how branches & envs should be used, but it looked like a neat concept
23:11 housl joined #salt
23:12 mgw joined #salt
23:12 __number5__ I'm still waiting gitfs remove the mandate environments-branches mapping..
23:13 mgw joined #salt
23:15 ipmanx don't like it?
23:17 rjc joined #salt
23:20 cb joined #salt
23:20 bhosmer joined #salt
23:22 __number5__ ipmanx: I would like different environments live in the same branch, much easier to keep them at same version
23:23 scoates yeah, that's why I don't use that, too
23:23 ipmanx so what do you guys use instead?
23:23 scoates hackery /-:
23:23 scoates __grains__['env'] set by the minion
23:23 __number5__ a hand-coding git state to do regular pull :D
23:24 jalaziz joined #salt
23:26 Jellyfrog ipmanx: that url isnt 100% valid
23:26 Jellyfrog salt-ssh could be used for "no masters"
23:27 pipps_ joined #salt
23:27 ipmanx Jellyfrog: i heard it's still sort of alpha, but maybe that's old news
23:27 Jellyfrog in rc
23:28 Jellyfrog http://docs.saltstack.com/en/latest/topics/releases/2014.7.0.html
23:30 bhosmer joined #salt
23:30 higgs001 joined #salt
23:32 yomilk joined #salt
23:34 aparsons_ joined #salt
23:36 bhosmer_ joined #salt
23:37 bocig joined #salt
23:38 bocig hey guys. I am hoping someone can be of help .I've setup a multimaster setup and keep getting failover disconnects. Handling event '__master_disconnected\n\n\x82\xa6_stamp\xba2014-10-16T16:34:16.065855\xa6master\xb
23:38 Emantor joined #salt
23:41 yomilk joined #salt
23:48 yomilk joined #salt
23:53 ipmanx Jellyfrog: when it's released, will salt-ssh be positioned as a viable means of doing ad hoc maangement?
23:53 pdayton joined #salt
23:54 Jellyfrog its another way of connecting, that dosent require minions or masters
23:54 kballou joined #salt
23:54 eunuchsocket joined #salt
23:54 juice joined #salt
23:54 pdayton2 joined #salt
23:55 dude051 joined #salt
23:55 __number5__ Jellyfrog: does salt-ssh copying salt states over?
23:55 ipmanx right, it seems like a big departure, and its lack is one of the arguments from some of my (pro-ansible) team against salt...  wondering how significant it will be in salt going forward
23:55 ipmanx i am the pro-salt guy, trying to get ammo :-)
23:56 dude051 joined #salt
23:56 Jellyfrog http://docs.saltstack.com/en/latest/topics/ssh/index.html
23:56 Jellyfrog explains a bit
23:56 Jellyfrog im far from expert
23:56 __number5__ ipmanx: last time I checked (when salt-ssh first came out) salt-ssh was a quick way to take over your existing infrastructure/bootstrap minions
23:57 ramishra joined #salt
23:57 higgs001 joined #salt
23:57 deepz88 joined #salt

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