<zarvox> So I'm finding myself writing similar logic in multiple places to do data lookup, and thinking that should probably get DRY'd up.
<zarvox> This is stuff like "given a package, what is the icon source URL"
<zarvox> "given an action, what is the noun associated with the action"
<kentonv> given a package record or given a package ID?
<zarvox> a package record
<zarvox> Where sounds like a sane place to put our back-compat logic?
<zarvox> I don't think it quite belongs in sandstorm-db
<kentonv> mongo has a way that you can define methods and such that get added to records as they come out of the database... not sure if I'd want to use that though
<kentonv> why not in sandstorm-db?
spangattack has quit [Ping timeout: 252 seconds]
<zarvox> It *could* go there, but I worry it'd feel like littering that interface with a huge number of lookup functions, many of which are pure and don't even need a SandstormDb handle
<kentonv> they could be "static methods" (members of the type rather than the instance). Otherwise we can have a separate SandstormUtil library but I'm not sure if that's actually any cleaner
<zarvox> so then I'd write, e.g. var nounPhrase = SandstormDb.nounPhraseForAction(action);
<zarvox> ?
<zarvox> and then whenever I use one of these, I'd depend on the sandstorm-db package
<kentonv> yeah
home has joined #sandstorm
<kentonv> SandstormDb would perhaps be better-named SandstormDataModel. Ideally each record type would be wrapped in a class that has friendly methods and such. But that would take a while.
<kentonv> and Javascript is impossible to refactor due to lack of type checking
<kentonv> another possibility
<zarvox> http://flowtype.org/ may be of some value, particularly if you can use the Match stuff
<kentonv> if the problem is mainly backwards-compatibility fixups, you can rig the collections to perform these fixups on results from a query automatically.
<kentonv> or, we can do a migration
<zarvox> can't really do a migration, since the data isn't necessarily already in the DB, but maybe the collection-fixup approach is workable?
home is now known as home_clutchmaste
home_clutchmaste has quit [Client Quit]
<kentonv> a migration combined with performing the fixups at install time on newly-installed apps?
<zarvox> maybe, but then the migration and the fixup code should share the implementation, so then where does that one go...
<zarvox> I'm sufficiently convinced that SandstormDb is not the worst place in the world for functions like https://github.com/sandstorm-io/sandstorm/blob/master/shell/packages/sandstorm-ui-applist/applist-client.js#L57..L87 to go for now to DRY things up, and if we want to restructure/rename/relocate things later, then that's fine too
<kentonv> I do think SandstormDb has gotten weird -- it's proven to be the obvious place for a lot more code than I originally anticipated
<kentonv> but I think the way to respond to that is to split it up into more files and say "yeah, it's a big library but at least it has a clear purpose"
<kentonv> also the client/server separation has gotten particularly weird. Need to think more about that.
<zarvox> Yeah. Theoretically, each collection could go in its own file with the helpers for that collection, and maybe someday those helpers return object wrappers instead of raw data
<kentonv> I actually think a lot of ddp method and publish implementations should be moved into SandstormDb
<zarvox> I agree with the publishes, for sure. applist-server and grainlist-server want to share a publish, so one depends on the other.
<zarvox> They'd make more sense in SandstormDb
<zarvox> At some point it starts to feel like we're building a separate backend API and frontend UI
<zarvox> I wonder if other Meteor users experience this
<kentonv> yes, that's basically it. SandstormDb defines the client<->server interface and most of the server's interaction with mongo
<kentonv> it's the M in MVC I suppose
isd has quit [Quit: Leaving.]
spangattack has joined #sandstorm
spangattack has quit [Changing host]
spangattack has joined #sandstorm
jaaason has joined #sandstorm
neynah has joined #sandstorm
<maurer> OK, so I have a weird idea that I was thinking about implementing myself, but when I thought about it, it sounded similar to sandstorm grains, so I figured I'd informally throw it out here and see if it sounds similar to grains
<maurer> The basic idea was to have a task app, where each task has a "context" associated with it. A "context" would consist of a bundle of software, some data, and a set of services which need to be launched.
<maurer> For exmaple, if I had a task to fix a bug in Holmes, a piece of software I'm writing, the immutable state would have installed copies of rust, vim, standard build tools, and libraries I depend upon
<maurer> It would also have a systemd user unit which spawns a postgres database on a local data directory
<maurer> Users could then access the context for a given task either through a web browser, which would run the context on the server
<maurer> or by "checking out" the context, which would copy the context to the local machine and fire it up, allowing them to send it back to the server when done
<maurer> A context _seems_ very much like a grain
<maurer> the awkward thing is that it would be constructed somewhat dynamically, unlike what happens with an spk
<maurer> The other awkward part would be that if I tried to make this app as a sandstorm app, it would need to be able to spawn grains from inside the todo app instance, which had not been uploaded as spks, which seems weird
<maurer> The alternative approach I was considering was cobbling these pseudo-grains together using systemd, nix, and git (nix closures for the read-only portion, systemd user units for services, git for managing mutable per-context state)
<maurer> In any case, now that I've spewed all over your channel, I appreciate any feedback I get :)
nander has joined #sandstorm
<nander> Lol, did sandstorm just install gitlab for me? Is this black magic?
<nander> It took like 6 seconds
<maurer> thatsthepoint
<maurer> :P
<geofft> I have long suspected the point of sandstorm is to be black magic
<maurer> (as someone who administers a non-sandstorm gitlab instance, I understand that it does not normally take 6 seconds)
<nander> Can I have an application on a specific url, without the sandstorm UI around it?
<nander> Or is that precisely not the point?
<maurer> nander: I don't think that's currently possible for dynamic content, but I don't think it's being designed to not happen
<nander> I'm kind of amazed at the fact that I just installed draw.io, apache wave and gitlab in mere seconds
<maurer> nander: I'm not a core developer, so maybe they can do it now, but I think that's a "not yet" rather than a "this is impossible intentionally"
<nander> I found this through an article on apache wave
<nander> I was one of the 6 google wave users
<nander> Apache wave isn't as good as google wave was
<nander> No dynamic content yet it seems
neynah has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
rchrd2 has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
simonv3 has quit [Quit: Connection closed for inactivity]
rchrd2 has joined #sandstorm
bb010g has joined #sandstorm
rchrd2 has quit [Client Quit]
<dwrensha> Ugh. So, the problem with the schema that I propose here: https://github.com/sandstorm-io/sandstorm/pull/983#discussion_r41440181
<dwrensha> ... is that Mongo apparently doesn't give me an easy way to project out just the keys of user.identities.service
<dwrensha> like, I want to say "only return the service name", but Mongo wants to give me the whole service object
<dwrensha> unless I specifically exclude fields of the subojects
<dwrensha> I think this means that I need to make the service object not a proper union
<dwrensha> just give it a "name" field
<dwrensha> and say that it can have arbitrary service-specific fields
<dwrensha> actually, I think it should be "type" rather than "name"
<dwrensha> I suppose if I'm going this way, I might as well just keep identities.service as string, and add a new field serviceData that can have service-specific data
NOTevil has joined #sandstorm
NOTevil has quit [Quit: Leaving]
gopar has joined #sandstorm
gopar has quit [Ping timeout: 268 seconds]
gopar has joined #sandstorm
zeroish has quit [Ping timeout: 264 seconds]
<warren> jadewang: ping
gopar has quit [Remote host closed the connection]
rchrd2 has joined #sandstorm
rchrd2 has quit [Client Quit]
larjona has joined #sandstorm
jadewang has quit [Remote host closed the connection]
larjona has quit [Ping timeout: 268 seconds]
larjona has joined #sandstorm
jadewang has joined #sandstorm
jadewang has quit [Ping timeout: 250 seconds]
jadewang has joined #sandstorm
mort___ has joined #sandstorm
jadewang has quit [Ping timeout: 255 seconds]
larjona has quit [Ping timeout: 246 seconds]
larjona has joined #sandstorm
rchrd2 has joined #sandstorm
rchrd2 has quit [Client Quit]
DanC__ has quit [Ping timeout: 264 seconds]
DanC__ has joined #sandstorm
jadewang has joined #sandstorm
jadewang has quit [Ping timeout: 252 seconds]
mort___ has left #sandstorm [#sandstorm]
larjona has quit [Quit: Konversation terminated!]
jadewang has joined #sandstorm
larjona has joined #sandstorm
jadewang has quit [Ping timeout: 264 seconds]
larjona has quit [Read error: Connection reset by peer]
mort___1 has joined #sandstorm
rchrd2 has joined #sandstorm
rchrd2 has quit [Client Quit]
fonfon has joined #sandstorm
ripdog has quit [Ping timeout: 246 seconds]
ripdog has joined #sandstorm
fonfon has quit [Remote host closed the connection]
mort___ has joined #sandstorm
mort___1 has quit [Read error: Connection reset by peer]
aaronr has joined #sandstorm
jadewang has joined #sandstorm
jadewang has quit [Ping timeout: 240 seconds]
larjona has joined #sandstorm
<skay> paulproteus: hey! I thought yesterday was thursday but it was not. which means today is not Friday, which is when I would have liked to meet to talk about sandstorm ipython stuff
<skay> paulproteus: is it okay to talk friday instead? I hope so! maybe we could just email otherwsie
<skay> paulproteus: naive questions ahoy: I am familiar with using juju to deploy a set of things inside containers and then setting up relations between the containers
<skay> paulproteus: e.g. I deploy my django app and it has relations to postgresql in another container, block storage, etc.
<skay> paulproteus: sandstorm allows things like that, yes? and I could see an example maybe with mediagoblin?
<skay> paulproteus: this means I should be able to make a sandstorm pyvideo site?
<paulproteus> skay: Hey! Yes you said Friday and I meant Friday so that all works fine to me.
<paulproteus> re: juju + relations:
<paulproteus> Sandstorm apps are designed to work immediately, see e.g. https://docs.sandstorm.io/en/latest/developing/handbook/
<paulproteus> So they're not composable in the juju way of "A database here, an app there".
<paulproteus> There is a MediaGoblin app; it embeds its database. This means when you click "New MediaGoblin" you get a totally isolated fully automatically configured MediaGoblin.
<paulproteus> Click that button as many times as you want.
<paulproteus> https://docs.sandstorm.io/en/latest/guided-tour/ discusses "static publishing", but basically, a Sandstorm app can easily expose static HTML to the world.
<paulproteus> However, the app's dynamic view can only be seen by authorized users, typically by you creating a "Sharing link" and sharing it with them, as in Google Docs.
jadewang has joined #sandstorm
mort___ has quit [Ping timeout: 246 seconds]
fonfon has joined #sandstorm
jadewang has quit [Remote host closed the connection]
spangattack has quit [Ping timeout: 250 seconds]
spangattack has joined #sandstorm
* skay nods
NOTevil has joined #sandstorm
gopar has joined #sandstorm
<maurer> paulproteus: Can a grain produce and install a new app? Can an authorized external-to-sandstorm app do this? Is there a way to install apps that don't show up in the app list?
achernya_ has joined #sandstorm
achernya has quit [Ping timeout: 244 seconds]
<paulproteus> re: Can a grain produce and install a new app? No, I think, although that'd be interesting....
<paulproteus> The way installs work is that there's a mysandstorm.example.com/install/ URL that means, "Install an app whose details are provided by query string parameters, after the user clicks OK."
<paulproteus> So I guess a grain _could_ actually present a URL that works for this!
<maurer> paulproteus: OK, do you have scrollback?
<paulproteus> It could use the static-publishing-url to store the SPK in, even.
<paulproteus> ? re: scrollback
<paulproteus> https://botbot.me/freenode/sandstorm/ is IRC scrollback if that's what you mean.
<paulproteus> I also have some in my IRC client here.
<paulproteus> I see, you asked some Qs last night!
<maurer> paulproteus: OK, I gave a longwinded explanation earlier of what I'm considering doing (in IRC) but I grabbed it and put it into a gist just now in case you didn't have it: https://gist.github.com/maurer/ed5af53c1d9aa17e93fc
<maurer> these are related :P
<maurer> Basically one way I'm considering realizing this idea is to have a sandstorm app for todo list management that creates context grains with required software installed, such that those grains/contexts can be recovered and used later
<paulproteus> I agree that your context thing sounds like a grain.
<paulproteus> And you can use static publishing in Sandstorm to create a URL that you can pass to /install/
<paulproteus> A URL for an SPK that is.
<paulproteus> And you can even tell other people that they can run that SPK on their own Sandstorm rather than yours.
<paulproteus> Silly (?) Q: Why is it necessary to construct the context dynamically?
<paulproteus> Is that because the software might change? Or the data might change?
larjona is now known as larjona_afk
<maurer> paulproteus: Because the set of software involved in the context depends on the task
<paulproteus> If the data, it would be "easy" to modify the SPK to have different data contents.
<paulproteus> Mm, OK, yeah.
<paulproteus> Well basically, if you're cool with programmatically creating SPKs, this should work fine for you.
<maurer> paulproteus: for example, if I start writing code in R tomorrow (unlikely, but possible), I'd need an R interpreter
<maurer> Yeah, I think I've got a trick for turning nixos closures into spks
<maurer> I haven't tried it yet, but it looks like it'd work
<paulproteus> AFK a bit!
<maurer> thanks
<paulproteus> Back in ~10 min
jadewang has joined #sandstorm
jadewang has quit [Ping timeout: 250 seconds]
<paulproteus> rehi, maurer
<paulproteus> Let me know how else I can help you make this (-:
<paulproteus> re: Can an authorized external-to-Sandstorm app do this? Yes, if you create a /install/... URL.
<paulproteus> To get a sense of how to compute those, take a look at the "old" app index: https://github.com/sandstorm-io/sandstorm-website/blob/master/apps/index.html
jadewang has joined #sandstorm
<paulproteus> re: Is there a way to install apps that don't show up in the app list? Yes, by either the user clicking "Upload SPK" or by the user visiting such an /install/ URL.
<maurer> paulproteus: I think I might have been unclear with my grammar on that last one
<maurer> paulproteus: I was wondering if I can let the user install an spk that won't show up on their dashboard, otherwise I could see this getting cluttered quickly
<maurer> (I may also just do it ignoring this for now, since I can just deal with the clutter)
<paulproteus> Oh, I see, huh. Yeah, I think there's no way to do that, and I _think_ I believe that's a feature.
<paulproteus> I can usually be convinced of nearly anything though if you want to try. (-:
<maurer> Eh, I don't think I'll try to convince anyone of this until I at least have a prototype
<paulproteus> (-:
<paulproteus> I do like this idea, btw, quite a bit.
<dwrensha> Grrr. "MinimongoError: Minimongo doesn't support $ operator in projections yet."
<ocdtrekkie> FYI paulproteus, someone on a Wekan issue thought logging in to use someone else's grain might equal having to pay.
<ocdtrekkie> maurer: Grains being able to create new grains, at least, is a thing on my wishlist.
fonfon has quit [Remote host closed the connection]
rchrd2 has joined #sandstorm
<paulproteus> ocdtrekkie: That's fascinating, yeah.
simonv3 has joined #sandstorm
larjona_afk is now known as larjona
fonfon has joined #sandstorm
fonfon has quit [Remote host closed the connection]
fonfon has joined #sandstorm
gopar has quit [Quit: Leaving]
eternaleye has joined #sandstorm
gopar has joined #sandstorm
* paulproteus waves to all y'all
<maurer> Hrm. Sandstorm may finally force me to get a proper ssl cert instead of just using a self-signed one and verifying the hash
<maurer> (when trying to let other people use it, the foo-hash subdomains don't automatically get exceptioned in when they accept the cert, so it still doesn't work)
<maurer> (and browsers don't pop up a new "trust this cert also for this other domain?" when the js is doing the requesting for some reason)
<paulproteus> https://www.ssl2buy.com/cheap-wildcard-ssl-certificates-ads is confusingly cheap at $42/yr
<kentonv> or use free sandcats certs. :)
<paulproteus> sandcats.io is confusingly cheap at $0/week
<maurer> Or I just start telling my "users" (aka friends) that they can totally trust Honest Maurer's Root CA :P
<geofft> per week? "we'll make it up on volume?" :P
<kentonv> maurer: Is there a reason you'd prefer not to use sandcats?
<paulproteus> Or $0/hr depending on if you were using a Sandstorm build from 2 days ago
<paulproteus> ahem
neynah has joined #sandstorm
<maurer> kentonv: Not a real one, I've just been keeping my stuff behind my own domains for a while
<maurer> kentonv: it's not like it's a production service where I need to have a professional looking domain
<paulproteus> <3 one's own domain
<kentonv> amusingly, I suspect our "unprofessional-looking" domain was a big part of why we were able to make the deal with globalsign.
<paulproteus> I feel like a huge fraction of why I learned about computer things was so I could look cool by having my own domain.
<paulproteus> But yeah, I do run my Sandstorm instance at https://rose.sandcats.io for sandcats convenience.
<kentonv> because they know sandcats can't possibly compete with their normal wildcard cert business which sells to big companies with money
<kentonv> yeah vanity names are nice but sandcats is so easy... and more secure since the keys rotate. :)
<maurer> Is there a procedure for sandcatsifying a sandstorm installation that already exists?
<maurer> Oh, now I remember the original reason I didn't sandcats
<maurer> it doesn't apply anymore, but I was using SNI + multiple certs to run another webapp on this machine
<maurer> but I run it inside sandstorm now, so it no longer applies
<kentonv> maurer: yes, you can convert an existing server; I think paulproteus has docs somewhere
<maurer> OK, I'll look
<kentonv> maurer: note that for sandcats-https, you'll need to ditch any nginx reverse-proxy and let sandstorm take over port 443
<maurer> Sure, that's why I didn't do it before
<maurer> but the other thing behind the reverse proxy is dead now
<maurer> well, s/dead/moved inside sandstorm/
<paulproteus> kentonv: ya one sec
<paulproteus> maurer: There are two steps to sandcats-ifying.
<paulproteus> 1. Registering a name with the Sandcats servce along with a client cert that identifies you.
<paulproteus> That part is undocumented except as part of the install, though I can provide hints.
<paulproteus> 2. Convert an existing Sandstorm install to request certs from Sandcats.io.
<paulproteus> That part is doc'd here: https://docs.sandstorm.io/en/latest/administering/ssl/ "Enabling HTTPS for an existing sandcats.io Sandstorm server"
<paulproteus> I can write docs for #1 and add a link to both of those as part of https://docs.sandstorm.io/en/latest/administering/sandcats/ (aka https://sandcats.io/ ) since it seems that's the best place for it.
<paulproteus> For now, though, my "advice" is, run the install script somewhere. |:
<paulproteus> (to handle #1)
<maurer> paulproteus: If I run the install script on the machine that already has sandstorm, will badness occur, or will that work well?
<paulproteus> |:
<paulproteus> Totally possibly badness.
<maurer> OK. I guess I can boot up a vm or something
<paulproteus> I can work on documenting something smoother later today/tomorrow; have to finish something first though.
<maurer> No rush, I'll figure it out somehow
neynah has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
neynah has joined #sandstorm
<maurer> paulproteus: so, nc -z 0.0.0.0 portnumber does not seem to do what the sandstorm script expects on my (debian) system, and as a result it declares 443 and 80 unusable and doesn't try to negotiate a sandcats cert
<paulproteus> oh my
<maurer> paulproteus: In that nc -z 0.0.0.0 22 (which has sshd running) returns 1, and nc -z 0.0.0.0 80 (which is unused according to netstat -tulpn) returns 1, and nc -z 0.0.0.0 8060 (which sandstorm tries to use instead) also returns 1
<maurer> I'm not familiar with the proper things for nc -z to do, but it does not seem to be detecting port availability
<paulproteus> Oh dear.
gopar has quit [Remote host closed the connection]
<maurer> (I'll just comment them out in the install script for now)
<paulproteus> ➜ ~ ls -l /etc/alternatives/nc
<paulproteus> lrwxrwxrwx 1 root root 15 Mar 25 2015 /etc/alternatives/nc -> /bin/nc.openbsd
<paulproteus> What's your nc set to in /etc/alternatives?
<maurer> lrwxrwxrwx 1 root root 15 May 1 16:02 /etc/alternatives/nc -> /bin/nc.openbsd
<paulproteus> i,i http://ctypes.sh/
<maurer> That was probably a good check, since my local machine (which I didn't even try this on) is evidently using a version where -z means zero io
<maurer> but that seems to be a non-issue
<paulproteus> That's what it's supposed to mean!
<paulproteus> ➜ ~ nc -z 0.0.0.0 23 && echo true || echo false
<maurer> No, like on my local machine (a weirdo case you don't want to support) it does:
<paulproteus> false
<paulproteus> true
<paulproteus> ➜ ~ nc -z 0.0.0.0 22 && echo true || echo false
<maurer> [maurer@fragarach:~]$ nc -z 0.0.0.0 443
<maurer> nc: missing hostname argument
<paulproteus> !!
<maurer> (it's gnu nc)
<maurer> (which is why it's broken)
<paulproteus> Gnu's Not Netcat
<maurer> maurer@mimung:~$ nc -z 0.0.0.0 22 && echo true || echo false
<maurer> false
<maurer> maurer@mimung:~$ nc -z 0.0.0.0 23 && echo true || echo false
<maurer> false
<maurer> ^ that ones' openbsd netcat from debian tho
<maurer> where I'm ssh'd in
<maurer> I _suspect_ it has something to do with 0.0.0.0
<paulproteus> Yeah... does this machine like not have IPv4?
<maurer> No, it has ipv4, no ipv6
<maurer> but it also has extra interfaces for vms
<maurer> and extra ips
<paulproteus> Oh, and maybe the ports are bound on specific VM IP addresses?
<paulproteus> Not 0.0.0.0 ?
<maurer> Yeah, I dunno
<maurer> I just tried the machine's cannonical external IP too, and still getting 1 from echo $?
<maurer> but netstat -tulpn | grep 443 is empty
<paulproteus> Well, yeah, I think the idea is that it exits 1 if it can't connect.
<warren> kentonv: jadewang: ping
<warren> or maybe somebody else knows the answer, whwat is the legal name of the company?
<paulproteus> Sandstorm Development Group, Inc.
<kentonv> paulproteus: on my machine, `nc -z 0.0.0.0 22` *succeeds* despite sshd running.
simonv3 has quit [Quit: Connection closed for inactivity]
<paulproteus> er yeah kentonv it should succeed; it should exit 1 if ssh isn't running
<warren> business address? (PM me please)
<warren> (filling out purchase order)
<kentonv> warren: our "office" address
<kentonv> paulproteus: or I see, for some reason I thought it was trying to listen on the port
<kentonv> paulproteus: never mind, all seems to behave normally here
<paulproteus> Yay
<maurer> paulproteus: In any case, my goal here is to figure out what the installer script refuses to sandcats
<maurer> Guess I'll just read the script
<maurer> Ah, the problem is that it's disabled for servers with devmode
<maurer> sorry for all the weird configurations/questions :(
<kentonv> maurer: devmode servers are not entirely secure, so you don't want to expose them publicly
<maurer> kentonv: I see. Last time I read through the prompts the only thing I remember reading was that if I wanted to run spk-dev, I'd need devmode.
<maurer> I'll set it to normal mode.
<paulproteus> Ah, great.
<kentonv> maurer: yeah you generally shouldn't do spk-dev on a server that is hosting "live data"; you should use a separate private local server for dev. Though the biggest issue is whether dev accounts are enabled -- letting anyone log in as "Bob dev user", etc.
<maurer> kentonv: Amusingly, I now have a dev account enabled sandcats server
<maurer> which is not what I really intended - dev accounts weren't on my system before
<kentonv> better disable them in sandstorm.conf :)
<maurer> That's what I did
<maurer> Yeah, they're gone now
<maurer> OK, thanks for the help
<paulproteus> bd
bb010g has quit [Quit: Connection closed for inactivity]
<maurer> Heh, the first thing that happened when I pasted an ipython grain to someone is that they're trying to poke the sandbox
<kentonv> maurer: yay
<ckocagil> neynah: yt?
rchrd2 has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
<eternaleye> Does anyone know if anything using postgres has been ported yet?
<neynah> hi!
<paulproteus> Howdy eternaleye
<paulproteus> I _think_ nothing has been ported that uses postgres, but I think there's no essential reason you couldn't use Postgres in a Sandstorm package.
<neynah> how's it going ckocagil?
<paulproteus> If you were going to do that, the thing I'd look at is how "vagrant-spk setupvm lemp" works, and then adjust things so it's Postgres instead of MySQL.
<warren> kentonv: here?
<larjona> mediagoblin?
<kentonv> warren: yep
<ckocagil> neynah: great! can you help me out with the images for the Gogs port?
<paulproteus> Having said that, depending on what you're porting, you could consider using sqlite instead eternaleye.
<eternaleye> paulproteus: I guess; I'm just not sure I like the idea of running it in the same one.
<eternaleye> paulproteus: One thing that might be neat would be to port *postgres*, and have grain-per-db and sandstorm-based auth
<paulproteus> Oh, fascinating.
<eternaleye> paulproteus: No, Matrix (matrix.org, an open chat thing)'s reference server hard-deps on postgres
<maurer> Hm, I wonder if I can access systemd inside the sandbox
<eternaleye> paulproteus: It used to do sqlite as well, but it bogs down *hard*
<neynah> Absolutely ckocagil, do you have any existing graphics?
<ckocagil> neynah: the Gogs project has this one: https://github.com/gogits/gogs/blob/master/public/img/gogs-lg.png
<paulproteus> eternaleye: Interesting. Yeah, in theory it should presumably be totally possible.
<paulproteus> grain-per-db and Sandstorm auth is honestly a fascinating idea.
<paulproteus> I could imagine doing that to grant/ungrant access to Postgres to data analysts at a company, and having some other process for getting the data into the Postgres.
<eternaleye> paulproteus: Main thing would be figuring out how connecting to it should work - how to turn the sockets into communication over CapnProto
<neynah> ckocagil: cool! I can use this. For the appGrid icon, would it be reasonable to have this graphic on top of a blue bg like they have on their website?
<paulproteus> A difficulty is presumably people's Postgres clients would want to use the Postgres TCP protocol on port 5432. Maybe you could ask clients to run a bridge so that localhost:5432 => HTTP POST to a Sandstorm grain with an Authorization: Bearer header.
<eternaleye> paulproteus: Postgres supports pluggable auth, too
<paulproteus> I want a generic "Listen on a TCP port, map it to a remote WebSocket with an Authorization: Bearer" header tool.
<ckocagil> neynah: honestly I have no idea
<maurer> paulproteus: If you were doing grain->grain access, you could always do it by sharing a unix socket
<maurer> e.g. use user-opening-the-socket auth, but users are actually grains, rather than traditional users
<maurer> And avoid the networking assuming the grains are running on the same system by putting a socket in there
<paulproteus> eternaleye: Postgres clients presumably don't have pluggable network stacks, though, in that they expect the TCP Postgres protocol, I presume?
<paulproteus> I kinda want "it's like inetd but for Sandstorm".
<eternaleye> paulproteus: True
<paulproteus> I do happen to run a public Postgres instance: http://public-udd-mirror.xvm.mit.edu/
<eternaleye> paulproteus: Could probably translate that to/from CapnProto though
<paulproteus> Possibly, yeah. A question, though, eternaleye -- are you asking about grain-per-DB w/r/t Matrix, or just for its own sake?
<paulproteus> If Matrix doesn't expose its Postgres to the world, but merely exposes a HTTP interface to the world, the easy path to what you want is to embed the Postgres into the Matrix app.
<eternaleye> paulproteus: And thus have a socket-activated translator in any grain that needs postgres, and a translator in the postgres grain too.
<paulproteus> The Sandstormy way to do things generally is to have apps that are self-contained so that when you click "New ${whatever}" you get a ${whatever} without having to think about anything.
<eternaleye> paulproteus: For its own sake
<paulproteus> Cool, great.
<paulproteus> FWIW Sandstorm grains can't yet expose generic Cap'n Proto APIs to the world, merely HTTP via Authroization: Bearer token.
<paulproteus> https://docs.sandstorm.io/en/latest/developing/http-apis/ covers the HTTP API stuf.
<paulproteus> +/- f
<eternaleye> paulproteus: Mm. I'm a sysadmin by day and a distro packager by night, so I generally am not fond of bundling :P
<eternaleye> paulproteus: Also, either ident or PAM auth might be workable: http://www.postgresql.org/docs/9.4/static/auth-methods.html
<paulproteus> Yeah, I sympathize. I'm also a Debian developer. What distro do you package in?
<neynah> ckocagil: I'll have a set of icons ready for you within a few hours. Gotta do a few other things first. :)
<eternaleye> paulproteus: Since sandstorm could pretty easily implement either an ident server or a PAM module (the latter would likely be more useful)
<eternaleye> paulproteus: Exherbo
<eternaleye> paulproteus: Source distro, which is why a few days ago I was in here griping about ekam :P
<ckocagil> neynah: sure, take your time
<maurer> eternaleye: I feel your pain, I tried to package stuff for nixos and got dinged similarly
<eternaleye> I feel ekam is at best half-done. In particular, no way to *constrain* parallelism.
<eternaleye> I don't necessarily *want* it to use all my CPU cores; doing that thrashed my laptop's disk and made it unusable for ~15min.
<kentonv> eternaleye: ekam supports the -jN flag just like make
<kentonv> Sandstorm's makefile defaults to passing nproc, but you can set a variable to change that
<eternaleye> kentonv: Huh, then the "building sandstorm" docs are wrong
<eternaleye> Mm
<eternaleye> kentonv: That really ought to just respect the make jobserver protocol, IMO...
<kentonv> eternaleye: I'm happy to accept a patch. :)
<eternaleye> kentonv: Heh, that'll have to go on the List, well behind such things as "recover that server that kicked three drives out of a RAID-6"
<eternaleye> (SCSI cards dying violently: Bad times.)
<kentonv> one tricky thing with the sandstorm makefile is that I don't really want the meta-make process to run in parallel, I only want ekam to parallelize. Running ekam and meteor build at the same time, for example, would probably be ugly; overlapping logging and such, for not much gain.
<maurer> dwrensha: So, I just successfully reinstalled
<maurer> dwrensha: I didn't have any critical data so I just yolo'd it
<maurer> it worked fine
<dwrensha> maurer: when was your initial install?
<maurer> dwrensha: Sometime in the capnproto 0.4.something days
<maurer> I'm bad with dates
<dwrensha> yeah, this problem came up since then
<dwrensha> if your initial install had been sometime after this spring, ish, you would have hit trouble
<paulproteus> Wow!
<dwrensha> approx April 15, I think
fonfon has quit [Ping timeout: 265 seconds]
NOTevil has quit [Quit: ... I'm off !]
<kentonv> dwrensha: shall I merge #983 now?
<ckocagil> does anyone have a clue on how to debug php in a grain?
<dwrensha> kentonv: OK!
<kentonv> dwrensha: done
<kentonv> ckocagil: probably jparyani and zarvox
<jparyani> I never really figured out a good way beyond using `print` :)
<ckocagil> bummer.
<dwrensha> is it error_log or log_error? :P
<jparyani> but print is awesome, it will show up in your HTML :)
<ckocagil> this simple PHP app has a 1-dirty-line build time longer than a 20m SLOC C++ project I worked with
<paulproteus> Fascinating.
<jparyani> are you using vagrant-spk, and does your app have composer?
<dwrensha> build time? What's it building?
<ckocagil> it uses composer, and it has a build script that invokes composer + does some copy pasting of files
<jparyani> ya typically I skip the composer steps during development. You only have to run it once every time your dependencies change
<ckocagil> the app is Flarum btw, I'm trying to port it
larjona has quit [Quit: Konversation terminated!]
<zarvox> Ahhh. Unfortunate that the composer/build steps are so slow.
<ocdtrekkie> I found some really awful bugs in Google Groups when I responded to Kenton's post.
<zarvox> One of the upsides of PHP was supposed to be that it was just an edit-file, refresh-browser, new-code-runs development experience, which is pretty convenient
<ocdtrekkie> Google Groups warned me I was posting with 'unsubscribe@googlegroups.com' as a visible email address to the list.
<ocdtrekkie> This is fail for two different reasons.
<ocdtrekkie> A. Google Groups should probably recognize that it's own unsubscribe links are okay to end up in quoted replies on the list.
<ocdtrekkie> B. Google Groups should probably properly detect that the email is sandstorm-dev+unsubscribe@googlegroups.com, because Google should recognize the actual email address, particularly when it's Google's own little formatting trick to categorize emails.
<ocdtrekkie> So it seems if I did like ocdtrekkie+list@gmail.com, Google would fail to warn me that I put ocdtrekkie@gmail.com in my message somewhere. I wouldn't be worried about list@gmail.com, because it's not a real address.
<kentonv> ocdtrekkie: Groups has always been pretty broken.
<ocdtrekkie> Just means a Sandstorm-based app will have an easier time exceeding it. :)
<ckocagil> weird coincidence. it was the "Why is the Sandstorm Dev Group on Google?" topic that made me want to port flarum.
groxx has joined #sandstorm
<ocdtrekkie> ckocagil: Not really a coincidence. I read the list. :D
<ocdtrekkie> Re: Flarum, I don't know if I feel a forum-type app is a good replacement for a list-type use case. Forums and email lists have distinctly different community feels.
<ckocagil> I completely agree, but we can't know until we try.
<ckocagil> For some reason I don't feel comfortable with forums pinging me via email, while it is completely fine for Groups to do so
jacksingleton has joined #sandstorm
<eternaleye> Personally, I just want my lists over NNTP :P
<eternaleye> Gmane for life!
gopar has joined #sandstorm