Perl 6 - the future is here, just unevenly distributed

IRC log for #salt, 2015-07-28

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

All times shown according to UTC.

Time Nick Message
00:02 lompik joined #salt
00:03 lompik Hi, how do you pass "refresh: True" in the command line (to pkg.upgrade) ?
00:04 murrdoc refresh=True
00:06 furrowedbrow joined #salt
00:06 lompik Thanks !
00:14 holler joined #salt
00:15 holler hello, I am running into issue provisioning a previously working vagrant box that uses salt as provisioner..
00:15 holler Im getting "You need to allow pip based installations (-P) in order to install the python package 'tornado >= 4.0'"
00:15 geekatcmu It's a bug in the installer.
00:15 geekatcmu There's a patch, but it's not released.
00:15 holler if I google that a bunch of posts come up from within last few days.. anyone know a workaround? should I specify an older salt version in my Vagrantfile? (currently it uses "stable")
00:16 holler geekatcmu: I see, so that doesn't have to do with the actual salt version
00:16 geekatcmu I could say something about how smart it is to bootstrap your servers by getting a script off the innertubes and piping it to sh, but ... everyone but me seems to think it's really smart.
00:17 geekatcmu You can browse git and download the previous revision of the script which is not broken.
00:17 zsoftich1 joined #salt
00:17 geekatcmu Or you can do "apt-get install python-pip" and re-run the script with -P
00:17 geekatcmu (that assume an Ubuntu system, alter to fit your reality)
00:18 holler is it possible to work that into the Vagrantfile? we dont have a devops person
00:18 holler it is ubuntu 14.04 box
00:19 aurynn in vagrant, use the shell provisioner before trying your salt provisioner?
00:19 holler btw what is a better way than using the bootstrap script for the noobs?
00:20 pipps joined #salt
00:23 holler looks like vagrant has a "bootstrap_script" setting, can I use that to point to working script? http://docs.vagrantup.com/v2/provisioning/salt.html
00:26 ayee I wanted to lint my salt code, my jinja files are basically my only code.
00:26 ayee What's the recommended way to lint salt jinja files?
00:35 MindDrive joined #salt
00:36 napsterX joined #salt
00:38 smcquay left #salt
00:54 zsoftich1 joined #salt
00:57 g3cko joined #salt
01:00 pipps joined #salt
01:14 luke23423423 joined #salt
01:22 jodv joined #salt
01:22 cberndt joined #salt
01:22 jodv joined #salt
01:36 jaybocc2 joined #salt
01:37 napsterX joined #salt
01:38 luke23423423 left #salt
01:47 ilbot3 joined #salt
01:47 Topic for #salt is now Welcome to #salt | 2015.5.2 is the latest | Please use https://gist.github.com for code, don't paste directly into the channel | 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:50 cowpunk22 joined #salt
01:55 omegamike joined #salt
01:59 masterkorp joined #salt
02:00 pacopablo joined #salt
02:00 pickledpig joined #salt
02:01 JoeHazzers joined #salt
02:04 funzo joined #salt
02:05 solidsnack joined #salt
02:05 XenophonF left #salt
02:16 64MADGHR9 joined #salt
02:22 c10b10 joined #salt
02:24 evle joined #salt
02:27 holler joined #salt
02:27 solidsnack joined #salt
02:27 holler anyone know the specific version of bootstrap-salt that doesn't throw the error "You need to allow pip based installations (-P) in order to install the python package 'tornado >= 4.0'"
02:27 cberndt joined #salt
02:29 manfred tornado isn't required in 2015.5
02:29 manfred it is for 2015.8 and develop
02:33 napsterX joined #salt
02:39 ITChap joined #salt
02:43 title joined #salt
02:44 holler manfred: of bootstrap script right? ive tried a few and keep getitng same error! frustrating
02:46 lompik joined #salt
02:48 alemeno22 joined #salt
02:49 ignarps have you tried this one,  https://github.com/saltstack/salt-bootstrap/issues/631
02:49 saltstackbot [#631]title: Stable broken in 15.04 even with -P | I have tried this with and without the PIP flag, it get farthest with the PIP flag....
02:58 cowpunk22 joined #salt
02:58 murrdoc joined #salt
02:59 sunkist joined #salt
03:05 sunkist1 joined #salt
03:05 ITChap joined #salt
03:07 favadi joined #salt
03:15 cberndt joined #salt
03:32 ajw0100 joined #salt
03:37 myth__ joined #salt
03:44 omegamike joined #salt
03:47 zmalone joined #salt
03:51 cberndt joined #salt
03:54 cpowell joined #salt
03:55 jaybocc2 joined #salt
04:01 zmalone joined #salt
04:04 cwyse joined #salt
04:04 cpowell joined #salt
04:17 forrest joined #salt
04:20 funzo joined #salt
04:22 hasues joined #salt
04:22 hasues left #salt
04:23 madpenguin joined #salt
04:24 cpowell joined #salt
04:25 tzero joined #salt
04:33 Alekti joined #salt
04:37 tzero joined #salt
04:37 stoogenmeyer__ joined #salt
04:39 jeddi joined #salt
04:40 zmalone joined #salt
04:50 ramteid joined #salt
05:01 jaybocc2 joined #salt
05:04 zer0def joined #salt
05:05 madduck hoonetorg: but the order (of states?) in reclass is well-defined. What's the problem?
05:08 tzero joined #salt
05:08 bitc01d joined #salt
05:14 tzero joined #salt
05:15 otter768 joined #salt
05:25 Bryson joined #salt
05:32 napsterX joined #salt
05:32 omegamike joined #salt
05:33 jhauser joined #salt
05:37 jaybocc2 joined #salt
05:37 catpigger joined #salt
05:48 stoogenmeyer joined #salt
05:50 irctc594 joined #salt
05:51 tzero joined #salt
05:53 sirex joined #salt
05:57 c10b10 joined #salt
05:57 chiui joined #salt
06:01 tzero joined #salt
06:04 _JZ_ joined #salt
06:12 jaybocc2 joined #salt
06:12 cpowell joined #salt
06:13 malinoff joined #salt
06:14 gcfhvjbkn joined #salt
06:16 AndreasLutro joined #salt
06:18 tzero joined #salt
06:20 jaybocc2 joined #salt
06:22 gcfhvjbkn joined #salt
06:23 lionel joined #salt
06:26 ageorgop joined #salt
06:29 zhoujl joined #salt
06:30 zhoujl hi  . I installed salt-mast by using "curl -L https://bootstrap.saltstack.com -o install_salt.sh  "
06:30 zhoujl and sh install_salt.sh -M
06:30 zhoujl but i can't find salt-ssh
06:31 zhoujl just "salt         salt-call    salt-cp      salt-key     salt-master  salt-minion  salt-run     salt-unity "
06:31 zhoujl how can i use salt-ssh
06:35 bitc01d apt-get install salt-ssh
06:38 dopesong joined #salt
06:41 zhoujl what ? salt-ssh is independent ?
06:43 tzero joined #salt
06:43 irctc594 guys I am dealing with user management. Currently I am taking the pillar data and make sure that user is present in the server using jinjja for loop. But when there are 100s of users every time I need to go through the for loop even if the users are already present. Is there any other effective way ?
06:43 kawa2014 joined #salt
06:45 AndreasLutro irctc594: no
06:46 nethershaw joined #salt
06:51 unicoletti joined #salt
06:54 tzero joined #salt
06:54 Savemech joined #salt
06:56 KermitTheFragger joined #salt
06:57 harkx joined #salt
06:59 trikke joined #salt
07:00 jaybocc2 joined #salt
07:02 tzero joined #salt
07:03 seenae joined #salt
07:03 stoogenmeyer_ joined #salt
07:04 c10b10 joined #salt
07:05 malinoff_ joined #salt
07:07 tzero joined #salt
07:13 zhoujl bitc01d thank you
07:15 ThomasJ AndreasLutro: Technically you could set a grain with a value to check against, a revision number set in the pillar which needs to be incremented everytime a change is made. However it also means the state will no longer be enforced on any external change until the revision is bumped :/
07:16 otter768 joined #salt
07:19 eseyman joined #salt
07:22 fredvd joined #salt
07:23 AndreasLutro ThomasJ: I find "no" much more pragmatic than "technically yes but it requires a ton of work and involves a lot of 'but's" :D
07:23 ThomasJ Agreed :)
07:28 tzero joined #salt
07:32 gcfhvjbkn joined #salt
07:33 agend joined #salt
07:37 ajw0100 joined #salt
07:38 _JZ_ joined #salt
07:44 cryptolukas joined #salt
07:45 joeto joined #salt
07:45 tmclaugh[work] joined #salt
07:49 adonis joined #salt
07:52 myth_ joined #salt
07:55 rdas joined #salt
07:55 tzero joined #salt
08:03 linjan_ joined #salt
08:06 dopesong_ joined #salt
08:08 tzero joined #salt
08:08 ITChap joined #salt
08:09 hoonetorg madduck: i know, but i think i stumbled across something, when i defined same application in different classes (for some reason)!
08:10 madduck hoonetorg: then the first occurrence counts and subsequent ones ignored. If you ever reproduce this, let me know!
08:11 N-Mi joined #salt
08:12 Xevian joined #salt
08:12 MadsRC What's the correct way to check a software version before deploying a config file? IE making the deployment dependent of the version?
08:12 hoonetorg madduck: it was a long time ago, probably i find something for reproducing the problem in an very old git commit :)
08:13 wvds-nl joined #salt
08:14 malinoff_ joined #salt
08:14 AndreasLutro MadsRC: look up pkg.version and pkg.version_cmp
08:14 MadsRC AndreasLutro: Thanks will do :)
08:15 hoonetorg madduck: do you also ensure that states run in an specific order on one node by defining applications(states) in the correct order in reclass? does this always work for you?
08:15 chiui joined #salt
08:15 babilen joined #salt
08:16 khebbie joined #salt
08:16 hoonetorg madduck:  if yes, that would make code like this: https://github.com/hoonetorg/salt-nfs-formula/blob/master/nfs/client.sls#L7 to https://github.com/hoonetorg/salt-nfs-formula/blob/master/nfs/client.sls#L12 .... useless
08:16 malinoff joined #salt
08:18 bitc01d welcome
08:18 aurynn joined #salt
08:18 bitc01d zhoujl
08:19 madduck hoonetorg: yes, I think the order is well-defined and stable
08:19 hoonetorg madduck: thx
08:20 hoonetorg madduck: my refactoring party can begin now :)
08:21 AndreasLutro hoonetorg: https://github.com/hoonetorg/salt-nfs-formula/blob/master/nfs/client.sls#L7-12
08:24 tzero joined #salt
08:25 aurynn joined #salt
08:26 hoonetorg AndreasLutro: thx, great hint
08:28 peters-tx joined #salt
08:33 tzero joined #salt
08:33 madduck hoonetorg: please refactor reclass when you're done with your first stage ;)
08:35 keimlink joined #salt
08:36 N-Mi joined #salt
08:38 tzero joined #salt
08:45 aurynn joined #salt
08:45 aurynn joined #salt
08:51 kbaikov joined #salt
08:51 pcdummy joined #salt
08:51 pcdummy joined #salt
08:52 jaybocc2 joined #salt
08:55 monkey661 joined #salt
08:56 tzero joined #salt
08:56 mike25de hey guys is it possible to use something like {{    'someString' + {{ variable }}       }}
08:56 mike25de so to generate a dynamic variable
08:59 hasues joined #salt
09:01 lothiraldan joined #salt
09:04 aurynn yes - check the jinja docs
09:05 c10b10 joined #salt
09:09 tzero joined #salt
09:12 Mate mike25de: expression inside {{}} is like python code (an extended subset in fact)
09:13 Mate so {{ "foo" + bar }} is what you want (it's the same as foo{{ bar }})
09:14 supersheep joined #salt
09:15 Ztyx joined #salt
09:17 otter768 joined #salt
09:18 slav0nic joined #salt
09:27 AirOnSkin joined #salt
09:30 AirOnSkin Hey guys. If I run a single state with state.sls, that requires some parts of another state, how do I instruct Salt to follow that require and also execute the requirement (but only the requirement, not the whole state file)?
09:32 AndreasLutro AirOnSkin: the easiest way is to just split up the required state file
09:33 AirOnSkin AndreasLutro: And the less easy way? ;)
09:35 seena joined #salt
09:36 seena http://pastebin.com/DPj7SYDb , this code adding keys to authorized_keys every time when I run , and not checking whether the key is already present
09:36 AndreasLutro correction: it's the only way, I misremembered something
09:36 dankrs left #salt
09:37 seena http://pastebin.com/DPj7SYDb , this code adding keys to authorized_keys every time when I run , and not checking whether the key is already present . Am I doing anything wrong
09:37 haarp joined #salt
09:37 AirOnSkin AndreasLutro: I see. Thanks :)
09:38 AndreasLutro seena: I don't think the "names" arg works very well, I'd create multiple states for each key instead. you could try adding a comment to the keys
09:42 haarp hey. im very new to salt and i am experiencing weird behavior. http://pastebin.ca/3079278 - for some reason, the onlyif statement ALWAYS evaluates to true, even if i give it "false" as a command. this is on 2014.1.13. any ideas?
09:43 seena AndreasLutro: http://pastebin.com/XbER2WX4 you mean this way?
09:43 AndreasLutro haarp: 2014.1 isn't really supported anymore, your first step should probably be to upgrade
09:44 AndreasLutro seena: yeah, though I wouldn't use {{ key }} in the state ID
09:44 AndreasLutro seena: https://bpaste.net/show/6cb5dc3ec487 here's my state
09:46 seena AndreasLutro: Thanks let me try that
09:48 haarp is http://debian.saltstack.com/debian-salt-team-joehealy.gpg.key the correct key for the debian repo on saltstack.com? apt still can't verify the package even after i imported the key
09:49 AndreasLutro haarp: yes
09:50 haarp ah, my bad, forgot to do anotehr repo update after adding the key :)
09:55 gcfhvjbkn is there any way to change output mode (terse/full/…) per-execution?
09:55 gcfhvjbkn salt '*' state.sls somestate state_output=full
09:55 gcfhvjbkn like this (but it doesnt work)
09:56 gcfhvjbkn of course it doesnt
09:56 AndreasLutro --state-output=full
09:56 AndreasLutro salt -h
09:58 gcfhvjbkn it doesnt work, interestingly
09:58 impi joined #salt
09:58 tzero joined #salt
09:59 AndreasLutro works here
10:01 gcfhvjbkn i commented out "state_output: mixed" setting in the master config and it worked for full and terse
10:01 mike25de Mate: thanks man
10:01 gcfhvjbkn however when that setting is one —state-output=full wouldn't work
10:01 gcfhvjbkn as if master configuration takes precedence over the flag, which makes no sense
10:02 AndreasLutro hmm that is possible
10:02 gcfhvjbkn so that's the expected behaviour?
10:02 gcfhvjbkn what's the rationale?
10:02 AndreasLutro nope, you're wrong... --state-output takes precedence here
10:02 AndreasLutro what version are you on?
10:02 mike25de hi guys,.. i have an issue with watch / watch_in  http://pastebin.com/EjK7b4qb   the thing is that i suppose that the last statement yum-rpm-key-tmp-folder should run only if something changes inside the FOR loop, but is triggered every time.
10:02 gcfhvjbkn salt 2015.5.2 (Lithium)
10:03 AndreasLutro mike25de: look up "onchanges"
10:03 mike25de we have used that as well... and the state still gets triggered
10:03 AndreasLutro gcfhvjbkn: works for me on the latest 2015.5 head, so not sure what's going on
10:04 gcfhvjbkn ok i'll try to upgrade and see if it helps
10:04 AndreasLutro mike25de: can you show me what your state looks like with onchanges?
10:04 gcfhvjbkn may be a bug either way
10:04 mike25de AndreasLutro: one sec
10:05 markm joined #salt
10:05 joeto joined #salt
10:06 mike25de AndreasLutro: http://pastebin.com/BB8ViBVL
10:06 AndreasLutro I'm not sure onchanges_in is a thing
10:07 mike25de AndreasLutro: The _in versions of requisites All of the requisites also have corresponding requisite_in versions, which do the reverse of their normal counterparts.
10:08 dankrs joined #salt
10:08 mike25de this is taken from : http://docs.saltstack.com/en/latest/ref/states/requisites.html#onchanges
10:09 mike25de AndreasLutro: the main idea is to trigger a state from a loop (and not for every loop iteration - just for the iteration that changes )
10:09 AndreasLutro I hope that's correct
10:09 AndreasLutro anyway
10:09 AndreasLutro https://bpaste.net/show/30a134594a53 is what I would do
10:10 AndreasLutro I don't see the need for the file.absent
10:10 tzero joined #salt
10:10 tachikoma joined #salt
10:10 tachikoma hi
10:11 aqua^c joined #salt
10:11 mike25de i see what you did, but my question still exists... how to trigger ... an action depending on a loop iteration...
10:12 AndreasLutro mike25de: you're thinking of it wrong, there is no loop iteration when salt runs, the loop is only in the templating language
10:12 cpowell joined #salt
10:13 mike25de yes AndreasLutro but in that loop... i have to trigger some state/action
10:13 mike25de it should be possible, right?
10:13 mike25de or as you said ... i don't see correctly how the loop is working with the states.
10:14 AndreasLutro mike25de: in your case, each loop iteration is creating two states, you just need to define how those two states interact with eachother and other states
10:15 mike25de ah ok
10:15 mike25de thanks man .. i will .. rethink it . AndreasLutro owe you a beer
10:25 ITChap joined #salt
10:29 aqua^c joined #salt
10:33 nexus hi
10:33 nexus anyone has tried the sysctl formula with a centos 6.6?
10:34 babilen nexus: Did you?
10:34 nexus it shows a error message: failed: Jinja syntax error: no test named 'mapping'
10:34 babilen When does it show that?
10:34 nexus could be because of the jinja version?
10:34 nexus centos 6.6 has jinja 2.2
10:34 babilen Which jinja version?
10:38 nexus I've also tried to upgrade jinja to 2.7 but it shows another error
10:38 nexus http://pastebin.com/vNyFQYPH
10:39 TyrfingMjolnir joined #salt
10:40 nexus the problem comes when you try to execute the param.sls
10:40 ITChap joined #salt
10:40 nexus the line: {% if param is mapping %}
10:42 drawsmcgraw joined #salt
10:44 chiui joined #salt
10:44 haarp ok, i did the upgrade from 2014.1.13 to 2015.5.2. now i'm having this problem: http://pastebin.ca/3079306 which is weird, as it used to work on the old version
10:44 tzero joined #salt
10:45 giantlock joined #salt
10:47 aqua^c joined #salt
10:48 denys joined #salt
10:50 AndreasLutro haarp: your top.sls needs to reside inside one of the file roots
10:50 linjan joined #salt
10:51 haarp AndreasLutro: i tried that too, it made no difference
10:53 jaybocc2 joined #salt
10:54 haarp i now copied top.sls into all three file roots, the same error remains
10:55 amcorreia joined #salt
10:57 aqua^c joined #salt
10:58 haarp ah, got it now. the master service hung, it silently ignored my restart commands after i edited the config
10:58 haarp killed it manually and restarted
11:00 evle joined #salt
11:01 seena AndreasLutro: http://pastebin.com/8HPuWd6r Tried this with a key pair value , no luck
11:05 sgargan joined #salt
11:09 AndreasLutro seena: errors?
11:10 soren joined #salt
11:11 AndreasLutro joined #salt
11:11 TyrfingMjolnir joined #salt
11:12 dynamicudpate joined #salt
11:14 tzero joined #salt
11:15 seena AndreasLutro: no errors , keys are getting added again and again
11:15 aqua^c joined #salt
11:16 ITChap joined #salt
11:16 CeBe joined #salt
11:17 AndreasLutro seena: not sure then, try adding the comment arg
11:18 AndreasLutro I can't remember if salt uses that to identify keys or not
11:18 AndreasLutro also are you on a recent version of salt?
11:18 otter768 joined #salt
11:20 TyrfingMjolnir joined #salt
11:20 seena AndreasLutro: I have code with single ssh key , that is working perfectly fine and detecting the key is already present . Problem comes only when giving multiple keys
11:20 seena AndreasLutro: Could you please paste your sampe pillar data structure?
11:22 AndreasLutro sure
11:22 AndreasLutro seena: https://bpaste.net/show/c09d722faef6
11:24 aqua^c joined #salt
11:30 tzero joined #salt
11:30 gcfhvjbkn going back to —salt-output
11:30 gcfhvjbkn i tried both 2015.2.3 and #develop
11:31 gcfhvjbkn with the same result
11:31 gcfhvjbkn so i supposed that's a bug
11:31 gcfhvjbkn could be related to https://github.com/saltstack/salt/issues/16235 i suppose
11:31 saltstackbot [#16235]title: --state-output doesn't seem to be working | `--state-output` seems to be broke in latest `develop` branch. It seems to show full output even if `terse` or `changes` are given....
11:32 beauby_ joined #salt
11:32 gcfhvjbkn i put "sys.write("{0}\n".format(self.opts))" here
11:32 gcfhvjbkn https://github.com/saltstack/salt/blob/develop/salt/cli/salt.py#L34
11:33 rburkholder joined #salt
11:33 aqua^c joined #salt
11:34 gcfhvjbkn and for some reason it contains "mixed" instead of "full" when i pass "—salt-output full" with "salt_output: mixed" in the configuration file
11:34 malinoff joined #salt
11:34 gcfhvjbkn however it has "terse" if i pass "—salt-output terse"
11:34 gcfhvjbkn http://pastie.org/private/hv8c3lksm7bodyfks9nkw
11:34 gcfhvjbkn that's really strange
11:39 amcorreia joined #salt
11:42 aqua^c joined #salt
11:43 xf10e joined #salt
11:43 xf10e hey
11:45 tzero joined #salt
11:45 xf10e I guess not salt-devs awake at this time, eh?
11:46 xf10e do we have a nice way of doing release-specific conditionals in salt-modules?
11:48 gcfhvjbkn ok i think i found the problem
11:48 gcfhvjbkn https://github.com/saltstack/salt/blob/develop/salt/utils/parsers.py#L255
11:49 gcfhvjbkn i see why this condition is necessary
11:49 gcfhvjbkn if user didn't pass anything salt shouldn't override the defaults
11:50 gcfhvjbkn but sadly there's no way to differentiate between implicit and explicit defaults
11:50 gcfhvjbkn at the very least i don't see it
11:51 gcfhvjbkn so if the user passed a value that happened to equal default value, salt wouldn't know that he did that
11:51 aqua^c joined #salt
11:56 xf10e gcfhvjbkn: you would to have different sets: one with the defaults, one with the passed values
11:58 omegamike joined #salt
11:58 gcfhvjbkn xf10e: you mean self.config and self.args?
11:58 gcfhvjbkn they are merged at some point i think
11:59 gcfhvjbkn it is this merge code that contains the problem, in my mind
12:00 giantlock joined #salt
12:00 aqua^c joined #salt
12:03 lompik joined #salt
12:04 xf10e something like that, but if you merge self.defaults into self.config self.defaults is still around... oh wait. but if the user set a value to the default... *sigh*
12:04 gcfhvjbkn yeah, exactly
12:04 lothiraldan joined #salt
12:05 xf10e yeah, you need something like self.args_set
12:12 mike25de hi guys .... we are testing the latest version of salt... and i think i discovered a BUg OR ... i am idiot and do not understand the onchanges:  http://pastebin.com/VLAcJsz0   What i want to accomplish is that the tmp-file9 is triggered IF ANY of the file 1-3 is being changed. At the moment only if all tmp-file-1 to 3 are changed ... then the file9 action is triggered. Is that normal?
12:12 mike25de any enlightenment would be much appreciated
12:13 tzero joined #salt
12:13 gcfhvjbkn filed the issue https://github.com/saltstack/salt/issues/25785
12:13 saltstackbot [#25785]title: --state-output and overriding defaults | It seems like there's an issue with the way salt treats command-line arguments in general, i only run into this with --salt-output however. I believe it's not the intended behaviour – that would be odd if true....
12:13 gcfhvjbkn gonna try to look for the remedy
12:15 madpenguin joined #salt
12:18 gcfhvjbkn xf10e: can you expand a bit?
12:18 gcfhvjbkn can't see a method/attribute like that both in optparse and utils.parsers
12:18 aqua^c joined #salt
12:22 tzero joined #salt
12:23 mike25de hi guys .... we are testing the latest version of salt... and i think i discovered a BUg OR ... i am idiot and do not understand the onchanges:  http://pastebin.com/VLAcJsz0   What i want to accomplish is that the tmp-file9 is triggered IF ANY of the file 1-3 is being changed. At the moment only if all tmp-file-1 to 3 are changed ... then the file9 action is triggered. Is that normal?
12:23 xf10e you'd need to keep a separate dict or s/t with the parameters actually passed by the user so you can figure out which are defaults and which are just identical to the defaults
12:23 rideh joined #salt
12:24 AndreasLutro mike25de: I think you'll have to duplicate the tmp-file9 state inside the for loop to achieve that - maybe open an issue to allow onchanges to work with OR conditionals instead of AND
12:24 mike25de AndreasLutro: i think you are correct... onchanges should work with OR instead of AND.
12:24 mike25de thanks again AndreasLutro
12:25 mike25de where can i open an issue? never done that before
12:25 AndreasLutro maybe. I've only ever used one onchanges thing
12:25 TyrfingMjolnir joined #salt
12:25 AndreasLutro https://github.com/saltstack/salt/issues
12:32 mike25de i have another issue :) God damn it .... http://pastebin.com/TM562gne   it seems i trigger an error.. when i run attached state.  State 'file.mod_watch' was not found in SLS 'debug.test'
12:33 markm joined #salt
12:34 AndreasLutro mike25de: file states don't support listen/watch
12:35 catpig joined #salt
12:36 breakingmatter joined #salt
12:36 aqua^c joined #salt
12:37 mike25de ah ok .good to know
12:37 mike25de thanks again! AndreasLutro
12:37 tzero joined #salt
12:38 mike25de then what would be recommended for files? AndreasLutro ... is somewhere documented that listen/watch is not supported for files/
12:38 mike25de ?
12:39 xf10e always fun when you test so long you don't even remember what the test you're running tries to accomplish in the first place...
12:39 AndreasLutro mike25de: depends entirely on what you actually want to do
12:39 mike25de lol xf10e
12:41 snaggleb_ joined #salt
12:43 funzo joined #salt
12:44 omegamike joined #salt
12:44 _Cyclone_ joined #salt
12:47 tzero joined #salt
12:48 saltman joined #salt
12:48 saltman I use salt 2015.5.3
12:49 saltman and I have the following line in python: self.cloud = salt.cloud.CloudClient('/etc/salt/cloud'), for some reason, it failed on: AttributeError: 'module' object has no attribute 'cloud'
12:49 saltman But from what I see from the docs, it supported: http://docs.saltstack.com/en/latest/ref/clients/
12:51 LotR but is it complaining about salt having no cloud, or about self having no cloud..
12:53 colegatron joined #salt
12:53 saltman The code works with salt 2014.1.7
12:53 losh joined #salt
12:53 jaybocc2 joined #salt
12:54 saltman It fails on this: salt.cloud.CloudClient('/etc/salt/cloud')
12:54 aqua^c joined #salt
12:55 debian112 joined #salt
12:59 tzero joined #salt
12:59 khebbie joined #salt
13:01 xintron Using gitfs, is it possible to lock down a specific commit/tag for a repository?
13:02 furrowedbrow joined #salt
13:04 DammitJim joined #salt
13:04 Ztyx left #salt
13:05 napsterX joined #salt
13:05 SVQTQ joined #salt
13:05 SVQTQ Hello guys. At the end of my highstate I would like to restart a few services. How can I make sure that these services are restarted? The 'restart_service' is in another state file than that the config files are being put in place.
13:06 Mate watch the config files
13:06 Mate in the service definition
13:07 SVQTQ Can I just do that without having them in the same state file?
13:07 Mate yes
13:08 Mate - watch_in: service: foo at the end of the file defs
13:08 Mate is easier
13:08 SVQTQ alright, thanks!
13:09 SVQTQ Mate, my nginx uses like 4 files. Best to put the watch on all these four states?
13:09 SVQTQ s/watch/watch_in/g
13:10 AndreasLutro for config files it's often easier to use watch: file: /etc/nginx/*
13:10 AndreasLutro but the end result will be the same
13:10 SVQTQ AndreasLutro, on the service state that is, then?
13:10 AndreasLutro yeah
13:10 ferbla joined #salt
13:10 tzero joined #salt
13:11 Tecnico1931 joined #salt
13:12 TyrfingMjolnir joined #salt
13:12 stephanbuys joined #salt
13:12 aqua^c joined #salt
13:13 bhosmer joined #salt
13:14 DammitJim AndreasLutro, may I ask you a question in pvt?
13:14 DammitJim it's off topic for salt, but in regards to nginx
13:16 AndreasLutro DammitJim: yeah ok
13:19 otter768 joined #salt
13:20 Mate https://github.com/saltstack/salt/commit/a36b3d1858ad127bfe87b73c9faf737d7309bfb1 do i see it correctly that this change wasnt documented?
13:20 Mate http://docs.saltstack.com/en/latest/ref/states/requisites.html cant find it here
13:21 AndreasLutro Mate: seems like that's the case yeah
13:22 AndreasLutro https://github.com/saltstack/salt/issues/14047
13:22 saltstackbot [#14047]title: please document glob file watches | Salt appears to support globs for file watches as per #663. However, I cannot seem to find any documentation other than that bug report. Could that please be documented somewhere?...
13:22 Mate i have seen this syntax in some snippets, but considered bad
13:22 Mate and never tried :)
13:23 AndreasLutro a comment in the issue seems to imply that it has flaws so yeah maybe
13:24 pdayton joined #salt
13:26 TyrfingMjolnir joined #salt
13:31 aqua^c joined #salt
13:31 xintron Does file_roots support globbing? Something like - /conf/my_stuff/*/ Where all states are in /conf/my_stuff/dir1/git/init.sls as an example?
13:31 SVQTQ Is the file.copy state the right one to use when trying to copy a directory and it's subdirs?
13:31 AndreasLutro SVQTQ: file.recurse
13:32 SVQTQ AndreasLutro, file.recurse checks on the master, I need to copy a file from the minion to another directory on the same minion
13:32 AndreasLutro aha
13:32 AndreasLutro then I don't know
13:33 SVQTQ :D ok, thanks for the input anyway, I'll just try. It's just that I couldn't find a 'recursive: True' option, so not sure if copy is the right thing to use.
13:34 racooper joined #salt
13:35 bhosmer joined #salt
13:35 SVQTQ I used salt pre version 2014.7, they then said cmd.run was bad practice. But now to achieve my recursive copy, would it be a bad idea to just cmd.run?
13:35 tzero joined #salt
13:36 murrdoc joined #salt
13:36 AndreasLutro cmd.run itself is not a bad practice, it depends on the context of what you want to do
13:36 Mate SVQTQ: file.copy
13:37 Mate it is recursive by default (doc dosesnt mention it)
13:37 SVQTQ Mate, ok thanks. Will do that, then.
13:37 zz_ashmckenzie joined #salt
13:38 TyrfingMjolnir joined #salt
13:44 tzero joined #salt
13:44 unicoletti joined #salt
13:45 wnkz joined #salt
13:46 monkey66 joined #salt
13:49 aqua^c joined #salt
13:49 mapu joined #salt
13:50 sgargan what would be the recommended way to wait for a rest service to be available?
13:50 sgargan loop until 200 or payload contains…
13:53 tipiak joined #salt
13:55 Ztyx joined #salt
13:59 tzero joined #salt
14:04 nexus why in some pillars is used the lookup word?
14:04 nexus is some kind of convention?
14:05 babilen nexus: "lookup" is short for "lookup table" and is used in the pillar for those values that are defined in the map.jinja or, more specifically, those values that are unlikely to be changed by the user
14:06 joeto joined #salt
14:06 nexus babilen: thanks XD
14:06 babilen Say you have some default values that are being kept in map.jinja (or elsewhere) for, say, package names. These differ between distributions, but users typically don't want to change those values
14:07 aqua^c joined #salt
14:07 babilen Examples include package names, URIs of template files, ...
14:07 nexus understood
14:07 nexus thanks
14:08 babilen What we typically do these days is more akin to what you find in https://github.com/saltstack-formulas/salt-formula, https://github.com/saltstack-formulas/influxdb-formula or https://github.com/saltstack-formulas/collectd-formula (check map.jinja, defaults.yaml, ...)
14:09 cowpunk22 joined #salt
14:13 kaptk2 joined #salt
14:13 fgimian joined #salt
14:14 pdayton joined #salt
14:15 jdesilet joined #salt
14:16 tzero joined #salt
14:16 fgimian joined #salt
14:16 XenophonF joined #salt
14:17 BradThurber joined #salt
14:20 micko joined #salt
14:23 BradThurber I'm guessing it is a little early in the day for questions but I'll give it a shot anyway
14:23 BradThurber I'm trying to install a particular version with pkg.installed but I don't want to specify the whole version-release-arch - just the version
14:24 beauby_ joined #salt
14:24 xf10e BradThurber: early? it's 16:23 around here ;)
14:25 BradThurber wow - not early!
14:25 pdayton joined #salt
14:25 aqua^c joined #salt
14:26 BradThurber So this works fine
14:26 BradThurber salt-call state.single pkg.installed httpd version='2.2.26-38.ep6.el6'
14:26 BradThurber But this doesn't
14:26 BradThurber salt-call state.single pkg.installed httpd version='2.2.26'
14:27 BradThurber strictly speaking 2.2.26 IS the version
14:28 dude051 joined #salt
14:29 nexus babilen: thanks again ;D
14:30 babilen BradThurber: Early? I'm about to go home :)
14:30 babilen BradThurber: That is quite specific to RedHat, don't you have to do the same if you use the package manager directly?
14:31 LtLefse BradThurber: try version='2.2.26-*'
14:31 LtLefse which gets passed onto yum
14:31 murrdoc XenophonF:  fix my shizzle
14:31 murrdoc :D
14:32 breakingmatter joined #salt
14:34 rideh joined #salt
14:35 aqua^c joined #salt
14:37 BradThurber LtLefse: -* works. Thank you!
14:38 ildiroen joined #salt
14:38 icflournoy joined #salt
14:39 dude051 joined #salt
14:39 LtLefse cool! like babilen says, it'll probably only work on rpm/yum based distros
14:39 jaybocc2 joined #salt
14:40 tzero joined #salt
14:42 xf10e LtLefse: but you'll probably won't need it anywhere else.
14:43 xf10e and I would think that's a bug in passing pkgname + version to the rpm_pkg (or w/e it's called) module
14:43 XenophonF murrdoc: LOL
14:43 adelcast left #salt
14:43 XenophonF murrdoc: you break it you buy it my friend
14:44 aqua^c joined #salt
14:44 murrdoc but u PROMISED !
14:44 zmalone joined #salt
14:46 Niamkik hi everyone :)
14:46 XenophonF LOL
14:46 XenophonF I'll take another crack at it today.
14:47 SVQTQ I have a state file that clones 3 repos. I also have 3 state files which would 'pull' these repos seperately. do I have to use force: True in order to let salt pull the latest changes? or will it pull once .git is initiated in the folder?
14:47 BradThurber In my particular case (JBoss EAP), the RPMs are only available for RHEL (not even CentOS, etc) so it isn't a concern. I can tell from all the debug logs going on while it is doing its thing that this code wasn't fun to write. 4 calls to 'repoquery' and 3 calls to 'yum', 1 call to npm.
14:47 murrdoc XenophonF:  where was it failing ?
14:47 adelcast joined #salt
14:49 murrdoc XenophonF:  fixed
14:49 XenophonF BradThurber: hey speaking of J2EE (/me furtively waves his hand to ward off the evil eye), do you have any experience deploying jetty on RHEL/CentOS?  the jetty RPMs are...incomplete
14:49 XenophonF murrdoc: vielen danke
14:50 XenophonF let me pull your changes
14:50 druonysus joined #salt
14:50 Brew joined #salt
14:50 Niamkik I've a strange issue today (again) with salt-2015.5.2 on ubuntu 14.04. all result from minion are sent many times (2 times, 3 times, 4 times). So, when I launch a command with '*' I've lot of duplication result. On some minion I have "[CRITICAL][18247]" and "[ERROR   ][18247]" errors. On others one I have "[ERROR   ][3000]" errors...
14:50 tzero joined #salt
14:51 Niamkik I've read some topic about that on google, but, no one has worked... (purge/remove/delete/reinstall/reinit key...)
14:51 giantlock joined #salt
14:51 murrdoc XenophonF:  i mean i think i fixed it
14:53 CeBe joined #salt
14:53 BradThurber XenophonF: No jetty experience unfortunately
14:53 c10b10 joined #salt
14:53 aqua^c joined #salt
14:53 madpenguin joined #salt
14:53 XenophonF murrdoc: different errors this time - https://gist.github.com/xenophonf/ce0fc68d24c8485ad90e
14:54 XenophonF BradThurber: ah too bad - i was hoping there was an easier way to deploy than from source-ish
14:55 jeddi joined #salt
14:56 jondonas joined #salt
14:56 murrdoc damn u xeno and your etsting!
14:57 TooLmaN joined #salt
14:57 murrdoc k i am going to fix this later
14:58 XenophonF that's cool
14:58 XenophonF i gotta dash - bbl
14:58 XenophonF left #salt
15:00 programmerq joined #salt
15:00 clintberry joined #salt
15:01 b18 joined #salt
15:02 aqua^c joined #salt
15:03 BradThurber Here's a repeat question from the other day. I wrote a pure python state renderer (http://docs.saltstack.com/en/latest/ref/renderers/all/salt.renderers.py.html) in one of my formulas because I needed to parse some JSON-like stuff. The problem I am running into is the formula map.jinja is creating a pillar value I need. In normal jinja2/yaml state files I do a {% from map.jinja import settings with context %} to get at the map.jinja data. Is there an
15:03 BradThurber y way to get at this from a pure python state? I'm guessing the answer is no. I have a feeling that I should probably not be writing a python state but rather just plain python.
15:03 hacksepe joined #salt
15:05 xf10e BradThurber: you just need to render the jinja and parse the resulting YAML/JSON/whatever
15:05 xf10e I guess there are functions for this somewhere in modules/ or utils/
15:06 dopesong_ joined #salt
15:06 sdm24 joined #salt
15:07 tzero joined #salt
15:07 cowpunk22 joined #salt
15:08 BradThurber xf10e: I looked through utils briefly but when I opened one and the comment sait "This is where all the black magic happens..." I got scared
15:08 rideh joined #salt
15:08 Seanny joined #salt
15:08 Seanny Hey alll!
15:09 Seanny Shouldn't this work im trying to check if my grain is empty which it is but it doesnt work. {% if salt['grains.get']('kafka_id') == 'None' %}
15:10 Seanny {% if salt['grains.get']('kafka_id') == 'None' %}
15:10 sdm24 is not defined %}
15:10 sdm24 'None' is not the same as empty
15:11 aqua^c joined #salt
15:12 Seanny salt '*' grains.item kafka_id returns None
15:12 iggy 'None' is a string
15:12 whytewolf wouldn't that be the string 'None'? and not None
15:13 whytewolf and iggy beat me to it
15:13 iggy None is a keyword
15:13 murrdoc None is the loneliest number
15:13 BradThurber Seanny: Perhaps this would work in your case {%- if "kafka_id" not in grains %}
15:13 Seanny I'll try both two mins
15:14 iggy technically you should probably use both
15:14 iggy or .get()
15:15 xf10e BradThurber: some day you'll dive into all this magic anyway ;)
15:15 murrdoc just use .get()
15:15 iggy {% if 'kafka_id' in grains and grains['kafka_id'] == None %}
15:15 iggy or {% if grains.get('kafka_id') %}
15:15 murrdoc {% if salt['grains.get']('kafka_id', False) %}
15:15 Seanny {% if salt['grains.get']('kafka_id') %} {% set kafka_id = salt['grains.item']('kafka_id') %} {% else %} {% set kafka_id = salt['grains.setval']('kafka_id',range(10000)|random) %} {%- endif %}
15:16 iggy the default for .get is NoneType which evaluates to False, so you can generally leave it out in situations like this
15:17 murrdoc iggy right
15:17 perfectsine joined #salt
15:18 tzero joined #salt
15:18 canci joined #salt
15:20 otter768 joined #salt
15:20 NV joined #salt
15:20 aqua^c joined #salt
15:21 venu0336 joined #salt
15:23 tzero joined #salt
15:23 napsterX joined #salt
15:25 bhosmer_ joined #salt
15:26 Slimmons In case you missed it yesterday.  I'm having this issue.  http://serverfault.com/questions/708898/rvm-install-via-saltstack-could-not-install-ruby
15:26 Slimmons gist here https://gist.github.com/johnsimmons/4bcb844828b5e96b3a7f
15:26 c10b10 joined #salt
15:28 lrojas joined #salt
15:28 CeBe joined #salt
15:29 aqua^c joined #salt
15:32 PredatorVI joined #salt
15:34 Guest51825 joined #salt
15:35 DammitJim joined #salt
15:35 oznah joined #salt
15:39 xf10e oh, hey basepi, didn't know you're here
15:40 xf10e basepi: how bad is checking the salt-version inside a module and adjusting the behavior of said module accordingly?
15:40 stoogenmeyer_ joined #salt
15:40 xf10e got this annoying "let's wrap everything in a one-key-dict" behavior of the openstack modules again...
15:41 xf10e and when I just check for the version I can prepare the code and have it switch automatically ^^
15:42 iggy I imagine it's a bit like kernel code... if it's yours and lives outside the upstream repo.... you gotta do what you gotta do
15:43 iggy if it's merged upstream it shouldn't be necessary
15:44 zlhgo_ joined #salt
15:44 jaybocc2 joined #salt
15:44 TyrfingMjolnir joined #salt
15:45 SeeDickCode joined #salt
15:45 xf10e iggy: I just want someone like basepi or thatch45 sign this off ;)
15:46 hacksepe Hey folks, got a question.  For the LocalClient API I want to use compound command for  cmd(tgt, fun, arg=(), timeout=None, expr_form='glob', ret='', jid='', kwarg=None, **kwargs)
15:46 dopesong joined #salt
15:46 kbaikov joined #salt
15:46 hacksepe from the docs I see "This requires that the arg param is a list of lists.".  It seems the same does not apply for kwarg.  Should you not logically be able to supply a list of dicts for kwarg to the execution module?
15:47 favadi joined #salt
15:48 hacksepe I've tried it and it seems to ignore the kwarg if it is a list of dict.
15:48 tzero joined #salt
15:49 breakingmatter joined #salt
15:50 zlhgo_ i have two salt-minions running in vitrualbox, first i do '/etc/init.d/salt-minion start', the salt-minion connect to salt-master but after a while the master lost the salt-minion.
15:53 CeBe joined #salt
15:53 khebbie_ joined #salt
15:54 iggy zlhgo_: what version of salt? What's the network look like?
15:57 xf10e zlhgo_: which OS?
15:57 tzero joined #salt
15:58 dopesong joined #salt
15:58 alemeno22 joined #salt
15:58 malinoff joined #salt
16:00 pipps joined #salt
16:06 rideh joined #salt
16:07 zsoftich1 joined #salt
16:13 tanta joined #salt
16:15 theologian joined #salt
16:15 xf10e when I got this glance state-module stuff merged I should problably look into the issue with the salt-minion constantly dying on one of my FreeBSD 9 hosts ^^
16:21 robinsmidsrod joined #salt
16:21 MatthewsFace joined #salt
16:21 newbie joined #salt
16:23 pipps joined #salt
16:23 tzero joined #salt
16:26 debian112 can I use another pair of eyes here: http://paste.debian.net/286987/
16:26 debian112 I am getting this: local:
16:26 debian112 Data failed to compile:
16:26 debian112 ----------
16:26 debian112 The state "legacy-sudo" in sls sudo.newinit is not formed as a list
16:27 supersheep joined #salt
16:27 debian112 seems fine to me
16:27 sdm24 I think you might have too many spaces
16:27 drneilmb joined #salt
16:27 sdm24 under file.managed, all of the - lines should be 4 spaces indented
16:28 sdm24 for the first part, they are 5 spaced indented
16:29 murrdoc use get_ssh_keys_from_oclocal
16:29 xf10e debian112: try `salt \* state.show_sls $STATE`, I would guess your state is empty because grains.os is 5.6 or 5.0.5 or something ;)
16:29 murrdoc uh yaml-online-parser.appspot.com
16:29 kevinquinnyo joined #salt
16:30 debian112 yeah it appears empty on that server
16:31 debian112 I have no match for it, which I wanted
16:31 xf10e debian112: maybe you should wrap the whole thing in {% if grains.osfinger in ['CentOS-5.5', 'Debian-5.0.3', 'Debian-5.0.8'] %}
16:31 debian112 should it just ignore
16:31 xf10e but check the osfinger on your hosts first
16:31 smcquay joined #salt
16:31 tzero joined #salt
16:31 aba joined #salt
16:32 xf10e that's why I said "wrap the whole [legacy-sudo]" ;)
16:32 aba Hi. I want to transfer credentials via salt to individual servers (i.e. no server should be able to access foreign files). What's the best way to do that with salt?
16:32 debian112 yeah that was my first thought, but osfinger is not available in Debian 5 although the minions are the same version
16:32 aqua^c joined #salt
16:32 iggy {% elif grains['os'] == 'Debian' and ( grains['osrelease'] == '5.0.3' or grains['osrelease'] == '5.0.8' ) %}
16:33 iggy ()'s
16:33 iggy also, Debian 5...
16:33 sdm24 I thought there wasn't Salt for Debian 5
16:34 debian112 there is not, I complied a frozen version from source
16:34 clintberry joined #salt
16:36 xf10e debian112: you could write a tiny custom grain for Debian 5 to set grains.osfinger to (grains.os + grains.osrelease) ;)
16:37 cowpunk22 joined #salt
16:40 debian112 ok I fixed the white spaces
16:40 debian112 I think the problem is from none of the grains match him so it error out
16:40 debian112 ?
16:40 debian112 maybe
16:41 murrdoc joined #salt
16:41 jodv joined #salt
16:42 basepi xf10e: I assume you're talking about a custom module? Because modules shipped with salt will be pegged to a specific salt version anyway.... I can't see it being a huge problem. The fastest way is probably `import salt.version; if salt.version.__version__ ...`
16:42 basepi It also has `__versions_information__` and `versions_report` and other useful stuff
16:43 amcorreia joined #salt
16:44 KyleG joined #salt
16:44 KyleG joined #salt
16:45 holler joined #salt
16:45 tzero joined #salt
16:45 djstorm joined #salt
16:49 erazer joined #salt
16:49 erazer hi
16:49 xf10e basepi: If I do it this way I can prepare all the openstack-modules for the change and write warnings to the log.
16:49 xf10e after carbon we could just remove the warning
16:50 jaybocc2 joined #salt
16:50 xf10e makes a softer deadline ;)
16:50 BradThurber_ joined #salt
16:50 aqua^c joined #salt
16:51 erazer what is the best way in salt to construct one configuration file from other configuration files - add multiple files together to one bigger file
16:51 erazer ?
16:51 basepi xf10e: I don't have a problem with it.
16:51 xf10e basepi: oh, and it's about getting additional salt-modules into saltstack so I don't need to maintain them in my formulas
16:51 xf10e OK then
16:51 basepi You should be able to get the actual release codename from the version object if that's helpful
16:52 xf10e thx
16:52 basepi https://www.irccloud.com/pastebin/eUPfrmgj/
16:53 khebbie joined #salt
16:53 basepi That could help with trying to compare against future versions that don't yet have numbers.
16:53 pullphinger joined #salt
16:54 sdm24 erazer: !saltstackbot states.file.append
16:54 sdm24 :(
16:54 sdm24 http://docs.saltstack.com/en/latest/ref/states/all/salt.states.file.html#salt.states.file.append
16:54 sdm24 you can list multiple sources
16:55 aparsons joined #salt
16:55 williamthekid joined #salt
16:56 holler hello, I am using salt as provisioner for vagrant and getting this error " * ERROR: You need to allow pip based installations (-P) in order to install the python package 'tornado >= 4.0'"
16:56 holler I tried using the develop version of bootstrap-salt.sh
16:56 holler using "stable" version of salt
16:57 jaybocc2 joined #salt
16:57 pipps joined #salt
16:58 erazer do you have pip installed?
16:59 rideh joined #salt
17:00 Bryson joined #salt
17:00 erazer try appending -P before stable
17:02 holler erazer: like this? http://dpaste.com/0N9R7R0#line-36
17:02 erazer maybe that helps yes
17:03 erazer the problem is that the tornado python package is not installed
17:03 erazer so pip is used to install this package
17:04 ageorgop joined #salt
17:05 xf10e basepi: that's great - but has to wait until tomorrow ;)
17:05 xf10e c yas
17:06 K joined #salt
17:07 erazer @sdm24: append may not be the best choice for me because it is more like a merge of small files into a big existing file - my idea is to use something like file.accumulator, but fed from a file and not from text in an sls
17:08 erazer i do not want to append only at the end
17:09 aqua^c joined #salt
17:09 erazer maybe it is possible to read the contents of files into variables and use these variables in the config file?
17:12 holler erazer: what does salt use tornado for?
17:12 holler ps it seems like that worked as the install is progressing now.. so thanks
17:13 erazer ok
17:13 erazer it is some networking library
17:15 CeBe joined #salt
17:16 holler damn now im getting some other error
17:16 holler OSError: [Errno 12] Cannot allocate memory
17:18 XenophonF joined #salt
17:18 XenophonF I wonder if I can get Salt installed on this old Fedora Core box I have...
17:19 iggy python version?
17:19 XenophonF Evidently, even the voices inside my head think this is a bad idea. =)
17:19 XenophonF um, looks like Python 2.4.3
17:19 pcn Time to build a new python
17:20 iggy ^
17:20 pcn The change in the language since then is quite dramatic
17:20 XenophonF I've been trying for years to retire this server.
17:20 otter768 joined #salt
17:21 manfred XenophonF: if you really hate your life, you might get lucky and try the python26 package from IUS
17:21 hal58th joined #salt
17:21 manfred or i guess it is in epel
17:21 manfred oh, but they dropped the python-distribute
17:21 XenophonF yeah
17:22 XenophonF ugh
17:22 pcn Maybe see if pyenv will build it on the box
17:22 manfred XenophonF:  you could try the rhel 5 copr repo for salt
17:22 murrdoc stop being lazy
17:22 XenophonF this is one of our very first Linux VMs
17:22 XenophonF it needs to die
17:22 manfred yes
17:22 murrdoc make your own packages XenophonF
17:22 manfred the fact that it is fedora core is scary
17:22 XenophonF but murrdoc, i don't WANNA
17:22 XenophonF even better, it's Internet-facing
17:22 * murrdoc puts on shades
17:23 murrdoc dealWithIt (tm)
17:23 XenophonF LOL
17:23 XenophonF every day i read the logwatch output with increasing horror
17:23 manfred XenophonF:  http://copr.fedoraproject.org/coprs/saltstack/salt-el5/repo/epel-5/saltstack-salt-el5-epel-5.repo
17:23 manfred that is the copr repo for rhel 5
17:23 XenophonF thanks manfred, i'll give that a try
17:24 geekatcmu Eh, I think "stop being lazy" == "stop using EOL OSen"
17:24 XenophonF geekatcmu: omg you're preaching to the choir
17:24 manfred XenophonF:  do you have backups? if not, just delete it… woops
17:24 manfred what are we gonna do now? can't go back :P
17:24 XenophonF manfred: oh i should totally do that
17:25 manfred get your resume out there first
17:25 XenophonF and it's too old to run our backup client
17:25 manfred sounds like a win win
17:25 XenophonF dude, i have plausible deniability - we're in the middle of a storage migration, so i can blame it on my san guys ;)
17:25 manfred lol
17:25 XenophonF we've already had documented problems with our CentOS 7 boxes and XFS
17:25 * iggy c&p's to XenophonF's SAN guys
17:25 bhosmer joined #salt
17:26 XenophonF LOL
17:26 impi joined #salt
17:26 Bryson joined #salt
17:26 forrest joined #salt
17:26 XenophonF i should just fill the filesystem with /dev/urandom and walk away
17:26 tanta joined #salt
17:27 aqua^c joined #salt
17:28 manfred why urandom? dev zero is faster
17:28 XenophonF oooh, and that will look a lot more like VMFS PV extent corruption, too!
17:28 manfred just overwrite the boot sector
17:28 manfred ooh, and the msdos partition table
17:29 manfred or encrypt the disk
17:29 manfred there are so many solutions to your problem
17:29 manfred none of them are good, but such is life
17:32 pcn Or just start up a new vm on the same vswitch, and then cut over to it a bit later?
17:33 XenophonF it's running a php4 app
17:33 * murrdoc ships XenophonF beer
17:33 XenophonF i've been telling the boss that we need to nuke this server
17:34 XenophonF and he's been telling me that we're so close to getting its replacement webapp into production
17:34 XenophonF we're just a few months away, really
17:34 iggy a couple months downtime isn't so bad
17:34 iggy burn it with fire
17:35 XenophonF no, it's more like how cold fusion or strong AI is just a few years away
17:35 manfred oh
17:35 manfred so it will be ready in Q5, got it
17:35 XenophonF yeah
17:35 CeBe joined #salt
17:36 XenophonF i tried getting it running under php52 with mixed success
17:37 snarfy joined #salt
17:37 XenophonF and it doesn't work at all under modern versions of php
17:37 XenophonF c'est la vie
17:38 murrdoc try running it in perl
17:39 ayee I wanted to lint my salt code, my jinja files are basically my only code. What's the recommended way to lint salt jinja files?
17:39 stomith joined #salt
17:40 gerhardqux ayee: I'd like that too!
17:40 iggy we're all still waiting for someone to write it
17:41 ayee http://docs.saltstack.com/en/latest/topics/development/conventions/style.html#linting
17:41 ayee `pylint --rcfile=/path/to/salt/.pylintrc salt/dir/to/lint` I found htat..
17:41 XenophonF that's for salt source code, right?
17:42 ayee I found that, but it wants __init__.py files and so on, I'm not sure if that looks at jinja files
17:42 ayee https://github.com/johanek/salt-lint .. I found that took.
17:42 ayee `lint salt states` is the readme
17:42 pcdummy joined #salt
17:44 ayee seems worth a shot, I'll try it out now.
17:45 ajw0100 joined #salt
17:45 ayee https://github.com/lukaszraczylo/salt-lint
17:46 ayee another one, but he says not to use it until version 0.5, but he's only at version 0.1.2, heh
17:46 JordanRinke joined #salt
17:46 aw110f joined #salt
17:48 lexter joined #salt
17:51 stanchan joined #salt
17:53 gcfhvjbkn joined #salt
17:53 gcfhvjbkn does anyone know if CI on the salt repo is completely broken or partly?
17:54 forrest iggy: Can you try not to be quite so impatient with people who create issues? I know that guy modified a lot of stuff, but we can say 'hey this is your fault' a little bit kinder ;)
17:54 gcfhvjbkn i see it's ok if at least some checks aren't finished, amirite?
17:54 iggy forrest: what is this in reference to?
17:54 forrest https://github.com/saltstack-formulas/mysql-formula/issues/85
17:54 saltstackbot [#85]title: mysql/defaults.yaml not found | I'm getting the following error when I run the mysql state:...
17:54 gcfhvjbkn do you know if there are any checks that aren't ok to fail?
17:55 forrest gcfhvjbkn: Some of them fail when you make a PR against dev because other stuff is broken since it's develop. I'd look at the log links and confirm it isn't your stuff
17:56 khebbie_ joined #salt
17:56 gcfhvjbkn forrest: the log links are broken
17:56 iggy nope
17:56 gcfhvjbkn https://jenkins.saltstack.com/job/salt-pr-dsl/7957/testReport/junit/integration.shell.matcher/MatchTest/test_glob/
17:57 gcfhvjbkn for example
17:57 aberdine hi - is there a way, via salt-run for instance, to force gitfs to re-clone repos?
17:57 iggy I tried to help and that person acted like he was mr alwaysright from the get go
17:57 forrest gcfhvjbkn: oh I don't know what's up with that then, it doesn't work when you click on details?
17:58 BradThurber joined #salt
17:59 forrest iggy: Yeah I know he did.
17:59 gcfhvjbkn forrest: you could say it does, but none of the links below "Test Result" seem to work
17:59 forrest gcfhvjbkn: Link?
17:59 forrest to your issue
17:59 forrest I just looked at another one and the 'details' links work fine
18:02 gcfhvjbkn joined #salt
18:03 forrest gcfhvjbkn: Did you see my comments?
18:03 forrest gcfhvjbkn: Regarding a link to your issue on github that is problematic
18:03 gcfhvjbkn forrest: yeah sorry
18:03 gcfhvjbkn https://jenkins.saltstack.com/job/salt-pr-dsl/7957/testReport/
18:04 forrest no worries, just wanted to make sure
18:04 gcfhvjbkn https://jenkins.saltstack.com/job/salt-pr-dsl/7957/
18:04 forrest Are you talking about the console output gcfhvjbkn? https://jenkins.saltstack.com/job/salt-pr-dsl/7957/console
18:04 gcfhvjbkn nope
18:05 forrest I see the 42 integration failures
18:05 gcfhvjbkn click "https://jenkins.saltstack.com/job/salt-pr-dsl/7957/testReport/junit/integration.shell.matcher/MatchTest/test_compound/"
18:05 gcfhvjbkn oh shi
18:05 gcfhvjbkn click "integration.shell. blah-blah-blah"
18:05 gcfhvjbkn yeah
18:05 forrest https://jenkins.saltstack.com/job/salt-pr-rs-cent7-n/6604/testReport/integration.shell.matcher/MatchTest/test_compound/
18:05 forrest that loads for me
18:06 forrest 7957 redirects me to 6604
18:06 gcfhvjbkn ah ok
18:06 gcfhvjbkn i don't get redirected
18:06 CeBe joined #salt
18:06 forrest really?? What do you see as the link when you hover over test_compound?
18:06 forrest maybe try a refresh in case it regenerated the links?
18:07 gcfhvjbkn …7957….
18:07 forrest gcfhvjbkn: If not, then please take some screenshots/links and create a new issue on the salt repo so the team can look at it ASAP
18:07 forrest very odd
18:07 lompik joined #salt
18:07 gcfhvjbkn also
18:07 gcfhvjbkn https://jenkins.saltstack.com/job/salt-pr-rs-cent7-n/6604/testReport/integration.shell.matcher/MatchTest/test_compound/
18:07 gcfhvjbkn "cannot allocate memory" everywehre
18:07 forrest Yeah
18:08 forrest At this point I'd say create two issues, one for that, one for the incorrect linking
18:08 forrest I don't know why salt-pr-dsl/7957 is redirecting to salt-pr-rs-cent7-n/6604 for me
18:08 forrest maybe it's just the jenkins config and I'm not familiar with it
18:08 tanta joined #salt
18:08 oznah anyone have time for some best practice questions about gitfs implementation?
18:08 forrest but either way, if you can report those issues that would be good *unless someone already has
18:08 bhosmer joined #salt
18:08 forrest oznah: Just ask your questions, if someone is around that can comment they usually do :)
18:09 supersheep joined #salt
18:09 snarfy joined #salt
18:10 perfectsine_ joined #salt
18:10 gcfhvjbkn forrest: ok, i'll do that tomorrow if it will persist (i made the screenshots anyway though), it's evening here already
18:11 forrest gcfhvjbkn: Awesome thanks a bunch! It's very odd. Make sure you note the 6604 links above as that's what I'm seeing when I go to that page you linked
18:11 oznah I have read the docs on gitfs and it makes a lot of sense. I am trying to figure out how to lay out my repos on the git server. do most people have large monolithic repos or do they break them up. ie. repo.org/states repo.org/pillar
18:12 jaybocc2 i dont use gitfs, but monolithic, git submodules are a pita
18:13 oznah if you don't do monolithic repos, how does that affect the relationship between repo branches and salt environments?
18:14 iggy states and pillars separate was the only workable solution for us
18:15 danielcb joined #salt
18:15 sdm24 I have states on git, and the pillar is local on the master'
18:15 oznah that is how I was leaning. monolithic seems like a bag of hurt
18:15 sdm24 since between testing and production, the states will be the same but the minions will change
18:15 oznah sdm24: do you version control your pillar data at all?
18:16 iggy the root= thing didn't work for us at the time
18:16 zemm left #salt
18:16 iggy it may work now
18:16 sdm24 I save a backup whenever I change the top file
18:16 sdm24 so no
18:16 oznah sdm24: thanks
18:17 oznah related, is anyone using formulas heavily?
18:18 XenophonF oznah: i have separate repos for pillar and states, with git branches in the states repo corresponding to different salt environments, and with extensive use of formulas (except where i write my own, like apache)
18:19 XenophonF oznah: example configs are at https://github.com/irtnog/salt-states and https://github.com/irtnog/salt-pillar-example
18:19 oznah XenophonF: I am assuming you fork the formula. that seems like the only way to go.
18:19 XenophonF oznah: i'm configuring my masters using salt, see https://github.com/irtnog/salt-pillar-example/blob/master/salt/example/com/init.sls for example pillar data
18:19 iggy we use formulas heavily, and yes, fork them
18:19 oznah XenophonF: oh thanks. that's awesome
18:20 c10b10 joined #salt
18:20 iggy they break from time to time (we try not to, but you know...)
18:20 XenophonF oznah: that uses both salt-formula and users-formula
18:20 XenophonF oznah: as iggy said, fork them
18:20 ipmb joined #salt
18:20 XenophonF i update my forks on a monthly schedule with change manager approval
18:21 XenophonF my production pillar data's in a private git repo
18:22 XenophonF the salt masters have their own git accounts
18:22 murrdoc till the next time u put your git key on this chat
18:22 murrdoc :D
18:22 XenophonF LOL
18:23 XenophonF i'm using gitpython because pygit2/libgit2/libssh2 don't support ed25519 key pairs
18:23 babilen boooo!
18:23 sdm24 I'm using gitpython because we are using Ubuntu
18:24 oznah is pygit2 solid otherwise
18:24 babilen I'm using gitpython because I can't be arsed to tinker with something that works in the hope to gain features I won't need ;)
18:24 XenophonF and because freebsd packages for those are too outdated, and because salt-formula doesn't support compiling those from source on freebsd
18:24 XenophonF brb
18:24 XenophonF oznah - listen to babilen. i basically stole all my tricks from him.
18:25 oznah XenophonF: loud and clear
18:25 babilen XenophonF: Which probably means that you have a much nicer system as you are at my "If I had known ... before I would have done it like $WHAT_I_TOLD_YOU" :)
18:26 babilen .. stage
18:28 sdm24 I'm trying to connect an old Debian 6.0.9 VM to my salt master. The minion sees the master (tries to authenticate to the correct IP), and can reach the master on ports 4505 and 4506. Whenever salt-minion starts, or I salt-call, I get "Attempt to authenticate with the salt master failed". The minion is running salt v2014.7.1. I have other minions with teh same Debian version that work fine
18:29 sdm24 https://gist.github.com/sdm24/4a80e6fd326dbd617720 here is the output from salt-minion -l debug
18:29 sdm24 salt-key -L on the master doesn't list the minion
18:29 rideh joined #salt
18:29 iggy you can clone over https with a username and personal access token (which can be shoved into the config file)
18:30 oznah I really appreciate the feedback re gitfs. Thanks!
18:30 iggy instead of needing to use ssh keys (which we always had problems with
18:30 tanta joined #salt
18:30 aqua^c joined #salt
18:31 johnwebbcole joined #salt
18:33 bhosmer joined #salt
18:36 bash124512 joined #salt
18:36 jayjayjay joined #salt
18:39 jayjayjay Hello. I have a state that installs Splunk. I have a second state that needs a piece of data that isn't known until after Splunk installs. I can retrieve that piece of data after the install using the requisite system. BUT how can I deliver that to the second state without human intervention?
18:39 alemeno22 joined #salt
18:39 sdm24 What piece of splunk data? I also use Salt to install splunk
18:40 iggy {% set splunkvar = salt['cmd.run']('some splunk command that returns data') %}
18:41 aqua^c joined #salt
18:42 rideh joined #salt
18:42 jayjayjay I want to install the add-on for Unix. That add-on installs to /opt/splunk or /opt/splunkforwarder. There are many ways that I can know which directory splunk installed to, but I'm having trouble feeding that to my add-on installer state because my jinja is rendered on the initial highstate BEFORE Splunk has been installed.
18:43 jayjayjay My ideal would be to pass a parameter to the state from top.sls
18:43 iggy use reload_modules: True on the splunk install and see if that helps
18:44 geekatcmu So, is it a known thing that Ubuntu repos of the form 'deb [arch=amd64] ...' aren't manageable by salt.states.pkgrepo because it uses an RE search for the repo, and [arch=amd64] looks like a character set?
18:44 sdm24 there are a couple of ways to test if a file/directory exists, and then have Salt act on that
18:44 iggy geekatcmu: think there's a bug open about that somewhere
18:45 sdm24 one option is to have 2 similiar IDs, one with - onlyif: test -d /opt/splunk, the other - onlyif: test -d /opt/splunkforwarder
18:46 jayjayjay oooh, that only_if option looks easy
18:46 jayjayjay i mean "maintainable" :)
18:46 sdm24 http://docs.saltstack.com/en/latest/ref/states/requisites.html#onlyif
18:46 * geekatcmu sighs
18:47 Savemech joined #salt
18:47 murrdoc the solution is easy geekatcmu
18:47 geekatcmu I guess I get to figure out how to configure apt to do the right thing in this case.
18:47 geekatcmu "don't use Ubuntu"
18:47 geekatcmu yes, I know
18:47 murrdoc dont put [ arch=amd64 ] in the name
18:47 murrdoc but use the -architecture: amd64 param
18:47 murrdoc and it will add the repo as u want
18:47 geekatcmu Where does that get used?
18:47 murrdoc heh u sound jaded :D
18:48 murrdoc basepi:  https://github.com/saltstack/salt/issues/20851
18:48 saltstackbot [#20851]title: pkgrepo.managed in ubuntu and architecture | Every time the following state is applied, it appends the name from pkgrepo.managed to the file. ...
18:48 murrdoc geekatcmu:  ^^
18:48 geekatcmu looking
18:48 geekatcmu thanks
18:49 geekatcmu awesome.
18:49 * geekatcmu loves undocumented parameters!
18:49 murrdoc code is documentation geekatcmu
18:49 murrdoc and there fore parametr was documented :D
18:50 druonysus joined #salt
18:50 druonysus joined #salt
18:51 geekatcmu http://24.media.tumblr.com/tumblr_l1krwjtpgs1qzufnjo1_500.jpg
18:51 murrdoc hahah
18:51 murrdoc http://i.imgur.com/dAjXOEs.gif
18:53 XenophonF babilen: kind of, babilen - my setup at home is a lot prettier than at work b/c my boss didn't let me update our 10-year-old naming conventions :/
18:54 cowpunk22 joined #salt
18:54 forrest What's up with this branch? https://github.com/saltstack-formulas/users-formula/tree/xenobeta
18:54 forrest Why are we making branches on the main repos?
18:55 iggy easier sharing? ("hey use this branch on some rando's fork of a formula" "yeah, I'd rather castrate myself with rocks")
18:58 BradThurber joined #salt
19:00 aqua^c joined #salt
19:03 perfectsine joined #salt
19:07 nzero joined #salt
19:08 bhosmer joined #salt
19:08 forrest iggy: Well, people should probably be reading the code before they just deploy to their server regardless of the repo.
19:11 murrdoc i did it
19:11 murrdoc i accidentally pushed to master
19:11 * iggy throws murrdoc under the bus
19:11 murrdoc while trying to fix the code
19:12 murrdoc xeno will test/ fix this branch
19:12 murrdoc thats why its branched out
19:12 murrdoc :D
19:13 jdesilet joined #salt
19:15 perfectsine joined #salt
19:16 forrest murrdoc: Any reason you didn't just use your own fork?
19:18 aqua^c joined #salt
19:19 CeBe joined #salt
19:21 Shirkdog joined #salt
19:21 otter768 joined #salt
19:21 murrdoc mistake actually
19:22 murrdoc i can nuke the brnach if u want
19:22 forrest murrdoc: Nah just do it when you're done if it isn't going to take more than a few days. Just don't want people to start branching on the main repo
19:23 ajw0100 joined #salt
19:23 sdm24 Would/Should there be an issue trying to connect a 32-bit Debian minion to a 64-bit Ubuntu master? Or is my problem somewhere else?
19:24 iggy somewhere else
19:24 forrest definitely somewhere else if they're on the same release.
19:24 sdm24 darn, I thought I had a breakthrough
19:24 murrdoc forrest:  can u nuke the branch
19:25 Akhter joined #salt
19:25 forrest murrdoc: I could from the command line, but just wait till you make the PR, once merged we'll trash it. It's not that big a deal.
19:26 forrest I just wasn't sure if it was for some specific release of salt or something.
19:26 murrdoc no no nuke it
19:26 murrdoc xeno has no time to test
19:26 murrdoc i dont use the formula
19:26 murrdoc i was just improving code quality
19:27 murrdoc 'trying'
19:27 aqua^c joined #salt
19:29 forrest murrdoc: Hah okay, that one is done.
19:31 stoogenmeyer_ joined #salt
19:32 napsterX joined #salt
19:33 lrojas hi all, sorry i am kind of new at salt, i have a server whose minion stoped working ( server is running ubuntu 12.04 ), i had to remove the package python-psutil ( after several google searches ), for it to work.
19:33 lrojas my question is, why some other servers also on ubuntu 12.04 work fine even with said package installed ?
19:34 forrest lrojas: Are all the versions the same release?
19:34 lrojas yes
19:34 lrojas 12.04.5 LTS to be precise
19:35 forrest I mean the same version of salt
19:35 forrest sorry
19:35 lrojas oh, i guess but i am new and this is my first week, how would i check that?
19:36 sinonick joined #salt
19:36 ayee How can I do a test.ping using the salt api?
19:36 ayee # curl -k -sS https://saltmaster.ash1.cloud.net:8080/run -k -H "Accept: application/json" -d tgt='b-kubernet-r16*' -d run='test.ping'; echo ""
19:36 ayee {"status": 500, "return": "An unexpected error occurred"}
19:36 ayee That doesn't work.
19:37 forrest lrojas: Use salt --version, might need to use salt-call on the minion
19:38 lrojas salt '*' cmd.run 'salt --version' ?
19:38 forrest lrojas: Yeah that would be fine
19:38 forrest iggy: Was there ever a command line option created to just check version mismatches? They should add that...
19:38 sdm24 wouldn't salt '*' cmd.run 'salt-call --version' be better?
19:38 sdm24 salt '*' test.version
19:38 lrojas salt 2015.5.0 (Lithium)
19:39 sdm24 err salt-run manage.version
19:39 sdm24 to check against the master
19:39 iggy ^
19:39 forrest sdm24: Does that check each host against the master and report issues?
19:39 iggy the runner is the only thing I can think of
19:39 iggy it's got "older than master" "newer than master" etc
19:39 forrest lrojas: So same version across all instances? If that's the case I'm not sure why python-psutil would be problematic :\
19:39 sdm24 forrest: it returns the master version, list of out of date minions, list of current minions
19:40 forrest Nice, I wasn't aware of that one, haven't been running a setup with a master for a while now.
19:40 funzo joined #salt
19:40 lrojas sdm24 what command?
19:40 sdm24 salt-run manage.version on the master
19:41 sdm24 manage.versions*
19:41 sdm24 manage.versions*
19:41 forrest lol
19:41 funzo_ joined #salt
19:41 lrojas ok, this gives a different response
19:42 lrojas master is 2015.5.2
19:42 lrojas problematic server is same as master...
19:42 lrojas server that works ok is 2015.5.0
19:43 XenophonF left #salt
19:45 aqua^c joined #salt
19:46 aba left #salt
19:47 ayee Can I make a salt user that has it's own auth through the salt master or salt api?
19:47 ayee I'm trying to do some simple hello world run through the salt api, but it's confusing what auth I use.
19:48 ayee I can't find good docs on how to configure salt-api.conf
19:49 jodv joined #salt
19:49 tkharju joined #salt
19:49 iggy if you are just playing around, use the auto external_auth
19:50 tanta joined #salt
19:56 TyrfingMjolnir joined #salt
19:56 ayee iggy: I'm trying to set username and password in the salt-api.conf
19:57 ayee http://salt-api.readthedocs.org/en/latest/ref/netapis/all/saltapi.netapi.rest_cherrypy.html .. I found the docs on how to do the http call using the username and password, but not how to specify the username/password on the server side/salt-api.conf
19:58 iggy you use the normal eauth config
19:58 iggy master config external_auth setting
20:00 ayee http://docs.saltstack.com/en/latest/topics/eauth/index.html
20:00 ayee iggy: Can I specify a username and password in salt-api.conf ? or do I have to bind to something, either external ad/ldap, or to say local unix auth?
20:02 iggy normally, you bind to something else, but the "auto" eauth module just accepts any password for whatever users you setup
20:02 dude051 joined #salt
20:02 iggy completely insecure, but for testing it's simple
20:02 khebbie joined #salt
20:03 ayee I see. hmm
20:03 aqua^c joined #salt
20:03 iamgr00t joined #salt
20:03 geekatcmu murrdoc: The architecture flag?  What release is that in.
20:04 geekatcmu Because it's not in whatever we're running.
20:04 geekatcmu 2015.5.0, I believe.
20:05 murrdoc its in 2014.7
20:05 rideh joined #salt
20:05 murrdoc paste in yo state
20:07 murrdoc oh geekatcmu i get what they are doing , i dont like it, but i get it
20:07 murrdoc trusty onwards, ubuntu is managing the the archs globally
20:08 c10b10 joined #salt
20:09 murrdoc https://github.com/saltstack/salt/blob/develop/salt/modules/aptpkg.py#L1818-L1819
20:09 murrdoc but architectures will work
20:12 aqua^c joined #salt
20:14 rideh joined #salt
20:17 dude051 joined #salt
20:20 geekatcmu Oh, I was using architecture singular.
20:20 geekatcmu I just punted and added an apt preference file to force it.
20:20 rideh joined #salt
20:22 aqua^c joined #salt
20:26 linjan joined #salt
20:29 sgargan joined #salt
20:29 keimlink joined #salt
20:31 aqua^c joined #salt
20:32 Cliph joined #salt
20:33 VR-Jack joined #salt
20:33 napsterX joined #salt
20:33 ajw0100 joined #salt
20:36 druonysus joined #salt
20:38 synical joined #salt
20:39 sgargan joined #salt
20:40 aqua^c joined #salt
20:41 adelcast joined #salt
20:43 geekatcmu OK, I think I'm confused.
20:44 geekatcmu when I want to add a new alternative, I use alternatives.install.
20:44 geekatcmu If I want to actually *switch* to that alternative, I need to use alternatives.auto (or .set_).
20:44 geekatcmu But, if I try to do both, I get the old "multiple state declarations of the same type".  What's to do?
20:45 geekatcmu and of course, now that I've typed all that out, I remember the name= override.
20:45 * geekatcmu sighs
20:47 funzo joined #salt
20:49 aqua^c joined #salt
20:50 giantlock joined #salt
20:51 murrdoc do runners go under the ext_module directory
20:51 murrdoc or the state file root
20:57 murrdoc thanks gais
20:58 manfred murrdoc:  i think you have to configure the runner_dirs option in /etc/master
20:58 manfred i have never tried doing it without modifying that
21:00 sgargan joined #salt
21:02 pipps99 joined #salt
21:05 pipps_ joined #salt
21:06 sgargan joined #salt
21:07 aqua^c joined #salt
21:07 stanchan joined #salt
21:12 KyleG joined #salt
21:12 KyleG joined #salt
21:13 murrdoc Gareth:  can salt runners be scheduled :)
21:14 murrdoc manfred:  turns out if u setup an external module dir, say for  an ext_pillar
21:14 murrdoc you can put the runners in a 'runner/' direcotry init
21:15 sgargan joined #salt
21:15 tzero joined #salt
21:16 dopesong joined #salt
21:16 aqua^c joined #salt
21:17 dopesong_ joined #salt
21:20 iggy should be able to use any of the normal modules
21:22 otter768 joined #salt
21:22 iggy I think utils and stuff too
21:23 sgargan joined #salt
21:25 cberndt joined #salt
21:25 aqua^c joined #salt
21:32 napsterX joined #salt
21:35 sgargan joined #salt
21:44 aqua^c joined #salt
21:44 jaybocc2 anyone have jobs that say "data failed to compile" "The function "state.highstate" is running as PID 30579 and was started at 2015, Jul 28 21:38:39.751843 with jid 20150728213839751843"
21:44 jaybocc2 which is the job that was started by state.highstate
21:44 jaybocc2 all the other nodes returned but occasionally this happens
21:45 jaybocc2 and when i try to check that job, it shows data for a DIFFERENT node, the node in question doesn't pickup its changes
21:46 jalbretsen joined #salt
21:49 __monty__ joined #salt
21:49 sgargan joined #salt
21:51 iggy jaybocc2: stop the minion, check for other minion processes, kill if necessary, start minion service
21:56 c10b10 joined #salt
22:02 aqua^c joined #salt
22:03 sgargan joined #salt
22:03 pipps joined #salt
22:05 Bryson joined #salt
22:07 ayee How does the openshift naming convention relate to the kubernetes one?
22:07 ayee er, wrong window. ignore.
22:07 omegamike joined #salt
22:11 aqua^c joined #salt
22:19 mapu joined #salt
22:20 stoogenmeyer_ joined #salt
22:20 aqua^c joined #salt
22:20 hasues left #salt
22:21 stoogenmeyer_ joined #salt
22:24 sunkist joined #salt
22:29 aqua^c joined #salt
22:29 b18 joined #salt
22:30 Nazca joined #salt
22:31 monkey66 left #salt
22:33 napsterX joined #salt
22:35 coval3nce joined #salt
22:36 coval3nce Is it possible to use jinja maps in pillar files similar to states in order to dynamically perform some mappings in pillars based off grains?
22:36 coval3nce e.g., map certain things to pillar values depending on grains of the minions
22:37 coval3nce For example, if minions have ip’s in subnet A, set pillar value X, etc etc
22:37 phx coval3nce, sure. #!py
22:38 phx coval3nce, with the python renderrer you can also contact an external-to-salt inventory and return data based on that
22:39 coval3nce hmm, how would i access grains within that py file?
22:39 coval3nce I see the docs mention this as a “state” renderer, but it can be applied to pillars as well? http://docs.saltstack.com/en/latest/ref/renderers/all/salt.renderers.py.html
22:39 phx salt is written in python. it has a python API
22:40 coval3nce Ah i see the grrains object __grains__
22:40 phx also that
22:40 phx the python renderrer is a bloody powerful tool
22:40 coval3nce Grains from a minon are available in the compilate of the pillar for that minion correct?
22:40 coval3nce *compilation
22:41 phx that should be the case, yes
22:42 coval3nce ok, this might get me started then
22:42 coderMe joined #salt
22:42 coval3nce phx: thanks a lot!
22:42 coval3nce didn’t even know a python renderer existed
22:45 coval3nce sweet, justed tested it out as a pillar rendere and it works
22:46 phx coval3nce, awesome
22:46 phx coval3nce, i used the py renderrer in pillars to connect salt to my own inventory database, and provide per-host configuration based on a more granular inventory
22:46 coval3nce thats exactly what i want to do in the long run
22:46 coval3nce but right now, some ghetto “is this ip in this subnet” logic will have to do
22:46 phx so i configured the inventory to its details, then salt knew through the pillars what states to assign with what data provided
22:47 sgargan joined #salt
22:47 coval3nce that is a great endstate to be at
22:47 aqua^c joined #salt
22:47 coval3nce Hmm i swore there were some helper ip address functions in salt somewhere
22:48 coval3nce sweet…salt.modules.network.in_subnet
22:48 phx python 2 or 3?
22:48 coval3nce 2
22:48 phx https://pypi.python.org/pypi/py2-ipaddress/
22:49 phx in 3 it's builtin
22:49 iggy salt has most of that stuff already
22:49 phx if you by any chance overstep the capabilities of the salt one
22:49 coval3nce I can use the salt one tho
22:49 coval3nce gotcha, thanks
22:49 iggy you really want to do as little importing modules in py rendered files as possible
22:49 murrdoc also py renderer bad
22:49 murrdoc custom state is much better
22:50 iggy pillars
22:50 coval3nce Is pyrender bad if i wan to use common computed pillar data amongst my states?
22:51 coval3nce Implementign the same mapping logic in states seems wrong (if mapping logic is same to differrent key/value pairs uses amongst many states)
22:51 murrdoc i would have done a custom pillar
22:51 murrdoc or a map.jinja
22:51 coval3nce E.g., if host in dataceter A, it uses syslog host x, ntp, y, sensu z  etc
22:51 sgargan joined #salt
22:51 iggy we have grains for that stuff
22:51 murrdoc uh hmm
22:52 murrdoc or heira and ext_pillar
22:52 nzero joined #salt
22:53 coval3nce Ideallly i would pass a grian to an ext_pillar and let it do the work
22:54 murrdoc as u should
22:54 coval3nce But i dont have an external data source for now, so baby steps i guess.
22:55 napsterX joined #salt
22:55 pipps joined #salt
22:56 aqua^c joined #salt
22:58 lompik joined #salt
23:00 _JZ_ joined #salt
23:00 sgargan joined #salt
23:05 aqua^c joined #salt
23:06 sgargan joined #salt
23:07 eliasp joined #salt
23:09 omegamike joined #salt
23:11 keimlink_ joined #salt
23:12 sunkist joined #salt
23:13 aron_kexp joined #salt
23:14 aqua^c joined #salt
23:15 sgargan joined #salt
23:23 otter768 joined #salt
23:23 aqua^c joined #salt
23:23 sgargan joined #salt
23:25 c10b10 joined #salt
23:26 pipps joined #salt
23:29 sgargan joined #salt
23:31 breakingmatter joined #salt
23:32 forrest joined #salt
23:32 aqua^c joined #salt
23:40 murrdoc joined #salt
23:42 aqua^c joined #salt
23:46 pdayton joined #salt
23:47 eliasp joined #salt
23:51 aqua^c joined #salt
23:52 nzero joined #salt
23:58 jaybocc2 anyone know if there is a way to disable output for a particular state???
23:58 jaybocc2 ex: a state that runs a command that requires a sensitive key

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