Support non-TLD resolving / IP HostNames #566
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Using an SSH config block where the
Hostis a local / non-TLD resolving nameProduces the following error
When I add the following entry to my
/etc/hostsfileThis allows
abrato succeed in connecting to my serverI assume this is because
abrais doing (or not) something other CLI tools likesshorgitwhich can handle such non-resolvingHostvalues and just using the IP address.I think it would be nice for abra to handle such user configurations and not require users to add to their
/etc/hostsfile. The SSH documentation should reflect this constraint.abrarunsssh -G <hostname>under the hood and parses the output to grab the SSH details. It should have resolved this succesfully,--debugshould tell you more. I think it's an issue in theserver addimplementation, it demands that the domain it is passed be publicly reachable:0643df6d73/cli/server/add.go (L125-L179)It's trying to resolveeotl-sandbox. Shouldserver addalso perform assh -G ...trick to resolve the underlying SSH configHostname <...>entry foreotl-sandbox?Upon running
abra --debugon another server with the same SSH config block, it produces a bit more verbose feedback for debugging.Note: the stacktrace printed numerous
\nwhich failed to properly render as line breaks, but i'll open a separate issue for that.I'm not sure what you mean here!
abra server addreceiveseotl-sitesand checks, doeseotl-sitescorrespond to an ipv4 address? Then it fails. i'm proposing we adjust this functionality to check ifeotl-sitesmatches a SSH configHostentry and pull theHostnamefield to get the thing that does have a ipv4 address.I think this should work seamlessly and fix this issue.
An issue with allowing
Hostvalues like i'm using is when setting up apps liketraefikthe non-TLD hostname is shown, which is not ideal from DX (developer experience) perspective.Looking at the data added to
~/.abra/servers/eotl-sandbox/traefik.eotl-sandboxI see this:Which i'm assuming that will cause other problems once deployed. But maybe not? So we should probably make abra save the
Hostnamefield, which then MUST be a resolvable domain name, if I understand your comment above @decentral1seYes, Traefik would try to generate a certificate for
traefik.eotl-sandbox, will fail, so routing won't work.Is
49.12.102.35internet-accessible? If so then either using that as the server name, or adding a DNS record for it, would work.If not, we're in slightly uncharted territory with LAN/VPN-only apps; supporting them (e.g. using self-signed or manually-provided certs) is possible, but I think that a lot of Co-op Cloud implementation bakes in the assumption that apps are deployed on an internet-facing server, the changing of which might be a bit of an involved project.
Ah looks like this might be coming already in coop-cloud/abra#398?
Abra: support non-TLD resolving / IP HostNamesto Support non-TLD resolving / IP HostNamescoop-cloud/abra#415 allows you to
abra server add fooif you haveHost fooin your~/.ssh/config. Lemme know if that's going in the right direction for this ticket for now.@decentral1se oh, I see you addressed this issue here, which is what led me to filing #570 hrm... 🤔 I think need to go through the Tutorial and test various bespoke / failure states.
I'm leaving a note here that the docs need to updated as per #537