Perl 6 - the future is here, just unevenly distributed

IRC log for #salt, 2016-01-15

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

All times shown according to UTC.

Time Nick Message
00:01 RandyT regarding beacons:
00:01 RandyT I've configured beacons via pillars and have tested the configured service watcher and it works.
00:01 RandyT However, if I do a beacons.list, it returns nothing for the minion
00:02 RandyT bug? or something I am missing?
00:02 tuco_ joined #salt
00:03 tuco_ hi there.. i'm very new to salt stack and couldn't find anything useful googling.. so here it goes
00:03 RandyT zmalone: pretty green here, but did not know that you could even use /
00:04 tuco_ i manage nginx in a state.. really just nginx.conf and server.running installed.. now i have a second state which includes nginx and manages one site-enabled file.. why doesn't watch_in work for me
00:04 tuco_ maybe to hard to explain.. i can build a gist if someone is listening
00:07 hightekvagabond joined #salt
00:09 RandyT tuco_: as I was reminded yesterday, watch (and watch_in) do not watch a file. They watch a state.
00:10 tuco_ RandyT: yeah.. the site-enabled/file is handled by file.managed
00:13 tuco_ something like this https://gist.github.com/tuco86/32b928a32fcd21550294
00:14 RandyT typo in last line? servie?
00:14 tuco_ 0o.. yeah just saw..
00:15 tuco_ searching all the net for a problem with watch_in.. and no one had that same problem xD
00:15 RandyT have to run rescue my wife... will look in later
00:15 tuco_ no need.. just fixed it :)
00:15 tuco_ RandyT: thx
00:19 chitown joined #salt
00:24 brianfeister joined #salt
00:29 subsignal joined #salt
00:31 subsigna_ joined #salt
00:35 otter768 joined #salt
00:36 amcorreia joined #salt
00:38 mehakkahlon joined #salt
00:39 bhosmer joined #salt
00:42 ajw0100 joined #salt
00:46 keimlink_ joined #salt
01:15 antpa joined #salt
01:16 flowstate joined #salt
01:17 hal58th joined #salt
01:20 dober joined #salt
01:20 dober joined #salt
01:24 jdipierro joined #salt
01:25 larsfronius joined #salt
01:25 spaceSub joined #salt
01:28 baweaver joined #salt
01:29 Lionel_Debroux_ joined #salt
01:35 digitalhero joined #salt
01:36 flowstate joined #salt
01:50 tristianc joined #salt
01:57 flowstate joined #salt
02:06 jdipierro joined #salt
02:11 kermit joined #salt
02:12 digitalhero joined #salt
02:18 ageorgop joined #salt
02:21 digitalhero joined #salt
02:22 donmichelangelo joined #salt
02:22 murrdoc joined #salt
02:22 digitalh_ joined #salt
02:28 bhosmer joined #salt
02:32 amcorreia joined #salt
02:34 edrocks joined #salt
02:36 otter768 joined #salt
02:39 _JZ_ joined #salt
02:42 Steven- joined #salt
02:47 ilbot3 joined #salt
02:47 Topic for #salt is now Welcome to #salt! | Latest Version: 2015.8.3 | Paid support available for open source Salt! www.saltstack.com/support | Logs: http://irclog.perlgeek.de/salt/ | Paste: https://gist.github.com/ (please don't multiline paste into channel) | Ask with patience as we are volunteers and may not have immediate answers
02:47 ageorgop joined #salt
02:51 catpiggest joined #salt
02:52 snarfy joined #salt
02:53 snarfy^ joined #salt
02:56 evle joined #salt
03:00 PeterO joined #salt
03:00 anmol joined #salt
03:03 edrocks joined #salt
03:07 burp joined #salt
03:10 favadi joined #salt
03:11 ageorgop joined #salt
03:12 writtenoff joined #salt
03:14 digitalhero joined #salt
03:22 bhosmer joined #salt
03:25 MikeyYeahYeah joined #salt
03:26 drawsmcgraw joined #salt
03:26 drawsmcgraw If I'm using the .py renderer for my state files.... how do I include another state file?
03:28 jab416171 joined #salt
03:38 evle joined #salt
03:48 racooper joined #salt
03:49 blckbit10 joined #salt
03:59 rem5 joined #salt
03:59 iggy drawsmcgraw: include in what sense?
03:59 iggy if you mean like a regular yaml+jinja `include:\n  - foo` like statement, just make that part of your return data
04:00 iggy if you're talking a jinja include, no
04:00 drawsmcgraw iggy: If I'm writing a normal state file, I can say something like {{ from '/foo/bar' include baz  with context }}
04:00 iggy no
04:00 drawsmcgraw :(
04:00 drawsmcgraw Alright, well thanks...
04:02 iggy it's one of the downsides of using !yaml+jinja
04:03 iggy it's also one of the reasons some of the formulas have moved away from using map.jinja and moved to defaults.yaml
04:03 jdipierro joined #salt
04:04 mosen joined #salt
04:06 drawsmcgraw Ah... thanks. we'll look into that, then
04:15 flowstate joined #salt
04:19 quasiben joined #salt
04:25 racooper joined #salt
04:25 burp joined #salt
04:25 _krash joined #salt
04:25 _krash hey anyone on?
04:26 _krash I have a dumb question that I think is easy
04:26 _krash anyone know how to execute a salt state using compound targeting?
04:26 _krash or with compound targeting
04:27 burp joined #salt
04:29 RandyT trying to debug a reactor triggered from a beacon event.
04:29 RandyT Everything seems to be working with exception that when event is triggered, I get the following logged to master
04:29 RandyT 016-01-15 04:24:33,769 [salt.utils.process][INFO    ][13824] Process <class 'salt.utils.reactor.Reactor'> (16164) died with exit status None, restarting...
04:31 RandyT this is the reactor state file : https://gist.github.com/rterbush/1cacf1243bc4890fd6d8
04:31 burp joined #salt
04:31 RandyT command executes from the command line without a problem
04:32 RandyT this state file appears to parse correctly when looking at the log
04:32 RandyT "exit status None" does not give me much to go on here
04:33 _krash salt -C 'G@update:early and not G@roles:platform and not G@update:manual:fusion-io and not jira.communitect.com' updates.update_reboot test=True
04:33 _krash I am trying something like this
04:34 _krash salt -C 'G@somegrain:group and not thisthing' state.sls mymodules.pushout test=True
04:36 flowstate joined #salt
04:37 otter768 joined #salt
04:44 burp joined #salt
04:46 ageorgop joined #salt
04:50 digitalhero joined #salt
04:50 digitalhero joined #salt
04:57 flowstate joined #salt
04:57 om joined #salt
05:10 bhosmer_ joined #salt
05:11 burp joined #salt
05:12 om joined #salt
05:13 drawsmcgraw left #salt
05:15 flowstate joined #salt
05:16 favadi joined #salt
05:22 godzirra joined #salt
05:23 godzirra Howdy!
05:23 godzirra So I have a few salt stack questions.  I'll start off by saying I'm new to it and looking at possibly using it in conjunction with docker for server deploys.
05:24 godzirra I was just curious how that works with Docker.  Say I wanted to install a node.js server.  Do I have a docker container that knows it's a node server that deploys and then contacts the salt master and it installs the packages it needs to be a web server?
05:24 larsfronius joined #salt
05:24 godzirra I guess I'm just curious what the best practice is.
05:25 _JZ_ joined #salt
05:26 burp joined #salt
05:31 burp joined #salt
05:43 burp joined #salt
05:47 rdas joined #salt
05:49 burp joined #salt
06:05 rdas joined #salt
06:05 bhosmer_ joined #salt
06:08 ramteid joined #salt
06:16 larsfron_ joined #salt
06:19 linjan joined #salt
06:21 iggy godzirra: docker specifically? You'd at most use salt to orchestrate docker containers on your hosts. Not actually run a minion inside docker
06:21 ageorgop joined #salt
06:21 calvinh joined #salt
06:25 upb yeah, as the functionality for the same goal overlaps, there is no point in using both like that ;)
06:25 thyghaleon joined #salt
06:26 MikeyYeahYeah joined #salt
06:26 godzirra iggy: Makes sense.
06:26 godzirra I'm trying to figure out how we'd use salt+aws or docker+aws.
06:26 godzirra And what the advantage is of using one over the other, or if we'd use all 3 together, I geuss.
06:27 thyghaleon hello, has anyone came up with a way to test jinja rendered values in salt? trying to iterate through a nested pillar dic and having issues debugging what i'm doing wrong exactly
06:27 iggy godzirra: honestly, there are better tools for managing docker if you're starting from scratch
06:29 iggy salt's docker support is fine if you've already got investment in salt for other parts of your infrastructure
06:36 rdas joined #salt
06:38 otter768 joined #salt
06:52 mehakkahlon joined #salt
06:57 LondonAppDev joined #salt
06:57 jimklo joined #salt
07:01 ageorgop joined #salt
07:08 snicers-work joined #salt
07:08 snicers-work Where does salt stack keep it's stateful information such as minions?
07:09 snicers-work I have a salt master in a docker and need to be able to destroy and rebuild the container without losing salt master to minion relationships
07:12 iggy snicers-work: /etc/salt/pki/ is the keys
07:12 iggy snicers-work: might want to look at the docs for multi-master where it talks about what to sync between the masters
07:13 snicers-work Specifically looking not to do multi master
07:14 snicers-work I just want multiple separate masters on a single box.
07:14 snicers-work I am using /etc/salt/pki/ as a docker volume but it seems not to have persisted through a destroy and recreation of the container.
07:15 flowstate joined #salt
07:18 dendazen joined #salt
07:22 colegatron joined #salt
07:23 colegatron good morning.
07:26 larsfronius joined #salt
07:28 jimklo joined #salt
07:30 k_sze[work] joined #salt
07:30 iggy snicers-work: uhh, I wasn't saying use multi-master, I was saying look at the list of files that the multi-master docs tell you to sync, but good job reading what I said
07:30 k_sze[work] Just me or "finite" really means "deterministic"? https://docs.saltstack.com/en/latest/ref/states/ordering.html
07:31 linjan joined #salt
07:34 jimklo joined #salt
07:34 impi joined #salt
07:34 malinoff joined #salt
07:38 colegatron I'm trying to install jenkins without starting the service (it would fail because tomcat is already in the same default 8080 port). I've found a workaround but I am not sure if it could interfere with salt states that could be running in parallel.
07:38 colegatron the workaround is setting some fake files before and remove after the installation (http://askubuntu.com/questions/74061/install-packages-without-starting-background-processes-and-services)
07:39 colegatron anyone knows a better way to do it or can confirm if the workaround can interfere with another salt processes?
07:39 colegatron salt states, sorry
07:40 jimklo joined #salt
07:47 jimklo joined #salt
07:48 federicob joined #salt
07:53 bhosmer joined #salt
07:54 anmol joined #salt
07:55 duncanmv joined #salt
07:55 jimklo joined #salt
07:56 deniszh joined #salt
07:56 KermitTheFragger joined #salt
07:59 slav0nic joined #salt
08:00 otter768 joined #salt
08:02 otter768_ joined #salt
08:02 jimklo_ joined #salt
08:03 elsmo joined #salt
08:04 otter768 joined #salt
08:06 otter768 joined #salt
08:08 otter768 joined #salt
08:09 jimklo joined #salt
08:10 otter768 joined #salt
08:11 otter768_ joined #salt
08:12 egil joined #salt
08:13 otter76__ joined #salt
08:15 flowstate joined #salt
08:15 otter768 joined #salt
08:17 otter768 joined #salt
08:19 otter768_ joined #salt
08:19 a7p left #salt
08:21 otter768 joined #salt
08:23 illern joined #salt
08:23 otter768 joined #salt
08:23 dgutu joined #salt
08:25 writtenoff joined #salt
08:25 otter768_ joined #salt
08:26 cyborg-one joined #salt
08:27 otter76__ joined #salt
08:29 otter768 joined #salt
08:29 rdas joined #salt
08:31 otter768_ joined #salt
08:33 otter768 joined #salt
08:35 otter768_ joined #salt
08:40 AlberTUX joined #salt
08:41 jhauser joined #salt
08:44 Grokzen joined #salt
08:47 bhosmer joined #salt
08:51 impi joined #salt
08:53 zerthimon joined #salt
08:53 LondonAppDev joined #salt
08:55 LondonAppDev joined #salt
08:56 yawniek how can i run a schedule cmd.run as a specific user?
08:59 yawniek https://gist.github.com/yannick/64fd6a0b675b272e2ca2 this does not work, but it should be obvious what i try to archieve
09:01 simoo joined #salt
09:02 simoo How can I write a state (in SLS) that will execute something on a localhost (master) and then execute other states on the minion?
09:03 simoo I want to have a single SLS with 1. create an archive on salt-master and mv it to the location-A and then 2. Copy the archive from salt://location-A/myarchive to minion to location-B
09:05 martoss joined #salt
09:08 cybacolt any saltstack-formula contributors here?
09:10 cybacolt i've recently been added as a contributor and was wondering if there was any info on whats acceptable practise for PR's and such
09:11 cybacolt i'm assuming i could just merge my own, but thought PR's be peer reviewed and merged by someone else?
09:11 cybacolt ^should
09:14 flowstate joined #salt
09:14 GreatSnoopy joined #salt
09:18 Rumbles joined #salt
09:20 aqua^c joined #salt
09:26 denys joined #salt
09:27 aqua^c joined #salt
09:29 chiui joined #salt
09:32 permalac joined #salt
09:36 s_kunk joined #salt
09:36 s_kunk joined #salt
09:37 aqua^c joined #salt
09:40 cybacolt ....
09:40 cybacolt no feedback, i'll just put in a PR for now
09:40 keimlink joined #salt
09:41 bhosmer joined #salt
09:42 jhauser_ joined #salt
09:42 jamesp9 joined #salt
09:45 N-Mi joined #salt
09:52 giantlock joined #salt
09:53 favadi joined #salt
09:55 shanemhansen joined #salt
09:59 elsmo joined #salt
09:59 slav0nic cybacolt, check and bump #26963 )
10:00 slav0nic https://github.com/saltstack/salt/issues/26963
10:00 saltstackbot [#26963]title: Formula documentation should have a contributing section | Recently we've had more issues with people making direct pushes to the saltstack-formulas repos. It would be nice if https://docs.saltstack.com/en/latest/topics/development/conventions/formulas.html had a section regarding contributing. I don't think it needs to be extremely extensive since there's a chance people won't read it (small link at the top of the org page) but
10:03 cybacolt thanks! thats bang on what i'd have expected
10:03 cybacolt tah
10:06 lothiraldan joined #salt
10:09 sahilsinha joined #salt
10:11 LondonAppDev joined #salt
10:14 fredvd joined #salt
10:19 LondonAppDev joined #salt
10:20 linjan joined #salt
10:31 LondonAppDev joined #salt
10:31 favadi joined #salt
10:34 shaggy_surfer joined #salt
10:35 larsfronius joined #salt
10:35 otter768 joined #salt
10:37 larsfron_ joined #salt
10:41 dabb joined #salt
10:45 SVQTQ joined #salt
10:48 simoo how can I copy stuff recursive but without exposing it using salt:// ??
10:48 rbjorkli1 joined #salt
10:48 dabb_ joined #salt
10:48 simoo I've tried file.recurse file.managed file.copy and none of these can copy a full directory on a minion to a different location...
10:49 simoo my case is that I need to transfer sensitive data from master to minion. a whole directory, so I tar gzip it converet to base64 and expose it as a pillar...
10:49 MikeyYeahYeah joined #salt
10:49 simoo then I use contents_pillar in file.managed module to transfer that data to the minion and there I got a one-liner to b64decode and unzip
10:50 simoo and now I wanted to file.recurse that unpacked directory from one place to another, to make use of backup:minion option and differential copy and to just have a nice SLS that does that...
10:50 simoo any idea how can I achieve it?
10:51 babilen simoo: Where do you want to copy it from?
10:52 babilen Ah .. you want to manage all files in a pillar. You could dynamically create a state for each file in the pillar
10:54 k_sze[work] left #salt
10:56 mehakkah_ joined #salt
11:02 LondonAppDev joined #salt
11:05 ravenx joined #salt
11:06 upb hi, how do i match a grain with a value of type list against another list to find if an intersection exists
11:06 ravenx i am following this tutorial http://hittaruki.info/post/vagrant-saltstack-tutorial/   and at the part with /var/www/html... under "Refactoring" doesn't seem to work
11:06 upb something like G@role against bo fe ds
11:06 ravenx i keep getting the errro: State '/var/www/html/info.php' in SLS 'base' is not formed as a list
11:07 ravenx when i do sudo salt '*' state.highstate
11:07 ravenx however, when i remove that line, and only tell it to install those for packages for the LAMP stack, it runs fine.
11:08 upb there's a typo
11:08 upb it's supposed to be file.managed:
11:08 upb - contents: blabla
11:08 upb note the -
11:08 ravenx omg.
11:08 ravenx upb: <33333
11:09 ravenx i was checking everything like:  "did vagrant mess up, is my virtualbox alright, etc"
11:09 ravenx thank so much upb
11:09 upb np
11:16 Hitechcg joined #salt
11:16 Hitechcg left #salt
11:18 mortis doesnt pkg have a "list" option of some sort?
11:18 mortis i'd like to list all packages installed without using cmd.run :)
11:19 mortis list_pkgs
11:19 mortis :)
11:20 favadi joined #salt
11:23 favadi joined #salt
11:23 colegatron joined #salt
11:26 TomJepp_ joined #salt
11:30 bhosmer joined #salt
11:32 CeBe joined #salt
11:36 VSpike I'm getting an issue with mysql_grants.present state in which some of them always fail, even though I can run the SQL statement manually without a problem, and the grants actually appear to be added
11:36 VSpike I found a couple of similar issues reported but neither seem to match my case
11:38 VSpike Can't see any pattern to the ones that fail, either
11:41 simoo babilen: from the filesystem on the minion. basically it can bo done using cmd.run "cp location1 location2" but I wanted to use salt's mechanisms. I can also use rsyncm but I wanted to do as much as I can in salt
11:43 simoo babilen: generally the issue I faced was that I wanted to expose a whole directory with sensitive data (keys, certs and so on) to given minions and I need isolation, so pillar is the way to go.. but there everything has to be a YAML file.
11:44 simoo babilen: I've seen even ext file_system for plugins, so I can access all files via pillars, but still I want to do a simple thing like "transfer whole directory as it is from master to pillar securely".. so i don't need to care about explicitly accessing all subdirs and files in that file tree I want to expose
11:45 simoo fro mmaster to minion* of course...
11:46 rmnuvg joined #salt
11:47 simoo the easiest way would be to have something like pillar:// schema, so I could use file.recurse state and set source to pillar://<my directory> and restrict access to that pillar to the right set of minions, but I've seen a ticket that this schema won't be implemented...
11:48 jhauser_ joined #salt
11:48 simoo so as a workaround I use simple one-liner on master to prepare a gzipped package encoded using base64.. i got a pillar.sls which uses import_text and sets a property in YAML and then I can push it to the minion, decode and extract it there..
11:50 simoo and then I want to sync that temp location to which I extracted everything with the right directories on the minion's filesystem... and I thought I might use file module to do the job, but it appears it cannot simply copy/sync directory from a local location to another local location...
11:51 simoo if it's using the recurse module it has to be pointed to salt:// location so something that is publicly available, because everything in states is public for all minions.. and because I have sensitive data I won't do it this way
11:51 VSpike Here's the debug log which I'm trying to pick my way through https://bpaste.net/show/805d82ba61fd but if anyone has any insight I'd appreciate it!
11:56 VSpike Wondering about lines like grants mismatch {'host': 'localhost', 'database': '*.*', 'user': 'maint', 'grant': ['INSERT', 'RELOAD', 'SUPER', 'REPLICATION CLIENT', 'CREATE TABLESPACE']}<>{'host': 'localhost', 'database': '*.*', 'user': 'maint', 'grant': ['INSERT', 'RELOAD', 'SUPER', 'REPLICATION CLIENT']}
11:57 VSpike Should it fail if the user has *more* grants than the ones specified?
11:57 danduk82 joined #salt
11:57 VSpike Seems to me like mysql_grants.present should success as long as all the requested grants are there
11:59 lothiraldan joined #salt
12:03 VSpike Oh, OK. I just have to add "CREATE TABLESPACE" to the list of grants I'm trying to add, and it works. It seems that one is getting granted by default, or perhaps as a side effect of another grant
12:03 VSpike Even adding "revoke_first: True" doesn't help
12:13 simoo babilen: I'm using 2015.5.8 so i dealt with it using cmd.run rsync -r <loc-1> <loc-b> for now cos I guess there is no better way to do that
12:20 jdipierro joined #salt
12:24 sjorge joined #salt
12:24 sjorge joined #salt
12:24 bhosmer_ joined #salt
12:35 quasiben joined #salt
12:36 otter768 joined #salt
12:39 jdipierro joined #salt
12:39 impi joined #salt
12:40 rm_jorge joined #salt
12:41 Grokzen joined #salt
12:53 danduk82 hello everybody, I wonder if it is possible to apt::pin some specific packages in a state. In particular, I need to remove the default packages, and install new ones form another repo. I have written a detailed explanation of my problem, with the different steps I have followed on pastebin: http://pastebin.com/48ZG36wQ . Could anyone have a look to this please? Thanks in advance
13:00 BradThurber joined #salt
13:02 MikeyYeahYeah joined #salt
13:10 flowstate joined #salt
13:11 DammitJim joined #salt
13:18 bhosmer joined #salt
13:21 linjan joined #salt
13:22 akhter joined #salt
13:27 netcho joined #salt
13:29 amcorreia joined #salt
13:33 akhter joined #salt
13:36 danduk82 Good afternoon, may I ask again the same question as this morning: "hello everybody, I wonder if it is possible to apt::pin some specific packages in a state. In particular, I need to remove the default packages, and install new ones form another repo. I have written a detailed explanation of my problem, with the different steps I have followed on pastebin: http://pastebin.com/48ZG36wQ . Could anyone have a look to this please? Thanks in
13:36 danduk82 advance"
13:39 jvv joined #salt
13:41 sknebel joined #salt
13:42 evle joined #salt
13:42 morissette joined #salt
13:43 ingslovak joined #salt
13:43 gh34 joined #salt
13:45 _mel_ joined #salt
13:46 dendazen joined #salt
13:51 dariusjs joined #salt
13:53 Score_Under How do I install a specific version of a python package using pip? Passing "name: psutil >= 2.0.0" and "upgrade: True" to the pip.installed state still doesn't upgrade from psutil==0.7.1 on an older machine
14:02 edrocks joined #salt
14:07 patrek joined #salt
14:11 bhosmer joined #salt
14:14 martoss left #salt
14:18 BradThurber joined #salt
14:20 cpowell joined #salt
14:23 dariusjs joined #salt
14:28 numkem joined #salt
14:31 racooper joined #salt
14:31 giantlock joined #salt
14:33 subsignal joined #salt
14:33 spiette joined #salt
14:37 otter768 joined #salt
14:37 froztbyte hrm
14:38 froztbyte without enforcing a specific state of a file from salt, is there a way to just "watch" it?
14:38 kawa2014 joined #salt
14:38 froztbyte in such a fashion that I can get told if there's a checksum change between runs?
14:39 froztbyte (wondering if I can cheap&cheesy what I'm pondering to do without having to pull out an accumulator or something)
14:39 hasues joined #salt
14:40 AndreasLutro froztbyte: I don't think so... maybe a beacon can do what you want?
14:41 froztbyte yup
14:41 froztbyte that indeed
14:41 froztbyte thanks
14:41 RandyT good day
14:42 RandyT would someone be able to help me debug this issue with reactor + beacons?
14:42 RandyT https://gist.github.com/rterbush/1cacf1243bc4890fd6d8
14:42 RandyT that is the reactor state. Getting called from an event generated from a beacon.
14:46 hasues left #salt
14:49 rem5 joined #salt
14:50 RandyT The beacon is creating the event and the reactor is getting rendered, but Reactor is dieing with "Exit status None". I've added a snippet from the error log on the master to that gist.
14:50 RandyT This works from the command line.
14:52 malinoff joined #salt
14:52 Priyanka joined #salt
14:53 Priyanka hi, Using Salt, How to execute an exe file
14:53 Priyanka is it possible?
14:53 Score_Under Priyanka: The cmd.run state, if you want a state
14:53 XenophonF Priyanka: yes, via cmd.run
14:54 Priyanka ok. Thanks...
14:54 LondonAppDev joined #salt
14:54 Priyanka And Can I extract data out of database using Salt
14:54 thetoolsmith joined #salt
14:54 XenophonF Priyanka: https://docs.saltstack.com/en/latest/ref/states/all/salt.states.cmd.html
14:54 Score_Under Priyanka: there's also a module by the same name. salt '*' cmd.run 'hostname && date'
14:54 Azid joined #salt
14:54 XenophonF Priyanka: probably, using Salt Mine
14:54 dyasny joined #salt
14:55 bhosmer joined #salt
14:55 XenophonF Priyanka: https://docs.saltstack.com/en/latest/topics/mine/
14:55 Priyanka Using Salt Mine, I can extract data out of database also
14:55 Priyanka Am I correct?
14:56 XenophonF Priyanka: alternatively - https://docs.saltstack.com/en/latest/ref/pillar/all/salt.pillar.mysql.html
14:56 XenophonF you could use an external pillar
14:56 Priyanka My db is SQL
14:56 XenophonF SQL what?
14:57 XenophonF lots of databases have those three letters in their name :)
14:57 Priyanka I mean, My database is all SQL server
14:57 Priyanka I am sorry..
14:57 zmalone joined #salt
14:57 Priyanka on that Pillar link, it is mentioned about MySql..
14:57 Priyanka Not SQL Server
14:58 XenophonF sorry my ability to read your mind isn't working today ;)
14:58 XenophonF doesn't look like anyone's contributed a sql_base adapter for SQL Server
14:59 flowstate joined #salt
14:59 XenophonF that sucks
14:59 Score_Under How does salt.modules.launchctl register itself as a provider for [1;5Dthe salt.states.service
14:59 XenophonF looks like there isn't one for postgresql either
14:59 Score_Under ...functions?
14:59 Brew joined #salt
15:00 XenophonF Score_Under: there's a loader mechanism
15:00 XenophonF it scans for .py files in special places, e.g., _modules in your state tree
15:00 colegatron I'm trying to ask 'Y' in the state to a "pkg.install jenkins". this is because the /etc/default/jenkins exists and want to keep it. any idea aside a 'cmd.run apt-get -y install' ?
15:01 XenophonF when it finds one, it tries to load a __virtual__() function defined in that file
15:01 Score_Under ah
15:01 Score_Under is there a way I can prioritize my __virtual__ (→ 'service') over the others
15:01 XenophonF that function needs to return the name of the module, I think
15:01 ALLmightySPIFF joined #salt
15:01 XenophonF are you re-writing or modifying a salt-provided module?
15:02 XenophonF if so, just copy it to your states tree, e.g., /usr/local/etc/salt/states/_modules/
15:02 XenophonF then run "salt-call saltutil.sync_all" on your minion
15:02 Score_Under A bit of both. I want to halfheartedly hack in some osx 10.10 launchctl compatibility into launchctl.py, so I want to be picked over the usual launchctl.py if we're on 10.10
15:03 pyropoptrt joined #salt
15:03 XenophonF ah so in your __virtual__() function, put a bit of code that checks the OS version
15:03 XenophonF this will help you https://docs.saltstack.com/en/latest/topics/development/dunder_dictionaries.html
15:03 Score_Under That's great, so _modules takes priority over salt.modules?
15:03 XenophonF then if your minion isn't running on Mac OS X 10.10, just return False
15:04 XenophonF and the original module should still load
15:04 XenophonF yes
15:04 Score_Under ah
15:04 Score_Under thanks very much for the help
15:04 XenophonF https://docs.saltstack.com/en/develop/ref/file_server/dynamic-modules.html
15:04 XenophonF i might have the details wrong so be sure to RTFM
15:05 cwright_ is anyone here successfull using an onlyif/unless with cmd.wait/-watch: ?  because cmd.wait with a watch appears to completely ignore onlyif/unless for me
15:05 cwright_ i've seen several issues in github about this but none are resolved
15:05 XenophonF and be sure to RTFS of the other modules to get clues
15:05 cwright example: https://github.com/saltstack/salt/issues/29515
15:05 saltstackbot [#29515]title: cmd.wait state watching a cmd.run state with onlyif/unless always runs | I'd like to have a `cmd.wait` state `watch` a `cmd.run` state.  For example:...
15:06 nofxrok joined #salt
15:06 cwright https://github.com/saltstack/salt/issues/16647
15:06 saltstackbot [#16647]title: unless / onlyif is not properly handled: ignored | SLS...
15:06 andrew_v joined #salt
15:07 XenophonF cwright: a cmd.run state will always return changes, so i'm guessing you want the onlyif/unless kwarg to prevent execution, right?
15:07 cwright XenophonF: i want to trigger db schema changes on a package upgrade, so i have a state that runs the migrations watching the pkg upgrade state
15:08 cwright however, i want to use `onlyif` to check to see if the schema migration has already be run
15:08 BradThurber joined #salt
15:08 cwright when using cmd.wait to run the migration, watching the pkg states, the cmd.wait always runs no matter whether onlyif/unless are specified
15:09 cwright in other words, the onlyif/unless clauses are completely ignored
15:09 cwright this seems to be what is happening in those two github issues i found as well, but there was no clear "fix" or resolution to either of those. they were just closed
15:11 XenophonF ugh the salt/states/cmd.py sources make my head hurt
15:13 XenophonF so i'm RTFS-ing
15:13 XenophonF and get this: the wait() function is empty
15:13 XenophonF i guess everything shares code with run(), so wait, wait_script, etc. are just stubs
15:14 cpowell joined #salt
15:15 XenophonF there's a function named mod_run_check that seems to implement the onlyif/unless/etc. functionality
15:15 cwright how new is that?
15:15 LtLefse left #salt
15:19 XenophonF i happend to be looking at tags/v2015.8.3
15:19 XenophonF unfortunately i don't have time to look at this further
15:20 XenophonF you can try running the SLS file using salt-call -l debug state.sls blahblah test=True or something along those lines
15:20 cwright XenophonF: thanks
15:20 RandyT cwright: fwiw, I tackled this exact same issue last week and ended up using orchestrate to do software and db upgrades.
15:20 XenophonF that should tell you whether your onlyif or unless clauses are running
15:20 XenophonF i dunno
15:20 XenophonF ttyl
15:21 RandyT controls seemed to be more predictable using orchestrate
15:21 cwright RandyT: yea, i'd just like to know if this is an issue with onlyif/unless and cmd.wait/watch
15:21 cwright because it sure seems broken to me
15:21 RandyT very well could be. I was not getting the results I expected, so moved to something that did that for me
15:25 peters-tx SaltConf16 is right around the corner; does anyone know how long the SSCE (certification) is good for?  I have one from '15
15:25 digitalhero joined #salt
15:26 denys joined #salt
15:29 mapu joined #salt
15:34 jor joined #salt
15:35 nkuttler joined #salt
15:35 digitalhero joined #salt
15:36 honestly joined #salt
15:37 flowstate joined #salt
15:37 tehsu joined #salt
15:38 samed joined #salt
15:38 samed joined #salt
15:38 Nebraskka joined #salt
15:39 nkuttler joined #salt
15:40 permalac joined #salt
15:42 TooLmaN joined #salt
15:43 atmosx joined #salt
15:43 atmosx hello, what does mkmnt: True stand for?
15:43 atmosx nm
15:43 atmosx If the mount point is not present then the state will fail, set mkmnt: True to create the mount point if it is otherwise not present
15:44 anotherZero joined #salt
15:44 amcorreia joined #salt
15:45 teryx510 joined #salt
15:46 cpowell joined #salt
15:47 danlsgiga hey folks... is there any way to force an event to be sent only at the end of the state execution?
15:47 aqua^c joined #salt
15:47 jeffspeff joined #salt
15:48 catpig joined #salt
15:49 danlsgiga Basically I want an event to add a new server to the proxy load balancer only when all the highstate is run and operational
15:50 bhosmer joined #salt
15:50 RandyT danlsgiga: is this an aws elb, or something else?
15:50 danlsgiga RandyT: NginX!
15:51 RandyT I've run across some examples in recent months for registering with load balancers.
15:51 bronz joined #salt
15:52 RandyT for starters, I think you could use event.send to create an event after some state run and a requisite for good measure.
15:52 DammitJim is there pip install in salt?
15:52 RandyT you might also want to look at beacons to send the event for you based on the minion becoming available
15:52 danlsgiga RandyT: I have that currently... and event.send with a onchange to the apache service
15:52 RandyT danlsgiga: yes, there is pip.installed:
15:52 tpaul joined #salt
15:53 danlsgiga the problem is that I need Apache to be the first one to be installed
15:53 danlsgiga RandyT: DammitJim asked that! :)
15:53 RandyT danlsgiga: so make the pkg install for apache a requisite
15:53 DammitJim woot?
15:53 DammitJim thanks
15:53 godzirra iggy: Like what tools?  Aopparently I'm not using them. :)
15:53 RandyT DammitJim: too quick with my tab...
15:54 danlsgiga RandyT: The service already has a requisite for the package and the event send has the onchanges for the service... so it is chained
15:55 danlsgiga RandyT: I need to have the apache formula running first to create the folder structure for the php-fpm formula, but I'd like to have the event.send atached to the apache service to run at the end of the execution only
15:56 danlsgiga RandyT: I know that the Listen requisite does that for services, but it doesn't seem to do for the event
15:56 danlsgiga RandyT: I was thinking on using the - order: 999
15:56 danlsgiga RandyT: hacky and ugly, but
15:56 tpaul Can a Master run on Windows?
15:57 RandyT danlsgiga: maybe I am not understanding what you are trying to do. seems that making the php-fpm state require: - pkg: apache takes care of that issue
15:57 RandyT tpaul: my understanding that it is not supported
15:58 RandyT tpaul: and why would you want to do that to yourself anyway? :-)
15:58 danlsgiga RandyT: I need to check that, but I know I have a requisite in the php-fpm config.sls for the apache pkg. hence apache is running before
15:58 smokebeast joined #salt
15:59 danlsgiga RandyT: Or I can maybe use - makedirs: True in the php-fpm to create the folder structure required
15:59 toastedpenguin joined #salt
15:59 RandyT danlsgiga: or use the file states to create the directory structure.
15:59 RandyT danlsgiga: I guess I am missing what is NOT working in your setup.
15:59 tpaul RandyT: We use salt for all of our hosted and internal infrastructure but we have a very big complex deployment we need to do at a customer's data center and that customer only allows windento servers in their environment.  I was hoping I could use salt there too
16:00 tpaul RandyT: So I don't really "want to do that" to myself, but...
16:00 RandyT tpaul: might have to see if you can sneek a linux box in there. :-)
16:00 danlsgiga RandyT: Everything is working flawlessly... I just wanted to check if there was any other option to force the event to be sent at the end of the highstate execution
16:01 RandyT tpaul: I am managing a number of Windows roles in my environment, so I cannot imagine adding the pain of using a Windows master.
16:01 RandyT The minions have been a big enough challenge. :-)
16:01 tpaul RandyT: No way that would work for this customer, we're not even allowed to do the deployment we have to hand off instructions to their IT staff and we're completely hands off
16:02 RandyT tpaul: so does this mean that MSFT is switching to salt to manage their their environments?! :-)
16:02 danlsgiga tpaul: Feeling really sad for you sir! :P
16:02 smokebeast I have accepted the key on my salt master successfully, however when I do a test ping (salt * test.ping) I get the following message "No minions matched the target.  No command was sent, no jid was assigned  ERROR: No return received."  I have removed the minion_master file and re-accepted the key on the master.  Still not working.  Any suggestions or advice is appreciated.
16:02 brianfeister joined #salt
16:02 tpaul danlsgiga: please do, I've been able to stay off the project up until today, now I'm getting dragged in
16:03 RandyT danlsgiga: I've been playing with beacons lately and find them very useful for the task of generating events.
16:03 RandyT Could easily create a beacon to watch for apache service and send event
16:04 RandyT or any service for that matter, even windows services as I can attest
16:04 RandyT which brings me to the issue I am trying to solve here today.
16:04 RandyT https://gist.github.com/rterbush/1cacf1243bc4890fd6d8
16:04 RandyT Reactor not doing what I would expect.
16:05 RandyT not clear if I just cannot run the slack.post_message from a reactor or what the issue might be with minimal response from Reactor error log
16:05 Lionel_Debroux_ joined #salt
16:06 jhauser joined #salt
16:06 bhosmer joined #salt
16:08 edrocks joined #salt
16:08 AndreasLutro aren't you missing a local. in front of slack.post_message?
16:09 RandyT AndreasLutro: error is more clear when I add local.
16:09 RandyT clear in the sense that it is complete failure
16:09 RandyT Have found examples of other folks using it this way, but perhaps not in reactor
16:11 danlsgiga RandyT: yup, definitely you need the local. in the reactor
16:11 danlsgiga RandyT: Will take a look if Beacons can help me in this task! :)
16:12 hal58th joined #salt
16:12 AndreasLutro RandyT: for what it's worth, I use a custom returner to notify me about state run results
16:12 AndreasLutro involving a reactor for that seems unnecessary
16:13 RandyT AndreasLutro: appreciate that feedback. Can you point me to an example. Was looking at returners for this but could not find anything that described how to limit what is sent to specific returners.
16:13 RandyT Seemd to be an all or nothing pipe
16:13 RandyT clearly missing something as that does not seem very useful.
16:14 LondonAppDev__ joined #salt
16:14 RandyT changing this to add local results in following error
16:14 RandyT 2016-01-15 16:07:45,452 [salt.utils.reactor][WARNING ][23382] Exception caught by reactor: cmd_async() takes at least 3 arguments (2 given)
16:14 RandyT which might be progress
16:14 AndreasLutro just add a bunch of if checks to your returners, and add them all in your config
16:16 AndreasLutro RandyT: https://bpaste.net/show/9a7177e66950
16:16 brianfeister joined #salt
16:17 RandyT AndreasLutro: thanks for sharing. Will look into that in more detail
16:17 AndreasLutro if you want to still use local.slack.post_message I think you need the "tgt" and "args" as shown here https://docs.saltstack.com/en/develop/topics/reactor/index.html#calling-execution-modules-on-minions
16:18 RandyT AndreasLutro: I'll give the returner a go and see what I learn there. Have not yet gone down that path in salt.
16:19 RandyT it does feel awkward to run this in reactor since in reality, I am wanting to run this on master every time and it just doesn't fit the model.
16:19 akhter_1 joined #salt
16:19 AndreasLutro yeah I don't think this is what the reactor is meant for
16:22 RandyT AndreasLutro: I guess the other thing I was struggling with when looking at returners was the abiliity to act on events.
16:23 AndreasLutro yeah, I'd just "solve" that with a bunch of if statements :p
16:23 RandyT AndreasLutro: I now see this: https://docs.saltstack.com/en/latest/ref/returners/index.html#event-returners
16:24 AndreasLutro I haven't tried that yet
16:25 maduro joined #salt
16:25 jimklo joined #salt
16:25 fleaz joined #salt
16:26 blckbit10 joined #salt
16:29 fleaz Hi, is there a way to loop through all my minions in my state file? I need a seperate file for every minion so my idea was to use a file.managed inside a loop. Or is there a better way?
16:31 murrdoc joined #salt
16:32 CheKoLyN joined #salt
16:32 jfindlay fleaz: you may want to try the orchestrate runner, which runs in the master context
16:32 norii fleaz: does pillar not  work for what you  need
16:32 jfindlay whereas states run on the minions
16:34 MikeyYeahYeah joined #salt
16:35 jdipierro joined #salt
16:35 alemeno22 joined #salt
16:37 fleaz what i'm trying to do: A state which runs only on my icinga host an creates there one file for every minion.
16:38 fleaz just using salt for a few days now, not sure if I already got every idea of salt ;)
16:38 otter768 joined #salt
16:39 mpanetta joined #salt
16:45 ALLmightySPIFF joined #salt
16:46 RandyT fleaz: as norii says, you might want to look at pillars
16:46 RandyT takes awhile to get your head around all of the moving parts
16:46 bhosmer__ joined #salt
16:46 RandyT pillars definitely a key part to grasp to simplify the application of salt
16:47 hexa- RandyT: isn't that basically duplicating what is already in the top.sls?
16:47 hexa- like knowledge what package is rolled out to which machine
16:47 ALLmightySPIFF joined #salt
16:48 AndreasLutro you could use the mine to get all the minions
16:48 RandyT hexa-: yes, that is probably one way to approach it. I've gravitated toward keeping things that are unique to specific machines or roles in pillars.
16:49 RandyT so a common file.managed state file that uses variables assigned via pillar to make them unique per host
16:58 onlyanegg joined #salt
16:59 FreeSpencer Is it possible to have schedule jobs not depend on the minion being able to connect to the master?
17:01 murrdoc joined #salt
17:05 AndreasLutro FreeSpencer: yes, with cronjobs ;)
17:05 FreeSpencer Ahh so the schedule isnt cached on the minion is it?
17:05 AndreasLutro it might be, but it's a salt operation, so it needs master-minion connectivity
17:06 jhauser joined #salt
17:09 FreeSpencer Interesting thanks!
17:09 DammitJim joined #salt
17:10 bhosmer joined #salt
17:15 Bryson joined #salt
17:19 linjan joined #salt
17:23 colegatron joined #salt
17:24 neogenix joined #salt
17:28 RandyT AndreasLutro: is a schedule actual a master process?
17:28 RandyT I have minions happily running scheduled states from cache for schedules loaded from pillar data
17:32 L2SHO joined #salt
17:35 AndreasLutro I think it's a minion process, but not sure
17:39 writtenoff joined #salt
17:48 guest234123 joined #salt
17:49 impi joined #salt
17:50 guest234123 Hi. I have a rule with a couple of requires like this "use-debian-testing:\n    pkg.refresh_db\n    require: ..." and would like to require the execution of it in another file. Doing it like "install-foo:\n    pkg.installed: ... -require:\n  -pkg: use-debian-testing" does not work ("The following requisites were not found"). Any ideas?
17:53 bhosmer joined #salt
17:54 AndreasLutro guest234123: you probably want something similar to this https://bpaste.net/show/6ad744705d74
17:54 zmalone Is anyone else using spaces in state ids?  I can't find any example of it in the salt docs, but I keep running into internal salt formulas which are using that format.
17:55 zmalone How do you reference a state id like "johns apache config:" from another state?  Double quotes?
17:55 AndreasLutro zmalone: the : is not part of the state id
17:55 guest234123 AndreasLutro: thanks, I'll look into it.
17:55 zmalone Yeah, I understand, but I included it to make what I meant by "state id" a little more obvious
17:56 AndreasLutro ok, well, you reference it just as you would any other
17:56 anotherZero joined #salt
18:01 guest234123 AndreasLutro: if I move pkg.refresh_db into module.run (as "use-debian-testing: -> - module.run: -> - pkg.refresh_db"), can I somehow require "require: -> - module: use-debian-testing")? use-debian-testing for me is nothing but a collection of requires. Right now "require: -> - module: use-debian-testing" results in "The following requisites were not found" for me.
18:01 joyrida08 joined #salt
18:01 AndreasLutro guest234123: make a gist or pastebin or something of what you're doing
18:01 iggy godzirra: docker compose/swarm, kubernetes, mesos, fleet, Amazon Container Service, etc
18:02 L2SHO_ joined #salt
18:03 guest234123 AndreasLutro: https://bpaste.net/show/194ca989399b
18:04 AndreasLutro uuh
18:04 iggy fleaz: salt mine maybe?
18:07 larsfronius joined #salt
18:08 zmalone joined #salt
18:10 AndreasLutro there's a lot of mistakes here guest234123 - but for starters, why are you using debian testing to install docker instead of their official apt repositories? https://docs.docker.com/engine/installation/debian/
18:11 sfxandy joined #salt
18:11 sfxandy hi everybody
18:11 guest234123 AndreasLutro: I much prefer the debian packages. I am open to any hints for improvement. I am completely new to salt.
18:12 jab416171 I'm trying to set up gitfs with gitpython, but whenever I try to run a highstate, I get "No Top file or external nodes data matches found"
18:13 AndreasLutro guest234123: I prefer debian packages as well because of stability, but by using testing you're throwing that stability out the window, so you may as well go with docker's
18:13 sfxandy question about beacons: is it possible to raise an arbitrary tag or to add an arbitrary item to to the 'data' field for the event that gets raised by the beacon?
18:13 moogyver joined #salt
18:13 guest234123 AndreasLutro: Might be true. But doesn't fix my salt problems :)
18:14 jab416171 nevermind, I fixed it
18:14 guest234123 AndreasLutro: It's also a trust thing. I trust the Debian project much more to run a secure infrastructure.
18:15 AndreasLutro guest234123: again... this doesn't apply to testing
18:15 AndreasLutro guest234123: I can't think of a way to do what you're trying to achieve
18:15 ageorgop joined #salt
18:17 guest234123 Any idea for a different approach to https://bpaste.net/show/194ca989399b ? AndreasLutro, or anyone?
18:18 karlthane joined #salt
18:18 sfxandy whats wrong with the current approach guest234123?
18:18 iggy jab416171: what was it?
18:18 impi joined #salt
18:19 guest234123 sfxandy: "The following requisites were not found" -> prereq: -> module: use-debian-testing-repo
18:20 rihannon joined #salt
18:21 anotherZero joined #salt
18:22 snarfy^ joined #salt
18:23 flowstate joined #salt
18:27 ajw0100 joined #salt
18:27 jimklo_ joined #salt
18:28 wendall9111 joined #salt
18:29 brianfeister joined #salt
18:31 jhauser joined #salt
18:35 akhter joined #salt
18:38 larsfronius joined #salt
18:39 otter768 joined #salt
18:46 zsoftich1 joined #salt
18:47 baweaver joined #salt
18:49 ageorgop joined #salt
18:50 duncanmv joined #salt
18:51 flowstate joined #salt
18:54 DammitJim joined #salt
18:54 snarfy^ joined #salt
18:55 brianfeister joined #salt
18:55 Crazy67 joined #salt
18:57 aboe joined #salt
18:57 lompik joined #salt
19:02 overyander joined #salt
19:04 giantlock joined #salt
19:05 hal58th iggy, I took my laptop home and then it suddenly started working. This might be because I'm working on a vagrant box. Still took a lot of reading to get my configuration into a working state.
19:07 cedwards joined #salt
19:08 federicob joined #salt
19:10 Ch3LL joined #salt
19:10 viq joined #salt
19:12 Fiber^ joined #salt
19:15 baweaver joined #salt
19:15 denys joined #salt
19:15 hal58th guest234123: I see your problem. Your include statement is incorrect. It should read     - debian-repositories
19:16 hal58th false enter...   debian-repositories/testing
19:19 jdipierro joined #salt
19:19 hoonetorg joined #salt
19:20 akhter joined #salt
19:23 aqua^c joined #salt
19:26 guest234123 hal58th: ah, that seems to do something with a few other minor adjustments. Thanks, I think I am a step further, now. Will let you know.
19:29 deniszh joined #salt
19:30 edrocks joined #salt
19:32 sfxandy question about beacons: is it possible to raise an arbitrary tag or to add an arbitrary item to to the 'data' field for the event that gets raised by the beacon?
19:33 hal58th welcome guest234123, glad I could help
19:37 perfectsine joined #salt
19:37 jmickle joined #salt
19:37 jmickle is this the correct way to use the env variable in the minion config in a .sls file? {{ salt['env'] }}
19:38 baweaver joined #salt
19:43 choopooly joined #salt
19:46 hightekvagabond joined #salt
19:46 hightekvagabond Is there a salt state module that lets me manage just one line in a config file? I want to leave the rest of the file alone but just want to verify a specific line is there if not add it, bonus points for being able to use a regex to find the line and replace it's value (but thats an edge case for me in this case)
19:46 muep_ file.replace
19:46 hightekvagabond thanks, I'll go look at it
19:47 muep_ https://docs.saltstack.com/en/latest/ref/states/all/salt.states.file.html#salt.states.file.replace
19:47 bhosmer joined #salt
19:47 hightekvagabond yes, this is exactly what I was looking for, thanks much
19:48 hightekvagabond thats a lot easier than how I was dealing with the issue
19:48 Shirkdog joined #salt
19:50 _JZ_ joined #salt
19:52 GreatSnoopy joined #salt
19:52 digitalhero joined #salt
19:54 zmalone joined #salt
19:56 ageorgop joined #salt
20:00 CeBe joined #salt
20:05 sahilsinha does anyone have experience with the x509 module/state? Is there a way that I can confirm minions are able to remote call the sign_remote_certificate function
20:05 dendazen what does error mean 'No matching sls found for 'my_state' in env 'base' mean?
20:07 moogyver sfxandy - from looking at the beacon documentation, it looks like the 'tag' key is grabbed from dict's that are returned and that's what used.  you'd have to modify the beacon if there was an existing one you wanted to use and you wanted to add more data.
20:12 terinjokes joined #salt
20:13 akhter joined #salt
20:19 linjan joined #salt
20:28 digitalhero joined #salt
20:32 devopsprosiva joined #salt
20:32 devopsprosiva Hi, what's the sys.doc command to view the state documentation?
20:33 norii dendazen: there should be a matching sls in  your salt root i believe
20:33 perfectsine joined #salt
20:34 dendazen yeah.
20:34 dendazen thank you.
20:34 dendazen i was just misspeling my state in command.
20:34 norii systax always gets  me too
20:35 Rumbles joined #salt
20:38 jimklo joined #salt
20:40 otter768 joined #salt
20:41 bhosmer_ joined #salt
20:42 beardedeagle joined #salt
20:44 brianfeister joined #salt
20:50 jeffspeff joined #salt
20:56 MikeyYeahYeah joined #salt
20:56 danlsgiga shouldn't a salt-cloud -d remove the minion cache? When I'm destroying an AWS instance, everything works, including the key removal, but the cache remains there...
20:56 danlsgiga what happens is that the mine calls still get the mines cached from the dead instance
20:57 danlsgiga anyone facing the same problem
20:57 danlsgiga ?
20:57 _beardedeagle joined #salt
21:00 perfectsine joined #salt
21:02 mehakkahlon joined #salt
21:06 rem5 joined #salt
21:07 stooj joined #salt
21:08 akhter joined #salt
21:09 jayne_ joined #salt
21:15 sknebel joined #salt
21:17 flowstate joined #salt
21:18 _beardedeagle one of these things is to much like the other: [DEBUG   ] Please login as the user "root" rather than the user "root".
21:19 rem5 joined #salt
21:21 jfindlay it's a paradoxical tautology
21:21 bronz joined #salt
21:21 Crazy67 joined #salt
21:21 digitalhero joined #salt
21:26 devopsprosiva joined #salt
21:29 yamamushi joined #salt
21:30 yamamushi When I provision a *nix cloud profile, I can set the ssh_interface to "private_ips", to connect to the attached private IP, what is the equivalent setting for a Windows instance?
21:33 flowstate joined #salt
21:35 ajw0100 joined #salt
21:47 ageorgop joined #salt
21:48 baweaver joined #salt
21:51 brianfeister joined #salt
21:54 GnuLxUsr joined #salt
21:56 netcho_ joined #salt
21:57 RandyT trying to get a local event_return working.
21:57 RandyT sync_all shows that it finds it.
21:58 RandyT But when events fire, I get a log message saying cannot find it.
21:58 RandyT any ideas how to debug this?
21:58 RabidCicada joined #salt
21:59 RandyT __virtualname__ is set to same value I am using in master config for event_return:
22:02 akhter joined #salt
22:02 subsignal joined #salt
22:03 coval3nce joined #salt
22:03 coval3nce is calling a moudle directly from jinja simply salt[‘module.func’](args) ?
22:04 coval3nce “[ERROR   ] Rendering exception occurred :Jinja variable 'salt.utils.templates.AliasedLoader object' has no attribute 'dockerng.exists’” is getting tossed out for me
22:04 coval3nce “salt-call 2015.8.3 (Beryllium)”
22:05 RandyT I see "could not lazyload localreturner.event_return" in logs
22:07 qman__ joined #salt
22:11 jfindlay RandyT: may be a syntax error.  Are you able to load it with the standard python loader `python ; import my_returner`?
22:11 Brew joined #salt
22:12 jfindlay coval3nce: can you verify that you have access to `dockerng.exists` in other contexts, like `salt '*' sys.doc dockerng.exists`?
22:13 jfindlay RandyT: also be sure to check the __virtual__ logic
22:13 jfindlay in your custom module
22:13 RandyT @jfindlay: looks like problem might be missing python modules for slack
22:14 RandyT let me investigate that further. thanks for that help
22:14 RandyT import fails
22:14 coval3nce @jfindlay that returns nothing for me.
22:15 jfindlay coval3nce: that means the dockerng module is not loading.  You should probably check the prerequisites for salt+docker
22:15 RandyT @jfindlay: if I name this returner the same as the builtin slack_return.py, can I expect it to overload the builtin?
22:16 jfindlay RandyT: it should
22:17 coval3nce @jfindlay ah yeah thats it, damn….so taht means i cna’t use a highstate to install the pip bits i need.  Cause the jinja expects dockerng
22:17 coval3nce guess i’m rewriting jinja to be system calls?
22:18 jfindlay coval3nce: not necessarily.  You can force a reload of the exec modules
22:18 jfindlay in the middle of a state run
22:18 TyrfingMjolnir joined #salt
22:19 coval3nce i’ve got thes pre-reqs getting installed in a completely different state tho
22:19 jfindlay coval3nce: https://docs.saltstack.com/en/latest/ref/states/, search for reload_modules
22:19 coval3nce and i haven’t executed anyting yet, its just jina rendering that is faling
22:19 jfindlay https://docs.saltstack.com/en/latest/ref/states/#reloading-modules
22:20 coval3nce This would work in the context of a state execution, but not jinja  calling salt modules correct?
22:20 coval3nce This happens before the state files are even rendered.
22:21 jfindlay that's a good point.  I think you should be able to structure your states such that a highstate should still work, but don't have enough experience writing states to recommend how to do it
22:21 coval3nce I could use built-in moduelsi n salt somehow in the jinja maybe instead of relying on modules that require additions
22:22 coval3nce or make salt-bootstrap always install the thigns i need first
22:22 coval3nce almost like a need a  high high state.  hehe
22:24 GreatSnoopy joined #salt
22:27 coval3nce there a way to get a list of applicable states on the minion?
22:27 coval3nce Could maybe do it that way
22:30 bhosmer joined #salt
22:38 ajw0100 joined #salt
22:41 RandyT it seems that this module may be failing to load at the import salt.utils.slack
22:41 otter768 joined #salt
22:41 RandyT where should it be getting this? installation of python slack module has not solved this.
22:41 jimklo_ joined #salt
22:46 zenlot joined #salt
22:47 RandyT appears I grabbed a development version of the current returner...
22:48 jfindlay coval3nce: you want to know all of the state modules that were loaded?  There is `__states__`, but I'm not sure of all the contexts in which it's available
22:49 coval3nce @jfindlay thx man
22:50 jfindlay sure
22:50 frew if anyone is interested: https://blog.afoolishmanifesto.com/posts/checking-sudoers-with-visudo-in-saltstack/
22:51 jfindlay frew: is that your blog?
22:51 frew jfindlay: yes
22:51 jfindlay cool
22:53 frew jfindlay: would you be interested in that as an example for the docs?  I sorta think that each directive should have at least one example, as it makes it a lot more clear how to use it
22:53 ageorgop joined #salt
22:53 frew I can make a PR or you could just use the example
22:53 jfindlay frew: I think that would be a totally awesome example to have
22:54 jfindlay could you send in a PR to 2015.8?
22:54 frew yeah, on it
22:54 jfindlay awesome, thanks!
22:58 jimklo joined #salt
23:02 MarkusDBX joined #salt
23:05 mapu joined #salt
23:06 frew jfindlay: https://github.com/saltstack/salt/pull/30406
23:06 saltstackbot [#30406]title: Add an example of how to use file.managed/check_cmd |
23:06 sfxandy joined #salt
23:07 jfindlay nice
23:08 frew happy to help
23:09 RandyT https://gist.github.com/rterbush/05e40fd59807e3af2361
23:09 RandyT that is the returner I am trying to modify to include an event_return for slack
23:09 RandyT loads from command line with python; import
23:10 RandyT but logs to master "Returner 'localslack' not found'
23:11 RandyT The returner is virtually unchanged other than added the error_return()
23:11 RandyT and renaming a few necessary items to 'localslack'
23:12 jfindlay RandyT: did you set the `extension_modules` master config to a path under which returners/localslack.py can be found?
23:13 RandyT @jfindlay: yes, and a sync_all shows that the returner is loaded
23:13 jfindlay master side external plugin modules use a different mechanism from minion side plugins
23:13 jfindlay that is strange
23:13 RandyT uh...
23:14 flowstate joined #salt
23:14 RandyT following directions that I see here: https://docs.saltstack.com/en/latest/ref/returners/index.html#custom-returners
23:14 RandyT is this different?
23:17 hasues joined #salt
23:17 hasues left #salt
23:18 jfindlay yes, if you want a master returner, you need to put in `extension_modules`.  I've been meaning to revise that doc for a long time.  Also returners can be used for multiple things and the distinctions aren't clear enough in the docs
23:19 RandyT ok, giving that a spin
23:21 RandyT already seeing a more positive error regarding config
23:23 colegatron joined #salt
23:23 jfindlay nice
23:24 GnuLxUsr joined #salt
23:24 netcho_ joined #salt
23:26 rem5 joined #salt
23:31 snicers-work joined #salt
23:32 snicers-work Hello all. I have a docker container with volumes for minion specific tracking set up. The problem is when I destroy and recreate a container salt gets reinstalled and seems to remove state specific files about my minion. Is there a way to prevent this?
23:35 brianfeister joined #salt
23:39 pdx6_ left #salt
23:40 RandyT @jfindlay: should I expect to be able to configure this returner in pillars?
23:40 jfindlay RandyT: I'm not sure.  I assume so
23:40 RandyT based on comments at the top of the file, the slack:\r\n username: foo is not working
23:41 RandyT I can see it in the pillar for every minion, yet it is not being picked up...
23:41 jfindlay you should also be able to use the master config, I think
23:42 RandyT ok, will try it in there..
23:43 lompik joined #salt
23:45 baweaver joined #salt
23:51 yamamushi joined #salt

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