Perl 6 - the future is here, just unevenly distributed

IRC log for #salt, 2017-07-06

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

All times shown according to UTC.

Time Nick Message
00:02 hoonetorg joined #salt
00:19 mpanetta joined #salt
00:26 druonysus joined #salt
00:37 noraatepernos joined #salt
01:02 onlyanegg joined #salt
01:19 ssplatt joined #salt
01:22 noobiedubie joined #salt
01:24 noraatepernos Is it possible to run these commands on ubuntu *before* packages are installed with cloud-init?  https://repo.saltstack.com/#ubuntu  I’m having trouble figuring out how to get the *latest* salt-minion during my cloud-init boot.
01:25 noraatepernos Maybe this is a better question for #aws or something but I can’t seem to figure out the order of packages vs runcmd.
01:25 nicksloan joined #salt
01:28 aneeshusa joined #salt
01:28 hemebond noraatepernos: This helpful? https://gist.github.com/hemebond/4b48df43721adb283e0df404501a4b59#file-cloud-init-yaml
01:28 noraatepernos hemebond: Very, very, very helpful thank you!!!
01:30 deuscapturus joined #salt
01:33 davedash joined #salt
01:34 davedash https://www.irccloud.com/pastebin/HViFdKiF/
01:35 davedash The SLS looks like so: https://www.irccloud.com/pastebin/RxZCzcf5/
01:37 alexlist joined #salt
01:47 davedash Running into an issue with rbenv
01:48 ilbot3 joined #salt
01:48 Topic for #salt is now Welcome to #salt! <+> Latest Versions: 2016.3.6, 2016.11.6 <+> Support: https://www.saltstack.com/support/ <+> Logs: http://irclog.perlgeek.de/salt/ <+> Paste: https://gist.github.com/ <+> See also: #salt-devel, #salt-offtopic <+> We are volunteers and may not have immediate answers <+> The call for speakers for SaltConf17 is now open: http://tinyurl.com/SaltConf17
01:58 auzty joined #salt
02:02 gnomethrower joined #salt
02:03 gnomethrower joined #salt
02:03 gnomethrower joined #salt
02:06 nicksloan joined #salt
02:14 onlyanegg joined #salt
02:16 neilf__ joined #salt
02:44 Bock joined #salt
02:54 Praematura joined #salt
03:08 evle joined #salt
03:17 donmichelangelo joined #salt
03:21 Praematura joined #salt
03:21 renoirb joined #salt
03:39 aneeshusa joined #salt
03:48 onlyanegg joined #salt
04:03 tellendil joined #salt
04:09 qman__ joined #salt
04:14 icebal joined #salt
04:16 tellendil joined #salt
04:22 icebal joined #salt
04:23 tellendil joined #salt
04:40 icebal joined #salt
04:45 icebal joined #salt
05:05 nethershaw joined #salt
05:08 gmoro joined #salt
05:09 pocketprotector- joined #salt
05:10 phobosd_ joined #salt
05:10 doglike joined #salt
05:10 doglike joined #salt
05:11 fujexo[m]1 joined #salt
05:11 tedski_ joined #salt
05:12 ahrs_ joined #salt
05:13 aerbax_ joined #salt
05:13 ventris joined #salt
05:13 chowmein__ joined #salt
05:14 mquin_ joined #salt
05:14 ConnorCG_ joined #salt
05:14 TheBigRedButton joined #salt
05:14 ujjain- joined #salt
05:15 chowmein__ left #salt
05:15 gareth_ joined #salt
05:17 tom29739_ joined #salt
05:18 sjohnsen_ joined #salt
05:19 the_lale1u joined #salt
05:19 m0nky_ joined #salt
05:19 mschiff_ joined #salt
05:20 andi^ joined #salt
05:22 ZombieTwiglet joined #salt
05:22 Valfor joined #salt
05:22 Savemech_ joined #salt
05:26 flowstategames joined #salt
05:27 gtmanfred joined #salt
05:27 ksa joined #salt
05:28 nledez joined #salt
05:28 c06 joined #salt
05:28 J0hnSteel joined #salt
05:29 c06 hi all
05:29 tom29739 joined #salt
05:29 c06 i configured my salt with reclass using reclass-salt --pillar node i am able to see the pillar data
05:30 c06 is there anyother way to verify the data from pillar side. i.e., salt node pillar.items
05:37 flowstategames joined #salt
05:39 c06 i got the answer..:)
05:44 mauli joined #salt
05:45 daemonkeeper joined #salt
05:57 nismo joined #salt
06:00 nismo meow
06:01 guerby joined #salt
06:01 guerby joined #salt
06:02 nismo Hi all, I'm trying to install a package but when installing the package manually (ubuntu 16.04) a purple screen appears asking for configuration. How can I pass that argument along with SALT?
06:03 cswang joined #salt
06:03 baffle joined #salt
06:04 nismo joined #salt
06:05 nismo halp
06:06 Morrolan joined #salt
06:06 guerby joined #salt
06:07 FreeSpencer joined #salt
06:07 FreeSpencer joined #salt
06:11 felskrone joined #salt
06:14 do3meli joined #salt
06:16 do3meli left #salt
06:16 fracklen joined #salt
06:21 scooby2 joined #salt
06:22 lionel joined #salt
06:22 kiorky joined #salt
06:26 t0m0 joined #salt
06:27 shakalaka joined #salt
06:32 hemebond nismo: Ubuntu? You can pre-configure packages.
06:33 hemebond It's debconf. You can see it being used in https://github.com/saltstack-formulas/mysql-formula/blob/master/mysql/server.sls
06:40 nismo That's perfect, thank you
06:43 preludedrew joined #salt
07:02 JohnnyRun joined #salt
07:06 aldevar joined #salt
07:07 daxroc joined #salt
07:16 lorengordon joined #salt
07:17 onovy joined #salt
07:18 notCalle joined #salt
07:18 palsveningson_ joined #salt
07:20 palsveningson_ ji
07:20 palsveningson_ hi
07:23 Praematura joined #salt
07:26 Ricardo1000 joined #salt
07:43 jhauser joined #salt
07:45 onlyanegg joined #salt
07:51 Ricardo1000 joined #salt
07:55 Rumbles joined #salt
08:02 coredumb in jinja should I do: grains['host'].upper() or grains['host']|upper() ?
08:03 armguy joined #salt
08:03 _KaszpiR_ joined #salt
08:04 pbandark joined #salt
08:06 mikecmpbll joined #salt
08:12 shengis joined #salt
08:17 voidspace_ joined #salt
08:19 lorengordon joined #salt
08:21 darioleidi joined #salt
08:24 Naresh joined #salt
08:27 coredumb ok .upper() seems like it :)
08:28 OliverUK1 joined #salt
08:32 Electron^- joined #salt
08:37 ronnix joined #salt
08:37 Dev0n joined #salt
08:41 ccha hello, when will nitrogen be released ?
08:44 hemebond ccha: Probably in about a month.
08:45 Mattch joined #salt
08:50 ccha ok thank hemebond
08:53 hemebond It's just a guess though.
08:53 hemebond Based on the fact that there is a release candidate out now.
08:53 hemebond But I don't know of any date given for a full release.
08:54 ccha hemebond: how do you follow the rc ?
08:55 hemebond The salt-announce Google group/mailing list.
08:56 ccha oh ok, I susbscribe only on salt-users
09:00 ccha Thanks, now I join on this list too
09:04 evle joined #salt
09:06 rpb joined #salt
09:28 pbandark hi..  is there any way to confirm if salt execution/state function is present for any specific application? for ex. I would like to confirm if there is any existing salt execution/state function for "activemq".
09:29 Tucky joined #salt
09:40 sillywilly joined #salt
09:44 sillywilly left #salt
09:44 sillywilly joined #salt
09:45 onlyanegg joined #salt
09:46 voidspacexyz_ joined #salt
09:46 sillywilly joined #salt
09:46 sillywilly Does anyone have any experience with windows services and salt?
09:47 sillywilly Getting this bastard of an error: "the service did not return an error. This could be an internal windows error or an internal service error"
09:49 voidspac1 joined #salt
09:50 fannet hi everyone - with an external http pillar endpoint (https://docs.saltstack.com/en/latest/ref/pillar/all/salt.pillar.http_yaml.html#module-salt.pillar.http_yaml) How can I ensure that the pillars exposed by this endpoint target only specific hosts (in normal top.sls fashion)
09:57 voidspacexyz joined #salt
09:57 voidspacexyz https://github.com/saltstack/salt/issues/23130
09:57 voidspacexyz Can someone help with the last comment in this issue
09:58 xet7 joined #salt
10:02 coredumb fannet: when looking at the code that doesn't seem to be possible
10:02 coredumb althought it has been fix in develop
10:02 coredumb https://docs.saltstack.com/en/develop/ref/pillar/all/salt.pillar.http_yaml.html#configuring-the-http-yaml-ext-pillar
10:02 coredumb you should then be able to activate grains and use <id> at the end of your URL
10:04 palsveningson_ Could someone help me please. I am trying to run salt formula, but when I try to state.apply salt.minion I get this traceback
10:04 palsveningson_ https://gist.github.com/anonymous/5d5e7b42d18ab2a8f4b61625f21d9ddf
10:09 kamsz joined #salt
10:10 kamsz_ joined #salt
10:16 absolutejam joined #salt
10:18 babilen How can I access environment variables from salt-ssh roster files? (or how could I have a configurable username in there)
10:18 babilen Would like to share config with people who want to use their own username (or actually: .ssh/config)
10:21 voidspacexyz babilen: you could set them in grains
10:22 voidspacexyz I dont think, salt-ssh , we can access env variables, atleast from what I have read
10:23 mikecmpb_ joined #salt
10:25 babilen voidspacexyz: Where and how?
10:26 babilen No, salt.environ.get is not working in rosters
10:26 babilen I always wonder why it needs the username in the first place as I have a perfectly fine ~/.ssh/config
10:27 babilen (with multi-hop setups, usernames, ...)
10:27 voidspacexyz babilen: All you want is to pass is a custom username to your salt-ssh commands right ?
10:27 manji babilen, isn't --user=SSH_USER
10:27 manji you could maybe add an alias
10:28 manji alias salt-ssh='salt-ssh  --user=$USER'
10:28 manji do you think this will work for you ?
10:28 manji and  --sudo
10:29 babilen That would work, I guess .. but it also means that it's impossible to define different usernames for different hosts (as per ~/.ssh/config)
10:29 voidspacexyz no you can
10:29 babilen Not sure people will be too happy with it, but it solves the immediate problem
10:29 voidspacexyz your roster file has a user configuration
10:29 voidspacexyz https://docs.saltstack.com/en/latest/topics/ssh/roster.html#how-rosters-work
10:30 babilen My background is that I'd like to share roster/salt-ssh setups between users who all have their own ~/.ssh/config and, in particular, usernames
10:30 manji babilen, you could use a custom bash script to run on .profile
10:30 babilen I therefore can't hardcode usernames in the roster as they differ and some boxes need different usernames (which is all configured in ~/.ssh/config)
10:30 manji parse the user's .ssh/confg
10:31 manji and pull whatever data you need from there
10:31 manji I am not sure how, but I'd investigate this option
10:32 fracklen joined #salt
10:32 manji actually, I'd add a feature request
10:32 manji your case is kind of common
10:32 manji although, if you have ssh_wipe=False
10:33 manji the perms in the salt-thin directory will become a huge mess
10:33 rahav joined #salt
10:33 manji (they already are either way when using sudo)
10:34 babilen We're primarily using "proper" master/minions for most boxes, but I just want to enable some colleagues to run things easily. The first thing they'll ask is "My SSH works exactly as it should .. why doesn't salt-ssh use that?"
10:35 pbandark1 joined #salt
10:36 voidspacexyz https://github.com/saltstack/salt/issues/23130
10:36 voidspacexyz Also need some help with the last comment in this issue
10:37 Tucky hello, when I run this command on master sudo "salt-call --local pkg.available_version nginx" I get "'pkg.available_version' is not available." What's wrong?
10:38 babilen manji: Which thin directory do you mean?
10:38 babilen On the minion?
10:38 manji yes
10:38 babilen And that is problematic if different users use salt-ssh?
10:39 manji it can be, the permissions used to be very messy
10:39 manji so files belonging to root, other to the ssh-user
10:39 manji the parent dir will have 700 perms
10:39 babilen The basic takeway is: Don't use salt-ssh :)
10:40 manji I wish I could :/
10:40 Praematura joined #salt
10:40 manji it took me a while to live with its issues
10:40 manji or go around them
10:40 manji let us know either way :p
10:42 babilen I might just use Ansible for these cases
10:42 manji the thing is that a) one has to learn yet another config management/orchistration
10:42 babilen But one idea was to get people to know salt without configuring a minion/master architecture right away
10:43 babilen And if salt-ssh is the first thing they see they'll assume it's horrible :)
10:43 manji ofc it is
10:43 manji I was using it master-client, ti was obiously more human
10:43 babilen So I wanted to give them something to run execution modules, but the fact that it doesn't work with ~/.ssh/config is embarrassing
10:44 manji in my case, I hope that I will ise salt-syndic or multimaster in the future
10:44 babilen I have that in other setups .. but some people are old school and I want them to start liking these "fancy new tools"
10:44 manji fiddle with the code a bit when I switch, and see how it goes
10:44 babilen aye
10:45 manji that is the only reason I switched to salt-ssh and not ansible
10:45 babilen That you can fiddle with the code more easily with salt?
10:46 manji I can fiddle with it so to become master-client
10:46 manji eg I am not using mine
10:46 manji to pull info about other minions, it was too buggy
10:46 manji so I parse the roster file as a yml file
10:46 manji put stuff in a pillar
10:47 manji an pull data from there
10:48 manji I am not proud, but it works :p
10:50 babilen right
10:50 babilen :)
10:52 dstensnes anyone remember the issue number for the case where removed packages cannot be purged?
10:53 dstensnes ah, found it
10:55 CrummyGummy joined #salt
10:58 rahav joined #salt
10:59 rahav_ joined #salt
11:02 voidspacexyz1 joined #salt
11:05 patrek joined #salt
11:10 gareth_ joined #salt
11:14 palsveningson_ Anyone here to help`
11:14 palsveningson_ ?
11:14 coredumb palsveningson_: just ask
11:14 palsveningson_ I am trying to run salt formula, but when I try to state.apply salt.minion I get this traceback
11:14 palsveningson_ https://gist.github.com/anonymous/5d5e7b42d18ab2a8f4b61625f21d9ddf
11:15 palsveningson_ dunno what I do wrong
11:18 voidspacexyz1 joined #salt
11:39 donmichelangelo joined #salt
11:40 Tucky In fact, the pkg module is missing on my master (sys.list_modules pkg returns nothing) how can I fix this?
11:46 onlyanegg joined #salt
11:49 babilen manji: https://github.com/saltstack/salt/commit/16f21e57b295b558bac587da53a3942e4cf9888e
11:50 manji ah lovely
11:50 manji so it will be in the next release?
11:50 babilen Yeah :)
11:50 babilen I had to dig deep
11:50 manji hehe
11:51 ws2k3 joined #salt
11:51 ws2k3 joined #salt
11:52 ws2k3 joined #salt
11:52 ws2k3 joined #salt
11:53 ws2k3 joined #salt
11:53 ws2k3 joined #salt
11:59 cyteen joined #salt
12:02 justan0theruser joined #salt
12:12 gmoro joined #salt
12:12 c06 is there any value set new (keys,values) or modify the existing value in pillar
12:12 pbandark Hi.. all
12:12 pbandark even after installing required python module(pymongo) for mongodb on minion, state execution is failing with "'mongodb_user' __virtual__ returned False"
12:12 pbandark https://paste.fedoraproject.org/paste/YCCVmnUo6NvG~MvS9ynw7g
12:13 ecdhe joined #salt
12:14 dstensnes pbandark: does it work if you use pymongo from the distribution, and not via pip?
12:14 pbandark yes
12:15 dstensnes is using that not an option?
12:15 pbandark dstensnes: with distribution I can see older version of pymongo
12:15 pbandark hence, I am going with pip
12:16 dstensnes so, maybe salt doesn't find the one you installed with pip?
12:17 pbandark yeah. it seems to be . but I am not getting why
12:17 pbandark i can see mongo* state python code present on the minion
12:18 dstensnes https://stackoverflow.com/questions/135035/python-library-path
12:18 dstensnes maybe you can add something with the PYTHONPATH before starting salt or something?
12:19 dstensnes i guess you can try printing sys.path somewhere, and see if it covers where pip installed pymongo
12:19 dstensnes sys.path being the variable in python. No idea how to print it from the salt environment though
12:22 pbandark dstensnes: after failed attempt, if I reexecute the same state file, its successful.
12:22 pbandark i am wondering whats happening
12:23 benbro1 joined #salt
12:24 dstensnes ah, that's weird...
12:24 dstensnes i don't know then
12:24 bencc1 joined #salt
12:24 dstensnes try running the salt minion from the shell
12:24 dstensnes /usr/bin/salt-minion -l debug
12:24 bencc1 left #salt
12:24 pbandark ok
12:24 dstensnes remember to stop it first
12:24 dstensnes you don't want two running at the same time
12:25 pbandark yup
12:26 dstensnes i managed to do that once, and it was very confusing, i tell you
12:37 pbandark dstensnes: same error: "[DEBUG   ] Could not LazyLoad mongodb_user.present: 'mongodb_user' __virtual__ returned False"
12:37 pbandark i dont see useful info :(
12:39 benbro joined #salt
12:39 benbro can I run the master from my laptop?
12:40 benbro or does it need to have a public address?
12:40 dstensnes benbro: you can probably manage to do that too, but you might have to forward some ports if some of the minions are outside your network
12:41 benbro dstensnes: I'm currently using masterless puppet. I'm uploading the manifests with fabric and execute locally
12:41 benbro I'm trying to see if salt is easier to use
12:42 benbro but couldn't find my way through the docs
12:42 Praematura joined #salt
12:42 benbro salt masterless doesn't seem to give me advantage over puppet masterless
12:42 dstensnes okay
12:43 dstensnes you can also look into salt-ssh
12:43 benbro I'll read about salt-ssh. thanks
12:44 dstensnes but part of what makes saltstack great it is the event bus though
12:44 benbro I only have few servers
12:44 dstensnes but it all really depends on you use cases
12:44 benbro using a master feels like a waste and complication
12:45 benbro if I could install the master on my laptop and push states from it it could be great
12:45 dstensnes i guess you can, but you might have to forward some ports in your router for the minions to reach the master
12:45 dstensnes or use salt-ssh
12:46 dstensnes but yeah, check out salt-ssh and see if that fits your needs better
12:46 benbro forwarding ports is not an option for me
12:47 benbro I'll check if salt-ssh can replace fabric+puppet masterless
12:47 dstensnes i have configured an openvpn to our external servers
12:47 dstensnes that works great for us
12:47 onlyanegg joined #salt
12:48 benbro thanks
12:48 dstensnes np
12:48 dstensnes hope you find what you're looking for
12:50 brianthelion left #salt
12:50 brianthelion joined #salt
12:52 brianthelion left #salt
12:52 noobiedubie joined #salt
12:52 fracklen joined #salt
12:53 ronnix joined #salt
12:54 nicksloan joined #salt
12:55 hemebond left #salt
12:55 c06 how we can add space at multiline statement but need to add infornt
12:55 c06 content: |
12:56 dstensnes not sure i understand your question
12:57 c06 file.line: i am trying to insert multiline content with leading 4 spaces
12:58 dstensnes aha
12:59 dstensnes you can also formulate lines as a list with quotes
12:59 dstensnes if that helps
12:59 c06 ok letme check that one ty
13:00 dstensnes at least with file.managed, if that's what you are using
13:01 brianthelion joined #salt
13:01 dstensnes file.managed with "contents:"
13:01 cgiroua joined #salt
13:01 c06 i am using file.line option in existing file have to add contents with space
13:02 davedash Running into an issue with rbenv. https://www.irccloud.com/pastebin/HViFdKiF The SLS looks like so: https://www.irccloud.com/pastebin/RxZCzcf5/
13:02 impi joined #salt
13:03 c06 dstensnes:  they are called .strip() function while adding lines so its removing spaces.
13:03 c06 ** they called
13:04 dstensnes c06: okay, then i don't know
13:05 c06 are you from salt team or user .?
13:05 dstensnes just a normal user
13:05 c06 nice dude.. ty for suggestions.. :)
13:05 dstensnes i hang here because I sometimes have a question of my own
13:06 nicksloan joined #salt
13:06 dstensnes and i figured i could answer some questions too, to make up for it :P
13:06 c06 last week only i started salt.. :-p
13:06 c06 yes you are doing good
13:06 dstensnes i see
13:06 dstensnes thanks :)
13:06 thinkt4nk joined #salt
13:06 c06 u welcome
13:07 dstensnes c06: are you adding a single line?
13:07 dstensnes maybe blockreplace could be a better match? Or simply regenerating the whole file from scratch from a template with file.managed?
13:07 dstensnes just throwing out the ideas here
13:07 c06 dstensnes: multi line(8 lines) i need to insert
13:08 dstensnes then i would consider using blockreplace instead maybe
13:09 shengis @c06 you could use the indent filter of jinja : {{ "text" | indent(4) }}
13:09 dstensnes ah, maybe a good idea if that works
13:10 c06 shengis: dstensnes ty and i will try the same
13:10 dstensnes np :)
13:10 fracklen joined #salt
13:10 dstensnes but yeah, file.blockreplace with a "source:" thingy could maybe work better
13:11 dstensnes or whatever shengis said
13:12 c06 dstensnes: ok i will try both dude
13:12 c06 dstensnes: have to go getting late
13:12 dstensnes i could at least give you some pointers :)
13:12 dstensnes c06: good luck :)
13:12 c06 dstensnes: ty.. :) tomorrow i will ping if works means.. :)
13:12 dstensnes okay :)
13:12 c06 have a great day all :)
13:12 dstensnes you too
13:12 c06 :)ty
13:18 fracklen joined #salt
13:36 c4rl3x joined #salt
13:36 brianthelion Ugh, freenode password fail
13:36 brianthelion n00b question here, but are includes and imports idempotent like they are in python? I am seeing this fail: https://gist.github.com/brianthelion/8d32238230d98d612535a10e551b313d
13:37 brianthelion the problem is that tmpdir gets set once for state_a and then again for state_b
13:38 brianthelion which would seem to suggest that either include or import is NOT idempotent
13:39 benbro1 joined #salt
13:58 ronnix joined #salt
14:00 PerilousApricot joined #salt
14:00 ssplatt joined #salt
14:09 cpc_ joined #salt
14:13 PatrolDoom joined #salt
14:14 losh joined #salt
14:19 c4rl3x joined #salt
14:20 ws2k3 joined #salt
14:21 evle1 joined #salt
14:23 racooper joined #salt
14:23 andrew_ joined #salt
14:25 deuscapturus joined #salt
14:27 nicksloan joined #salt
14:27 Inveracity joined #salt
14:29 Jroovec joined #salt
14:34 varun joined #salt
14:39 benbro joined #salt
14:42 tapoxi is there an easy way to create a lot of directories?
14:47 Brew joined #salt
14:48 lordcirth_work tapoxi, probably; in what pattern?
14:51 c4rl3x joined #salt
14:54 tapoxi lordcirth_work: a bunch of subdirectories (30) under a main one
14:55 lordcirth_work tapoxi, are they arbitrary string names or like 1 through 30?
14:55 tapoxi string names
14:55 lordcirth_work tapoxi, make a pillar list of the names
14:55 tapoxi I'm thinking I might be able to jinja it
14:55 lordcirth_work Then make a jinja for loop of a file.directory state
14:55 tapoxi can I do that without pillar?
14:56 tapoxi setting the list within the jinja template?
14:57 ksk tapoxi: iirc there is some way to recursivly transfer files that are in one dir? I would assume you can do the same with dirs
14:58 ksk tapoxi: eg https://gist.github.com/chilicat/6916304
15:07 onlyanegg joined #salt
15:07 deuscapturus joined #salt
15:11 ssplatt joined #salt
15:18 sarcasticadmin joined #salt
15:20 ivanjaros joined #salt
15:20 cpc_ joined #salt
15:22 colegatron joined #salt
15:24 raspado joined #salt
15:30 noobiedubie joined #salt
15:31 astronouth7303 ... a lot of people would really like this pepper wrapper i'm working on, i think
15:33 ronnix joined #salt
15:40 woodtablet joined #salt
15:40 benbro1 joined #salt
15:47 _Steve_ joined #salt
15:51 alan_ joined #salt
15:51 sp0097 joined #salt
15:52 lorengordon joined #salt
15:53 ws2k3 joined #salt
15:54 raspado joined #salt
15:54 ws2k3 joined #salt
15:55 ws2k3 joined #salt
15:55 ws2k3 joined #salt
15:56 ws2k3 joined #salt
15:56 ws2k3 joined #salt
15:58 lorengordon joined #salt
15:58 cyborg-one joined #salt
16:01 tiwula joined #salt
16:03 aldevar left #salt
16:03 major joined #salt
16:03 lorengordon joined #salt
16:06 c4rl3x joined #salt
16:07 preludedrew joined #salt
16:10 _Steve_ joined #salt
16:10 _Steve_ joined #salt
16:10 kay joined #salt
16:13 _Steve_ joined #salt
16:13 _Steve_ joined #salt
16:16 _Steve_ joined #salt
16:18 Trauma joined #salt
16:23 astronouth7303 speculation: Is it difficult to use the authenticated master/minion relationship to bootstrap another protocol? I'm thinking about a better logging system, and being able to utilize that would be nice.
16:27 _Steve_ joined #salt
16:27 _Steve_ joined #salt
16:29 c4rl3x joined #salt
16:30 astronouth7303 actual question: minions.connected() and manage.joined() show an extra minion not visible in manage.status() and key.list_all(). I destroyed the instance (with salt cloud). Why is it lingering?
16:31 _JZ_ joined #salt
16:35 socket-_ Can anyone help me understand why this state is failing to run. I'm getting errors about unacceptable character #x0007.  https://apaste.info/Vd0L
16:35 Praematura joined #salt
16:36 socket-_ I'm basicaly trying to archive a file, but make sure 7zip is installed and in the path before
16:36 ChubYann joined #salt
16:38 Lionel_Debroux_ joined #salt
16:38 ConnorCG joined #salt
16:40 benbro joined #salt
16:41 astronouth7303 `\7` in a string
16:42 astronouth7303 i think if you use forward slashes, it'll be happier
16:42 astronouth7303 (yes, i see it's windows. I'm 90% sure that it'll take forward slashes just as happily)
16:46 nicksloan joined #salt
16:49 wendall911 joined #salt
16:51 impi joined #salt
16:51 dstensnes socket-_: on a side note, that path probably doesn't work on windows
16:56 ws2k3 joined #salt
16:56 snarked joined #salt
17:01 c4rl3x joined #salt
17:03 justanotheruser joined #salt
17:05 cpc_ joined #salt
17:06 justanotheruser joined #salt
17:07 fritz09 joined #salt
17:07 deuscapturus joined #salt
17:11 swills joined #salt
17:11 swills joined #salt
17:12 swills joined #salt
17:12 swills joined #salt
17:15 SaucyElf joined #salt
17:23 SaucyElf_ joined #salt
17:23 c4rl3x joined #salt
17:24 cyborg-one joined #salt
17:26 felskrone joined #salt
17:29 nicksloan joined #salt
17:36 Deliant joined #salt
17:40 benbro1 joined #salt
17:41 astronouth7303 and now my minion isn't pulling in the updated saltfs file?
17:41 astronouth7303 i made a new tarball in my file_roots directory, but the minion keeps using the old one
17:41 astronouth7303 i'm not finding a salt command that causes it to pull the new one
17:43 noraatepernos joined #salt
17:44 scelestic i'm trying to figure out if or how i can pass connection_args to salt['mysql.query'] in a function, if i do salt['mysql.query']('database', 'query', 'connection_args'] it'll tell me too many args but as a shell command i'm able to just pass connection_user, connection_pass etc without a problem
17:46 astronouth7303 pass them as keyword arguments
17:46 astronouth7303 https://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.mysql.html#salt.modules.mysql.query
17:47 astronouth7303 the resident wolf (not tagging him) must be busy today :P
17:49 scelestic astronouth7303: would you have an example how to use keyword arguments? I think i've tried that but i might have done it wrong
17:49 astronouth7303 foobar(spam='eggs')
17:50 astronouth7303 unless jinja disallows them...
17:50 pbandark1 joined #salt
17:52 scelestic i cannot imagine jinja disallowing them, i might just not understand the syntax
17:53 Lionel_Debroux_ joined #salt
17:53 scelestic for example i try a file.managed with - contents: {{ salt.mysql.query('database', 'select * from something') }} but i cannot pass the connection_args anyway, if i add them after the query i get the error i'm passing too many arguments
17:55 Deliant joined #salt
17:56 censorshipwreck joined #salt
18:09 Phil joined #salt
18:10 noraatepernos joined #salt
18:12 astronouth7303 salt.mysql.query('foo', 'bar', arg=value, ...)
18:13 astronouth7303 each of the connection args broken out
18:14 scelestic thanks i'll give that a shot
18:21 druonysuse joined #salt
18:21 druonysuse joined #salt
18:22 astronouth7303 oh, figured out my fs caching issue
18:22 astronouth7303 salt:// does not count as a local filesystem, and doesn't seem to have the ability to get hashes of files
18:25 Inveracity joined #salt
18:34 PerilousApricot joined #salt
18:35 PerilousApricot joined #salt
18:36 Slimmons joined #salt
18:37 watersoul joined #salt
18:38 Praematura joined #salt
18:38 sjorge joined #salt
18:40 benbro joined #salt
18:42 watersoul joined #salt
18:43 beardedeagle joined #salt
18:47 watersoul joined #salt
18:48 wlfyit joined #salt
18:49 thinkt4n_ joined #salt
18:49 wlfyit joined #salt
18:50 nicksloan joined #salt
18:51 ChubYann joined #salt
18:52 watersoul joined #salt
18:53 sjorge joined #salt
18:57 watersoul joined #salt
19:06 aldevar joined #salt
19:09 PerilousApricot joined #salt
19:09 Edgan astronouth7303: salt:// is the fileserver from the salt master
19:09 astronouth7303 yes, i'm aware
19:10 astronouth7303 i was told previously that archive.extracted will automatically detect changes in archives in salt://. turns out, this isn't the case.
19:11 censorshipwreck joined #salt
19:13 fannet joined #salt
19:20 coredumb astronouth7303: you mean it's not extracting it again after changing it in salt:// ?
19:21 nixjdm joined #salt
19:32 oida_ joined #salt
19:32 astronouth7303 Yeah
19:33 astronouth7303 I change the file on the master (though conventional means), but the minion never pulls the new copy.
19:33 astronouth7303 *version
19:38 swills joined #salt
19:38 swills joined #salt
19:39 swills joined #salt
19:41 astronouth7303 (i looked at the source to figure that out)
19:41 benbro1 joined #salt
19:43 aarontc joined #salt
19:43 swills joined #salt
19:44 sjorge joined #salt
19:44 noraatepernos joined #salt
19:47 Slimmons I'm having some issues escaping characters inside of pillar data.  For example,  salt '*' state.sls deleteFile pillar='{fileToDelete: C:\testFile.txt}'
19:47 Slimmons I expected to be able to escape by using C:\\testFile.txt
19:48 Slimmons But, I get a "Pillar data must be formatted as a dictionary
19:48 Slimmons or, it renders the sls with the single \ as a tab
19:48 Slimmons which was odd
19:48 Slimmons (I think)
19:50 astronouth7303 is it expecting the argument to be JSON? That's not valid json
19:50 astronouth7303 it might be parsing as yaml...
19:50 Slimmons bah, I see the problem.  I was escaping correctly, but with the escapes I need to put it in quotes
19:50 Slimmons without escapes, no quotes (or not required at least)
19:50 aarontc joined #salt
19:51 astronouth7303 sounds like yaml
19:51 astronouth7303 hmmm... can I pass arguments to orchestrate?
19:51 Slimmons yep, it was yaml, I should have specified
19:52 Slimmons would have been easier to answer if you knew the format :)
19:52 astronouth7303 knowing the format, it becomes a simple question of "is this valid yaml" and "did I do my bash escaping correctly?"
19:54 onlyanegg joined #salt
19:57 ws2k3 joined #salt
19:57 ws2k3 joined #salt
19:58 ws2k3 joined #salt
19:58 nicksloan joined #salt
19:58 ws2k3 joined #salt
19:59 ws2k3 joined #salt
19:59 ws2k3 joined #salt
20:03 PatrolDoom joined #salt
20:06 aldevar left #salt
20:14 aarontc joined #salt
20:17 aarontc joined #salt
20:20 PatrolDoom joined #salt
20:21 aarontc joined #salt
20:25 _KaszpiR_ joined #salt
20:25 aarontc joined #salt
20:29 aarontc joined #salt
20:31 astronouth7303 can I pass arguments to orchestrate? Or is there a better way to have a parameterized series of salt commands?
20:32 astronouth7303 i need to give my CI the ability to run some salt when it deploys things, but i don't want to give it everything. It seems like giving it access to orchestration is a good middle ground.
20:32 noraatepernos joined #salt
20:35 shanth joined #salt
20:35 shanth did my last message send?
20:37 aarontc joined #salt
20:37 nixjdm joined #salt
20:38 astronouth7303 shanth: no?
20:39 shanth if i do grains.get for ipv4 i get a list back http://dpaste.com/3XC1VVN - how can i make it return only the ip that starts with 127?
20:40 shanth the order in the list is not guaranteed
20:40 shanth it wont always be first, second last, etc
20:40 benbro joined #salt
20:40 astronouth7303 shanth: will it ever not be 127.0.0.1?
20:41 aarontc joined #salt
20:45 shanth yes it will be different astronouth7303
20:45 shanth freebsd jails have cloned loopbacks with different 127 ip's
20:46 astronouth7303 ahh
20:46 coredumb shanth: I guess from jinja you could use .startwith()
20:46 shanth what would that look like coredumb?
20:47 coredumb startswith()
20:48 sjorge joined #salt
20:49 coredumb shanth: I'm not sure but I guess I'd try something like that https://pastebin.com/rG5vYWFP
20:49 shanth awesome let me try that coredumb thanks
20:50 coredumb then you can reuse {{ ip }} in the rest of the state
20:50 astronouth7303 ... i really really want to strangle archive.extracted.
20:51 astronouth7303 I handed it a sha1 file (in saltfs), it pulled the new sha1 file, and decided it still didn't need to get a a new archive.
20:53 aarontc joined #salt
20:54 nicksloan joined #salt
20:55 shanth it works coredumb http://dpaste.com/3JC0TC3
20:55 shanth just saved me hours worth of work :D
20:56 coredumb \o/
20:56 shanth was going to make a bunch of pillar data
20:56 shanth how does one start learning actual jinja? that was super useful but it all seems so foreign
20:57 coredumb I guess there is the most useful link http://jinja.pocoo.org/
20:57 fannet joined #salt
20:57 shanth the startswith() thing is a function? or something else?
20:57 coredumb then https://docs.saltstack.com/en/latest/topics/jinja/index.html
20:58 coredumb then read a bunch of already made states/formulas :D
20:58 shanth nice thanks
20:59 shanth wonder why i cant find starts with on the site - https://www.google.com/search?q=site%3Ahttp%3A%2F%2Fjinja.pocoo.org+"startswith"
21:00 shanth or is it a python thing?
21:00 absolutejam you can use 'in' iirc
21:00 coredumb it is
21:00 shanth ahhh
21:00 coredumb yeah there's also if xxx in yyyy
21:01 coredumb whatever suits your need
21:01 absolutejam Can python be embedded in jinja?
21:01 absolutejam I notice that a lot of useful jinja filters from the likes of Ansible are missing in Salt
21:01 coredumb honestly I still wonder what's coming from where
21:01 absolutejam which I thought were standard but aren't
21:02 coredumb https://docs.saltstack.com/en/latest/topics/jinja/index.html#filters < apparently salt only add these filters over the official ones
21:03 coredumb next version adds a bunch apparently :)
21:03 absolutejam cool :)
21:04 absolutejam Currently fighting with pkgrepo.managed and Packman repo (OpenSUSE)
21:04 absolutejam :{
21:21 ecdhe joined #salt
21:21 ConnorCG joined #salt
21:21 lorengordon joined #salt
21:24 hemebond joined #salt
21:30 scottjk_ joined #salt
21:31 scottk_ joined #salt
21:31 scottk_ does anyone know if the selinux module requires a reboot? i want to run selinux.setsemod
21:34 ConnorCG left #salt
21:38 nixjdm joined #salt
21:38 PatrolDoom joined #salt
21:40 benbro1 joined #salt
21:57 aarontc joined #salt
22:02 Praematura joined #salt
22:09 chupetito joined #salt
22:10 cyborg-one joined #salt
22:14 teratoma joined #salt
22:18 mikea joined #salt
22:24 noraatepernos joined #salt
22:27 lazybear joined #salt
22:27 pbandark joined #salt
22:28 eichiro joined #salt
22:37 nixjdm joined #salt
22:41 benbro joined #salt
22:44 rojem joined #salt
22:47 ssplatt joined #salt
23:01 patrek joined #salt
23:04 bluenemo joined #salt
23:04 Praematura joined #salt
23:08 deuscapturus joined #salt
23:20 xMopxShell If i've set some jinja variables in an state file, is there a way to make those vars automatically available to file.managed templates? I'm finding passing the vars I want to use a little clunky
23:23 whytewolf xMopxShell: read up on context, and defaults in relation to file.managed https://docs.saltstack.com/en/latest/ref/states/all/salt.states.file.html#salt.states.file.managed
23:25 xMopxShell whytewolf: thanks! i wasn't aware of 'context', but like 'defaults', i'm wondering if passing vars via those can be avoided.
23:25 whytewolf no
23:26 xMopxShell gotcha, thanks
23:27 Nightcinder joined #salt
23:39 _KaszpiR_ joined #salt
23:40 lorengordon joined #salt
23:41 benbro1 joined #salt
23:42 lorengordon absolutejam: stay tuned for a bunch of new jinja filters, currently in the develop docs, but i think in the 2017.7 release... https://docs.saltstack.com/en/develop/topics/jinja/index.html#filters
23:47 lorengordon pretty sure that list isn't even quite "complete"
23:57 onlyanegg nice! that's pretty significant

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