<xpheres>
I don't mind having a specific port for sandstorm instead of sharing one with apache, but I change sandstorm.conf configuration and it still does not start
<ocdtrekkie>
Hmmm, are you getting a particular error message? Did the install perhaps fail to complete?
<xpheres>
sandstorm/run-bundle.c++:1874: failed: bind(sockFd, reinterpret_cast<sockaddr *>(&sa), sizeof(sockaddr_in)): Address already in use
<ocdtrekkie>
What ports are defined in your sandstorm.conf?
<TimMc>
There are a couple of ports involved -- the local port Sandstorm listens on, and the one used in URLs.
<ocdtrekkie>
Bear in mind it may be trying to bind to both 80 and 443.
<xpheres>
I changed them to 81 and 444 (and more than standard ports) to see if I can have both services running
<ocdtrekkie>
SMTP port isn't duplicated either?
<xpheres>
the problem is that sudo sandstorm restart shows :Sandtorm is not running
xpheres_ has joined #sandstorm
<ocdtrekkie>
Because there really isn't any reason Sandstorm shouldn't work if using different ports (I ran mine on nonstandard ports for years.) I think something has to be grabbing that port already,
xpheres has quit [Ping timeout: 260 seconds]
<xpheres_>
yes I don't understand either, I will keep testing and maybe restarting to see if I manage to make it work
<xpheres_>
now it runs
<ocdtrekkie>
Weird what'd you do? :P
<xpheres_>
the base url was https://myip and that was the problem
<xpheres_>
I changed it to my ip with https and now it starts
<xpheres_>
without the https I mean
<ocdtrekkie>
You can't use an IP as the base URL. So that's weird.
<xpheres_>
yes I mean the service starts but I can't access the website
<xpheres_>
I touched what I shouldn't
<ocdtrekkie>
I believe your base URL and wildcard host should have your configured port though.
<ocdtrekkie>
It's just really weird if changing those had any impact on the port binding error because I think those are unrelated.
<xpheres_>
I don't know I've just installed it recently and I'm not a network expert, but I will manage to make it work, at least now apache and sandstorm run simultaneously
<ocdtrekkie>
BASE_URL and WILDCARD_HOST being relatively easy ones to get wrong
<ocdtrekkie>
(You'll note base includes the protocol and wildcard does not)
<xpheres_>
I don't know how to set up wildcard yet but I wanted to test sandstorm on a local network and through a vpn first, not to internet yet
<xpheres_>
so I don't really need a dns yet
<ocdtrekkie>
You'll need wildcard DNS in order to load any apps in Sandstorm.
<xpheres_>
ah I understand
<xpheres_>
then I will do it tomorrow, it is late now. Thanks for all the help!
<ocdtrekkie>
Apps are spawned on randomly generated subdomains so it is an unavoidable requirement.
<xpheres_>
I see, even if I just use it locally I need that dns, got it
<xpheres_>
will learn more and set it up tomorrow
<ocdtrekkie>
Yeah. Feel free to hit us up with any more questions tomorrow or whenever. :)
<xpheres_>
I will, thank you!
<xpheres_>
I have to go now, bye bye!
xpheres_ has quit [Quit: Leaving]
<ocdtrekkie>
So I turned on DMARC like a week ago and apparently if I participate in Google Groups I get a ton of failure notices. :|
<ocdtrekkie>
I'm reading an article that claims that IF I set my DMARC to reject or quarantine instead of none, Google will automagically start rewriting emails "from" me to come from Google instead.
<ocdtrekkie>
Okay, I did a Sandstorm crime.
<ocdtrekkie>
github.com/ocdtrekkie/lemp-box is a bad idea and I'm totally running with it.
<ocdtrekkie>
I have some small pile of apps not worth packaging that also expect low to no traffic that won't static publish well, but I want to move from my shared hosting to Sandstorm.
<Zertrin>
fingers_crossed:
<Zertrin>
ocdtrekkie: (re: dmarc policy) wow, thanks for pointing that out, I thought there was no way to avoid getting unaligned DMARC reports because of google group. Have googled based on your statement and indeed found recomentations to not use the non policy, but rather quarantine with a low or even 0 percentage, such that google group starts From: rewriting. Have now changed my dmarc dns record, let's see in the coming weeks wether that works :
<TimMc>
ocdtrekkie: I wonder what it would take to have lemp-box's /data be backed by a davros grain...
<ocdtrekkie>
TimMc: Probably both apps adding that filesystem capability Ian wrote. Though I really don't want to make the lemp-box experience good because it lacks any semblance of security.
<ocdtrekkie>
Zertrin: Glad my notes on it were valuable to you! I am going to monitor it a few more days before I try ratcheting up the settings myself.
<ocdtrekkie>
Alternate app name idea for lemp-box: Footgun 😂
kentonv has quit [Ping timeout: 244 seconds]
<TimMc>
Oh, what's dangerous about it?
kentonv has joined #sandstorm
<TimMc>
Lack of separation between code and data, maybe?
<ocdtrekkie>
That's a big thing to me compared to other Sandstorm apps. And I may host a couple sites using standalone domains with it, which means anyone can access it and then it's pretty much your standard PHP webhost in a box but with inability to SEO properly.
<TimMc>
Search engine optimization?
<ocdtrekkie>
Sandstorm iframe likely screws up search behavior.
<ocdtrekkie>
But yeah, publicly exposing non-statically published PHP apps which also have a writeable code environment is pretty far from the Sandstorm ideal model.
<jonesv[m]>
<ocdtrekkie> "Alternate app name idea for lemp..." <- I like the first half sentence on the repo: "This Sandstorm app is sort of a crime" 😁
<TimMc>
crimeware
<TimMc>
ocdtrekkie: If the executable code lived in another grain... 🤔
<ocdtrekkie>
I mean it's assuming it's writeable so that doesn't help too much I think.
<ocdtrekkie>
But it can probably run some PHP apps not well suited to Sandstorm.
<ocdtrekkie>
I may try installing Nextcloud in it just to see what happens.
<ocdtrekkie>
Even though I think actually using it for such would be a Really Bad Idea.
<isd>
You'd need to do more than just get those apps to speak the file system cap stuff I wrote -- you also need to convince PHP to load code and whatnot from it, which isn't trivial since it's not a "real" filesystem. So you'd either need to copy it to the grain's own filesystem (and figure out sync) or somehow get php's filesystem access to go over capnp.
<isd>
...though if you did the latter making it read only would actually be pretty easy once you're there.
<isd>
A while back, when thinking about better ways to watch for grain size changes, I mused to myself about just putting a fuse filesystem over /var so we could intercept and track writes, rather than having to deal with the mess that is inotify. I have some concerns about perf, and frankly I don't want to add that much grain-exposed non-memory-safe code. But in theory it would let us do all sorts of neat things if we controlled the underlying VFS,
<isd>
including redirecting filesystem calls to some powerbox-acquired cap.
<isd>
File it under "things to do when we're rich"
<isd>
:P
<ocdtrekkie>
PHP not speaking capnp probably limits the options there drastically re: file system. But as I said I am not planning on investing heavily in polish for this, because it seems like a bad idea in general.
<isd>
Yeah, I agree don't make this a real app.
<ocdtrekkie>
It's just hopefully solving a niche case where I want to retain access to some old PHP sites nobody visits anymore.
<isd>
I just like to discuss the architectural implications.
<ocdtrekkie>
I am torn on publishing because I feel like it would be useful enough to enough people it might help get people to shift to Sandstorm but it is also definitely not something someone should rely on for anything mildly crucial.
<ocdtrekkie>
Maybe calling it Footgun will help convey the associated risks. :P
<isd>
I don't know if I would want to be in a situation where we have meaningful numbers of users who are using sandstorm for this, whether or not they appreciate the implications.
<ocdtrekkie>
That's relatively fair. I do think it's not actually too bad if you aren't also using standalone domains with it... which I'm gonna.
<ocdtrekkie>
I could permanently store it in the Experimental market, which I do like the idea of for "things we don't necessarily support or recommend".
<TimMc>
Making it hard (but possible) to do an ill-advised (but sometimes useful) thing seems like it would be the right approach.
<TimMc>
. o O ( Would the name "PHP Footgun" be too redundant? )
<ocdtrekkie>
I kinda like that
<ocdtrekkie>
But it may also be redundant
<TimMc>
Double-Barreled Footgun
<ocdtrekkie>
Okay, now the default index.php of the grain explains how to use it, after a pile of warnings about not using it.
<ocdtrekkie>
And it helpfully tells you what versions of PHP and MySQL it is running too.
<ocdtrekkie>
I spent an hour trying to get Nginx to let me also run an app out of a different directory so I could pack in a couple management tools.
<ocdtrekkie>
Nginx confs now make me sad. And I gave up for now.
<ocdtrekkie>
Was hoping to maybe add permissions to a management tool and have it at /footgun-manager and keep that in the normal /opt/app directory.