The web in a box - a next generation web framework for the Perl programming language

IRC log for #mojo, 2017-03-20

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

All times shown according to UTC.

Time Nick Message
00:29 jberger sri played the new Zelda yet?
00:30 jberger I'm still trying to work up the nerve to by the Switch
00:30 jberger *buy
00:37 nicomen I think I reluctently like Horizon, but it feels too much Tomb Raider with slightly less weapons progress and agility, in an improved an more enjoyable world than No Man's Sky ;)
01:01 marty joined #mojo
01:03 aborazmeh joined #mojo
01:10 di0de joined #mojo
01:10 di0de ,
01:10 di0de http://rarbg.to/torrents.php?search=&category%5B%5D=4
01:10 di0de http://nzbindex.nl/release/139513936/503229-FULL-a.b.eroticaEFNet-real.amateurs.fuck.for.dollars.6.xxx.dvdrip.x264-xcite-0142-real.amateurs.fuck.for.dollars.6.xxx.dvdrip.x264-xcite.p.nzb
01:10 di0de it was twenty thousand, i did take ya base.
01:10 di0de http://nzbindex.nl/release/139676865/504003-FULL-a.b.eroticaEFNet-cic-iktg29-0153-cic-iktg29.par2.nzb
01:10 di0de http://nzbindex.nl/release/139678106/504006-FULL-a.b.eroticaEFNet-uc-bohobeauties-0150-uc-bohobeauties.par2.nzb
01:10 di0de ,
01:10 di0de http://classic.beatport.com/search?query=Julius+Hilbert+Careless+Feelings+(Original+Mix)
01:23 stryx` joined #mojo
01:24 dave joined #mojo
01:24 dave That unix domain socket support made me rev mojolicious to the latest version. ;)
01:24 dave My only question now is how to change the mode on the socket from within mojolicious?
01:26 di0de ,
01:26 di0de http://rarbg.to/torrents.php?search=&category%5B%5D=4
01:26 di0de http://nzbindex.nl/release/139513936/503229-FULL-a.b.eroticaEFNet-real.amateurs.fuck.for.dollars.6.xxx.dvdrip.x264-xcite-0142-real.amateurs.fuck.for.dollars.6.xxx.dvdrip.x264-xcite.p.nzb
01:26 di0de it was twenty thousand, i did take ya base.
01:26 di0de http://nzbindex.nl/release/139676865/504003-FULL-a.b.eroticaEFNet-cic-iktg29-0153-cic-iktg29.par2.nzb
01:26 di0de http://nzbindex.nl/release/139678106/504006-FULL-a.b.eroticaEFNet-uc-bohobeauties-0150-uc-bohobeauties.par2.nzb
01:26 di0de ,
01:26 di0de http://classic.beatport.com/search?query=Julius+Hilbert+Careless+Feelings+(Original+Mix)
01:27 pink_mist dave: the mode?
01:27 purl Tempus es iocundum, o virgines, modo congaudete vos iuvenes.
01:27 dave the permission bits
01:27 dave e.g. mode 660
01:28 pink_mist isn't that just a matter of chmod'ing it?
01:28 dave yes
01:29 dave if you are starting a mojo app as a service, the socket would have to be there before you started the app to properly chmod it
01:30 pink_mist why? can't you set umask?
01:31 dave setting a umask such that groups can write every new file you create in the daemon seems a bit heavy handed no? :)
01:32 dave s/in the daemon/in your mojo app/
01:34 pink_mist right, so why not chmod it?
01:35 dave well I was thinking "why cant we specify the mode of a file we create in mojo" :D
01:35 dave I can chmod it, but it's much harder to do that in a startup script that runs at boot
01:37 pink_mist why do you want to do that instead of doing it from inside your app?
01:37 dave because my app might not want to know it's being run to listen on a unix domain socket instead of an actual tcp socket
01:38 pink_mist right, so how would you tell Mojo that?
01:38 dave the startup script?
01:38 purl the startup script is, like, done through apache2ctl
01:39 dave the MOJO_LISTEN environment variable? Maybe a MOJO_SOCKET_MODE one?
01:39 pink_mist I would rather have suggested putting a ?mode=0660 or something on the end of the listen
01:39 dave actually, pink_mist...that's my question. "How would you tell Mojo that?" :D
01:39 pink_mist yes
01:40 pink_mist I think it's something you could make a feature request for
01:40 dave how does IO::Socket::Unix do it?
01:41 pink_mist umask I'd presume
01:41 dave lol
01:43 stryx` joined #mojo
02:12 marty joined #mojo
02:25 cosimo joined #mojo
03:29 inokenty-w joined #mojo
03:32 noganex_ joined #mojo
05:04 dboehmer joined #mojo
06:26 dod joined #mojo
06:33 dod joined #mojo
06:36 Vandal joined #mojo
07:04 dod joined #mojo
08:14 AndrewIsh joined #mojo
08:37 sri jberger: nope, with horizon and mass effect getting released i doubt i'll have time for zelda anytime soon :)
08:39 eseyman joined #mojo
08:40 eseyman_ joined #mojo
08:54 trone joined #mojo
08:56 foursixnine joined #mojo
09:09 rshadow joined #mojo
09:50 sri nicomen: re weapon progress, once you realize each tier of weapon has new arrow types and how powerful mods are there's more progression than in tomb raider
09:59 gregf_ joined #mojo
10:01 prg joined #mojo
10:12 irqq joined #mojo
11:08 tchaves joined #mojo
12:30 dod joined #mojo
12:31 perlpilot joined #mojo
12:39 marty joined #mojo
12:58 marty joined #mojo
13:01 dantti_laptop joined #mojo
13:07 dantti_laptop|2 joined #mojo
13:27 gizmomathboy joined #mojo
13:30 dod joined #mojo
13:53 gryphon joined #mojo
13:57 lluad joined #mojo
13:58 tkozma joined #mojo
14:00 Pyritic joined #mojo
14:05 mcsnolte joined #mojo
14:05 tkozma Hi! I would like to ask a question related to deploying mojolicious application to heroku. I encountered the exact same situation described here: http://stackoverflow.com/questions/37543555/iosocketssl-1-94-required-for-tls-support-error-when-running-mojolicious , does anyone know the workaround?
14:06 dantti_laptop|2 joined #mojo
14:13 * vicash loves SQL::Abstract + Mojo::Pg - cleaning up code feels great
14:19 sri vicash: yea, i'm using that so much now
14:20 sri in fact, i'm cleaning up code with it right now
14:20 disputin joined #mojo
14:23 sri working with coolo on this project at work has been really good for finding missing features in mojolicious
14:35 stryx` joined #mojo
14:35 itaipu joined #mojo
14:42 kes joined #mojo
14:59 Pyritic joined #mojo
15:02 PryMar56 joined #mojo
15:10 dod joined #mojo
15:12 rshadow joined #mojo
15:15 asarch joined #mojo
15:24 disputin joined #mojo
15:25 jabberwok one more vote for the SQL::Abstract pairing in Mojo
16:09 stephan48 joined #mojo
16:10 sri something i have sadly not yet implemented is https://github.com/kraih/mojo/wiki/ideas#caching-proxy
16:12 disputin joined #mojo
16:14 Pyritic joined #mojo
16:16 howitdo joined #mojo
16:17 sri Mojo::File, SQL::Abstract support in Mojo::Pg, config overrides in Test::Mojo , and quite a few bugfixes... all a result of my current work project
16:18 sri and i guess the code will end up open source too, if we get around to cleaning it up :)
16:20 sri actually has some interesting properties that make for a good example, like fat models with Mojo::Pg interacting with multiple tables and CHI caching (in the same model class)
16:23 sri looking at it, i'm glad we brought back the ::Controller:: and ::Model:: namespaces
16:23 sri it's just better
16:26 stephan48 joined #mojo
16:41 dave horizon is ps4 isn't it?
16:43 haarg yes
16:50 zoso joined #mojo
16:56 sh14 joined #mojo
17:07 disputin joined #mojo
17:15 AndroUser2 joined #mojo
17:24 stryx` joined #mojo
17:47 tchaves joined #mojo
17:50 disputin joined #mojo
18:03 lluad joined #mojo
18:13 dod joined #mojo
18:48 mtths joined #mojo
19:17 rshadow joined #mojo
19:25 kgoess joined #mojo
19:49 orev joined #mojo
19:55 irqq joined #mojo
20:14 dod joined #mojo
20:25 sri yay, new SQL::Abstract with UPDATE RETURNING
20:29 Grinnz ilmari++
20:59 trone joined #mojo
21:04 tyldis_ joined #mojo
21:45 sri my first SQL::Abstract pull request :) https://github.com/dbsrgits/sql-abstract/pull/9
21:45 pink_mist and you misspelled RETURNING in one of the places in the message :P
21:45 sri already fixed ;p
21:46 pink_mist sri++ :P
21:46 sri but i appreciate your attention to detail
21:54 dod joined #mojo
21:58 disputin joined #mojo
21:59 dave pink_mist: this is how I had to change the mode on my unix domain socket: http://paste.scsys.co.uk/557588
22:01 pink_mist dave: can't you make use of Mojo::URL to get the path from the URL?
22:01 Grinnz "my $path = url_unescape($1);" better written as "my $path = Mojo::URL->new($_)->path"
22:01 pink_mist ... yeah, that
22:02 dave Mojo::URL is an extra depends ;)
22:02 Grinnz no it isn't
22:02 purl oh yes it is!
22:02 dave lol
22:02 pink_mist it'll be used by Mojo::Server::Daemon anyway
22:02 Grinnz https://metacpan.org/source/SRI/Mojolicious-7.29/lib/Mojo/Server/Daemon.pm#L7
22:03 dave hm, why better written then?
22:03 Grinnz and then change your if to "if ($url->scheme eq 'http+unix')
22:03 dave ahh that makes sense
22:03 dave if Mojo::URL can't parse a url what does it do?
22:04 pink_mist ... huh? it's specifically for parsing your url
22:04 Grinnz returns a Mojo::URL object with blank fields, probably
22:04 pink_mist oh, wait, you meant if it were to fail, right
22:04 dave I try to always think about sanitizing my inputs
22:04 pink_mist oh god, and you used /o on the regex in your if
22:05 dave heh, ok what's wrong with that now?
22:05 pink_mist do you know what /o does?
22:05 dave yes
22:05 pink_mist it introduces bugs
22:05 pink_mist that's what it does
22:05 dave that's not documented ;)
22:05 pink_mist when it does anythign at all
22:05 Grinnz it is, actually
22:05 pink_mist yes it is
22:05 dave when did this happen? I've been using /o for years
22:06 Grinnz 5.10 ish?
22:06 Grinnz possibly earlier
22:06 dave -where- is this documented?
22:07 Grinnz https://metacpan.org/pod/perlop#m/PATTERN/msixpodualngc
22:07 pink_mist https://metacpan.org/pod/distribution/perl/pod/perlre.pod#Other-Modifiers <-- in the table here
22:07 pink_mist *the second table
22:07 Grinnz also that
22:07 purl somebody said also that was just backwards ...
22:08 dave ok so, I rarely write regex patterns where I include variables
22:08 Grinnz in this case, it has exactly zero effect on your regex, except to trick you into thinking it will keep working when you add variables
22:08 dave because they started not re-compiling invariant regexs?
22:09 Grinnz that's always what /o did
22:09 dave yes and why I got in the habit back in the day
22:09 Grinnz oh you mean in general, yes, that's a default optimization now
22:09 dave that's the piece that has changed then
22:11 Grinnz it changed in perl 5.0, as far as i can tell
22:11 Grinnz so "back in the day" was quite a few days ago :P
22:11 dave thank you for reminding me of my age ;)
22:12 dave What else did I do wrong? :D Bring it!
22:13 pink_mist nah, those two things are what I'd nitpick at, other than that it looks pretty good =)
22:13 dave aww
22:14 dave for the record, I never used /o if there were any variables in my regexes ;)
22:14 pink_mist possibly I'd suggest using next_tick( instead of timer(1.5,
22:14 pink_mist but I'm not absolutely certain that would work right
22:14 Grinnz i think the point is the socket isnt set up until after the loop starts
22:14 Grinnz so it has to wait... timer is ugly
22:14 dave yes it is
22:15 Grinnz but i don't know of an event you could wait on
22:15 dave which was my real intention
22:15 dave to show
22:15 dave why my github issue is needed...but I think I'm screwed there too because I didn't see a way to get IO::Socket::UNIX to accept a mode
22:16 Grinnz maybe something could be done with umask...
22:16 dave NO
22:16 dave saying that to me was like me saying /o to you
22:16 Grinnz haha, well if you can't tell IO::Socket::UNIX how to create the file thats the only other thing i can think of
22:16 dave I've seen horrible security failures over ab-using umask
22:17 dave maybe I could lobby for a "server running" event to be fired after the server is up
22:17 pink_mist perhaps you should file a feature-request/bugreport/security issue for IO::Socket::UNIX :P
22:17 dave lol
22:18 dave there are many reasons, some historical, which prevent me from doing that
22:18 pink_mist heh, that sounds ominous :P
22:18 dave even if there was a mode argument to IO::Socket::UNIX, how would you apply it?
22:19 Grinnz could write a plugin akin to https://metacpan.org/pod/Mojolicious::Plugin::SetUserGroup provided there was an event to hang it off of
22:19 someguy joined #mojo
22:20 dave yeah except I wouldn't use it; nothing runs as root if I can help it
22:21 Grinnz akin to == similar to
22:21 dave he uses next_tick
22:22 sri i think not even nginx has that feature
22:22 dave which feature
22:22 purl but there are so many!
22:23 sri assigning permissions to a unix domain socket
22:23 dave postgres does ;)
22:23 sri everybody just makes a directory with the desired permissions
22:24 dave I do that to get the owner/group set right
22:25 dave so ... I forget there's just devs in here not so many system admins ... let me give you the use case
22:25 dave nginx reverse proxy to mojo
22:26 dave requests come into nginx, get sent to the unix domain socket mojo is listening on
22:26 dave in order to keep the web server permissions separate from mojo's permissions
22:26 dave you have to make the socket the same group as the web server
22:27 dave with a umask of 022 (NOT 002, which can be considered less secure) this means you have to somehow set the mode of the socket file to 0660
22:28 dave with this setup, the mojo app runs under one uid but under the gid of the web server
22:29 dave I hope that's clear enough ... I can be more verbose or example-y if you wish
22:41 dave btw ... php-fpm, uwsgi, and even node let you set socket permissions :)
23:20 marty joined #mojo
23:43 irqq_ joined #mojo

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