Background:
Now that free wildcard certs are a thing, I figured I'd get my self-hosted Sandstorm instance actually working. Important context is that the machine in question is already running an Apache web server, which doesn't currently do HTTPS but I want to in the future, so I can't dedicate 80-and-443 to Sandstorm.
I could configure Apache (instead of nginx) as a reverse proxy with SSL, but I figured that would be hairy to configure and keep running, so I decided to just use another IP address -- which, with IPv6, isn't hard to get any more.
Since the old install predated Sandcats, I reran the installer. But of course since it doesn't know about my plans, it saw the conflict on port 80. I went with the alternate port and then edited the config file to:
SERVER_USER=sandstorm
PORT=80
HTTPS_PORT=443
MONGO_PORT=6081
BIND_IP=2600:3c03:e000:18c::1
BASE_URL=
https://switchborg.sandcats.io
WILDCARD_HOST=*.
switchborg.sandcats.io
UPDATE_CHANNEL=dev
ALLOW_DEV_ACCOUNTS=false
SANDCATS_BASE_DOMAIN=
sandcats.io
However, the server now won't start. /opt/sandstorm/var/log/sandstorm.log says:
sandstorm/util.c++:845: fatal: *exception = sandstorm/run-bundle.c++:1846: failed: bind(sockFd, reinterpret_cast<sockaddr *>(&sa), sizeof sa): Cannot assign requested address
stack: 0x4b48a2 0x4b485a 0x5944fe
** Front-end died immediately after starting.
Is Sandstorm not IPv6-clean?
Do I need to set some additional config option I missed?
(Is there a _reference_ for the config keys? I didn't find one.)
Am I doing something else wrong?
I've tried listening on the same address and port as
sudo nc -l -s 2600:3c03:e000:18c::1 -p 80
sudo nc -l -s 2600:3c03:e000:18c::1 -p 443
and it works, so the problem seems to be specific to Sandstorm.
--
Kevin Reid <
http://switchb.org/kpreid/>