Description
At the time of writing, https://server.fission.dev/healthcheck reports {"database_connected":true,"database_up_to_date":true}
, but it's not actually all fine.
Here's some tests to make sure DNS is configured correctly:
origin_correct
: Check if the request's domain matches ourorigin
configured in the settingsorigin_ns_resolvable
: Check ifNS <origin>
at1.1.1.1
or8.8.8.8
or the system-based DNS resolver resolves to our IP address. This makes sure our DNS service is running and set up correctly.users_origin_ns_resolvable
: Check if we can DNS-resolveNS <users_origin>
(with 1.1.1.1 etc.) to make sure it resolves to our IP address.
I'm not 100% sure yet if these checks are the correct ones. E.g. what if we don't know our own IP address? Or if there's some forwarding going on.
Perhaps it makes more sense to try to resolve _did.<origin>
to see if it resolves as our own DID?
But what if there's two accidentally deploys with the same DID? Or an old deploy with the same DID is still cached?
Also, we don't have any TXT records on <users_origin>
by default. Perhaps we should add one? And call it _healthcheck
, make sure that it's set to an in-memory random variable and see if it resolves correctly?