Perl 6 - the future is here, just unevenly distributed

IRC log for #salt, 2013-06-20

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

All times shown according to UTC.

Time Nick Message
00:01 mianos corey, I want to back up the production data to migrate for test or for archival
00:01 mianos today it's to create the same data on another cluster for testing
00:01 Corey mianos: You can fire off a process with Salt, or are you talking about using the salt bus itself to transport the data?
00:02 mianos that's the question
00:02 Corey You *can* do the latter, but it's inefficient.
00:02 mianos can just use salt to fire off and ssh to copy
00:02 Corey That's what I'd do.
00:02 jeddi i've got pip installed via .. err .. well pip.  (i'm using a pip-installed pip, and since removed the debian python-pip package, because the deb package is quite old).  anyway.  salt complains that it can't find a pip binary - presumably because it's in /usr/local/bin/pip  ... do i do a dodgy symlink somewhere, or is there a neater answer?
00:02 mianos but using salt I have not much connectivity between the servers
00:02 mianos I have not even logged into some of them, ever
00:02 Corey If this is within the LAN you can boost your performance by knocking down the SSH encryption.
00:02 mianos I'm like to be as lazy as possible
00:03 Corey mianos: How big is your dataset?
00:03 Corey mianos: The reason I ask is that as Salt is currently architected, the data has to pass to the other minion by way of the master.
00:03 Corey jeddi: How're you invoking salt?
00:03 Corey jeddi: Sounds like a pathing issue.
00:06 Slipo joined #salt
00:06 jeddi Corey: just running salt on the master, you mean?  no difference to 'usual'.
00:06 mianos dataset is smallish now but will grow
00:06 mianos so ssh the data back
00:06 jeddi Corey: salt minion will ahve its own path, i'm guessing, rather than pick it up from root's $PATH ?
00:08 jeddi mianos: not sure if it's useful to you - but i recently set up a backup of a mysqldump that runs every 2 hours (so quite a lot of separate backups) that i imported into a git repo.  it means i can keep a local backup to the machine (fast to extract, and update), and then git clone that back centrally (also very fast as it's jsut doing differentials of the text file backup.sql (or whatever))
00:09 jeddi mianos: there is Some Talk about this on various blogs on the intergoogles - there are certain parameters you can pass to mysqldump to get a slightly more friendly-to-git output.  unfortunately they are the kinds of things (more newlines being the obvious) that massively slow down the speed with which you can restore from.   but worth checking out.
00:10 Corey jeddi: It sources bin_env
00:10 jeddi Corey: ah, okay.  hmm.
00:11 Corey Checking exactly how.
00:11 Corey jeddi: def _get_pip_bin(bin_env):
00:11 Corey which_result = __salt__['cmd.which_bin'](['pip2', 'pip', 'pip-python'])
00:13 derelm joined #salt
00:13 Corey jeddi: Okay, it searches path, then appends         default_path = '/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin'
00:19 aat joined #salt
00:20 kstaken joined #salt
00:21 bensix2 joined #salt
00:22 bensix2 joined #salt
00:22 kstaken Should salt events work on a minion that's not connected to a master? The sockets don't show up in /var/run/salt/minion unless the minion connects to a master.
00:22 lex__ joined #salt
00:38 mianos too much data for a git repo, ssh it's going to be I think
00:39 mianos when I say smallish I mean 100s of megs
00:39 jacksontj joined #salt
00:40 Gwayne joined #salt
00:40 Gwayne joined #salt
00:41 jeddi Corey: hey, thanks for looking that up.  well, my pip is definitely at /usr/local/bin/pip .. so that's a bit weird.  i've restarted the salt-minion daemon since installing pip by pip (and removing the python-pip deb package).  might try the windows approach and just reboot him.
00:41 aat joined #salt
00:41 jeddi mianos: ack.  my dumps are ~600mb of .sql file.
00:41 aranhoide joined #salt
00:42 jeddi mianos: git is *very* good at compressing, and *reasonably* good at doing diffs even on plain sql dump files.  it's (apparently) especially good at storing tiny diffs for sql files that have more newlines.
00:42 mianos ah ok, also the issue of 8 servers
00:42 jeddi mianos: for shits and giggles you should jsut give it a go - take a dump, take a handful of recent backups, git add them, and see how you go.
00:42 Corey Yeah, that works ONLY if the deltas are small.
00:42 mianos deltas will be small
00:42 mianos not a scientific shop here :)
00:43 jeddi Corey: in my case the deltas are .. well, 2-hourly, so that's quite small.  and my db is almost exclusively being added to.  no updates or deletes.
00:43 Corey Hmm.
00:43 Corey I *think* git can handle that effectively, but I'm not positive.
00:43 jeddi but, as i say, i'm sitting on ~600mb worth of dump t a time.
00:43 jeddi you have to bump up some of your git configuration to take better use of the memory.
00:43 mianos interesting idea, as the idea is to migrate not for archive
00:43 jeddi git gc --aggressive .. i don't bother doing anymore - it chewed up the machine for some tens of minutes (lowly 1GB rackspace vm, single core, etc).   just not worth it.
00:44 jeddi now i just pull in a new directory, and move the old git-archive to one side, every week or fortnight.
00:44 mianos although if it's only a storage issue I think rsync is probably as good as git and actually designed for the job
00:45 jeddi mianos:  FYI - http://rn0.ru/show/dtxbWn4ID8XJtK97s9uZ/  <-- shoes the types of config changes you can make to gitconfig to assist you - bump these numbers up to taste, of course.
00:45 jeddi mianos: rsync's the obvious first choice, too, yes.  but f you ened archive, not just backup, then .. you still have the problem of maintaining multiple snapshots.
00:47 mianos yes, git might win due to the differential nature of each backup
00:47 mianos and it's got a versioning, obtuse as it is, system built in
00:48 jeddi final note on this subject -- just checked my current archive - it contains 212 commits, of a single ~690MB file, and the .git sub-directory is ~34GB.    this is bang on one month for me, of 2-hourly backups done during business hours mon-fri (or thereabouts).
00:49 jeddi if i was on real hardware / decent vps, then i'd look at doing aggressive git gc .. but i'm not .. so it's a simple tradeoff of storage .v. cpu.
00:49 Corey Might ask in #git about this.
00:49 Corey Seems like it's a bit overkill. :-)
00:50 jeddi http://stackoverflow.com/questions/4261480/is-it-viable-to-handle-mysql-backups-with-git
00:51 brettlangdon joined #salt
00:51 jeddi probably not the most compelling page. :)  google has plenty of hits of 'back up mysql with git'  anyway .. really .. i should stop selling this. :)
00:54 mianos jeddi, just had a huddle with the engineering team here, git it is :)
00:55 jeddi mianos: haha .. :)
00:56 jeddi mianos: the beautiful thing is that if it annoys you in a week or a month from now, it's going to be really easy to extract the bits you want to keep.   as i say, gc was painful, so i just rotate monthly.  you can then decide your archiving policy, and extract weekly copies from that old archive then ditch the fuller version, etc.  archive policies are a whole world of fun in themselevs.
00:58 m_george|away joined #salt
00:59 Corey mianos: Just be careful with size. I'm not sure that git just stores diffs. :-)
01:00 m_george left #salt
01:01 mianos hmm, not diffs
01:01 mianos that may fail the idea
01:02 mianos maybe the same thing using subversion
01:09 Ixan joined #salt
01:10 jchen joined #salt
01:10 basepi joined #salt
01:10 Furao joined #salt
01:12 jeddi Corey: git very definitely stores diffs.  the point is it stores diffs with a preference / eye to line-level changes.   so massively long lines that mysqldump produces can skew results.
01:12 EugeneKay joined #salt
01:13 N-Mi joined #salt
01:13 N-Mi joined #salt
01:13 echos joined #salt
01:14 oz_akan_ joined #salt
01:14 fragamus joined #salt
01:17 mianos subversion is has other handy attributes
01:18 mianos for example it does not need a complete repo, it stores the last version you synced only
01:18 mianos so you really only have two backups on each server
01:19 oz_akan_ hi all
01:22 oz_akan_ do you guys have an advice for keeping passwords in salt but out of a git repo (assuming all state/pillar files are under git)
01:23 mianos git does not store diffs, it creates a hash for each file and only stores changed filed, but as whole files, not diffs
01:23 mianos if you have a large tree with mostly unchanged files it does not have to store much
01:24 auser oz_akan_: hey
01:24 auser I use gitfs
01:25 auser and I mount an FS on there for all pillar data
01:25 oz_akan_ so do you keep passwords in pillar but everything else on gifts?
01:34 jeddi mianos: the way it handles blobs is a bit more diff-like than whole-file like, i think.k
01:35 jeddi that is - it looks for common bits between two files (or two generations of the same file).
01:35 jeddi oz_akan_: would you be happy to have them in /srv/pillar (say) but managed outside of git (via .ignore) say?
01:36 oz_akan_ yes, salt-master is in my environment, considered to be safe, while github is a public service which I can not control
01:37 oz_akan_ with git, I mean a service like github
01:37 oz_akan_ actually, one thing I could do is, ignore a specific pillar file from git and place all sensitive content in that
01:40 kermit joined #salt
01:50 mgw joined #salt
01:50 aat joined #salt
01:51 napperjabber joined #salt
01:57 melinath joined #salt
02:00 lex__ joined #salt
02:01 Slipo joined #salt
02:03 Nexpro joined #salt
02:03 EugeneKay !config_files
02:03 EugeneKay Oh right, no bot here.
02:03 EugeneKay https://gist.github.com/canton7/1423106
02:04 EugeneKay That's some good reading on dealing with sensitive data in a git repo(or rather, not dealing with)
02:04 EugeneKay For pillar I just keep the repo secret and commit everything for auditing & easy updating.
02:05 EugeneKay If you want to keep passwords in pillar, just use include a gitignored-file inside /srv/pillar/ and call it a day.
02:10 bemehow joined #salt
02:12 auser yep
02:12 auser that's another way
02:12 cxz but then where will we go EugeneKay
02:12 jeddi isn't that the same way that i suggested? ;)
02:12 cxz it's like the dwarves from LoTR
02:13 cxz where will we go gandalf
02:13 cxz where will we store our passwords
02:13 EugeneKay In our ears
02:13 cxz :<
02:14 EugeneKay jeddi - yup, but with a link to back it up :-p
02:15 jeddi ah.  those danged rascally links!
02:16 * EugeneKay curses at highstate
02:19 EugeneKay Scratch that.
02:19 * EugeneKay curses at 15.3
02:23 EugeneKay Yay, fixed it. Needed two more spaces -_-
02:38 aat joined #salt
02:39 juicer2 joined #salt
02:42 juicer2 left #salt
02:44 cxz joined #salt
02:52 cxz joined #salt
02:53 jalbretsen joined #salt
03:06 cxz joined #salt
03:10 zonk1024 joined #salt
03:11 napperjabber joined #salt
03:24 Rick1 joined #salt
03:33 maspwr joined #salt
03:34 jhauser joined #salt
03:41 fragamus joined #salt
03:44 aat joined #salt
03:48 omame joined #salt
03:49 stas joined #salt
03:53 cxz joined #salt
03:54 copec joined #salt
03:54 copec joined #salt
03:56 adotbrown would anyone be able to help me debug salt-cloud? when based on the example aws configs - my cloud deploy just hangs on `[INFO    ] Creating Cloud VM saltspawn in us-east-1` and then drops off silently
03:58 EugeneKay joined #salt
03:58 N-Mi joined #salt
03:58 N-Mi joined #salt
04:03 napperjabber joined #salt
04:13 cxz joined #salt
04:31 jdenning joined #salt
04:35 cxz joined #salt
04:43 lex__ joined #salt
04:52 idkfa joined #salt
04:56 djn joined #salt
05:07 maspwr joined #salt
05:09 cxz joined #salt
05:10 jefimenko joined #salt
05:11 krissaxton joined #salt
05:11 middleman_ joined #salt
05:24 jdenning joined #salt
05:28 stas joined #salt
05:29 SpX joined #salt
05:30 azbarcea joined #salt
05:30 az87c joined #salt
05:39 jhauser joined #salt
05:39 melinath joined #salt
05:41 Slipo joined #salt
05:46 bemehow joined #salt
05:51 jhauser joined #salt
06:04 auser joined #salt
06:11 linjan joined #salt
06:14 yidhra joined #salt
06:16 xiaocong joined #salt
06:26 jeffmendoza joined #salt
06:28 vaxholm joined #salt
06:41 giantlock joined #salt
06:42 fragamus joined #salt
06:45 nullity joined #salt
06:46 agend joined #salt
06:46 agend hello
06:47 nullity man, talk about rubber duck programming... I join here to ask a question and immediately figure it out without even asking
06:47 nullity so... thanks guys :)
06:49 pentabular joined #salt
06:49 agend what is the best way to do this: i have a system which consists four/five machines - I work on it locally using vagrant and shared directories - but in deployment i want the remote machine to clone my git repo - how should i configure salt to achive this?
06:49 f4cl3y joined #salt
06:49 f4cl3y joined #salt
06:52 jdenning joined #salt
06:52 stas joined #salt
07:13 dthom91 joined #salt
07:17 nliadm joined #salt
07:24 drozer joined #salt
07:25 fredvd joined #salt
07:25 fspot joined #salt
07:29 stas joined #salt
07:36 bemehow joined #salt
07:47 djn joined #salt
07:51 adotbrown joined #salt
08:01 krissaxton joined #salt
08:02 Lucas joined #salt
08:03 __gotcha joined #salt
08:03 __gotcha joined #salt
08:08 jefimenko joined #salt
08:11 felixhummel joined #salt
08:12 dthom91 joined #salt
08:18 yidhra joined #salt
08:21 melinath joined #salt
08:22 krissaxton left #salt
08:24 krak3n` joined #salt
08:31 p3rror joined #salt
08:40 carlos_ joined #salt
08:42 dthom91 joined #salt
08:49 zooz joined #salt
08:50 tonthon hi
08:50 tonthon is the match: nodegroup matching patern supposed to work in the pillar top.sls file ?
08:54 jesusaurus joined #salt
08:57 tonthon ok, it's just not working through salt-syndic
09:02 pgSnake left #salt
09:08 mikedawson joined #salt
09:15 scott_w joined #salt
09:17 Nexpro joined #salt
09:18 Lucas joined #salt
09:26 djn joined #salt
09:32 Teknix joined #salt
09:35 zooz joined #salt
09:43 Nexpro joined #salt
09:53 Tekni joined #salt
10:11 Teknix joined #salt
10:19 gmoro joined #salt
10:22 Slipo joined #salt
10:23 middleman_ joined #salt
10:28 gargmel joined #salt
10:42 fspot left #salt
10:43 carmony joined #salt
10:45 gmoro joined #salt
10:52 efixit joined #salt
10:52 Teknix joined #salt
10:52 faust joined #salt
10:55 gargmel i have a theory
10:59 krissaxton joined #salt
11:01 middleman_ joined #salt
11:03 aleszoulek joined #salt
11:13 joehh gargmel: ?
11:14 adotbrown joined #salt
11:39 giantlock joined #salt
11:45 knightsamar joined #salt
11:46 drawsmcgraw joined #salt
11:46 knightsamar hi, is there a VM or AWS image available where I can try out salt quickly ?
11:51 EugeneKay Searching public AMIs for "salt" comes up with nothing, but you can pretty trivially yum/apt-get install salt-minion per the docs
11:52 jeddi knightsamar: as EugeneKay indicates, you can just apt-get or yum install salt-minion + salt-master on the same vm very quickly.
11:52 drawsmcgraw knightsamar: I agree with EugeneKay. I went from "What is Salt?" to "I have a Master and a Minion" in under 45 minutes via yum install salt-(master | minion)
11:52 knightsamar but  i will also need to setup zeroMQ ?
11:53 drawsmcgraw knightsamar: I didn't
11:53 EugeneKay The rpm/deb handles the setup of that.
11:53 drawsmcgraw Yum did all the legwork for me.
11:53 knightsamar ok thanks everyone :) will give it a try
11:57 oz_akan_ joined #salt
12:05 drawsmcgraw I see how to populate an SLS file with pillar data. But how do I put pillar data in, say, a managed file?
12:07 middleman_ joined #salt
12:07 Furao drawsmcgraw: https://github.com/bclermont/states/tree/master/states check here for hundred of examples
12:09 drawsmcgraw Furao: Awesome, thanks. Do managed files need the extension (e.g. .jinja2) in order to be interpreted correctly?
12:11 Furao no
12:11 Furao it's just my IDE that nicely handle jinja template when they got this extension
12:11 drawsmcgraw got it
12:11 Furao not just colours but it parse jinja in real time
12:11 drawsmcgraw Also -> IDE? What are you using to manage your SLS files? I could use an upgrade from Vim eventually...
12:12 Furao PyCharm
12:12 drawsmcgraw Sweet. Thanks
12:20 fragamus joined #salt
12:21 jslatts joined #salt
12:22 mikedawson joined #salt
12:22 Mouzz joined #salt
12:24 williamthekid_ joined #salt
12:28 ada joined #salt
12:29 drawsmcgraw Furao: Turns out I failed to specify 'template:jinja' for my State dec. I figured it was implicit since jinja is the default template engine. I was wrong.
12:37 oz_akan_ joined #salt
12:38 brettlangdon left #salt
12:39 karlp drawsmcgraw: I got caught on that too :|
12:39 snixor joined #salt
12:40 snixor hello
12:40 snixor I'm a first time user of salt
12:40 snixor and i need a little help with adding contrib states
12:40 bhosmer joined #salt
12:40 krissaxton left #salt
12:42 snixor what would be the process to /  how do I add archive state?
12:43 snixor https://raw.github.com/saltstack/salt-contrib/master/states/archive.py
12:46 fredvd joined #salt
12:48 snixor eeh.  it's working now :)
12:48 Furao snixor: https://github.com/bclermont/states/blob/master/states/_states/archive.py#L15
12:48 drawsmcgraw I can get a pillar value to render correctly in a managed file on a Linux minion. But I hit a problem when trying it on a Windows minion. Stack trace that ends in --> salt/modules/file.py, line 1519, in manage_file  \n   NameError: global name 'contextlib' is not defined.
12:49 Furao what you got is probably an old version
12:52 drawsmcgraw I'm running 0.15.3
12:52 drawsmcgraw Of the Windows minion
12:53 knightsamar salt rox! :)
12:53 drawsmcgraw I'm looking through the debug log to see if there's a corresponding import error
12:53 drawsmcgraw And that's 60 minutes for knightsamar to go from 'What is salt?' to 'Salt rox' :)
12:55 middleman_ joined #salt
12:58 drawsmcgraw Looking at the logs on the Master, I'm also seeing an import error: salt/modules/win_file, line 36  ---> "cannot import name namespaced_function"
12:59 drawsmcgraw That's when I do a salt run against the Windows Minion
13:05 snixor what would be the preffered way for  pushing a website to minions?
13:05 snixor is it acceptable to do this with archives?
13:07 LyndsySimon joined #salt
13:08 Kholloway joined #salt
13:10 EugeneKay Via salt? The easy way is the git.latest state module; harder(and less prone to eating its own HEAD) is to make a rpm/deb and use pkg.latest
13:11 EugeneKay In #git I point to this doc, which has a lot of good info. http://sitaramc.github.com/the-list-and-irc/deploy.html
13:13 juicer2 joined #salt
13:15 m_george|away joined #salt
13:18 whiskybar joined #salt
13:21 carmony joined #salt
13:25 drawsmcgraw Found my fix!   https://github.com/saltstack/salt/pull/5502/files
13:25 drawsmcgraw And the original issue: https://github.com/saltstack/salt/issues/5406
13:29 m_george left #salt
13:30 bhosmer joined #salt
13:30 racooper joined #salt
13:31 oz_akan_ joined #salt
13:34 timoguin joined #salt
13:36 fragamus joined #salt
13:42 maspwr joined #salt
13:44 shea joined #salt
13:47 LarsN I'm working with salt-cloud & the HP Cloud.  I think I'm probabily doing something wrong with my /etc/salt.providers file. When I create an instances in the cloud It looks like, regardless of the profile I specify that it picks either the first or last region from the list and ALWAYS uses it.
13:48 LarsN http://p.intma.in/pastes/2013-06-20T09:43:15 is a paste of my cloud.providers
13:48 LarsN would someone be willing to take a look for any idiocy on my part?
13:50 snixor what would be the correct way of adding a new repository to my minions?
13:50 jacksontj joined #salt
13:50 snixor yum reposiroty
13:54 shea What is the best way to tell if your gitfs_remote is working correctly? I have started the salt-master with logging set to debug but I don't see a clear indication if my problem is with my git repo or my top.sls file.
13:58 LarsN shea: you could run it using "salt-call state.highstate"
13:58 LarsN from the minion.  There appears to be a lot more debugging info printed to the screen from that end.
13:59 LarsN snixor: you could use something like...
14:00 LarsN /etc/yum/repos.d/newrepo
14:00 LarsN file.managed:
14:00 LarsN - source: salt:///configs/newrepo
14:00 LarsN in an sls.
14:00 shea Thanks LarsN, I will give that a shot.
14:01 snixor understand. thank you!
14:01 snixor *understood
14:01 LarsN shea: I don't know if that will solve your problem, but it MIGHT help add insight.
14:10 p3rror joined #salt
14:11 gaston joined #salt
14:11 aberant joined #salt
14:12 gaston ohai - resumed debugging why test.ping was timing out on OpenBSD - turns out it tries to connect to 0.0.0.0:4506 which is obviously wrong
14:12 gaston anyone might have a clue at where salt does the dns resolution magic/low-level networking stuff ?
14:14 fredvd joined #salt
14:15 terminalmage joined #salt
14:20 gaston it seems a bit better if i set the ip in /etc/salt/master but it though this wasnt necessary ?
14:20 mgw1 joined #salt
14:23 gaston just wondering if it's an openbsd-specific issue or if anyone else experienced that 0.0.0.0 error...
14:24 joshe iirc it's a linux-specific issue that connecting to 0.0.0.0 works at all :)
14:24 lex__ joined #salt
14:24 lex___ joined #salt
14:24 gaston aha :)
14:24 gaston that might explain
14:25 gaston joshe: oh, you there :p
14:25 joshe the correct thing to do is to probably add a check in the programs which read the master config and if the listen address is 0.0.0.0, connect to a specific real IP
14:26 aat joined #salt
14:26 gaston yeah but that means you need an heuristic to guess which IP to use :)
14:26 fys joined #salt
14:26 joshe perhaps python has an API which portably yields a local IP address
14:27 gaston or i could force users to set the public ip in the master config..
14:27 fragamus_ joined #salt
14:27 joshe an acceptable workaround, but I wouldn't call it a proper fix
14:27 fridder joined #salt
14:28 gaston so i only need to make the pam thing optional and the port should be ready..
14:29 fridder joined #salt
14:30 abe_music joined #salt
14:30 napperjabber joined #salt
14:34 LyndsySimon joined #salt
14:34 pentabular joined #salt
14:36 tonthon Hi, is there some doc or example about pillar provisionning ?
14:37 tonthon I'd like to be able to extend pillar datas through commands result
14:37 tonthon typically : run salt "farm" cloud.create
14:37 tonthon and get the ip, the vm's name, hostname ... in pillar
14:38 timl0101 joined #salt
14:42 drawsmcgraw tonthon: http://docs.saltstack.com/topics/tutorials/pillar.html
14:42 drawsmcgraw Also (for next time): http://docs.saltstack.com/contents.html
14:44 tonthon drawsmcgraw: I already red this one about pillar
14:45 jacksontj joined #salt
14:45 tonthon I was trying to understand how salt.pillar.* libraries work
14:46 fspot joined #salt
14:46 __gotcha joined #salt
14:46 __gotcha joined #salt
14:48 baniir joined #salt
14:51 jeddi joined #salt
14:52 drawsmcgraw ah. Sorry
14:55 aberant joined #salt
14:55 krak3n` joined #salt
14:57 kho joined #salt
14:58 krak3n`_ joined #salt
15:01 shea A general suggestion: if there could be better debug notification when gitfs is not working, that would be really helpful. I made a stupid mistake and it took a long time to find it. Debuging messages would have helped.
15:01 gaston left #salt
15:02 dthom91 joined #salt
15:02 jacksontj_ joined #salt
15:03 bhosmer joined #salt
15:06 rkjr joined #salt
15:08 Rick1 joined #salt
15:09 backjlack joined #salt
15:09 bfrog is there someway to add a yum repo easily using salt?
15:09 snixor I'm getting an error: State archive.exctracted found in sls package-www is unavailable
15:09 snixor rings any bells?
15:09 bfrog not seeing squat on how to do it
15:10 jdenning joined #salt
15:10 snixor bfrog:  i was asking the same thinf
15:10 snixor thing
15:10 snixor the answer was
15:11 snixor something like:
15:11 snixor ./etc/yum.repo.d/remi.repo:
15:11 snixor file.managed:
15:11 snixor - source: salt://tas/lighttpd/yum.repo/remi.repo
15:11 snixor in a sls file
15:11 jalbretsen joined #salt
15:12 bfrog ah, so put all that stuff in the salt state stuff
15:14 chrisgilmerproj joined #salt
15:15 mgw joined #salt
15:15 bfrog still confused by the directory layout
15:15 bfrog there needs to be alike a big repo of examples
15:15 bfrog figuring this out from docs is ok... but a working example is like 10x more useful
15:16 akoumjian bfrog: saltstarters.org has a few
15:17 teskew joined #salt
15:20 jeddi bfrog, snixor: there's also this  http://docs.saltstack.com/ref/modules/all/salt.modules.apt.html#salt.modules.apt.mod_repo
15:21 snixor could someone help me out with why my state in unavailable?
15:22 snixor how can I debug this issue?
15:22 snixor I am using an archive contrib state
15:23 napperjabber joined #salt
15:24 bfrog I'm not using apt
15:24 bfrog though maybe I should since centos is freakin ancient
15:25 samsalt joined #salt
15:29 jschadlick joined #salt
15:29 danielbachhuber joined #salt
15:30 wendall911 joined #salt
15:32 cdn joined #salt
15:35 cdn HI all, hopefully and easy question. I have two cmds in my state .sls file but I want to make sure the 2nd cmd only runs when the first one is complete, is that possible? Both are extracting files. Trying prereq: -cmd: name-of-command   but no luck
15:38 jeddi cdn: can you require the presence of the first file(extract) ?
15:40 jeddi cdn: http://rn0.ru/show/m0AOKKJZSmdavgx5fLMV/ shows how i only run a cmd IFF a specific directory doesn't exist.  Will that approach work?
15:42 bemehow joined #salt
15:45 napperjabber joined #salt
15:46 bemehow joined #salt
15:51 napperjabber joined #salt
15:52 Ryan_Lane joined #salt
15:55 cdn Does require: make it wait or will fail if requirement isn't present
15:59 jacksontj joined #salt
15:59 mgw Does anyone else think the idea of a pluggable "hash" system for file.managed would be useful? E.g., two files may be substantially equal but have different hashes. And that difference may be important.
16:00 bfrog so I need to run initdb after installing postgres but before starting it
16:00 bfrog actually I need to run a few commands
16:00 bfrog is there an example or could someone point me in the right direction on how to do that
16:01 milind joined #salt
16:05 jeddi cdn: it simply won't run if that returns false.
16:05 jeddi cdn: so with my fragment, if /etc/.git exists, then it doesn't run the cmd.   sorry - logic around the wrong way - but you know what i mean.
16:06 bhosmer joined #salt
16:06 cdn hmm, ok thanks.. Looking for how to make cmd2 wait on cmd1 then run cmd2 when cmd1 is complete
16:06 jeddi bfrog: curiously the same example i pasted above will (mostly) do this for you.   the only problem is that postgres, if you install it from a package, may try to start automatically?  i think with debian and derivatives it does, though there may be a way to discourage it.
16:07 jeddi cdn: if you think of it in terms of 'what file can cmd1 generate that i can then test for the presence of before running cmd2' - it may be more managable.
16:08 cdn OK can figure one of those out, but I want to make sure cmd2 can still run
16:08 jdenning joined #salt
16:08 jeddi mgw: like http://docs.saltstack.com/ref/modules/all/salt.modules.file.html#salt.modules.file.check_hash does, or something else?
16:09 jeddi cdn:  just to clarify - you want cmd2 to run iff cmd1 has run, right?  and cmd2 needs only ever be run the once, not every time you run a highstate, is that right?
16:13 fspot left #salt
16:14 krak3n`_ joined #salt
16:16 timl0101 joined #salt
16:17 bfrog jeddi: I saw that, but it doesn't run initdb, the archlinux package doesn't automatically run initdb on the first startup
16:17 pentabular joined #salt
16:17 Nexpro1 joined #salt
16:17 mgw jeddi: like, that, but pluggable
16:17 mgw my particular use case is to be able to run an external command to compare the substance of two files
16:17 mgw instead of checking their md5sums
16:20 mgw jeddi: e.g., corey and I have been discussing how to only replace a bind zone file if more than the serial has changed.
16:20 kermit joined #salt
16:21 mgw It occurred to me that this could be easily accomplished if the templated zone file puts in a new serial, but the change only gets applied if a diff ignoring the serial turns up changes. Rather than writing a whole new module to manage zone files, a pluggable 'hash' system could solve this problem.
16:22 bemehow_ joined #salt
16:23 jeddi bfrog: hey, nice.   the auto-start stuff for some packages does annoy me every now and then on debian.
16:24 jeddi mgw: oh - okay - that's qiute a more complex problem domain :
16:24 bfrog so I have salt installing some basic stuff, but I want to have like a "dev" role, "postgres" role, etc
16:25 bfrog so I start a masterless minion, tell it to setup the state of the minion for doing development
16:25 bfrog right now I have base: '*': ....
16:25 bfrog whats the typical way people do this?
16:26 bfrog is that the minion config grains stuff?
16:26 EugeneKay Grains.
16:26 bfrog so I need to change the minion config for that right
16:27 bfrog and setup grain matching in my top.sls
16:27 jeddi bfrog: i don't know about best practice, but i have a /srv/salt/base.sls that is applied to EVERY machine, yes.
16:27 EugeneKay Yup.
16:27 jeddi after that .. grains that manage environments (dev, prod) .. and the nomenclature in the salt docs is *mostly* pretty consistent.  roles are things ilke 'web' or 'database', and environments are 'dev', 'prod'.  but a few places some people have slipped into talking about a 'dev' role.
16:28 EugeneKay Separate dev environments are for sissies :v
16:29 LarsN I'm working with salt-cloud & the HP Cloud.  I think I'm probabily doing something wrong with my /etc/salt.providers file. When I create an instances in the cloud It looks like, regardless of the profile I specify that it picks either the first or last region from the list and ALWAYS uses it. http://p.intma.in/pastes/2013-06-20T09:43:15 is a paste of my cloud.providers. Would someone be willing to take a look for any idiocy on my part?
16:29 jeddi bfrog: i set some grains during salt-cloud (provisioning) time and then manage them via a file owned by salt-master located at /fs/etc/salt/minion.d/grains.conf
16:29 jeddi the files are called grains.conf.{{ id }} or {{ dev }} or .DEFAULT  .. using that neat fall-through trick for source:
16:29 jeddi LarsN: known bug, if it's what i think it is.
16:30 bhosmer_ joined #salt
16:30 jeddi LarsN:  is this it?  https://github.com/saltstack/salt-cloud/issues/640
16:31 jeddi LarsN:  or rather this, i think https://github.com/saltstack/salt-cloud/issues/546
16:32 LarsN I'm looking at both of those links jeddi thanks!
16:32 aberant joined #salt
16:33 jeddi LarsN: it looks like s0undt3ch has done some patches .. i knew it's coming up soon .. but pip still reports 0.8.8 is the latest.
16:33 Rick1 left #salt
16:34 melinath joined #salt
16:34 s0undt3ch jeddi: ?
16:34 s0undt3ch jeddi: salt-cloud?
16:35 jeddi s0undt3ch: sorry .. realised that'd trigger your irc client.  yeah - salt cloud.
16:35 s0undt3ch jeddi: anything wrong?
16:35 jeddi s0undt3ch:  LarsN just bumped into the 'ignore all but the last' provider bug i think.
16:35 s0undt3ch ah
16:35 s0undt3ch :)
16:35 s0undt3ch yep, fixed in dev, the upcomming 0.8.9
16:35 jeddi and we're all sitting here waiting patiently for 0.8.9 ... for which i am *extra* sorry to disturb you :)
16:36 s0undt3ch jeddi: no worries
16:36 maspwr joined #salt
16:38 Ahlee so logging in custom modules.  What options are available?
16:39 Ahlee is there a way to return information to the master while functions are executing?
16:40 LarsN jeddi: looks EXACTLY like what I ran into
16:40 LarsN sigh
16:40 FreeSpencer joined #salt
16:41 LarsN I could totally script around that
16:41 dthom91 joined #salt
16:41 LarsN but "wild and crazy" aren't on the menu for today @work
16:41 LarsN :)
16:44 zonk1024 joined #salt
16:44 jkleckner joined #salt
16:45 kermit joined #salt
16:47 bfrog how do you match on grains: set in minion config
16:47 jeddi LarsN: as i say - i gather the resolution is not far off.
16:47 bfrog I tried 'roles:development':
16:47 bfrog but that does nothing
16:47 jeddi LarsN:  if you can wait, of curse.  it's a pretty tricky bug to work around (well, for me).
16:48 jeddi other than bringing in provider / profile files and relocating them out of the way when needed.   that was my first thought.  but truly ugly and hacky.
16:48 bfrog https://gist.github.com/bfrog/5824438
16:49 bfrog in /etc/salt/minion I have basically something like the docs say
16:49 bfrog http://docs.saltstack.com/topics/targeting/grains.html in the minion stuff
16:50 bfrog am I missing something here?
16:50 opapo joined #salt
16:52 jeddi bfrog:  do you need the match: grains line as per http://docs.saltstack.com/ref/states/top.html
16:54 bfrog oh, lemme try that
16:54 jeddi bfrog: and can i suggest you adopt the same naming system as the rest of salt stack docs - 'env' defines 'development (or dev)' and 'prod', but 'roles' are where you define what the machine needs to be doing / running.
16:55 jeddi bfrog: up to you, of course.  just .. it can confuse you later.  as i say, almost all salt docs stick with that convention, while a couple of places they don't, and that gets confusing.
17:00 flupke joined #salt
17:00 magmatt joined #salt
17:01 LarsN this is maybe the wrong question to ask, but how would one go about deploying the development branch of salt-cloud?
17:01 LarsN git-clone && python setup.py install?
17:01 jeddi LarsN:  just pip it :)
17:02 jeddi pip install salt-cloud
17:02 jeddi magic happens.
17:02 jeddi salt-cloud is installed.
17:02 jeddi profit.
17:02 maspwr joined #salt
17:02 LarsN jeddi: you're telling me pip now sees 8.9?
17:02 LarsN 0.8.9 rather...
17:02 jeddi oh, sorry - totally misunderstood.
17:02 jeddi yeah.  that's more complexificated.
17:02 flupke hello, how can I classify large numbers of machines in nodegroups without having all them listed in /etc/salt/master? the machines have numeric names (foo123.bar.com), I wish I could use jinja but I can't in the master config file
17:02 jeddi i think of 0.8.8 as kinda development :)
17:03 LarsN grumble grumble grumble. :)
17:03 LarsN where's the deploy button when I need it.
17:03 LarsN :)
17:03 baniir joined #salt
17:03 jeddi LarsN: yeah - i suspect you're right - the setup.py there is tempting.
17:04 UtahDave joined #salt
17:04 LarsN jeddi: heh.
17:05 LarsN wonder how many "Ace Of Spades" I've have to send UtahDave to get that pushed.  ;)
17:05 flupke for example I would like to have 100-130 in group1 and 130-160 in group2
17:05 UtahDave ??????
17:05 LarsN flupke: I don't know the exact syntax, but JinJa should totally be able to support clumping
17:06 UtahDave LarsN: what would you like to get pushed?
17:06 LarsN UtahDave: I need Salt-Cloud 0.8.9, that's all.
17:06 LarsN or more specifically patches soundtech put in
17:06 flupke LarsN: jinja cannot be used in /etc/salt/master
17:06 UtahDave Ah, OK.  It will be soon.  redbeard2 wants to release it with Salt 0.16.0
17:06 LarsN I didn't want to highlight him.
17:06 jlund joined #salt
17:06 LarsN flupke: for some reason I was thinking you were working with the .sls
17:07 LarsN I'm just a big dumb dummy.  :)
17:08 LarsN flupke: I'd likely still cheat,  use top.sls to push grains to move servers into specific groups.
17:08 LarsN or something similarly hackish.
17:08 LarsN we've however already established I'm a big dumb dummy, so you likely shouldn't listen to me :)
17:08 flupke LarsN: I could maybe define a "groupname" pillar and match on ids in the pillar top.sls
17:09 LarsN UtahDave: rgr.
17:09 LarsN UtahDave: it's halted my forward progress for the moment on what will hopefully be "monitoring deployment nirvana"
17:09 mgw Any ideas why I'm getting this instead of log messages emitted from salt-master:
17:09 mgw log_fmt_console
17:09 mgw log_fmt_console
17:09 mgw log_fmt_console
17:09 flupke LarsN: that sounds very hackish indeed, that's why I came here to ask if there was not a simpler way :)
17:10 flupke LarsN: but I think it will work, thanks
17:10 LarsN flupke: then again I'm also bootstrapping salt-minion onto my instances at the time of creation.
17:10 aberant joined #salt
17:10 baniir attempting to access pillar data with {{ pillar['foo']['bar'] }} fails but pillar.get('foo:bar') }} works; is the former syntax deprecated in recent versions
17:11 UtahDave mgw: looks like a bug
17:11 LarsN jeddi: to be honest, I'm actually kind of glad it's a bug
17:11 LarsN jeddi: because I'd think even less of myself if I was just doing it wrong.
17:11 LarsN with regards to (cloud.providers)
17:11 UtahDave LarsN: have you tried just installing salt-cloud from git over the top of your salt-cloud install?
17:12 djn joined #salt
17:12 LarsN UtahDave: at least as of Saturday afternoon the git repo was 0.8.8
17:12 AntonioRibeiro joined #salt
17:13 LarsN I suppose I could update and try again.
17:13 UtahDave LarsN: install from git develop branch
17:13 LarsN ah, that I bet I didn't do.
17:13 AntonioRibeiro "Data failed to compile" --> https://github.com/saltstack/salt/issues/3996
17:13 LarsN once my relief gets in I'll do exactly that UtahDave
17:13 AntonioRibeiro any leads to solve this very same problem these days?
17:14 UtahDave sounds good, LarsN
17:15 UtahDave AntonioRibeiro: Hm. I haven't seen that.  Can you pastebin you're output?
17:16 melinath joined #salt
17:16 AntonioRibeiro UtahDave: http://puu.sh/3kbpA.png
17:17 munhitsu Hi, I'm installing and starting mongodb using salt. Than I want to create users on it. Any recommendation how to wait for mongo to go  online before creating users?
17:17 UtahDave oh, AntonioRibeiro, that usually means that a highstate is still running on  your minion.
17:17 munhitsu otherwise I'm getting "log.error('Error connecting to database {0}'.format(database.message))" on the first run
17:17 AntonioRibeiro UtahDave: I was just start follwing a cookbook, so I really didn't started any highstates in my minion :)
17:18 UtahDave munhitsu: have you tried having your users state require a service.running on the mongodb service?
17:18 AntonioRibeiro Or if I did, I dont know how I did hehe
17:18 munhitsu UtahDave: I've put:     - require:
17:18 munhitsu - pkg: pymongo
17:18 munhitsu - service: mongod
17:18 UtahDave AntonioRibeiro: ok. try running your minion in the cli in debug mode to see if you get any error output there
17:18 jefimenko joined #salt
17:18 AntonioRibeiro UtahDave: okay
17:19 UtahDave munhitsu: how long does it take for mongod to be ready?
17:19 Ryan_Lane joined #salt
17:19 munhitsu usually few seconds
17:19 napperjabber joined #salt
17:20 munhitsu UtahDave: would be lovely to put timeout into mongodb_user state
17:20 munhitsu other would be to put delay into states, any recommendation how to do it?
17:20 UtahDave munhitsu: here's a bit of a hacky way to do it.
17:21 UtahDave munhitsu: use module.run   to send a test.wait 10
17:21 UtahDave have the test.wait require the pkg and service, then have the user state require the test.wait
17:22 munhitsu on multiple users it will run it once - should work
17:22 magmatt with salty-vagrant I'm seeing this error on vagrant up: http://bpaste.net/show/1ifN4HqppD7HFNj5CX36/
17:22 magmatt how do I debug?
17:23 munhitsu thx, testing
17:23 akoumjian magmatt: ssh into the box and try running any salt-call command (ie: salt-call state.highstate -l debug)
17:23 akoumjian magmatt: Do you have a master, or are you running masterless?
17:24 magmatt masterless
17:24 magmatt I just found the examples directory... and I didn't set salt.minion_config
17:24 magmatt in Vagrantfile
17:24 magmatt lemme try that
17:25 magmatt akoumjian: this is on the box: http://bpaste.net/show/v8WMa33GgZrDxLVlznpb/
17:25 oz_akan_ hi, I want to check if a grain value set on minion and if not, I want to print a message and quit execution of the SLS formula, how can I achieve this/
17:25 magmatt as vagrant user (not root)
17:25 cellofellow joined #salt
17:25 akoumjian magmatt: With masterless you need to tell salt to use a local file server. See the masterless example and how it uses a minion config with "file_client: local"
17:25 akoumjian https://github.com/saltstack/salty-vagrant/tree/develop/example/masterless
17:25 AntonioRibeiro UtahDave: looks like I have a lot to fix here: http://puu.sh/3kbNJ.png
17:25 cellofellow is there some way to read the 0.13.1 docs? Seems docs.saltstack.org only has latest.
17:25 bhosmer joined #salt
17:25 magmatt akoumjian: I did file_client: local, but I didn't tell it which minion conf to use;  trying now
17:26 akoumjian magmatt: run with sudo
17:26 LyndsySimon joined #salt
17:26 akoumjian magmatt: That should fix it, specifying the minion config
17:26 AntonioRibeiro move-window -t 2
17:26 UtahDave AntonioRibeiro: yeah, your sls file is malformed.  I can help you with that if you want to pastebin it
17:26 magmatt akoumjian: salty-vagrant runs with sudo, right?
17:26 bfrog ignoring the special characters, getting errors for this sls, https://gist.github.com/bfrog/5824750
17:26 akoumjian magmatt: yes
17:27 bfrog but the states.pecl docs basically give that example
17:27 UtahDave cellofellow: check out the 0.31.1 tag in the repo.  Then look in the docs directory
17:27 bfrog http://docs.saltstack.com/ref/states/all/salt.states.pecl.html#module-salt.states.pecl
17:27 magmatt akoumjian: should https://github.com/saltstack/salty-vagrant#configuration mention sal.minion_config = 'salt/minion' ?
17:27 bfrog there's no context in the example though
17:27 cellofellow UtahDave: heh, ok
17:27 akoumjian magmatt: yes, I'll add it
17:27 bfrog so its confusing to know where that goes
17:28 munhitsu works!
17:28 munhitsu wait-for-mongodb-server:
17:28 munhitsu cmd:
17:28 munhitsu - run
17:28 munhitsu - name: sleep 5
17:28 munhitsu - require:
17:28 munhitsu - service: mongod
17:28 AntonioRibeiro UtahDave: http://paste.laravel.com/xGd -- thanks!
17:28 UtahDave munhitsu: cool!
17:28 munhitsu UtahDave: thx
17:28 jlund joined #salt
17:29 UtahDave oz_akan_: Hey, I saw your question.  Just thinking about it
17:30 oz_akan_ UtahDave: I want to create a generic mongodb SLS formula, which needs replicate set information to be set in grains
17:30 magmatt akoumjian: well, it doesn't fail now... but it doesn't seem to have added the users I expect.  Not your problem, probably.  Thank you!
17:30 akoumjian magmatt: Good luck!
17:30 oz_akan_ UtahDave: someone who wants to use mongodb SLS Formula, should be informed that he needs to set replica_set grains on targeted minions
17:30 UtahDave AntonioRibeiro: actually, can you pastebin your top.sls?  I think that's where the issue is
17:31 oz_akan_ UtahDave: I though salt might provide an nice message that I can control
17:31 oz_akan_ thought
17:31 AntonioRibeiro UtahDave: this is the whole thing: http://paste.laravel.com/xGj
17:31 hazzadous joined #salt
17:31 AntonioRibeiro contents are between #######################
17:32 UtahDave AntonioRibeiro: yep! there it is.      you need a colon after your match line.      '*':
17:32 bfrog anyone?
17:32 AntonioRibeiro ha!
17:32 AntonioRibeiro cool, UtahDave, thanks a lot
17:32 UtahDave bfrog: just a moment. Let me finish something
17:33 mgw UtahDave: apparently it is a bug and already fixed (as of 8 minutes ago). Thanks s0undt3ch and thatch45.
17:34 UtahDave mgw: :)    Those guys rock!
17:34 oz_akan_ UtahDave: are you just a single person or a group of people trying help all people here :D
17:34 UtahDave oz_akan_: ha ha!
17:34 UtahDave After doing this for a year you get pretty good at multi tasking.   :)
17:34 oz_akan_ :)
17:34 UtahDave and sometimes you go crazy.   :)
17:35 oz_akan_ seems to me like all the time
17:35 s0undt3ch what did I do?
17:35 UtahDave oz_akan_: So generally Salt is designed to "flow" through different "states"
17:35 mgw fis0undt3ch: fixed the broken console logging
17:36 UtahDave oz_akan_: so generally Salt would just flow to those servers that have the correct grains.
17:36 mgw ^ s0undt3ch
17:36 oz_akan_ UtahDave: I could use lots of require's or maybe overstate
17:36 UtahDave oz_akan_: So I don't think we have a notification system like you're hoping for.   I think what you could do is just let those minions fail
17:36 s0undt3ch mgw: heh, I was just cleaning up my own mess ;)
17:37 tonthon I can't understand how I can use an external pilar system, I found this page  http://docs.saltstack.com/topics/development/external_pillars.html but it's not clear how to load ext_pillar modules
17:37 oz_akan_ UtahDave: I see, right, if that grain doesn't exist minion will fail and probably that is good enough
17:37 UtahDave oz_akan_: in your sls file let the grains template blow up if the grain doesn't exist.  That will be displayed in the return after running the command
17:38 kermit joined #salt
17:38 oz_akan_ UtahDave: got it, I won't do an if so assume that grains exists, which will break execution if it doesn't
17:38 UtahDave oz_akan_: yep.  And it will only break on those minions that don't have the correct grain
17:39 oz_akan_ UtahDave: thanks
17:39 UtahDave oz_akan_: you're welcome!
17:39 UtahDave bfrog: can you pastebin the error you're getting?
17:40 UtahDave tonthon: look here: http://docs.saltstack.com/topics/development/external_pillars.html#location
17:40 oz_akan_ by the way I started a blog series about salt and Marconi. It will be 4-5 blog posts. http://developer.rackspace.com/blog/marconi-and-salt.html
17:40 UtahDave tonthon: add your external pillar there and then restart the master
17:40 UtahDave oz_akan_: Ah, very cool!  I did see that first one.
17:40 bfrog UtahDave: Error running 'state.highstate': unhashable type: 'dict'
17:40 tonthon UtahDave: I want to use core pillar modules
17:40 oz_akan_ UtahDave: second online tomorrow, kind of ne per week
17:40 tonthon (pillar.cmd_json )
17:41 tonthon but can't figure how I can configure it
17:41 UtahDave oz_akan_: nice!
17:41 tonthon simply need to pass a command to it, but how ?
17:44 tonthon UtahDave: ok, I've got it
17:44 UtahDave tonthon: ah, good
17:44 tonthon cmd_json: "cat /tmp/test" in the ext_pillar section of the master file did the trick
17:45 UtahDave cool
17:45 tonthon it's an information that's not easy to find, maybe the doc could be enhanced a bit
17:45 UtahDave bfrog: please pastebin the entire output
17:45 tonthon Is there a specific bug tracker for the docs ?
17:45 cdn Trying to setup a state that contains two cmds, I want to make sure cmd2 runs after cmd1 when I call state.highstate.  Is this possible, how could I do it? or chain two cmds together?
17:46 UtahDave tonthon: would you mind adding language that you think would be helpful?
17:46 UtahDave cdn: you need to have cmd2 require cmd1
17:46 tonthon UtahDave: simply say how you can load core pillar modules and configure them
17:46 tonthon that information is lacking
17:47 tonthon (in my pov)
17:47 cdn Require will make it wait? or not run it all all
17:47 UtahDave tonthon: right.  That would be great if you could add that to the docs.  the docs are in the docs folder of the salt repo
17:47 tonthon UtahDave: ok, I'll give it a try
17:47 UtahDave cdn: require will make cmd2 wait for cmd1 to succeed before running
17:48 bfrog UtahDave: there's no other errors, lemme pastebin it
17:49 AntonioRibeiro UtahDave: part of the problem saved, but now I get: http://puu.sh/3kcKB.png
17:49 AntonioRibeiro UtahDave: master is in memory, I have some instances of it actually
17:49 UtahDave AntonioRibeiro: what version of Salt are you on?
17:49 bfrog https://gist.github.com/bfrog/5824950
17:49 AntonioRibeiro UtahDave: downloaded from sources yesterday
17:50 bfrog if I remove those pecl.installed pieces in the pastebinned php.sls things work fine
17:50 bfrog but I need those pecl modules installed
17:50 bfrog could just cmd them I guess...
17:50 AntonioRibeiro UtahDave: I just did wget -O - http://bootstrap.saltstack.org > /tmp/saltinstaller.sh
17:50 AntonioRibeiro how can I see the version salt -v gaves me nothing
17:50 ste76 joined #salt
17:50 drozer left #salt
17:51 UtahDave salt-call test.versions-report
17:51 cdn @UtahDave, thanks will try it out
17:51 AntonioRibeiro UtahDave: salt 0.15.3
17:51 AntonioRibeiro k
17:51 ste76 left #salt
17:52 UtahDave back in a minute
17:52 AntonioRibeiro UtahDave: Function test.versions-report is not available
17:53 zonk1024 joined #salt
18:09 auser joined #salt
18:12 Mrono joined #salt
18:14 UtahDave AntonioRibeiro: oh, try test.versions_report
18:15 SpX joined #salt
18:17 AntonioRibeiro UtahDave: still complainting about the key what is installed, here are some stuff I tested here: http://puu.sh/3ke0b.png
18:17 AntonioRibeiro *wich is installed :)
18:17 milind joined #salt
18:19 bhosmer joined #salt
18:21 krissaxton joined #salt
18:21 LyndsySimon joined #salt
18:23 alekibango joined #salt
18:23 pentabular joined #salt
18:23 efixit joined #salt
18:23 admineric joined #salt
18:24 carmony joined #salt
18:25 oliv_mc left #salt
18:25 admineric When I pass a  key arg to a runner it sets the whole thing to a string. Example http://pastebin.com/4fPfBtDZ
18:26 admineric Is this the expected behavior?
18:27 craig is there an easy way to delete keys matching a simple regex?
18:27 UtahDave admineric: what version of salt are you on?
18:28 UtahDave craig: I'm not sure if you can use a regex, but you can use a glob
18:28 admineric 15.1
18:28 UtahDave craig: salt-key -d 'minion*'
18:28 LyndsySimon joined #salt
18:28 craig UtahDave: in this case, that's what i need :)
18:28 craig thanks
18:28 UtahDave craig: you're welcome!
18:29 craig worked like a champ :)
18:29 UtahDave admineric: Hmm. That stuff can get tricky.  That does seem weird
18:29 UtahDave basepi: can you take a peek at admineric's example?
18:30 craig UtahDave: NOW i see it in the man page :)
18:30 craig love up to date docs :)
18:30 admineric UtahDave: Let me try this on 15.3 and see if there is a difference.
18:31 UtahDave craig: :)  me, too.  It takes a lot of work to keep them as close to up to date as possible
18:31 craig tell me about it...
18:31 UtahDave craig: if you see anything that could be said clearer or better, we'd love the feedback or a pull req
18:31 craig just internal apps up to date is a HUGE PITA!!!
18:31 AntonioRibeiro UtahDave: looks like version is running now: http://puu.sh/3keHO.png
18:31 craig ya, was just about to ask... where are the docs?
18:32 UtahDave craig: they're in the docs directory in the root of the Salt repo
18:32 craig yup
18:32 AntonioRibeiro UtahDave: but still failing to compile
18:32 oz_akan_ UtahDave: I set grains values with grains.setval but master still shows the old grain value, do I need to refresh some sort of cache?
18:32 craig have you guys thought about generating the man pages from rst?
18:33 craig oh, wait.. it is...
18:33 UtahDave oz_akan_: what version of Salt are you on?  There was a grains.setval bug somewhat recently that didn't refresh the grains.
18:33 craig so, you generate them and them check them in?
18:34 UtahDave oz_akan_: you might also try    salt \* saltutil.sync_grains
18:34 oz_akan_ UtahDave: 0.15.3
18:34 UtahDave craig: no, they're in rst  in the docs directory
18:34 craig hmm... must have built them on my own
18:35 LyndsySimon joined #salt
18:35 oz_akan_ UtahDave: I set the grains initially while creating from a map file, that might ne?
18:35 UtahDave oz_akan_: how are you querying the grain on the master?
18:36 oz_akan_ UtahDave: salt '*' grains.item roles
18:36 oz_akan_ UtahDave: sync_grains didn't help
18:37 UtahDave oz_akan_: yeah, you're hitting that bug.  If you restart the minion it will display the new value.  It seems like there was another way to get the new value to display, too.   Let me think
18:37 admineric UtahDave: Interesting, it works "correctly" on 15.3
18:38 admineric Time to upgrade:)
18:39 UtahDave admineric: :)   Oh, good.  I wasn't sure if that fix had made it into 0.15.3 or not
18:39 craig speaking of, i heard that 0.16 was coming soon
18:40 UtahDave yeah, it should be soonish
18:41 craig is there a "projected" features list?
18:43 UtahDave Probably the closest thing would be the release notes for the release. I don't know if Tom has started that yet.
18:43 craig combing thru git diffs is a little daunting
18:43 craig k. thanks. was just curious :)
18:44 UtahDave yeah, I understand.  We'll have a pretty good release notes for it.
18:45 craig well... tbh, its partly your own fault....
18:45 craig there is always so much cool stuff
18:45 craig that im anxious to see whats next :)
18:45 UtahDave he he.  Yes, that is true.  :)
18:47 oz_akan_ UtahDave: restart of minion doesn't fix
18:47 UtahDave ANNOUNCEMENT::   I was just informed that SaltStack has won the judges scoring at the big Gigaom event today!    :)
18:47 SEJeff_work :D
18:48 SEJeff_work UtahDave, Is there any sort of the beginnings of a changelog for 0.16?
18:48 SpX joined #salt
18:48 UtahDave oz_akan_: Hm.  let me test on my system here
18:48 SEJeff_work I'd like to see what major stuff is going to be on it if at all possible
18:48 guerrilla_imp joined #salt
18:48 oz_akan_ tonthon: bug is: when minion is created with map file, grains are put into /etc/salt/minion
18:48 oz_akan_ UtahDave: bug is: when minion is created with map file, grains are put into /etc/salt/minion
18:48 oz_akan_ UtahDave: when set with serval grains file is updated
18:49 oz_akan_ UtahDave: and I think data in minion file overrides data in grains file
18:50 UtahDave oz_akan_: Ah, you're totally right!
18:50 davidr joined #salt
18:50 UtahDave would you mind opening a bug on that?  I'm not sure if that is a Salt bug or a Salt-Cloud bug
18:50 UtahDave probably open it on the Salt repo because Salt should deal with grains properly regardless of where they are created
18:51 UtahDave SEJeff_work and craig  I just saw the release notes for 0.16.0 in the git repo
18:52 UtahDave doc/topics/releases/0.16.0.rst
18:52 Kholloway joined #salt
18:52 UtahDave http://docs.saltstack.com/topics/releases/0.16.0.html
18:52 UtahDave Of course that document is still in flux and WILL change.
18:54 auser hey UtahDave, does the overstate match on grains, do you know off the top of your head?
18:54 magmatt my minion conf contains http://bpaste.net/show/DqivYQVbMSI0dBLq1eF5/ and my top.sls contains http://bpaste.net/show/swjdJz8Re086XcaFA3Es/ but when I run highstate, I get this:http://bpaste.net/show/ZBRRxWUKuqCIsQU9gdTd/
18:55 auser Rather, anyone know if the overstate can match on more than just grains[id]
18:56 UtahDave auser: You know, I discussed this with Tom recently and I can't remember what he said!!  Lemme think for a sec
18:57 auser oh yes, we discussed it… my bad, I had forgotten that convo until now anyway
18:57 auser spaced it this morning
18:57 UtahDave auser: actually, I think the match is actually ALWAYS a compound matcher
18:57 auser o?
18:57 SEJeff_work UtahDave, In those release notes it has, "The new `prereq` requisite is very powerful!"
18:57 UtahDave so you can use  G@os:Ubuntu and such
18:58 SEJeff_work I could actually picture tom saying it just like that, and then hit the "blame view" and sure enough, he wrote it. Cracked me up
18:58 auser got it
18:58 auser thanks UtahDave
18:58 UtahDave you're welcome!
18:58 UtahDave SEJeff_work: :) he he.  so true!
19:02 SEJeff_work UtahDave, is Tom around?
19:02 SEJeff_work I love where he is going (reading: https://github.com/saltstack/salt/commit/28d93ab426686bae2746b287a20774a8ba21c920)
19:02 SEJeff_work but wouldn't it make sense to have the masters listen to events from other masters
19:02 SEJeff_work and just autoaccept keys
19:03 UtahDave I think he had to leave. I'm actually not in the office yet
19:03 SEJeff_work if one accepts, they all accepts
19:03 SEJeff_work UtahDave, What do you think of that idea?
19:03 UtahDave SEJeff_work: yeah, that sounds like a fantastic idea.
19:03 UtahDave This is just the initial release.  Moar features to come!   :)
19:03 SEJeff_work Always!
19:04 SEJeff_work I take it 0.16 is going to be a feature release, and then there will likely be a few followup point releases fixing boogs
19:04 UtahDave Make sure to email him about that idea.
19:04 magmatt I'm having trouble matching a minion.  I manually set id in the minion conf, and use the id in the top file: no match.  I set grains in the minion conf, use G@env:dev in the top file: no match.  Only '*' matches
19:04 magmatt help?
19:04 SEJeff_work ok
19:04 UtahDave Yeah, we're going to release a 0.16.0 RC  for the first time.
19:04 UtahDave Then drop 0.16.0
19:04 SEJeff_work UtahDave, I was literally just giving a brief rundown of architecturally how salt works vs mcollective
19:05 UtahDave magmatt: can you pastebin your topfile ?
19:05 UtahDave SEJeff_work: huh, interesting
19:05 SEJeff_work and said the single problem is that each master or syndic is a SPOF, which you can somewhat mitigate by running 2 of them and using something like pacemaker/corosync or keepalived to flip a VIP between the two (so long as they share the same pki dir)
19:05 jlund joined #salt
19:05 pentabular1 joined #salt
19:06 SEJeff_work UtahDave, I went back to the attendees of said meeting a minute ago and said, "Well scratch that, you can join each minion to multiple masters, so we can scratch that as a problem"
19:07 jdaggett joined #salt
19:08 magmatt UtahDave: http://bpaste.net/show/7oP1tqMnLyriI6BO9Fz3/
19:08 UtahDave SEJeff_work: ha, nice!!
19:08 magmatt UtahDave: as pasted, that matches and does users.dev
19:09 UtahDave ok, pastebin the version that's not working for you
19:09 magmatt but if I change '*' to joe (id set in minion conf) it doesn't match
19:09 UtahDave magmatt: are you adding  - match: grain     ?
19:09 magmatt no
19:09 UtahDave oh, scratch that
19:09 magmatt I'll paste
19:09 magmatt http://bpaste.net/show/6BJ0Fh0DiEcqoWrVFcnu/
19:09 magmatt that does not match
19:10 hunter joined #salt
19:10 magmatt here's my minion conf http://bpaste.net/show/wI1BhuNkCjkLd3akOdGV/
19:10 bfrog UtahDave: did you take a look, any ideas?
19:10 bfrog scratching my head here
19:12 abe_music UtahDave: heard some of the salt guys are at the gigaom event today?
19:12 UtahDave magmatt: does the minion return when you run this?      salt 'joe' test.ping
19:12 magmatt UtahDave: I'm masterless
19:13 UtahDave abe_music: yep!  Our CEO Marc Chenn is there.  The judges voted SaltStack the winner!   :)
19:14 abe_music UtahDave: NICE! Congratulations...Some of our guys are out there too….one was going to a salt talk and was gonna try to chat afterward
19:15 UtahDave bfrog: I'm not 100% sure.  those pecl.installed  states look fine to me.  Any chance you can try testing against the latest Salt from git develop?
19:15 pentabular joined #salt
19:15 UtahDave abe_music: nice!  yeah, make sure he finds Marc. Marc would love to chat
19:18 abe_music UtahDave: he's gonna go over and say hi i think
19:18 UtahDave cool!  Marc's a very approachable kind of guy.
19:20 abe_music UtahDave: do you know of a more complete example of how to use reactor (or something) to get minions configured based on some other minion's config?
19:24 UtahDave abe_music: I'm not quite following.  What are you trying to accomplish?
19:26 abe_music UtahDave: sorry, say i wanted to deploy a django app that depended on a mysql service running on a different machine. i would have a state to deploy mysql and another for django. is it possible to have the django app pull the mysql instance's host information to configure itself?
19:26 abe_music or better yet, the hadoop problem….namenode/jobtracker on one machine and N datanodes…those datanodes need to know where the namenode is so they can connect up
19:27 abe_music i know auser is working on that particular case, but i was hoping to get a jumpstart on how exactly to handle something like that because i can see it being very useful in many situations. orchestration i guess is what it's called
19:29 auser abe_music: my jumpstart looks like: https://gist.github.com/auser/5201567#file-informer-py
19:29 dthom91 joined #salt
19:29 auser using salt.mine of course
19:31 abe_music auser: hmm, need to read up on salt mine i guess
19:31 auser it's really easy, I'll add to that gist
19:32 abe_music auser: cool…is this what i need to look at? http://docs.saltstack.com/ref/modules/all/salt.modules.mine.html?highlight=salt%20mine#salt.modules.mine
19:32 abe_music this might be better: http://docs.saltstack.com/topics/mine/index.html
19:32 UtahDave abe_music: Yeah, you're going to want to look at the Salt Mine and also the peer interface (publish.publish)
19:32 auser yep
19:33 auser publish.publish is said to be a lot better… originally, informer was built with publish.publish
19:33 UtahDave the peer interface is for when you what live data NOW.  The Salt Mine is fantastic for things that you don't mind if they're a minute or so old
19:33 felixhummel joined #salt
19:33 auser https://gist.github.com/auser/5201567
19:34 hunter Can salt be run without a master control server? I have a use case where idealy we'd be able to just checkout a git repo and go .. ?
19:34 hunter (and yes, I'm totally new to salt)
19:34 abe_music UtahDave: ah ok…assuming peer interface is resource heavy then (hence the cache)
19:34 auser yes hunter
19:34 auser --local
19:35 abe_music auser: thanks for the updated gist…i'll work on a smaller example until i'm comfortable with how this works
19:35 auser sure, make sure you call `mine.update` on new machines
19:35 auser salt-cli will do that for you, if you use it
19:36 abe_music does salt-cli wrap salt-cloud?
19:36 auser no, they are separate
19:36 aberant joined #salt
19:36 abe_music meaning, can i continue to use the providers, profiles, and maps i'm currently working with?
19:36 auser no, continue working with salt-cloud
19:37 abe_music k
19:40 auser UtahDave: I'm exploiting the top.sls structure by allowing matches on multiple roles anywhere in the top.sls (https://gist.github.com/auser/5825919). Is it possible to retain that behavior in the overstate.sls? So far, looks like it's not
19:42 auser not really *exploiting*
19:43 auser just using the behavior
19:46 wifigi joined #salt
19:47 baniir i have grains: environment: - development in /etc/salt/minion but {% if grains['environment'] == 'development' %} is not true in my state file; is there something obvious i'm doing incorrectly
19:47 kermit joined #salt
19:48 wifigi i'm trying to write a script to install a salt-master and salt-minions automatically (packages from a local repo) given a set of ips. The package installation works fine, but when I try and restart the salt-master process (using sudo service salt-master restart), it just hangs indefinitely. The same for 'service salt-master start', and 'service salt-master stop' says the service is already stopped. However, I can still see about 7 or 8
19:48 wifigi (I was on here yesterday with the same question)
19:49 wifigi Output of 'salt-master -l debug': http://pastebin.com/HEJwQZR7
19:49 jschadlick joined #salt
19:49 wifigi Output of ps: http://pastebin.com/pjXd4d5L
19:49 wifigi Output of lsof: http://pastebin.com/na43PspQ
19:49 wifigi I am using Ubuntu Server 12.04 and salt 0.12.1
19:50 wifigi I can recreate this issue (and have several times) on salt masters with the same OS that were previously running fine: I remove the salt packages using 'apt-get purge', reinstall them with the script, put in the new configuration file, then try to restart. Hangs every time.
19:50 wifigi The only thing changed in the config file is uncommenting out the default file server root
19:51 wifigi There is nothing other than salt running on the master
19:52 sw__ joined #salt
19:53 UtahDave auser: I'm pretty sure you can match the same machines in multiple parts of your overstate
19:53 cron0 joined #salt
19:53 auser hm, running into issues with it… odd
19:53 auser thx
19:55 admineric wifigi: If you run "service salt-master stop" and then run "sudo pkill -9 salt-master" can you start salt-master after that?
19:56 UtahDave wifigi: So you're building a script that, for example, I could run from my laptop and it will go out and install Salt on an existing server somewhere?
19:57 wifigi admineric: No, I can't, the start and restart commands still hang, same as before
19:57 wifigi UtahDave: Yes, though these servers are just on our internal network. It sends commands using SSH (with root key)
19:58 wifigi admineric: The only way I've found to restart the saltmaster after that is to restart the machine
19:59 admineric wifigi: My guess is that this issue would be resolved by upgrading to 15.3.  I think I remember having some start/stop issues around 12 using ubuntu 12.04
20:02 wifigi admineric: Do you know if 0.15 will work with Ubuntu 12.04? It's listed under Ubuntu 13.10 packages, and it would be a pain to upgrade our Ubuntu distro
20:02 wifigi Our local repo only goes up to 12.10
20:03 admineric I am using 15.3 on my Ubuntu 12.04 desktop and haven't had any issues
20:04 wifigi Ok, thanks, I will try that
20:04 admineric I am using the salt ppa
20:04 hazzadous joined #salt
20:04 wifigi The internal development network has no internet connection, so that's not really an option for me
20:06 UtahDave wifigi: also, you could use the salt-cloud   "saltify" driver to do that for you.
20:06 UtahDave http://salt-cloud.readthedocs.org/en/latest/topics/config.html#saltify
20:06 UtahDave I'll be back in about an hour or so.
20:07 faldridge joined #salt
20:08 admineric wifigi: You could still download the script and use it on your internal network (maybe with some modifications)
20:09 wifigi I'll look at it, but it might just be easier for me to add newer packages to our repository, since I don't think we need this to stay updated in the long-run
20:12 racooper When I run a state.highstate against a new salt-master (migrating from a test box to new production), I get an error against it's own minion. http://pastebin.com/ZHv01mwS all other minions work correctly.  config file matches the test server (except for the master name, obviously). any ideas?
20:14 faldridge joined #salt
20:14 admineric racooper: Can you "salt 'salt-server.example.com' test.ping"?
20:15 racooper admineric,  yes, it pings.  I seem to be able to do anything except state.
20:16 admineric racooper: Can you explicitly run one state?  "salt 'yourserver' state.sls  nameofsinglestate"?
20:18 racooper yes, running the states manually seems to work.
20:20 hunter joined #salt
20:21 napperjabber joined #salt
20:22 admineric racooper: It is a problem in your top.sls file
20:22 admineric racooper: Probably yourserver isn't targeted anywhere in your top.sls
20:23 racooper gahh you're right. I was playing with grains matching and left a "not G@roles:configmaster" in base.
20:23 racooper Thanks.
20:23 admineric np:)
20:23 m_george|away joined #salt
20:30 dthom91 joined #salt
20:35 pentabular joined #salt
20:37 drawsmcgraw Question on the Windows silent installer
20:37 drawsmcgraw When you run a silent install with the Windows installer, does the Minion start up right after installation?
20:38 pentabular1 joined #salt
20:40 salticus joined #salt
20:44 Slipo joined #salt
20:52 dthom91 joined #salt
20:54 pentabular joined #salt
20:55 pentabular maybe I should join the bind9 call
20:57 UtahDave joined #salt
21:04 magmatt UtahDave: soo... any clue why 'joe' doesn't match the minion with id: joe?
21:04 mgw What's the proper CLI format for setting up an ubuntu ppa repo?
21:06 drawsmcgraw Just tested. A silent install of the Windows installer *does* start up after installation
21:06 UtahDave thanks, draws*  !  :)
21:06 kermit joined #salt
21:07 UtahDave magmatt: Let me take a look at that again. I think I still have that browser tab open.  I just got into the office
21:07 UtahDave mgw: with Salt?
21:07 magmatt UtahDave: also, hello from the valley to the south
21:07 mgw UtahDave
21:07 mgw : yes
21:08 UtahDave magmatt: :)   That's where I live!  :)
21:09 UtahDave mgw: I would use the pkrepo state from the cli.  Docs here: http://docs.saltstack.com/ref/states/all/salt.states.pkgrepo.html#salt.states.pkgrepo.managed
21:09 mgw UtahDave: I just found that, thanks
21:10 UtahDave mgw: salt \* state.single pkgrepo.managed name='<new repo>'  bla bla bla
21:12 mgw UtahDave: unfortunately, that breaks from behind an http proxy, due to an ubuntu bug….
21:12 UtahDave magmatt: can you give me the url to that pastebin you sent earlier?  I can't find it.
21:12 magmatt sure, lemme send a gist with everything
21:12 UtahDave magmatt: cool
21:12 UtahDave mgw: lovely.  :)
21:15 magmatt welll.... now it's deciding to match
21:15 magmatt UtahDave: do I need to restart the minion for some minion config changes to take effect?
21:16 magmatt specifically, grains and minion id?
21:17 UtahDave if you change anything in the config file, yes you have to restart the minion
21:17 magmatt well, that explains it
21:17 magmatt derp
21:17 magmatt UtahDave: thank you
21:17 dthom91 joined #salt
21:18 UtahDave You're welcome, magmatt.  Sorry I didn't think to ask about that earlier!
21:18 UtahDave Woot woot!  Here's the gigaom announcement about SaltStack winning: http://gigaom.com/2013/06/20/devops-player-saltstack-wins-structure-launchpad-competition-and-investor-interest/
21:19 UtahDave LarsN: can I send you a pm?
21:19 pentabular joined #salt
21:22 akoumjian UtahDave: (re: launchpad) That's awesome@
21:22 carlos joined #salt
21:23 mgw UtahDave: Actually, I'm not so sure it's the ubuntu bug
21:23 magmatt akoumjian: does salt-vagrant copy the minion conf into place?  Or is it a shared file/directory?
21:24 UtahDave akoumjian: :)  way cool
21:24 mgw It may just be salt-minion not picking up http_proxy from /etc/environment
21:24 akoumjian magmatt: It is copied to a tmp folder where it is picked up by the bootstrap script and copied into place
21:24 magmatt heh... so that's why my local changes aren't being seen
21:24 auser nice UtahDave!
21:26 pentabular Yay!  Nice job guys!!!!
21:27 UtahDave if anyone here wants to upvote the announcement on hacker news, here's the link: https://news.ycombinator.com/item?id=5915080
21:30 UtahDave Thanks, pentabular! This is a testament to the power of our community helping make Salt really awesome.  So much of Salt comes from each of our users helping polish Salt into something that is extremely effective in the real world
21:30 pentabular Thanks UtahDave! just hit it.
21:30 pentabular :) :)
21:30 UtahDave thanks again, pentabular!
21:30 oz_akan_ joined #salt
21:31 jdaggett joined #salt
21:31 xt +1ed, and grats
21:34 faldridge joined #salt
21:34 mgw UtahDave: re http_proxy — you could say it's an upstart 'feature'. It doesn't read /etc/environment by default.
21:34 mgw I fixed it by changing
21:34 mgw script
21:34 mgw exec salt-minion
21:34 mgw end script
21:34 mgw to
21:34 mgw script
21:34 mgw exec su root -c salt-minion
21:34 mgw end script
21:37 soukihei joined #salt
21:38 UtahDave thanks, xt!
21:39 dkauf joined #salt
21:46 jpcw_ joined #salt
21:50 dthom91 joined #salt
21:57 dave_den joined #salt
21:59 djn joined #salt
22:01 kleinishere joined #salt
22:04 jschadlick Is there any way to get output returner output from the master? It works when I call sudo salt-call test.ping --return=local on a minion, but I don't see the same output when I call sudo salt \* test.ping --return=local on the master
22:06 UtahDave jschadlick: can you pastebin what you're seeing?
22:06 jschadlick sure
22:07 jkleckner joined #salt
22:10 jschadlick https://gist.github.com/anonymous/5827169
22:10 kho joined #salt
22:11 UtahDave well, you could set up a returner on the master. But the data should be the same that's always returned to the master, jschadlick
22:14 jkleckner joined #salt
22:18 jschadlick so just to test, I could make a trivial returner that looks something like: https://gist.github.com/anonymous/5827231 put in /srv/_returners
22:21 jschadlick although that doesn't seem to be working
22:22 UtahDave jschadlick: So what's the end result you're looking for?
22:24 jschadlick well the end goal is going to be dumping minion info in a db, but I am just playing around with the returner functionality right now
22:25 UtahDave I think the easiest thing  to do is to run a minion on your master and just output it from the minion's point of view.
22:25 magmatt if 'G@env:dev' a correct grain match?
22:26 jschadlick interesting, I'll try that out. Thanks UtahDave
22:27 UtahDave magmatt: yeah, that should work.  Where are you using that to match?
22:28 magmatt in a top file
22:28 magmatt UtahDave: and I just realized what - match: is meant for
22:28 UtahDave oh, that's not the correct format
22:28 UtahDave 'env:dev':
22:28 UtahDave - match: grain
22:29 magmatt and 'G@env:dev' is for compound, right?
22:29 UtahDave magmatt: yes
22:32 magmatt UtahDave: and how would I match http://bpaste.net/show/XIZXTwJy1UlcAioAmLr5/ for roles containing webserver-v1 ?
22:32 magmatt (in a top file, that is)
22:32 magmatt 'roles:*webserver-v1*' doesn't seem to match
22:33 magmatt bah... vagrant problem again
22:34 magmatt UtahDave: I'm going to implement a 5 minute muzzle.  I won't ask in here until I've played for 5 minutes
22:35 UtahDave he he.  :)
22:35 UtahDave did you figure it out?
22:38 magmatt yeah, I keep editing my minion conf locally, thinking I'm editing the minion conf on my vm.  It works for my state files because they're shared with the vm.  The conf is just special
22:41 kho joined #salt
22:45 UtahDave ah, ok.
22:49 faldridge joined #salt
22:57 samsalt joined #salt
23:02 magmatt akoumjian: if, in Vagrantfile, I set salt.pillar to something, but I also have a folder synced to /srv/pillar/... do the pillar attrs set in Vagrantfile get overwritten?
23:03 akoumjian magmatt: salt.pillar uses a cool feature where you can add pillar vars to a salt command. https://github.com/saltstack/salty-vagrant/blob/develop/lib/vagrant-salt/provisioner.rb#L303
23:03 akoumjian magmatt: I believe they will take precedent over anything in your pillar file root.
23:04 akoumjian magmatt: However, they will only be used during the vagrant operated state.highstate
23:04 magmatt oh, rats
23:04 magmatt that makes debugging a little harder.  My pillar match failed to run, and I don't know why
23:04 aat joined #salt
23:05 akoumjian You are probably best off adding it to your pillar root.
23:05 auser joined #salt
23:05 magmatt hrm
23:06 magmatt I'm trying to say, "make this vm a webserver"
23:07 abe_music UtahDave: i'm *loving* publish.publish :)  anyway to speed it up? i'm assuming that's what salt mine is for?
23:07 giantlock joined #salt
23:07 UtahDave abe_music: can you test against the latest from git develop branch?
23:07 akoumjian magmatt: You should use custom grains or the minion id to filter out its role in your top.sls or pillar top.sls
23:07 UtahDave Tom recently made some optimizations and made it completely asynchronous
23:07 conan_the_destro congrats salty people: http://gigaom.com/2013/06/20/devops-player-saltstack-wins-structure-launchpad-competition-and-investor-interest/
23:08 UtahDave :)  Thanks, conan_the_destro!
23:09 akoumjian magmatt: See http://docs.saltstack.com/topics/targeting/grains.html#grains-in-the-minion-config
23:09 abe_music UtahDave: does that logic happen in the master or minion? minions are being bootstrapped by salt-cloud so they should be pretty new, right? oh i bet they're not pulling from develop
23:09 magmatt akoumjian: yeah, I had it working with grains...
23:09 abe_music i bet my master is also a release version too….need to install from develop branch
23:09 akoumjian magmatt: You then use this in your top.sls to match against your minion's grain whether or not to apply certain sls files
23:09 UtahDave Yeah, they're not pulling from develop unless you specify that
23:09 adotbrown joined #salt
23:10 abe_music UtahDave: any way to get a minion to do that in salt-cloud? right now i'm using the 'ubuntu' script
23:10 akoumjian Or in your pillar file, assign pillar values based on whether or not a certain grain matches
23:10 magmatt akoumjian: so... here's my dilemma.  We have our state files and pillar files in a git repo
23:10 UtahDave abe_music: If your use case can withstand the info being a minute or so stale, then that's a great option, too
23:10 kermit joined #salt
23:10 magmatt akoumjian: I'd like to clone the git repo, and edit something *not* in the repo to declare what kind of machine it is
23:10 abe_music UtahDave: right now i'm just looking for host names so they shouldn't ever change, but later things might get tricky
23:11 magmatt oh, I guess that's the minion config
23:11 UtahDave abe_music: Yeah, I wouldn't use the ubuntu script at all any more. It defaults to the bootstrap script now.
23:11 akoumjian magmatt: yep
23:11 UtahDave abe_music: I think you can pass in the bootstrap options from salt-cloud
23:11 oz_akan_ joined #salt
23:11 abe_music UtahDave: oh ok, didn't know that…i'll look at the bootstrap script and its options. thanks!
23:12 UtahDave abe_music: https://github.com/saltstack/salt-bootstrap     LOTS of options there.
23:12 abe_music sweet
23:13 robawt wuddup UtahDave!
23:14 UtahDave yo, robawt!
23:15 robawt congrats on winning that structure launchpad competition
23:15 robawt tell Mr. Chenn we said "holla" for the shout out to cars.com
23:17 abe_music any salt-cloud gurus out there know if this would work to bootstrap in debug mode *and* install from the develop branch? script_args: -D git develop
23:17 abe_music that would be in my cloud.profiles file btw
23:18 UtahDave :)  robawt, I'll do that!
23:18 UtahDave abe_music: yeah, I think that will work
23:18 abe_music nvm, i think it works
23:18 abe_music :)
23:19 abe_music thanks UtahDave
23:19 UtahDave you're very welcome!
23:21 akoumjian Anyone care to upvote my answer here? http://stackoverflow.com/a/17225420/114786  UtahDave you describe pillar well but I feel like it needed clarity on the difference on how/when pillar vs grains are defined
23:22 UtahDave upvoted!
23:23 akoumjian UtahDave: thanks dude
23:23 UtahDave No problem. That was a good explanation.
23:23 UtahDave akoumjian: except that upvoted bumped you to 127 over my 126!!!
23:24 UtahDave :)
23:24 SpX joined #salt
23:24 akoumjian It is by far one of the most commond misconceptions I see in here.
23:24 akoumjian Lol, I almost never contribute to SO
23:25 UtahDave :)
23:29 napperjabber joined #salt
23:30 pentabular joined #salt
23:33 admineric joined #salt
23:35 aleszoulek joined #salt
23:37 carmony joined #salt
23:37 jacksontj joined #salt
23:40 jdaggett joined #salt
23:41 napperjabber joined #salt
23:41 mephx joined #salt
23:42 admineric I have a runner that has a function that takes *args.  How would I call this with the salt-api, sending args?
23:43 samsalt1 joined #salt
23:44 williamthekid joined #salt
23:46 UtahDave admineric: I'm not sure exactly how to do that.  Let's see if whiteinge is around
23:46 admineric :)
23:49 jdaggett joined #salt
23:51 UtahDave admineric: Looks like he's not available right now.  I'd recommend sending an email to the mailing list.  I'll make sure whiteinge sees it.
23:51 admineric UtahDave: Will do, thanks
23:51 UtahDave You're welcome. Sorry I couldn't help you.  I just haven't done much with that yet.
23:51 jschadlick joined #salt
23:54 adotbrown joined #salt
23:54 timl0101 joined #salt
23:54 jschadlick left #salt
23:55 aat joined #salt
23:56 Slipo joined #salt
23:56 FL1SK joined #salt

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